-
Notifications
You must be signed in to change notification settings - Fork 4.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #38561 from alejands/piZeroTask_12_5_X
Incorporate PiZeroAnalyzer code into ECAL DQM
- Loading branch information
Showing
5 changed files
with
459 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,70 @@ | ||
#ifndef DQM_EcalMonitorTasks_PiZeroTask_H | ||
#define DQM_EcalMonitorTasks_PiZeroTask_H | ||
|
||
#include "DQM/EcalMonitorTasks/interface/DQWorkerTask.h" | ||
#include "DQM/EcalCommon/interface/EcalDQMCommonUtils.h" | ||
|
||
#include "DataFormats/EcalRawData/interface/EcalDCCHeaderBlock.h" | ||
#include "DataFormats/EcalRecHit/interface/EcalRecHitCollections.h" | ||
#include "Geometry/CaloTopology/interface/CaloSubdetectorTopology.h" | ||
#include "FWCore/ParameterSet/interface/ParameterSet.h" | ||
#include "RecoEcal/EgammaCoreTools/interface/PositionCalc.h" | ||
|
||
#include "TVector3.h" | ||
|
||
namespace ecaldqm { | ||
|
||
class PiZeroTask : public DQWorkerTask { | ||
public: | ||
PiZeroTask(); | ||
~PiZeroTask() override = default; | ||
|
||
bool filterRunType(short const*) override; | ||
bool analyze(void const*, Collections) override; | ||
void runOnEBRecHits(EcalRecHitCollection const&); | ||
|
||
private: | ||
void setParams(edm::ParameterSet const&) override; | ||
|
||
static const int MAXCLUS = 2000; | ||
static const int MAXPI0S = 200; | ||
|
||
// Parameters needed for pi0 finding | ||
double seleXtalMinEnergy_; | ||
|
||
double clusSeedThr_; | ||
int clusEtaSize_; | ||
int clusPhiSize_; | ||
|
||
double selePtGammaOne_; | ||
double selePtGammaTwo_; | ||
double seleS4S9GammaOne_; | ||
double seleS4S9GammaTwo_; | ||
double selePtPi0_; | ||
double selePi0Iso_; | ||
double selePi0BeltDR_; | ||
double selePi0BeltDeta_; | ||
double seleMinvMaxPi0_; | ||
double seleMinvMinPi0_; | ||
|
||
edm::ParameterSet posCalcParameters_; | ||
}; | ||
|
||
inline bool PiZeroTask::analyze(void const* collection_data, Collections collection) { | ||
switch (collection) { | ||
case kEBRecHit: | ||
if (collection_data) | ||
runOnEBRecHits(*static_cast<EcalRecHitCollection const*>(collection_data)); | ||
return true; | ||
case kEERecHit: // This module does not run on EERecHits | ||
break; | ||
default: | ||
break; | ||
} | ||
|
||
return false; | ||
} | ||
|
||
} // namespace ecaldqm | ||
|
||
#endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,95 @@ | ||
import FWCore.ParameterSet.Config as cms | ||
|
||
ecalPiZeroTask = cms.untracked.PSet( | ||
params = cms.untracked.PSet( | ||
# Parameters needed for pi0 finding | ||
seleXtalMinEnergy = cms.double(0.0), | ||
clusSeedThr = cms.double(0.5), | ||
clusEtaSize = cms.int32(3), | ||
clusPhiSize = cms.int32(3), | ||
selePtGammaOne = cms.double(0.9), | ||
selePtGammaTwo = cms.double(0.9), | ||
seleS4S9GammaOne = cms.double(0.85), | ||
seleS4S9GammaTwo = cms.double(0.85), | ||
selePtPi0 = cms.double(2.5), | ||
selePi0Iso = cms.double(0.5), | ||
selePi0BeltDR = cms.double(0.2), | ||
selePi0BeltDeta = cms.double(0.05), | ||
seleMinvMaxPi0 = cms.double(0.5), | ||
seleMinvMinPi0 = cms.double(0.0), | ||
posCalcParameters = cms.PSet(T0_barl = cms.double(5.7), | ||
T0_endc = cms.double(3.1), | ||
T0_endcPresh = cms.double(1.2), | ||
LogWeighted = cms.bool(True), | ||
W0 = cms.double(4.2), | ||
X0 = cms.double(0.89) | ||
), | ||
), | ||
MEs = cms.untracked.PSet( | ||
Pi0MinvEB = cms.untracked.PSet( | ||
path = cms.untracked.string('%(subdet)s/%(prefix)sPiZeroTask/%(prefix)sPZT%(suffix)s Pi0 Invariant Mass'), | ||
kind = cms.untracked.string('TH1F'), | ||
otype = cms.untracked.string('EB'), | ||
btype = cms.untracked.string('User'), | ||
xaxis = cms.untracked.PSet( | ||
nbins = cms.untracked.int32(100), | ||
low = cms.untracked.double(0.), | ||
high = cms.untracked.double(0.5), | ||
title = cms.untracked.string('Inv Mass [GeV]') | ||
), | ||
description = cms.untracked.string('Pi0 Invariant Mass in EB') | ||
), | ||
Pi0Pt1EB = cms.untracked.PSet( | ||
path = cms.untracked.string('%(subdet)s/%(prefix)sPiZeroTask/%(prefix)sPZT%(suffix)s Pi0 Pt 1st most energetic photon'), | ||
kind = cms.untracked.string('TH1F'), | ||
otype = cms.untracked.string('EB'), | ||
btype = cms.untracked.string('User'), | ||
xaxis = cms.untracked.PSet( | ||
nbins = cms.untracked.int32(100), | ||
low = cms.untracked.double(0.), | ||
high = cms.untracked.double(20.), | ||
title = cms.untracked.string('1st photon Pt [GeV]') | ||
), | ||
description = cms.untracked.string('Pt 1st most energetic Pi0 photon in EB') | ||
), | ||
Pi0Pt2EB = cms.untracked.PSet( | ||
path = cms.untracked.string('%(subdet)s/%(prefix)sPiZeroTask/%(prefix)sPZT%(suffix)s Pi0 Pt 2nd most energetic photon'), | ||
kind = cms.untracked.string('TH1F'), | ||
otype = cms.untracked.string('EB'), | ||
btype = cms.untracked.string('User'), | ||
xaxis = cms.untracked.PSet( | ||
nbins = cms.untracked.int32(100), | ||
low = cms.untracked.double(0.), | ||
high = cms.untracked.double(20.), | ||
title = cms.untracked.string('2nd photon Pt [GeV]') | ||
), | ||
description = cms.untracked.string('Pt 2nd most energetic Pi0 photon in EB') | ||
), | ||
Pi0PtEB = cms.untracked.PSet( | ||
path = cms.untracked.string('%(subdet)s/%(prefix)sPiZeroTask/%(prefix)sPZT%(suffix)s Pi0 Pt'), | ||
kind = cms.untracked.string('TH1F'), | ||
otype = cms.untracked.string('EB'), | ||
btype = cms.untracked.string('User'), | ||
xaxis = cms.untracked.PSet( | ||
nbins = cms.untracked.int32(100), | ||
low = cms.untracked.double(0.), | ||
high = cms.untracked.double(20.), | ||
title = cms.untracked.string('Pi0 Pt [GeV]') | ||
), | ||
description = cms.untracked.string('Pi0 Pt in EB') | ||
), | ||
Pi0IsoEB = cms.untracked.PSet( | ||
path = cms.untracked.string('%(subdet)s/%(prefix)sPiZeroTask/%(prefix)sPZT%(suffix)s Pi0 Iso'), | ||
kind = cms.untracked.string('TH1F'), | ||
otype = cms.untracked.string('EB'), | ||
btype = cms.untracked.string('User'), | ||
xaxis = cms.untracked.PSet( | ||
nbins = cms.untracked.int32(50), | ||
low = cms.untracked.double(0.), | ||
high = cms.untracked.double(1.), | ||
title = cms.untracked.string('Pi0 Iso') | ||
), | ||
description = cms.untracked.string('Pi0 Iso in EB') | ||
) | ||
) | ||
) |
Oops, something went wrong.