CMS 3D CMS Logo

List of all members | Public Member Functions | Private Types | Private Member Functions | Private Attributes | Static Private Attributes
CSCTriggerPrimitivesReader Class Reference

#include <CSCTriggerPrimitivesReader.h>

Inheritance diagram for CSCTriggerPrimitivesReader:
edm::EDAnalyzer edm::EDConsumerBase

Public Member Functions

void analyze (const edm::Event &event, const edm::EventSetup &setup) override
 Does the job. More...
 
int chamberIX (CSCDetId id)
 
int chamberIXi (CSCDetId id)
 
int chamberSerial (CSCDetId id)
 
 CSCTriggerPrimitivesReader (const edm::ParameterSet &conf)
 Constructor. More...
 
void endJob () override
 Write to ROOT file, make plots, etc. More...
 
void HotWires (const edm::Event &iEvent)
 
 ~CSCTriggerPrimitivesReader () override
 Destructor. More...
 
- Public Member Functions inherited from edm::EDAnalyzer
void callWhenNewProductsRegistered (std::function< void(BranchDescription const &)> const &func)
 
 EDAnalyzer ()
 
SerialTaskQueueglobalLuminosityBlocksQueue ()
 
SerialTaskQueueglobalRunsQueue ()
 
ModuleDescription const & moduleDescription () const
 
std::string workerType () const
 
 ~EDAnalyzer () override
 
- Public Member Functions inherited from edm::EDConsumerBase
std::vector< ConsumesInfoconsumesInfo () const
 
void convertCurrentProcessAlias (std::string const &processName)
 Convert "@currentProcess" in InputTag process names to the actual current process name. More...
 
 EDConsumerBase ()
 
 EDConsumerBase (EDConsumerBase &&)=default
 
 EDConsumerBase (EDConsumerBase const &)=delete
 
ESProxyIndex const * esGetTokenIndices (edm::Transition iTrans) const
 
std::vector< ESProxyIndex > const & esGetTokenIndicesVector (edm::Transition iTrans) const
 
std::vector< ESRecordIndex > const & esGetTokenRecordIndicesVector (edm::Transition iTrans) const
 
ProductResolverIndexAndSkipBit indexFrom (EDGetToken, BranchType, TypeID const &) const
 
void itemsMayGet (BranchType, std::vector< ProductResolverIndexAndSkipBit > &) const
 
void itemsToGet (BranchType, std::vector< ProductResolverIndexAndSkipBit > &) const
 
std::vector< ProductResolverIndexAndSkipBit > const & itemsToGetFrom (BranchType iType) const
 
void labelsForToken (EDGetToken iToken, Labels &oLabels) const
 
void modulesWhoseProductsAreConsumed (std::vector< ModuleDescription const * > &modules, ProductRegistry const &preg, std::map< std::string, ModuleDescription const * > const &labelsToDesc, std::string const &processName) const
 
EDConsumerBaseoperator= (EDConsumerBase &&)=default
 
EDConsumerBase const & operator= (EDConsumerBase const &)=delete
 
bool registeredToConsume (ProductResolverIndex, bool, BranchType) const
 
bool registeredToConsumeMany (TypeID const &, BranchType) const
 
ProductResolverIndexAndSkipBit uncheckedIndexFrom (EDGetToken) const
 
void updateLookup (BranchType iBranchType, ProductResolverIndexHelper const &, bool iPrefetchMayGet)
 
void updateLookup (eventsetup::ESRecordsToProxyIndices const &)
 
virtual ~EDConsumerBase () noexcept(false)
 

Private Types

enum  { MAXPAGES = 20 }
 
enum  trig_cscs { MAX_ENDCAPS = 2, MAX_STATIONS = 4, CSC_TYPES = 10 }
 

Private Member Functions

void bookALCTHistos ()
 
void bookCLCTHistos ()
 
void bookCompHistos ()
 
void bookEfficHistos ()
 
void bookHotWireHistos ()
 
void bookLCTMPCHistos ()
 
void bookLCTTMBHistos ()
 
void bookResolHistos ()
 
void calcEfficiency (const CSCALCTDigiCollection *alcts, const CSCCLCTDigiCollection *clcts, const edm::PSimHitContainer &allSimHits)
 
void calcResolution (const CSCALCTDigiCollection *alcts, const CSCCLCTDigiCollection *clcts, const CSCWireDigiCollection *wiredc, const CSCComparatorDigiCollection *compdc, const edm::PSimHitContainer &allSimHits)
 
void compare (const CSCALCTDigiCollection *alcts_data, const CSCALCTDigiCollection *alcts_emul, const CSCCLCTDigiCollection *clcts_data, const CSCCLCTDigiCollection *clcts_emul, const CSCCLCTPreTriggerDigiCollection *pretrigs_emul, const CSCCorrelatedLCTDigiCollection *lcts_data, const CSCCorrelatedLCTDigiCollection *lcts_emul)
 
void compareALCTs (const CSCALCTDigiCollection *alcts_data, const CSCALCTDigiCollection *alcts_emul)
 
void compareCLCTs (const CSCCLCTDigiCollection *clcts_data, const CSCCLCTDigiCollection *clcts_emul, const CSCCLCTPreTriggerDigiCollection *pretrigs_emul)
 
void compareLCTs (const CSCCorrelatedLCTDigiCollection *lcts_data, const CSCCorrelatedLCTDigiCollection *lcts_emul, const CSCALCTDigiCollection *alcts_data, const CSCCLCTDigiCollection *clcts_data)
 
void compareMPCLCTs (const CSCCorrelatedLCTDigiCollection *lcts_data, const CSCCorrelatedLCTDigiCollection *lcts_emul, const CSCALCTDigiCollection *alcts_data, const CSCCLCTDigiCollection *clcts_data)
 
int convertBXofLCT (const int emul_bx, const CSCDetId &detid, const CSCALCTDigiCollection *alcts_data, const CSCCLCTDigiCollection *clcts_data)
 
bool doesALCTCrossCLCT (CSCDetId id, int key_wg, int key_hs) const
 
void drawALCTHistos ()
 
void drawCLCTHistos ()
 
void drawCompHistos ()
 
void drawEfficHistos ()
 
void drawHistosForTalks ()
 
void drawLCTMPCHistos ()
 
void drawLCTTMBHistos ()
 
void drawResolHistos ()
 
void fillALCTHistos (const CSCALCTDigiCollection *alcts)
 
void fillCLCTHistos (const CSCCLCTDigiCollection *clcts)
 
void fillLCTMPCHistos (const CSCCorrelatedLCTDigiCollection *lcts)
 
void fillLCTTMBHistos (const CSCCorrelatedLCTDigiCollection *lcts)
 
int getCSCType (const CSCDetId &id)
 
GlobalPoint getGlobalPosition (unsigned int rawId, int keWg, int keyHS) const
 
double getHsPerRad (const int idh)
 
int maxRing (int station)
 
void MCStudies (const edm::Event &ev, const CSCALCTDigiCollection *alcts, const CSCCLCTDigiCollection *clcts)
 
void setRootStyle ()
 

Private Attributes

edm::EDGetTokenT< CSCALCTDigiCollectionalcts_d_token_
 
edm::EDGetTokenT< CSCALCTDigiCollectionalcts_e_token_
 
const CSCBadChambersbadChambers_
 
bool checkBadChambers_
 
edm::EDGetTokenT< CSCCLCTDigiCollectionclcts_d_token_
 
edm::EDGetTokenT< CSCCLCTDigiCollectionclcts_e_token_
 
edm::EDGetTokenT< CSCComparatorDigiCollectioncompDigi_token_
 
edm::InputTag compDigiProducer_
 
edm::ESGetToken< CSCGeometry, MuonGeometryRecordcscGeomToken_
 
bool dataIsAnotherMC_
 
bool dataLctsIn_
 
bool debug
 
bool emulLctsIn_
 
int Event_
 
TTree * event_tree [6]
 
int eventsAnalyzed
 
bool gangedME1a
 
const CSCGeometrygeom_
 
TH1F * hAlctAccel
 
TH1F * hAlctBXN
 
TH1F * hAlctCollis
 
TH1F * hAlctCompFound
 
TH2F * hAlctCompFound2
 
TH2F * hAlctCompFound2i
 
TH2F * hAlctCompFound2x
 
TH1F * hAlctCompFoundCsc [MAX_ENDCAPS][CSC_TYPES]
 
TH1F * hAlctCompMatch
 
TH2F * hAlctCompMatch2
 
TH2F * hAlctCompMatch2i
 
TH2F * hAlctCompMatch2x
 
TH1F * hAlctCompMatchCsc [MAX_ENDCAPS][CSC_TYPES]
 
TH1F * hAlctCompSameN
 
TH2F * hAlctCompSameN2
 
TH2F * hAlctCompSameN2i
 
TH2F * hAlctCompSameN2x
 
TH1F * hAlctCompSameNCsc [MAX_ENDCAPS][CSC_TYPES]
 
TH1F * hAlctCompTotal
 
TH2F * hAlctCompTotal2
 
TH2F * hAlctCompTotal2i
 
TH2F * hAlctCompTotal2x
 
TH1F * hAlctCompTotalCsc [MAX_ENDCAPS][CSC_TYPES]
 
TH1F * hAlctCsc [MAX_ENDCAPS][CSC_TYPES]
 
TH1F * hAlctKeyGroup
 
TH1F * hAlctKeyGroupME11
 
TH1F * hAlctPerChamber
 
TH1F * hAlctPerCSC
 
TH1F * hAlctPerEvent
 
TH1F * hAlctQuality
 
TH1F * hAlctValid
 
TH1F * hAlctVsEta [MAX_STATIONS]
 
TH1F * hClctBendCsc [CSC_TYPES][2]
 
TH1F * hClctBXN
 
TH1F * hClctCFEB
 
TH1F * hClctCompFound
 
TH2F * hClctCompFound2
 
TH2F * hClctCompFound2i
 
TH2F * hClctCompFound2x
 
TH1F * hClctCompFoundCsc [MAX_ENDCAPS][CSC_TYPES]
 
TH1F * hClctCompMatch
 
TH2F * hClctCompMatch2
 
TH2F * hClctCompMatch2i
 
TH2F * hClctCompMatch2x
 
TH1F * hClctCompMatchCsc [MAX_ENDCAPS][CSC_TYPES]
 
TH1F * hClctCompSameN
 
TH2F * hClctCompSameN2
 
TH2F * hClctCompSameN2i
 
TH2F * hClctCompSameN2x
 
TH1F * hClctCompSameNCsc [MAX_ENDCAPS][CSC_TYPES]
 
TH1F * hClctCompTotal
 
TH2F * hClctCompTotal2
 
TH2F * hClctCompTotal2i
 
TH2F * hClctCompTotal2x
 
TH1F * hClctCompTotalCsc [MAX_ENDCAPS][CSC_TYPES]
 
TH1F * hClctCsc [MAX_ENDCAPS][CSC_TYPES]
 
TH1F * hClctKeyStrip [2]
 
TH1F * hClctKeyStripCsc [CSC_TYPES]
 
TH1F * hClctKeyStripME11
 
TH1F * hClctPattern [2]
 
TH1F * hClctPerChamber
 
TH1F * hClctPerCSC
 
TH1F * hClctPerEvent
 
TH1F * hClctQuality
 
TH1F * hClctSign
 
TH1F * hClctStripType
 
TH1F * hClctValid
 
TH1F * hClctVsPhi [MAX_STATIONS]
 
TH1F * hCorrLctMPCPerCSC
 
TH1F * hCorrLctTMBPerCSC
 
TH1F * hEfficALCTEta [MAX_STATIONS]
 
TH1F * hEfficALCTEtaCsc [CSC_TYPES]
 
TH1F * hEfficCLCTEta [MAX_STATIONS]
 
TH1F * hEfficCLCTEtaCsc [CSC_TYPES]
 
TH1F * hEfficHitsEta [MAX_STATIONS]
 
TH1F * hEfficHitsEtaCsc [CSC_TYPES]
 
TH1F * hEtaDiffCsc [CSC_TYPES][3]
 
TH1F * hEtaDiffVsEta [MAX_STATIONS]
 
TH2F * hEtaDiffVsWireCsc [CSC_TYPES]
 
TH2F * hEtaRecVsSim
 
TH1F * hHotCham1
 
TH1F * hHotWire1
 
TH1F * hLCTCompFound
 
TH2F * hLCTCompFound2
 
TH2F * hLCTCompFound2i
 
TH2F * hLCTCompFound2x
 
TH1F * hLctCompFoundCsc [MAX_ENDCAPS][CSC_TYPES]
 
TH1F * hLCTCompMatch
 
TH2F * hLCTCompMatch2
 
TH2F * hLCTCompMatch2i
 
TH2F * hLCTCompMatch2x
 
TH1F * hLctCompMatchCsc [MAX_ENDCAPS][CSC_TYPES]
 
TH1F * hLCTCompSameN
 
TH2F * hLCTCompSameN2
 
TH2F * hLCTCompSameN2i
 
TH2F * hLCTCompSameN2x
 
TH1F * hLctCompSameNCsc [MAX_ENDCAPS][CSC_TYPES]
 
TH1F * hLCTCompTotal
 
TH2F * hLCTCompTotal2
 
TH2F * hLCTCompTotal2i
 
TH2F * hLCTCompTotal2x
 
TH1F * hLctCompTotalCsc [MAX_ENDCAPS][CSC_TYPES]
 
TH1F * hLctMPCBend
 
TH1F * hLctMPCBXN
 
TH1F * hLctMPCChamber [MAX_STATIONS]
 
TH1F * hLctMPCEndcap
 
TH1F * hLctMPCKeyGroup
 
TH1F * hLctMPCKeyGroupME11
 
TH1F * hLctMPCKeyStrip
 
TH1F * hLctMPCKeyStripME11
 
TH1F * hLctMPCPattern
 
TH1F * hLctMPCPerCSC
 
TH1F * hLctMPCPerEvent
 
TH1F * hLctMPCQuality
 
TH1F * hLctMPCRing
 
TH1F * hLctMPCSector
 
TH1F * hLctMPCStation
 
TH1F * hLctMPCStripType
 
TH1F * hLctMPCValid
 
TH1F * hLctTMBBend
 
TH1F * hLctTMBBXN
 
TH1F * hLctTMBChamber [MAX_STATIONS]
 
TH1F * hLctTMBCsc [MAX_ENDCAPS][CSC_TYPES]
 
TH1F * hLctTMBEndcap
 
TH1F * hLctTMBKeyGroup
 
TH1F * hLctTMBKeyGroupME11
 
TH1F * hLctTMBKeyStrip
 
TH1F * hLctTMBKeyStripME11
 
TH1F * hLctTMBPattern
 
TH1F * hLctTMBPerChamber
 
TH1F * hLctTMBPerCSC
 
TH1F * hLctTMBPerEvent
 
TH1F * hLctTMBQuality
 
TH1F * hLctTMBRing
 
TH1F * hLctTMBSector
 
TH1F * hLctTMBStation
 
TH1F * hLctTMBStripType
 
TH1F * hLctTMBValid
 
TH1F * hPhiDiffCsc [CSC_TYPES][5]
 
TH1F * hPhiDiffPattern [CSCConstants::NUM_CLCT_PATTERNS]
 
TH1F * hPhiDiffVsPhi [MAX_STATIONS]
 
TH2F * hPhiDiffVsStripCsc [CSC_TYPES][2]
 
TH2F * hPhiRecVsSim
 
TH1F * hResolDeltaDS
 
TH1F * hResolDeltaEta
 
TH1F * hResolDeltaHS
 
TH1F * hResolDeltaPhi
 
TH1F * hResolDeltaPhiDS
 
TH1F * hResolDeltaPhiHS
 
TH1F * hResolDeltaWG
 
TH1F * hTrueBendCsc [CSC_TYPES]
 
std::string lctProducerData_
 
std::string lctProducerEmul_
 
edm::EDGetTokenT< CSCCorrelatedLCTDigiCollectionlcts_mpc_d_token_
 
edm::EDGetTokenT< CSCCorrelatedLCTDigiCollectionlcts_mpc_e_token_
 
edm::EDGetTokenT< CSCCorrelatedLCTDigiCollectionlcts_tmb_d_token_
 
edm::EDGetTokenT< CSCCorrelatedLCTDigiCollectionlcts_tmb_e_token_
 
std::string mpclctProducerData_
 
edm::ESGetToken< CSCBadChambers, CSCBadChambersRcdpBadToken_
 
TreePerStub perStub [6]
 
bool plotME1A
 
bool plotME42
 
edm::EDGetTokenT< CSCCLCTPreTriggerDigiCollectionpretrigs_e_token_
 
std::string resultsFileNamesPrefix_
 
std::string rootFileName
 
int RUN_
 
edm::EDGetTokenT< edm::PSimHitContainersimHit_token_
 
edm::InputTag simHitProducer_
 
TTree * stub_tree [4]
 
MyStubComparison stubs_comparison [4]
 
edm::EDGetTokenT< CSCWireDigiCollectionwireDigi_token_
 
edm::InputTag wireDigiProducer_
 

Static Private Attributes

static bool bookedALCTHistos = false
 
static bool bookedCLCTHistos = false
 
static bool bookedCompHistos = false
 
static bool bookedEfficHistos = false
 
static bool bookedHotWireHistos = false
 
static bool bookedLCTMPCHistos = false
 
static bool bookedLCTTMBHistos = false
 
static bool bookedResolHistos = false
 
static const std::string csc_type [CSC_TYPES]
 
static const std::string csc_type_minus [CSC_TYPES]
 
static const std::string csc_type_plus [CSC_TYPES]
 
static const int lut_wg_vs_hs_me1a [48][2]
 
static const int lut_wg_vs_hs_me1ag [48][2]
 
static const int lut_wg_vs_hs_me1b [48][2]
 
static const int MAX_HS [CSC_TYPES]
 
static const int MAX_WG [CSC_TYPES]
 
static const int NCHAMBERS [CSC_TYPES] = {36, 36, 36, 36, 18, 36, 18, 36, 18, 36}
 
static int numALCT = 0
 
static int numCLCT = 0
 
static int numLCTMPC = 0
 
static int numLCTTMB = 0
 
static bool printps = false
 
static const int ptype_TMB07 [CSCConstants::NUM_CLCT_PATTERNS]
 
static const double TWOPI = 2. * M_PI
 

Additional Inherited Members

- Public Types inherited from edm::EDAnalyzer
typedef EDAnalyzer ModuleType
 
- Public Types inherited from edm::EDConsumerBase
typedef ProductLabels Labels
 
- Static Public Member Functions inherited from edm::EDAnalyzer
static const std::string & baseType ()
 
static void fillDescriptions (ConfigurationDescriptions &descriptions)
 
static void prevalidate (ConfigurationDescriptions &)
 
static bool wantsGlobalLuminosityBlocks ()
 
static bool wantsGlobalRuns ()
 
static bool wantsInputProcessBlocks ()
 
static bool wantsProcessBlocks ()
 
static bool wantsStreamLuminosityBlocks ()
 
static bool wantsStreamRuns ()
 
- Protected Member Functions inherited from edm::EDConsumerBase
EDGetToken consumes (const TypeToGet &id, edm::InputTag const &tag)
 
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > consumes (edm::InputTag const &tag)
 
template<BranchType B = InEvent>
EDConsumerBaseAdaptor< B > consumes (edm::InputTag tag) noexcept
 
template<BranchType B>
EDGetToken consumes (TypeToGet const &id, edm::InputTag const &tag)
 
ConsumesCollector consumesCollector ()
 Use a ConsumesCollector to gather consumes information from helper functions. More...
 
template<typename ProductType , BranchType B = InEvent>
void consumesMany ()
 
void consumesMany (const TypeToGet &id)
 
template<BranchType B>
void consumesMany (const TypeToGet &id)
 
template<typename ESProduct , typename ESRecord , Transition Tr = Transition::Event>
auto esConsumes ()
 
template<Transition Tr = Transition::Event>
constexpr auto esConsumes () noexcept
 
template<typename ESProduct , typename ESRecord , Transition Tr = Transition::Event>
auto esConsumes (ESInputTag const &tag)
 
template<Transition Tr = Transition::Event>
auto esConsumes (ESInputTag tag) noexcept
 
template<Transition Tr = Transition::Event>
ESGetTokenGeneric esConsumes (eventsetup::EventSetupRecordKey const &iRecord, eventsetup::DataKey const &iKey)
 Used with EventSetupRecord::doGet. More...
 
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 
template<BranchType B>
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > mayConsume (edm::InputTag const &tag)
 

Detailed Description

Basic analyzer class which accesses ALCTs, CLCTs, and correlated LCTs and plot various quantities.

Author
Slava Valuev, UCLA.

Definition at line 124 of file CSCTriggerPrimitivesReader.h.

Member Enumeration Documentation

◆ anonymous enum

anonymous enum
private
Enumerator
MAXPAGES 

Definition at line 208 of file CSCTriggerPrimitivesReader.h.

208 { MAXPAGES = 20 }; // max. number of pages in postscript files

◆ trig_cscs

Enumerator
MAX_ENDCAPS 
MAX_STATIONS 
CSC_TYPES 

Definition at line 207 of file CSCTriggerPrimitivesReader.h.

207 { MAX_ENDCAPS = 2, MAX_STATIONS = 4, CSC_TYPES = 10 };

Constructor & Destructor Documentation

◆ CSCTriggerPrimitivesReader()

CSCTriggerPrimitivesReader::CSCTriggerPrimitivesReader ( const edm::ParameterSet conf)
explicit

Constructor.

Definition at line 272 of file CSCTriggerPrimitivesReader.cc.

272  : eventsAnalyzed(0) {
274  // rootFileName = conf.getUntrackedParameter<string>("rootFileName","TPEHists.root");
275  // Create the root file for the histograms
276  // theFile = new TFile(rootFileName.c_str(), "RECREATE");
277  // theFile->cd();
278 
279  // Various input parameters.
280 
281  printps = conf.getParameter<bool>("printps");
282  dataLctsIn_ = conf.getParameter<bool>("dataLctsIn");
283  emulLctsIn_ = conf.getParameter<bool>("emulLctsIn");
284  edm::ParameterSet commonParams = conf.getParameter<edm::ParameterSet>("commonParam");
285 
286  // Switch for a new (2007) version of the TMB firmware.
287  gangedME1a = commonParams.getParameter<bool>("gangedME1a");
288 
289  // is it (non-upgrade algorithm) run along with upgrade one?
290  plotME1A = true;
291  plotME42 = true;
292  lctProducerData_ = conf.getUntrackedParameter<string>("CSCLCTProducerData", "cscunpacker");
293  mpclctProducerData_ = conf.getUntrackedParameter<string>("CSCMPCLCTProducerData", "csctfDigis");
294  lctProducerEmul_ = conf.getUntrackedParameter<string>("CSCLCTProducerEmul", "cscTriggerPrimitiveDigis");
295 
296  simHitProducer_ = conf.getParameter<edm::InputTag>("CSCSimHitProducer");
297  wireDigiProducer_ = conf.getParameter<edm::InputTag>("CSCWireDigiProducer");
298  compDigiProducer_ = conf.getParameter<edm::InputTag>("CSCComparatorDigiProducer");
299 
300  simHit_token_ = consumes<edm::PSimHitContainer>(simHitProducer_);
301  wireDigi_token_ = consumes<CSCWireDigiCollection>(wireDigiProducer_);
302  compDigi_token_ = consumes<CSCComparatorDigiCollection>(compDigiProducer_);
303 
304  alcts_d_token_ = consumes<CSCALCTDigiCollection>(edm::InputTag(lctProducerData_, "MuonCSCALCTDigi"));
305  clcts_d_token_ = consumes<CSCCLCTDigiCollection>(edm::InputTag(lctProducerData_, "MuonCSCCLCTDigi"));
307  consumes<CSCCorrelatedLCTDigiCollection>(edm::InputTag(lctProducerData_, "MuonCSCCorrelatedLCTDigi"));
308  lcts_mpc_d_token_ = consumes<CSCCorrelatedLCTDigiCollection>(edm::InputTag(mpclctProducerData_));
309 
310  alcts_e_token_ = consumes<CSCALCTDigiCollection>(edm::InputTag(lctProducerEmul_));
311  clcts_e_token_ = consumes<CSCCLCTDigiCollection>(edm::InputTag(lctProducerEmul_));
312  pretrigs_e_token_ = consumes<CSCCLCTPreTriggerDigiCollection>(edm::InputTag(lctProducerEmul_));
313  lcts_tmb_e_token_ = consumes<CSCCorrelatedLCTDigiCollection>(edm::InputTag(lctProducerEmul_));
314  lcts_mpc_e_token_ = consumes<CSCCorrelatedLCTDigiCollection>(edm::InputTag(lctProducerEmul_, "MPCSORTED"));
315  cscGeomToken_ = esConsumes<CSCGeometry, MuonGeometryRecord>();
316  pBadToken_ = esConsumes<CSCBadChambers, CSCBadChambersRcd>();
317 
318  consumesMany<edm::HepMCProduct>();
319  resultsFileNamesPrefix_ = conf.getUntrackedParameter<string>("resultsFileNamesPrefix", "");
320  checkBadChambers_ = conf.getUntrackedParameter<bool>("checkBadChambers", true);
321  debug = conf.getUntrackedParameter<bool>("debug", false);
322  dataIsAnotherMC_ = conf.getUntrackedParameter<bool>("dataIsAnotherMC", false);
323 
324  //rootFileName = conf.getUntrackedParameter<string>("rootFileName");
325  // Create the root file.
326  // Not sure we really need it - comment out for now. -Slava.
327  //theFile = new TFile(rootFileName.c_str(), "RECREATE");
328  //theFile->cd();
329  stub_tree[0] = stubs_comparison[0].bookTree(stub_tree[0], "alcttree");
330  stub_tree[1] = stubs_comparison[1].bookTree(stub_tree[1], "clcttree");
331  stub_tree[2] = stubs_comparison[2].bookTree(stub_tree[2], "lcttree");
332  stub_tree[3] = stubs_comparison[3].bookTree(stub_tree[3], "mpclcttree");
333  // Per event TTree
334  event_tree[0] = perStub[0].bookTree(event_tree[0], "Ev_alcttree");
335  event_tree[1] = perStub[1].bookTree(event_tree[1], "Ev_emul_alcttree");
336  event_tree[2] = perStub[2].bookTree(event_tree[2], "Ev_clcttree");
337  event_tree[3] = perStub[3].bookTree(event_tree[3], "Ev_emul_clcttree");
338  event_tree[4] = perStub[4].bookTree(event_tree[4], "Ev_lcttree");
339  event_tree[5] = perStub[5].bookTree(event_tree[5], "Ev_emul_lcttree");
340  // My favourite ROOT settings.
341  setRootStyle();
342 }

References alcts_d_token_, alcts_e_token_, TreePerStub::bookTree(), MyStubComparison::bookTree(), checkBadChambers_, clcts_d_token_, clcts_e_token_, compDigi_token_, compDigiProducer_, cscGeomToken_, dataIsAnotherMC_, dataLctsIn_, debug, emulLctsIn_, event_tree, gangedME1a, edm::ParameterSet::getParameter(), edm::ParameterSet::getUntrackedParameter(), lctProducerData_, lctProducerEmul_, lcts_mpc_d_token_, lcts_mpc_e_token_, lcts_tmb_d_token_, lcts_tmb_e_token_, mpclctProducerData_, pBadToken_, perStub, plotME1A, plotME42, pretrigs_e_token_, printps, resultsFileNamesPrefix_, setRootStyle(), simHit_token_, simHitProducer_, stub_tree, stubs_comparison, wireDigi_token_, and wireDigiProducer_.

◆ ~CSCTriggerPrimitivesReader()

CSCTriggerPrimitivesReader::~CSCTriggerPrimitivesReader ( )
override

Destructor.

Definition at line 347 of file CSCTriggerPrimitivesReader.cc.

347  {
348  // histos->writeHists(theFile);
349  // theFile->Close();
350  //delete theFile;
351 }

Member Function Documentation

◆ analyze()

void CSCTriggerPrimitivesReader::analyze ( const edm::Event event,
const edm::EventSetup setup 
)
overridevirtual

Does the job.

Implements edm::EDAnalyzer.

Definition at line 363 of file CSCTriggerPrimitivesReader.cc.

363  {
364  ++eventsAnalyzed;
365  //if (ev.id().event()%10 == 0)
366  LogTrace("CSCTriggerPrimitivesReader") << "\n** CSCTriggerPrimitivesReader: processing run #" << ev.id().run()
367  << " event #" << ev.id().event() << "; events so far: " << eventsAnalyzed
368  << " **";
369  RUN_ = ev.id().run();
370  Event_ = ev.id().event();
371 
372  // Find the geometry for this event & cache it. Needed in LCTAnalyzer
373  // modules.
374  edm::ESHandle<CSCGeometry> cscGeom = setup.getHandle(cscGeomToken_);
375  geom_ = &*cscGeom;
376 
377  // Find conditions data for bad chambers & cache it. Needed for efficiency
378  // calculations.
379  if (checkBadChambers_) {
381  badChambers_ = pBad.product();
382  }
383 
384  // Get the collections of ALCTs, CLCTs, and correlated LCTs from event.
394 
395  // Data
396  if (dataLctsIn_) {
397  HotWires(ev);
398  // ev.getByLabel(lctProducerData_, alcts_data);
399  // ev.getByLabel(lctProducerData_, clcts_data);
400  // ev.getByLabel(lctProducerData_, lcts_tmb_data);
401  ev.getByToken(alcts_d_token_, alcts_data);
402  ev.getByToken(clcts_d_token_, clcts_data);
403  ev.getByToken(lcts_tmb_d_token_, lcts_tmb_data);
404  ev.getByToken(lcts_mpc_d_token_, lcts_mpc_data);
405 
406  if (!alcts_data.isValid()) {
407  edm::LogWarning("L1CSCTPEmulatorWrongInput")
408  << "+++ Warning: Collection of ALCTs with label MuonCSCALCTDigi"
409  << " requested, but not found in the event... Skipping the rest +++\n";
410  return;
411  }
412  if (!clcts_data.isValid()) {
413  edm::LogWarning("L1CSCTPEmulatorWrongInput")
414  << "+++ Warning: Collection of CLCTs with label MuonCSCCLCTDigi"
415  << " requested, but not found in the event... Skipping the rest +++\n";
416  return;
417  }
418  if (!lcts_tmb_data.isValid()) {
419  edm::LogWarning("L1CSCTPEmulatorWrongInput") << "+++ Warning: Collection of correlated LCTs with label"
420  << " MuonCSCCorrelatedLCTDigi requested, but not found in the"
421  << " event... Skipping the rest +++\n";
422  return;
423  }
424  /*
425  if (!lcts_mpc_data.isValid()) {
426  edm::LogWarning("L1CSCTPEmulatorWrongInput")
427  << "+++ Warning: Collection of MPC correlated LCTs with label"
428  << " MuonCSCCorrelatedLCTDigi + MCPSorted requested, but not found in the"
429  << " event... Skipping the rest +++\n";
430  //return;
431  }*/
432  }
433 
434  // Emulator
435  if (emulLctsIn_) {
436  // ev.getByLabel(lctProducerEmul_, alcts_emul);
437  // ev.getByLabel(lctProducerEmul_, clcts_emul);
438  // ev.getByLabel(lctProducerEmul_, lcts_tmb_emul);
439  // ev.getByLabel(lctProducerEmul_, "MPCSORTED", lcts_mpc_emul);
440  ev.getByToken(alcts_e_token_, alcts_emul);
441  ev.getByToken(clcts_e_token_, clcts_emul);
442  ev.getByToken(pretrigs_e_token_, pretrigs_emul);
443  ev.getByToken(lcts_tmb_e_token_, lcts_tmb_emul);
444  ev.getByToken(lcts_mpc_e_token_, lcts_mpc_emul);
445 
446  if (!alcts_emul.isValid()) {
447  edm::LogWarning("L1CSCTPEmulatorWrongInput")
448  << "+++ Warning: Collection of emulated ALCTs"
449  << " requested, but not found in the event... Skipping the rest +++\n";
450  return;
451  }
452  if (!clcts_emul.isValid()) {
453  edm::LogWarning("L1CSCTPEmulatorWrongInput")
454  << "+++ Warning: Collection of emulated CLCTs"
455  << " requested, but not found in the event... Skipping the rest +++\n";
456  return;
457  }
458  if (!lcts_tmb_emul.isValid()) {
459  edm::LogWarning("L1CSCTPEmulatorWrongInput")
460  << "+++ Warning: Collection of emulated correlated LCTs"
461  << " requested, but not found in the event... Skipping the rest +++\n";
462  return;
463  }
464  /*
465  if (!lcts_mpc_emul.isValid()) {
466  edm::LogWarning("L1CSCTPEmulatorWrongInput")
467  << "+++ Warning: Collection of emulated correlated LCTs (MPCs)"
468  << " requested, but not found in the event... Skipping the rest +++\n";
469  //return;
470  }*/
471  }
472 
473  // Fill histograms with reconstructed or emulated quantities. If both are
474  // present, plot LCTs in data.
475  if (dataLctsIn_) {
476  fillALCTHistos(alcts_data.product());
477  fillCLCTHistos(clcts_data.product());
478  fillLCTTMBHistos(lcts_tmb_data.product());
479  } else if (emulLctsIn_) {
480  fillALCTHistos(alcts_emul.product());
481  fillCLCTHistos(clcts_emul.product());
482  fillLCTTMBHistos(lcts_tmb_emul.product());
483  //fillLCTMPCHistos(lcts_mpc_emul.product());
484  }
485 
486  // Compare LCTs in the data with the ones produced by the emulator.
487  if (dataLctsIn_ && emulLctsIn_) {
488  compare(alcts_data.product(),
489  alcts_emul.product(),
490  clcts_data.product(),
491  clcts_emul.product(),
492  pretrigs_emul.product(),
493  lcts_tmb_data.product(),
494  lcts_tmb_emul.product());
495  }
496  // Fill MC-based resolution/efficiency histograms, if needed.
497  if (emulLctsIn_) {
498  MCStudies(ev, alcts_emul.product(), clcts_emul.product());
499  }
500 } // analyze

References alcts_d_token_, alcts_e_token_, badChambers_, checkBadChambers_, clcts_d_token_, clcts_e_token_, compare(), cscGeomToken_, dataLctsIn_, emulLctsIn_, ev, Event_, eventsAnalyzed, fillALCTHistos(), fillCLCTHistos(), fillLCTTMBHistos(), geom_, HotWires(), edm::HandleBase::isValid(), lcts_mpc_d_token_, lcts_mpc_e_token_, lcts_tmb_d_token_, lcts_tmb_e_token_, LogTrace, MCStudies(), pBadToken_, pretrigs_e_token_, edm::Handle< T >::product(), edm::ESHandle< T >::product(), RUN_, and singleTopDQM_cfi::setup.

◆ bookALCTHistos()

void CSCTriggerPrimitivesReader::bookALCTHistos ( )
private

Definition at line 637 of file CSCTriggerPrimitivesReader.cc.

637  {
638  string s;
639 
641  hAlctPerEvent = fs->make<TH1F>("ALCTs_per_event", "ALCTs per event", 31, -0.5, 30.5);
642  hAlctPerChamber = fs->make<TH1F>("ALCTs_per_chamber", "ALCTs per chamber", 4, -0.5, 3.5);
643  hAlctPerCSC = fs->make<TH1F>("ALCTs_per_CSCtype", "ALCTs per CSC type", 10, -0.5, 9.5);
644  for (int i = 0; i < MAX_ENDCAPS; i++) { // endcaps
645  for (int j = 0; j < CSC_TYPES; j++) { // station/ring
646  float csc_max = NCHAMBERS[j] + 0.5;
647  char asdf[256];
648  sprintf(asdf, "ALCTs_%i", i * CSC_TYPES + j);
649  if (i == 0)
650  s = "ALCTs, " + csc_type_plus[j];
651  else
652  s = "ALCTs, " + csc_type_minus[j];
653  hAlctCsc[i][j] = fs->make<TH1F>(asdf, s.c_str(), NCHAMBERS[j], 0.5, csc_max);
654  }
655  }
656 
657  hAlctValid = fs->make<TH1F>("ALCT_validity", "ALCT validity", 3, -0.5, 2.5);
658  hAlctQuality = fs->make<TH1F>("ALCT_quality", "ALCT quality", 5, -0.5, 4.5);
659  hAlctAccel = fs->make<TH1F>("ALCT_accel_flag", "ALCT accel. flag", 3, -0.5, 2.5);
660  hAlctCollis = fs->make<TH1F>("ALCT_collision_flag", "ALCT collision. flag", 3, -0.5, 2.5);
661  hAlctKeyGroup = fs->make<TH1F>("ALCT_key_wiregroup", "ALCT key wiregroup", 120, -0.5, 119.5);
662  hAlctBXN = fs->make<TH1F>("ALCT_bx", "ALCT bx", 20, -0.5, 19.5);
663 
664  hAlctKeyGroupME11 = fs->make<TH1F>("hAlctKeyGroupME11", "ALCT key wiregroup ME1/1", 50, -0.5, 49.5);
665 
666  bookedALCTHistos = true;
667  std::cout << " bookedALCTHistos " << std::endl;
668 }

References bookedALCTHistos, gather_cfg::cout, csc_type_minus, csc_type_plus, CSC_TYPES, hAlctAccel, hAlctBXN, hAlctCollis, hAlctCsc, hAlctKeyGroup, hAlctKeyGroupME11, hAlctPerChamber, hAlctPerCSC, hAlctPerEvent, hAlctQuality, hAlctValid, mps_fire::i, dqmiolumiharvest::j, TFileService::make(), MAX_ENDCAPS, NCHAMBERS, and alignCSCRings::s.

Referenced by fillALCTHistos().

◆ bookCLCTHistos()

void CSCTriggerPrimitivesReader::bookCLCTHistos ( )
private

Definition at line 670 of file CSCTriggerPrimitivesReader.cc.

670  {
671  string s;
672 
674  hClctPerEvent = fs->make<TH1F>("CLCTs_per_event", "CLCTs per event", 31, -0.5, 30.5);
675  hClctPerChamber = fs->make<TH1F>("CLCTs_per_chamber", "CLCTs per chamber", 3, -0.5, 2.5);
676  hClctPerCSC = fs->make<TH1F>("CLCTs_per_CSCtype", "CLCTs per CSC type", 10, -0.5, 9.5);
677  for (int i = 0; i < MAX_ENDCAPS; i++) { // endcaps
678  for (int j = 0; j < CSC_TYPES; j++) { // station/ring
679  char asdf[256];
680  sprintf(asdf, "CLCTs_%i", i * CSC_TYPES + j);
681  float csc_max = NCHAMBERS[j] + 0.5;
682  if (i == 0)
683  s = "CLCTs, " + csc_type_plus[j];
684  else
685  s = "CLCTs, " + csc_type_minus[j];
686  hClctCsc[i][j] = fs->make<TH1F>(asdf, s.c_str(), NCHAMBERS[j], 0.5, csc_max);
687  }
688  }
689 
690  hClctValid = fs->make<TH1F>("CLCT_validity", "CLCT validity", 3, -0.5, 2.5);
691  hClctQuality = fs->make<TH1F>("CLCT_layers_hit", "CLCT layers hit", 9, -0.5, 8.5);
692  hClctStripType = fs->make<TH1F>("CLCT_strip_type", "CLCT strip type", 3, -0.5, 2.5);
693  hClctSign = fs->make<TH1F>("CLCT_sing_(L/R)", "CLCT sign (L/R)", 3, -0.5, 2.5);
694  hClctCFEB = fs->make<TH1F>("CLCT_cfeb_#", "CLCT cfeb #", 6, -0.5, 5.5);
695  hClctBXN = fs->make<TH1F>("CLCT_bx", "CLCT bx", 20, -0.5, 19.5);
696 
697  hClctKeyStrip[0] = fs->make<TH1F>("CLCT_keystrip_distrips", "CLCT keystrip, distrips", 40, -0.5, 39.5);
698  //hClctKeyStrip[0] = fs->make<TH1F>("","CLCT keystrip, distrips", 160, -0.5, 159.5);
699  hClctKeyStrip[1] = fs->make<TH1F>("CLCT_keystrip_halfstrips", "CLCT keystrip, halfstrips", 160, -0.5, 159.5);
700  hClctPattern[0] = fs->make<TH1F>("CLCT_pattern_distrips", "CLCT pattern, distrips", 13, -0.5, 12.5);
701  hClctPattern[1] = fs->make<TH1F>("CLCT_pattern_halfstrips", "CLCT pattern, halfstrips", 13, -0.5, 12.5);
702 
703  for (int i = 0; i < CSC_TYPES; i++) {
704  char asdf[256];
705  string s1 = "CLCT bend, " + csc_type[i];
706  sprintf(asdf, "CLCT_bend0_%i", i + 1);
707  hClctBendCsc[i][0] = fs->make<TH1F>(asdf, s1.c_str(), 5, -0.5, 4.5);
708  sprintf(asdf, "CLCT_bend1_%i", i + 1);
709  hClctBendCsc[i][1] = fs->make<TH1F>(asdf, s1.c_str(), 5, -0.5, 4.5);
710 
711  sprintf(asdf, "CLCT_keystrip_%i", i + 1);
712  string s2 = "CLCT keystrip, " + csc_type[i];
713  int max_ds = MAX_HS[i] / 4;
714  hClctKeyStripCsc[i] = fs->make<TH1F>(asdf, s2.c_str(), max_ds, 0., max_ds);
715  }
716 
717  hClctKeyStripME11 = fs->make<TH1F>("hClctKeyStripME11", "CLCT keystrip, halfstrips ME1/1", 161, -0.5, 160.5);
718 
719  bookedCLCTHistos = true;
720  std::cout << " bookedCLCTHistos " << std::endl;
721 }

References bookedCLCTHistos, gather_cfg::cout, csc_type, csc_type_minus, csc_type_plus, CSC_TYPES, hClctBendCsc, hClctBXN, hClctCFEB, hClctCsc, hClctKeyStrip, hClctKeyStripCsc, hClctKeyStripME11, hClctPattern, hClctPerChamber, hClctPerCSC, hClctPerEvent, hClctQuality, hClctSign, hClctStripType, hClctValid, mps_fire::i, dqmiolumiharvest::j, TFileService::make(), MAX_ENDCAPS, MAX_HS, NCHAMBERS, alignCSCRings::s, and indexGen::s2.

Referenced by fillCLCTHistos().

◆ bookCompHistos()

void CSCTriggerPrimitivesReader::bookCompHistos ( )
private

Definition at line 863 of file CSCTriggerPrimitivesReader.cc.

863  {
864  string s;
865 
867  // hAlctCompMatch;
868 
869  hAlctCompFound = fs->make<TH1F>("h_ALCT_found", "h_ALCT_found", 600, 0.5, 600.5);
870  hAlctCompFound2 = fs->make<TH2F>("h_ALCT_found2", "h_ALCT_found2", 19, -9.5, 9.5, 36, 0.5, 36.5);
871  hAlctCompFound2x = fs->make<TH2F>("h_ALCT_found2x", "h_ALCT_found2x", 19, -9.5, 9.5, 18, 0.5, 36.5);
872 
873  hAlctCompSameN = fs->make<TH1F>("h_ALCT_SameN", "h_ALCT_SameN", 600, 0.5, 600.5);
874  hAlctCompSameN2 = fs->make<TH2F>("h_ALCT_SameN2", "h_ALCT_SameN2", 19, -9.5, 9.5, 36, 0.5, 36.5);
875  hAlctCompSameN2x = fs->make<TH2F>("h_ALCT_SameN2x", "h_ALCT_SameN2x", 19, -9.5, 9.5, 18, 0.5, 36.5);
876 
877  hAlctCompMatch = fs->make<TH1F>("h_ALCT_match", "h_ALCT_match", 600, 0.5, 600.5);
878  hAlctCompMatch2 = fs->make<TH2F>("h_ALCT_match2", "h_ALCT_match2", 19, -9.5, 9.5, 36, 0.5, 36.5);
879  hAlctCompMatch2x = fs->make<TH2F>("h_ALCT_match2x", "h_ALCT_match2x", 19, -9.5, 9.5, 18, 0.5, 36.5);
880 
881  hAlctCompTotal = fs->make<TH1F>("h_ALCT_total", "h_ALCT_total", 600, 0.5, 600.5);
882  hAlctCompTotal2 = fs->make<TH2F>("h_ALCT_total2", "h_ALCT_total2", 19, -9.5, 9.5, 36, 0.5, 36.5);
883  hAlctCompTotal2x = fs->make<TH2F>("h_ALCT_total2x", "h_ALCT_total2x", 19, -9.5, 9.5, 18, 0.5, 36.5);
884 
885  hClctCompFound = fs->make<TH1F>("h_CLCT_found", "h_CLCT_found", 600, 0.5, 600.5);
886  hClctCompFound2 = fs->make<TH2F>("h_CLCT_found2", "h_CLCT_found2", 19, -9.5, 9.5, 36, 0.5, 36.5);
887  hClctCompFound2x = fs->make<TH2F>("h_CLCT_found2x", "h_CLCT_found2x", 19, -9.5, 9.5, 18, 0.5, 36.5);
888 
889  hClctCompSameN = fs->make<TH1F>("h_CLCT_SameN", "h_CLCT_SameN", 600, 0.5, 600.5);
890  hClctCompSameN2 = fs->make<TH2F>("h_CLCT_SameN2", "h_CLCT_SameN2", 19, -9.5, 9.5, 36, 0.5, 36.5);
891  hClctCompSameN2x = fs->make<TH2F>("h_CLCT_SameN2x", "h_CLCT_SameN2x", 19, -9.5, 9.5, 18, 0.5, 36.5);
892 
893  hClctCompMatch = fs->make<TH1F>("h_CLCT_match", "h_CLCT_match", 600, 0.5, 600.5);
894  hClctCompMatch2 = fs->make<TH2F>("h_CLCT_match2", "h_CLCT_match2", 19, -9.5, 9.5, 36, 0.5, 36.5);
895  hClctCompMatch2x = fs->make<TH2F>("h_CLCT_match2x", "h_CLCT_match2x", 19, -9.5, 9.5, 18, 0.5, 36.5);
896 
897  hClctCompTotal = fs->make<TH1F>("h_CLCT_total", "h_CLCT_total", 600, 0.5, 600.5);
898  hClctCompTotal2 = fs->make<TH2F>("h_CLCT_total2", "h_CLCT_total2", 19, -9.5, 9.5, 36, 0.5, 36.5);
899  hClctCompTotal2x = fs->make<TH2F>("h_CLCT_total2x", "h_CLCT_total2x", 19, -9.5, 9.5, 18, 0.5, 36.5);
900 
901  hLCTCompFound = fs->make<TH1F>("h_LCT_found", "h_LCT_found", 600, 0.5, 600.5);
902  hLCTCompFound2 = fs->make<TH2F>("h_LCT_found2", "h_LCT_found2", 19, -9.5, 9.5, 36, 0.5, 36.5);
903  hLCTCompFound2x = fs->make<TH2F>("h_LCT_found2x", "h_LCT_found2x", 19, -9.5, 9.5, 18, 0.5, 36.5);
904 
905  hLCTCompSameN = fs->make<TH1F>("h_LCT_SameN", "h_LCT_SameN", 600, 0.5, 600.5);
906  hLCTCompSameN2 = fs->make<TH2F>("h_LCT_SameN2", "h_LCT_SameN2", 19, -9.5, 9.5, 36, 0.5, 36.5);
907  hLCTCompSameN2x = fs->make<TH2F>("h_LCT_SameN2x", "h_LCT_SameN2x", 19, -9.5, 9.5, 18, 0.5, 36.5);
908 
909  hLCTCompMatch = fs->make<TH1F>("h_LCT_match", "h_LCT_match", 600, 0.5, 600.5);
910  hLCTCompMatch2 = fs->make<TH2F>("h_LCT_match2", "h_LCT_match2", 19, -9.5, 9.5, 36, 0.5, 36.5);
911  hLCTCompMatch2x = fs->make<TH2F>("h_LCT_match2x", "h_LCT_match2x", 19, -9.5, 9.5, 18, 0.5, 36.5);
912 
913  hLCTCompTotal = fs->make<TH1F>("h_LCT_total", "h_LCT_total", 600, 0.5, 600.5);
914  hLCTCompTotal2 = fs->make<TH2F>("h_LCT_total2", "h_LCT_total2", 19, -9.5, 9.5, 36, 0.5, 36.5);
915  hLCTCompTotal2x = fs->make<TH2F>("h_LCT_total2x", "h_LCT_total2x", 19, -9.5, 9.5, 18, 0.5, 36.5);
916 
917  //Chad's improved historgrams
918  hAlctCompFound2i = fs->make<TH2F>("h_ALCT_found2i", "h_ALCT_found2i", 18, 0, 18, 36, 0.5, 36.5);
919  hAlctCompSameN2i = fs->make<TH2F>("h_ALCT_SameN2i", "h_ALCT_SameN2i", 18, 0, 18, 36, 0.5, 36.5);
920  hAlctCompMatch2i = fs->make<TH2F>("h_ALCT_match2i", "h_ALCT_match2i", 18, 0, 18, 36, 0.5, 36.5);
921  hAlctCompTotal2i = fs->make<TH2F>("h_ALCT_total2i", "h_ALCT_total2i", 18, 0, 18, 36, 0.5, 36.5);
922  hClctCompFound2i = fs->make<TH2F>("h_CLCT_found2i", "h_CLCT_found2i", 18, 0, 18, 36, 0.5, 36.5);
923  hClctCompSameN2i = fs->make<TH2F>("h_CLCT_SameN2i", "h_CLCT_SameN2i", 18, 0, 18, 36, 0.5, 36.5);
924  hClctCompMatch2i = fs->make<TH2F>("h_CLCT_match2i", "h_CLCT_match2i", 18, 0, 18, 36, 0.5, 36.5);
925  hClctCompTotal2i = fs->make<TH2F>("h_CLCT_total2i", "h_CLCT_total2i", 18, 0, 18, 36, 0.5, 36.5);
926  hLCTCompFound2i = fs->make<TH2F>("h_LCT_found2i", "h_LCT_found2i", 18, 0, 18, 36, 0.5, 36.5);
927  hLCTCompSameN2i = fs->make<TH2F>("h_LCT_SameN2i", "h_LCT_SameN2i", 18, 0, 18, 36, 0.5, 36.5);
928  hLCTCompMatch2i = fs->make<TH2F>("h_LCT_match2i", "h_LCT_match2i", 18, 0, 18, 36, 0.5, 36.5);
929  hLCTCompTotal2i = fs->make<TH2F>("h_LCT_total2i", "h_LCT_total2i", 18, 0, 18, 36, 0.5, 36.5);
930 
931  // hAlctCompFound = fs->make<TH1F>("h_ALCT_found","h_ALCT_found",600,0.5,600.5);
932 
933  // ALCTs.
934  for (int i = 0; i < MAX_ENDCAPS; i++) { // endcaps
935  for (int j = 0; j < CSC_TYPES; j++) { // station/ring
936  char asdf[256];
937 
938  float csc_max = NCHAMBERS[j] + 0.5;
939  if (i == 0)
940  s = "Comp_ALCTs, " + csc_type_plus[j];
941  else
942  s = "Comp_ALCTs, " + csc_type_minus[j];
943  sprintf(asdf, "Comp_ALCTsFound_%i", i * CSC_TYPES + j);
944  hAlctCompFoundCsc[i][j] = fs->make<TH1F>(asdf, s.c_str(), NCHAMBERS[j], 0.5, csc_max);
945  sprintf(asdf, "Comp_ALCTsSame_%i", i * CSC_TYPES + j);
946  hAlctCompSameNCsc[i][j] = fs->make<TH1F>(asdf, s.c_str(), NCHAMBERS[j], 0.5, csc_max);
947  sprintf(asdf, "Comp_ALCTsTotal_%i", i * CSC_TYPES + j);
948  hAlctCompTotalCsc[i][j] = fs->make<TH1F>(asdf, s.c_str(), NCHAMBERS[j], 0.5, csc_max);
949  sprintf(asdf, "Comp_ALCTsMatch_%i", i * CSC_TYPES + j);
950  hAlctCompMatchCsc[i][j] = fs->make<TH1F>(asdf, s.c_str(), NCHAMBERS[j], 0.5, csc_max);
951  hAlctCompFoundCsc[i][j]->Sumw2();
952  hAlctCompSameNCsc[i][j]->Sumw2();
953  hAlctCompTotalCsc[i][j]->Sumw2();
954  hAlctCompMatchCsc[i][j]->Sumw2();
955  }
956  }
957 
958  // CLCTs.
959  for (int i = 0; i < MAX_ENDCAPS; i++) { // endcaps
960  for (int j = 0; j < CSC_TYPES; j++) { // station/ring
961  float csc_max = NCHAMBERS[j] + 0.5;
962  char asdf[256];
963  if (i == 0)
964  s = "Comp_CLCTs, " + csc_type_plus[j];
965  else
966  s = "Comp_CLCTs, " + csc_type_minus[j];
967  sprintf(asdf, "Comp_CLCTsFound_%i", i * CSC_TYPES + j);
968  hClctCompFoundCsc[i][j] = fs->make<TH1F>(asdf, s.c_str(), NCHAMBERS[j], 0.5, csc_max);
969  sprintf(asdf, "Comp_CLCTsSame_%i", i * CSC_TYPES + j);
970  hClctCompSameNCsc[i][j] = fs->make<TH1F>(asdf, s.c_str(), NCHAMBERS[j], 0.5, csc_max);
971  sprintf(asdf, "Comp_CLCTsTotal_%i", i * CSC_TYPES + j);
972  hClctCompTotalCsc[i][j] = fs->make<TH1F>(asdf, s.c_str(), NCHAMBERS[j], 0.5, csc_max);
973  sprintf(asdf, "Comp_CLCTsMatch_%i", i * CSC_TYPES + j);
974  hClctCompMatchCsc[i][j] = fs->make<TH1F>(asdf, s.c_str(), NCHAMBERS[j], 0.5, csc_max);
975  hClctCompFoundCsc[i][j]->Sumw2();
976  hClctCompSameNCsc[i][j]->Sumw2();
977  hClctCompTotalCsc[i][j]->Sumw2();
978  hClctCompMatchCsc[i][j]->Sumw2();
979  }
980  }
981 
982  // Correlated LCTs.
983  for (int i = 0; i < MAX_ENDCAPS; i++) { // endcaps
984  for (int j = 0; j < CSC_TYPES; j++) { // station/ring
985  float csc_max = NCHAMBERS[j] + 0.5;
986  char asdf[256];
987  if (i == 0)
988  s = "LCTs, " + csc_type_plus[j];
989  else
990  s = "LCTs, " + csc_type_minus[j];
991  sprintf(asdf, "LCTs_CompFound_%i", i * CSC_TYPES + j);
992  hLctCompFoundCsc[i][j] = fs->make<TH1F>(asdf, s.c_str(), NCHAMBERS[j], 0.5, csc_max);
993  sprintf(asdf, "LCTs_CompSame_%i", i * CSC_TYPES + j);
994  hLctCompSameNCsc[i][j] = fs->make<TH1F>(asdf, s.c_str(), NCHAMBERS[j], 0.5, csc_max);
995  sprintf(asdf, "LCTs_CompTotal_%i", i * CSC_TYPES + j);
996  hLctCompTotalCsc[i][j] = fs->make<TH1F>(asdf, s.c_str(), NCHAMBERS[j], 0.5, csc_max);
997  sprintf(asdf, "LCTs_CompMatch_%i", i * CSC_TYPES + j);
998  hLctCompMatchCsc[i][j] = fs->make<TH1F>(asdf, s.c_str(), NCHAMBERS[j], 0.5, csc_max);
999  hLctCompFoundCsc[i][j]->Sumw2();
1000  hLctCompSameNCsc[i][j]->Sumw2();
1001  hLctCompTotalCsc[i][j]->Sumw2();
1002  hLctCompMatchCsc[i][j]->Sumw2();
1003  }
1004  }
1005 
1006  bookedCompHistos = true;
1007  if (debug)
1008  LogTrace("CSCTriggerPrimitivesReader") << "bookedCompHistos ";
1009  std::cout << "bookCompHistos " << std::endl;
1010 }

References bookedCompHistos, gather_cfg::cout, csc_type_minus, csc_type_plus, CSC_TYPES, debug, hAlctCompFound, hAlctCompFound2, hAlctCompFound2i, hAlctCompFound2x, hAlctCompFoundCsc, hAlctCompMatch, hAlctCompMatch2, hAlctCompMatch2i, hAlctCompMatch2x, hAlctCompMatchCsc, hAlctCompSameN, hAlctCompSameN2, hAlctCompSameN2i, hAlctCompSameN2x, hAlctCompSameNCsc, hAlctCompTotal, hAlctCompTotal2, hAlctCompTotal2i, hAlctCompTotal2x, hAlctCompTotalCsc, hClctCompFound, hClctCompFound2, hClctCompFound2i, hClctCompFound2x, hClctCompFoundCsc, hClctCompMatch, hClctCompMatch2, hClctCompMatch2i, hClctCompMatch2x, hClctCompMatchCsc, hClctCompSameN, hClctCompSameN2, hClctCompSameN2i, hClctCompSameN2x, hClctCompSameNCsc, hClctCompTotal, hClctCompTotal2, hClctCompTotal2i, hClctCompTotal2x, hClctCompTotalCsc, hLCTCompFound, hLCTCompFound2, hLCTCompFound2i, hLCTCompFound2x, hLctCompFoundCsc, hLCTCompMatch, hLCTCompMatch2, hLCTCompMatch2i, hLCTCompMatch2x, hLctCompMatchCsc, hLCTCompSameN, hLCTCompSameN2, hLCTCompSameN2i, hLCTCompSameN2x, hLctCompSameNCsc, hLCTCompTotal, hLCTCompTotal2, hLCTCompTotal2i, hLCTCompTotal2x, hLctCompTotalCsc, mps_fire::i, dqmiolumiharvest::j, LogTrace, TFileService::make(), MAX_ENDCAPS, NCHAMBERS, and alignCSCRings::s.

Referenced by compare().

◆ bookEfficHistos()

void CSCTriggerPrimitivesReader::bookEfficHistos ( )
private

Definition at line 1093 of file CSCTriggerPrimitivesReader.cc.

1093  {
1095 
1096  // Efficiencies per station.
1097  char histname[60];
1098  for (int i = 0; i < MAX_STATIONS; i++) {
1099  sprintf(histname, "SimHits vs eta, station %d", i + 1);
1100  hEfficHitsEta[i] = fs->make<TH1F>("", histname, 66, 0.875, 2.525);
1101 
1102  sprintf(histname, "ALCTs vs eta, station %d", i + 1);
1103  hEfficALCTEta[i] = fs->make<TH1F>("", histname, 66, 0.875, 2.525);
1104 
1105  sprintf(histname, "CLCTs vs eta, station %d", i + 1);
1106  hEfficCLCTEta[i] = fs->make<TH1F>("", histname, 66, 0.875, 2.525);
1107  }
1108 
1109  // Efficiencies per chamber type.
1110  for (int i = 0; i < CSC_TYPES; i++) {
1111  string t0 = "SimHits vs eta, " + csc_type[i];
1112  hEfficHitsEtaCsc[i] = fs->make<TH1F>("", t0.c_str(), 66, 0.875, 2.525);
1113  string t1 = "ALCTs vs eta, " + csc_type[i];
1114  hEfficALCTEtaCsc[i] = fs->make<TH1F>("", t1.c_str(), 66, 0.875, 2.525);
1115  string t2 = "CLCTs vs eta, " + csc_type[i];
1116  hEfficCLCTEtaCsc[i] = fs->make<TH1F>("", t1.c_str(), 66, 0.875, 2.525);
1117  }
1118 
1119  bookedEfficHistos = true;
1120  if (debug)
1121  LogTrace("CSCTriggerPrimitivesReader") << "bookedEfficHistos ";
1122  std::cout << " bookedEfficHistos " << std::endl;
1123 }

References bookedEfficHistos, gather_cfg::cout, csc_type, CSC_TYPES, debug, hEfficALCTEta, hEfficALCTEtaCsc, hEfficCLCTEta, hEfficCLCTEtaCsc, hEfficHitsEta, hEfficHitsEtaCsc, mps_fire::i, LogTrace, TFileService::make(), MAX_STATIONS, FrontierCondition_GT_autoExpress_cfi::t0, RandomServiceHelper::t1, and RandomServiceHelper::t2.

Referenced by calcEfficiency().

◆ bookHotWireHistos()

void CSCTriggerPrimitivesReader::bookHotWireHistos ( )
private

Definition at line 630 of file CSCTriggerPrimitivesReader.cc.

630  {
632  hHotWire1 = fs->make<TH1F>("hHotWire1", "hHotWire1", 570 * 6 * 112, 0, 570 * 6 * 112);
633  hHotCham1 = fs->make<TH1F>("hHotCham1", "hHotCham1", 570, 0, 570);
634  bookedHotWireHistos = true;
635 }

References bookedHotWireHistos, hHotCham1, hHotWire1, and TFileService::make().

Referenced by HotWires().

◆ bookLCTMPCHistos()

void CSCTriggerPrimitivesReader::bookLCTMPCHistos ( )
private

Definition at line 828 of file CSCTriggerPrimitivesReader.cc.

828  {
830  hLctMPCPerEvent = fs->make<TH1F>("MPC_per_event", "LCTs per event", 31, -0.5, 30.5);
831  hLctMPCPerCSC = fs->make<TH1F>("MPC_per_CSCtype", "LCTs per CSC type", 10, -0.5, 9.5);
832  hCorrLctMPCPerCSC = fs->make<TH1F>("CorrMPC_per_CSCtype", "Corr. LCTs per CSC type", 10, -0.5, 9.5);
833  hLctMPCEndcap = fs->make<TH1F>("MPC_Endcap", "Endcap", 4, -0.5, 3.5);
834  hLctMPCStation = fs->make<TH1F>("MPC_Station", "Station", 6, -0.5, 5.5);
835  hLctMPCSector = fs->make<TH1F>("MPC_Sector", "Sector", 8, -0.5, 7.5);
836  hLctMPCRing = fs->make<TH1F>("MPC_Ring", "Ring", 5, -0.5, 4.5);
837 
838  hLctMPCValid = fs->make<TH1F>("MPC_validity", "LCT validity", 3, -0.5, 2.5);
839  hLctMPCQuality = fs->make<TH1F>("MPC_quality", "LCT quality", 17, -0.5, 16.5);
840  hLctMPCKeyGroup = fs->make<TH1F>("MPC_key_wiregroup", "LCT key wiregroup", 120, -0.5, 119.5);
841  hLctMPCKeyStrip = fs->make<TH1F>("MPC_key_strip", "LCT key strip", 160, -0.5, 159.5);
842  hLctMPCStripType = fs->make<TH1F>("MPC_strip_type", "LCT strip type", 3, -0.5, 2.5);
843  hLctMPCPattern = fs->make<TH1F>("MPC_pattern", "LCT pattern", 13, -0.5, 12.5);
844  hLctMPCBend = fs->make<TH1F>("MPC_bend", "LCT L/R bend", 3, -0.5, 2.5);
845  hLctMPCBXN = fs->make<TH1F>("MPC_bx", "LCT bx", 20, -0.5, 19.5);
846 
847  // LCT quantities per station
848  char histname[60];
849  for (int istat = 0; istat < MAX_STATIONS; istat++) {
850  sprintf(histname, "MPC_CSCId, station %d", istat + 1);
851  hLctMPCChamber[istat] = fs->make<TH1F>("", histname, 10, -0.5, 9.5);
852  }
853 
854  hLctMPCKeyGroupME11 = fs->make<TH1F>("hLctMPCKeyGroupME11", "MPC LCT key wiregroup ME1/1", 50, -0.5, 49.5);
855  hLctMPCKeyStripME11 = fs->make<TH1F>("hLctMPCKeyStripME11", "MPC LCT key strip ME1/1", 161, -0.5, 160.5);
856 
857  bookedLCTMPCHistos = true;
858  if (debug)
859  LogTrace("CSCTriggerPrimitivesReader") << "bookedLCTMPCHistos ";
860  std::cout << " bookedLCTMPCHistos " << std::endl;
861 }

References bookedLCTMPCHistos, gather_cfg::cout, debug, hCorrLctMPCPerCSC, hLctMPCBend, hLctMPCBXN, hLctMPCChamber, hLctMPCEndcap, hLctMPCKeyGroup, hLctMPCKeyGroupME11, hLctMPCKeyStrip, hLctMPCKeyStripME11, hLctMPCPattern, hLctMPCPerCSC, hLctMPCPerEvent, hLctMPCQuality, hLctMPCRing, hLctMPCSector, hLctMPCStation, hLctMPCStripType, hLctMPCValid, LogTrace, TFileService::make(), and MAX_STATIONS.

Referenced by fillLCTMPCHistos().

◆ bookLCTTMBHistos()

void CSCTriggerPrimitivesReader::bookLCTTMBHistos ( )
private

Definition at line 723 of file CSCTriggerPrimitivesReader.cc.

723  {
724  string s;
725 
727  hLctTMBPerEvent = fs->make<TH1F>("LCTs_per_event", "LCTs per event", 31, -0.5, 30.5);
728  hLctTMBPerChamber = fs->make<TH1F>("LCTs_per_chamber", "LCTs per chamber", 3, -0.5, 2.5);
729  hLctTMBPerCSC = fs->make<TH1F>("LCTs_per_CSCtype", "LCTs per CSC type", 10, -0.5, 9.5);
730  hCorrLctTMBPerCSC = fs->make<TH1F>("CorrLCTs_per_CSCtype", "Corr. LCTs per CSC type", 10, -0.5, 9.5);
731  hLctTMBEndcap = fs->make<TH1F>("LCTS_endcap", "Endcap", 4, -0.5, 3.5);
732  hLctTMBStation = fs->make<TH1F>("LCTS_station", "Station", 6, -0.5, 5.5);
733  hLctTMBSector = fs->make<TH1F>("LCTS_sector", "Sector", 8, -0.5, 7.5);
734  hLctTMBRing = fs->make<TH1F>("LCTS_ring", "Ring", 5, -0.5, 4.5);
735  for (int i = 0; i < MAX_ENDCAPS; i++) { // endcaps
736  for (int j = 0; j < CSC_TYPES; j++) { // station/ring
737  char asdf[256];
738  float csc_max = NCHAMBERS[j] + 0.5;
739  if (i == 0)
740  s = "LCTs, " + csc_type_plus[j];
741  else
742  s = "LCTs, " + csc_type_minus[j];
743  sprintf(asdf, "LCTs_%i", i * CSC_TYPES + j);
744  hLctTMBCsc[i][j] = fs->make<TH1F>(s.c_str(), s.c_str(), NCHAMBERS[j], 0.5, csc_max);
745  }
746  }
747 
748  hLctTMBValid = fs->make<TH1F>("LCT_validity", "LCT validity", 3, -0.5, 2.5);
749  hLctTMBQuality = fs->make<TH1F>("LCT_quality", "LCT quality", 17, -0.5, 16.5);
750  hLctTMBKeyGroup = fs->make<TH1F>("LCT_key_wiregroup", "LCT key wiregroup", 120, -0.5, 119.5);
751  hLctTMBKeyStrip = fs->make<TH1F>("LCT_key_strip", "LCT key strip", 160, -0.5, 159.5);
752  hLctTMBStripType = fs->make<TH1F>("LCT_strip_type", "LCT strip type", 3, -0.5, 2.5);
753  hLctTMBPattern = fs->make<TH1F>("LCT_pattern", "LCT pattern", 13, -0.5, 12.5);
754  hLctTMBBend = fs->make<TH1F>("LCT_bend", "LCT L/R bend", 3, -0.5, 2.5);
755  hLctTMBBXN = fs->make<TH1F>("LCT_bx", "LCT bx", 20, -0.5, 19.5);
756 
757  // LCT quantities per station
758  char histname[60];
759  for (int istat = 0; istat < MAX_STATIONS; istat++) {
760  sprintf(histname, "LCT_CSCId, station %d", istat + 1);
761  hLctTMBChamber[istat] = fs->make<TH1F>("", histname, 10, -0.5, 9.5);
762  }
763 
764  hLctTMBKeyGroupME11 = fs->make<TH1F>("hLctTMBKeyGroupME11", "LCT key wiregroup ME1/1", 50, -0.5, 49.5);
765  hLctTMBKeyStripME11 = fs->make<TH1F>("hLctTMBKeyStripME11", "LCT key strip ME1/1", 161, -0.5, 160.5);
766 
767  bookedLCTTMBHistos = true;
768  std::cout << " bookedLCTTMBHistos " << std::endl;
769 }

References bookedLCTTMBHistos, gather_cfg::cout, csc_type_minus, csc_type_plus, CSC_TYPES, hCorrLctTMBPerCSC, hLctTMBBend, hLctTMBBXN, hLctTMBChamber, hLctTMBCsc, hLctTMBEndcap, hLctTMBKeyGroup, hLctTMBKeyGroupME11, hLctTMBKeyStrip, hLctTMBKeyStripME11, hLctTMBPattern, hLctTMBPerChamber, hLctTMBPerCSC, hLctTMBPerEvent, hLctTMBQuality, hLctTMBRing, hLctTMBSector, hLctTMBStation, hLctTMBStripType, hLctTMBValid, mps_fire::i, dqmiolumiharvest::j, TFileService::make(), MAX_ENDCAPS, MAX_STATIONS, NCHAMBERS, and alignCSCRings::s.

Referenced by fillLCTTMBHistos().

◆ bookResolHistos()

void CSCTriggerPrimitivesReader::bookResolHistos ( )
private

Definition at line 1012 of file CSCTriggerPrimitivesReader.cc.

1012  {
1014 
1015  // Limits for resolution histograms
1016  const double EDMIN = -0.05; // eta min
1017  const double EDMAX = 0.05; // eta max
1018  const double PDMIN = -5.0; // phi min (mrad)
1019  const double PDMAX = 5.0; // phi max (mrad)
1020 
1021  hResolDeltaWG = fs->make<TH1F>("", "Delta key wiregroup", 10, -5., 5.);
1022 
1023  hResolDeltaHS = fs->make<TH1F>("", "Delta key halfstrip", 10, -5., 5.);
1024  hResolDeltaDS = fs->make<TH1F>("", "Delta key distrip", 10, -5., 5.);
1025 
1026  hResolDeltaEta = fs->make<TH1F>("", "#eta_rec-#eta_sim", 100, EDMIN, EDMAX);
1027  hResolDeltaPhi = fs->make<TH1F>("", "#phi_rec-#phi_sim (mrad)", 100, -10., 10.);
1028  hResolDeltaPhiHS = fs->make<TH1F>("", "#phi_rec-#phi_sim (mrad), halfstrips", 100, -10., 10.);
1029  hResolDeltaPhiDS = fs->make<TH1F>("", "#phi_rec-#phi_sim (mrad), distrips", 100, -10., 10.);
1030 
1031  hEtaRecVsSim = fs->make<TH2F>("", "#eta_rec vs #eta_sim", 64, 0.9, 2.5, 64, 0.9, 2.5);
1032  hPhiRecVsSim = fs->make<TH2F>("", "#phi_rec vs #phi_sim", 100, 0., TWOPI, 100, 0., TWOPI);
1033 
1034  // LCT quantities per station
1035  char histname[60];
1036  for (int i = 0; i < MAX_STATIONS; i++) {
1037  sprintf(histname, "ALCTs vs eta, station %d", i + 1);
1038  hAlctVsEta[i] = fs->make<TH1F>("", histname, 66, 0.875, 2.525);
1039 
1040  sprintf(histname, "CLCTs vs phi, station %d", i + 1);
1041  hClctVsPhi[i] = fs->make<TH1F>("", histname, 100, 0., TWOPI);
1042 
1043  sprintf(histname, "#LT#eta_rec-#eta_sim#GT, station %d", i + 1);
1044  hEtaDiffVsEta[i] = fs->make<TH1F>("", histname, 66, 0.875, 2.525);
1045 
1046  sprintf(histname, "#LT#phi_rec-#phi_sim#GT, station %d", i + 1);
1047  hPhiDiffVsPhi[i] = fs->make<TH1F>("", histname, 100, 0., TWOPI);
1048  }
1049 
1050  for (int i = 0; i < CSC_TYPES; i++) {
1051  string t0 = "#eta_rec-#eta_sim, " + csc_type[i];
1052  hEtaDiffCsc[i][0] = fs->make<TH1F>("", t0.c_str(), 100, EDMIN, EDMAX);
1053  string t1 = t0 + ", endcap1";
1054  hEtaDiffCsc[i][1] = fs->make<TH1F>("", t1.c_str(), 100, EDMIN, EDMAX);
1055  string t2 = t0 + ", endcap2";
1056  hEtaDiffCsc[i][2] = fs->make<TH1F>("", t2.c_str(), 100, EDMIN, EDMAX);
1057 
1058  string t4 = "#eta_rec-#eta_sim vs wiregroup, " + csc_type[i];
1059  hEtaDiffVsWireCsc[i] = fs->make<TH2F>("", t4.c_str(), MAX_WG[i], 0., MAX_WG[i], 100, EDMIN, EDMAX);
1060 
1061  string u0 = "#phi_rec-#phi_sim, " + csc_type[i];
1062  hPhiDiffCsc[i][0] = fs->make<TH1F>("", u0.c_str(), 100, PDMIN, PDMAX);
1063  string u1 = u0 + ", endcap1";
1064  hPhiDiffCsc[i][1] = fs->make<TH1F>("", u1.c_str(), 100, PDMIN, PDMAX);
1065  string u2 = u0 + ", endcap2";
1066  hPhiDiffCsc[i][2] = fs->make<TH1F>("", u2.c_str(), 100, PDMIN, PDMAX);
1067  hPhiDiffCsc[i][3] = fs->make<TH1F>("", u0.c_str(), 100, PDMIN, PDMAX);
1068  hPhiDiffCsc[i][4] = fs->make<TH1F>("", u0.c_str(), 100, PDMIN, PDMAX);
1069 
1070  int MAX_DS = MAX_HS[i] / 4;
1071  string u5 = "#phi_rec-#phi_sim (mrad) vs distrip, " + csc_type[i];
1072  hPhiDiffVsStripCsc[i][0] = fs->make<TH2F>("", u5.c_str(), MAX_DS, 0., MAX_DS, 100, PDMIN, PDMAX);
1073  string u6 = "#phi_rec-#phi_sim (mrad) vs halfstrip, " + csc_type[i];
1074  hPhiDiffVsStripCsc[i][1] = fs->make<TH2F>("", u6.c_str(), MAX_HS[i], 0., MAX_HS[i], 100, PDMIN, PDMAX);
1075 
1076  string u7 = "#phi(layer 1)-#phi(layer 6), mrad, " + csc_type[i];
1077  hTrueBendCsc[i] = fs->make<TH1F>("", u7.c_str(), 100, -10., 10.);
1078  }
1079 
1080  int max_patterns, phibend;
1081  max_patterns = CSCConstants::NUM_CLCT_PATTERNS;
1082  for (int i = 0; i < max_patterns; i++) {
1083  phibend = ptype_TMB07[i];
1084  sprintf(histname, "#phi_rec-#phi_sim, bend = %d", phibend);
1085  hPhiDiffPattern[i] = fs->make<TH1F>("", histname, 100, PDMIN, PDMAX);
1086  }
1087 
1088  bookedResolHistos = true;
1089  if (debug)
1090  LogTrace("CSCTriggerPrimitivesReader") << "bookedResolHistos ";
1091 }

References bookedResolHistos, csc_type, CSC_TYPES, debug, hAlctVsEta, hClctVsPhi, hEtaDiffCsc, hEtaDiffVsEta, hEtaDiffVsWireCsc, hEtaRecVsSim, hPhiDiffCsc, hPhiDiffPattern, hPhiDiffVsPhi, hPhiDiffVsStripCsc, hPhiRecVsSim, hResolDeltaDS, hResolDeltaEta, hResolDeltaHS, hResolDeltaPhi, hResolDeltaPhiDS, hResolDeltaPhiHS, hResolDeltaWG, hTrueBendCsc, mps_fire::i, LogTrace, TFileService::make(), MAX_HS, MAX_STATIONS, MAX_WG, CSCConstants::NUM_CLCT_PATTERNS, ptype_TMB07, FrontierCondition_GT_autoExpress_cfi::t0, RandomServiceHelper::t1, RandomServiceHelper::t2, TWOPI, testProducerWithPsetDescEmpty_cfi::u1, and MetAnalyzer::u2.

Referenced by calcResolution().

◆ calcEfficiency()

void CSCTriggerPrimitivesReader::calcEfficiency ( const CSCALCTDigiCollection alcts,
const CSCCLCTDigiCollection clcts,
const edm::PSimHitContainer allSimHits 
)
private

Definition at line 2903 of file CSCTriggerPrimitivesReader.cc.

2905  {
2906  // Book histos when called for the first time.
2907  if (!bookedEfficHistos)
2908  bookEfficHistos();
2909 
2910  // Create list of chambers having SimHits.
2911  vector<CSCDetId> chamberIds;
2912  vector<CSCDetId>::const_iterator chamberIdIt;
2913  for (const auto& simHitIt : allSimHits) {
2914  // Find detId where simHit is located.
2915  bool sameId = false;
2916  CSCDetId hitId = (CSCDetId)simHitIt.detUnitId();
2917  // Skip chambers marked as bad (includes most of ME4/2 chambers).
2919  continue;
2920  //if (hitId.ring() == 4) continue; // skip ME1/A for now.
2921  if (!plotME1A && hitId.ring() == 4)
2922  continue;
2923  for (const auto& chamberId : chamberIds) {
2924  if (chamberId.endcap() == hitId.endcap() && chamberId.station() == hitId.station() &&
2925  chamberId.ring() == hitId.ring() && chamberId.chamber() == hitId.chamber()) {
2926  sameId = true;
2927  break;
2928  }
2929  }
2930  if (!sameId) {
2931  CSCDetId newChamberId(hitId.endcap(), hitId.station(), hitId.ring(), hitId.chamber(), 0);
2932  chamberIds.push_back(newChamberId);
2933  }
2934  }
2935  LogTrace("CSCTriggerPrimitivesReader") << "Found SimHits in " << chamberIds.size() << " CSCs";
2936 
2937  bool used[CSCConstants::NUM_LAYERS];
2938  vector<PSimHit> simHitsV[CSCConstants::NUM_LAYERS];
2939  for (const auto& chamberId : chamberIds) {
2940  // Find out how many layers of this chamber have SimHits.
2941  int nLayers = 0;
2942  for (int ilayer = 0; ilayer < CSCConstants::NUM_LAYERS; ilayer++) {
2943  used[ilayer] = false;
2944  simHitsV[ilayer].clear();
2945  }
2946 
2947  int endcap = chamberId.endcap();
2948  int station = chamberId.station();
2949  int ring = chamberId.ring();
2950  int chamber = chamberId.chamber();
2951  for (const auto& simHitIt : allSimHits) {
2952  CSCDetId hitId = (CSCDetId)simHitIt.detUnitId();
2953  if (hitId.endcap() == endcap && hitId.station() == station && hitId.ring() == ring &&
2954  hitId.chamber() == chamber) {
2955  int layer = hitId.layer() - 1;
2956  if (!used[layer] && abs(simHitIt.particleType()) == 13) {
2957  nLayers++;
2958  used[layer] = true;
2959  simHitsV[layer].push_back(simHitIt);
2960  }
2961  }
2962  }
2963  LogTrace("CSCTriggerPrimitivesReader") << "CSC in ME" << ((endcap == 1) ? "+" : "-") << station << "/" << ring
2964  << "/" << chamber << " has muon hits in " << nLayers << " layers";
2965 
2966  // If the number of layers with hits is above threshold, look for
2967  // a presence of LCTs.
2968  if (nLayers > 3) { // Should be a parameter.
2969  // Start with the key layer and take the eta of the first hit.
2970  // Really crude; should be improved.
2971  double hitEta = -999.;
2972  for (int ilayer = 2; ilayer < CSCConstants::NUM_LAYERS; ilayer++) {
2973  vector<PSimHit> layerSimHitsV = simHitsV[ilayer];
2974  if (!layerSimHitsV.empty()) {
2975  LocalPoint hitLP = layerSimHitsV[0].localPosition();
2976  CSCDetId layerId = (CSCDetId)(layerSimHitsV[0]).detUnitId();
2977  const CSCLayer* csclayer = geom_->layer(layerId);
2978  GlobalPoint hitGP = csclayer->toGlobal(hitLP);
2979  hitEta = hitGP.eta();
2980  break;
2981  }
2982  }
2983  if (hitEta < -3.) {
2984  edm::LogWarning("L1CSCTPEmulatorWrongValues") << "+++ Warning in calcEfficiency(): no SimHit found"
2985  << " where there must be at least " << nLayers << "! +++\n";
2986  continue;
2987  }
2988  int csctype = getCSCType(*chamberIdIt);
2989  hEfficHitsEta[station - 1]->Fill(fabs(hitEta));
2990  hEfficHitsEtaCsc[csctype]->Fill(fabs(hitEta));
2991 
2992  bool isALCT = false;
2993  for (auto adetUnitIt = alcts->begin(); adetUnitIt != alcts->end(); adetUnitIt++) {
2994  const CSCDetId& id = (*adetUnitIt).first;
2995  if (id == (*chamberIdIt)) {
2996  const auto& range = (*adetUnitIt).second;
2997  for (auto digiIt = range.first; digiIt != range.second; digiIt++) {
2998  if (digiIt->isValid()) {
2999  // Check the distance??
3000  LogTrace("CSCTriggerPrimitivesReader") << "ALCT was found";
3001  isALCT = true;
3002  break;
3003  }
3004  }
3005  }
3006  if (isALCT)
3007  break;
3008  }
3009  if (isALCT) {
3010  hEfficALCTEta[station - 1]->Fill(fabs(hitEta));
3011  hEfficALCTEtaCsc[csctype]->Fill(fabs(hitEta));
3012  } else {
3013  LogTrace("CSCTriggerPrimitivesReader") << "ALCT was not found";
3014  }
3015 
3016  bool isCLCT = false;
3017  for (auto cdetUnitIt = clcts->begin(); cdetUnitIt != clcts->end(); cdetUnitIt++) {
3018  const CSCDetId& id = (*cdetUnitIt).first;
3019  if (id == (*chamberIdIt)) {
3020  const auto& range = (*cdetUnitIt).second;
3021  for (auto digiIt = range.first; digiIt != range.second; digiIt++) {
3022  if (digiIt->isValid()) {
3023  // Check the distance??
3024  LogTrace("CSCTriggerPrimitivesReader") << "CLCT was found";
3025  isCLCT = true;
3026  break;
3027  }
3028  }
3029  }
3030  if (isCLCT)
3031  break;
3032  }
3033  if (isCLCT) {
3034  hEfficCLCTEta[station - 1]->Fill(fabs(hitEta));
3035  hEfficCLCTEtaCsc[csctype]->Fill(fabs(hitEta));
3036  } else {
3037  LogTrace("CSCTriggerPrimitivesReader") << "CLCT was not found";
3038  }
3039  }
3040  }
3041 }

References funct::abs(), badChambers_, bookedEfficHistos, bookEfficHistos(), relativeConstraints::chamber, CSCDetId::chamber(), checkBadChambers_, CSCDetId::endcap(), makeMuonMisalignmentScenario::endcap, PV3DBase< T, PVType, FrameType >::eta(), geom_, getCSCType(), hEfficALCTEta, hEfficALCTEtaCsc, hEfficCLCTEta, hEfficCLCTEtaCsc, hEfficHitsEta, hEfficHitsEtaCsc, CSCBadChambers::isInBadChamber(), CSCDetId::layer(), CSCGeometry::layer(), LogTrace, MuonTCMETValueMapProducer_cff::nLayers, CSCConstants::NUM_LAYERS, plotME1A, FastTimerService_cff::range, CSCDetId::ring(), relativeConstraints::ring, relativeConstraints::station, CSCDetId::station(), and GeomDet::toGlobal().

Referenced by MCStudies().

◆ calcResolution()

void CSCTriggerPrimitivesReader::calcResolution ( const CSCALCTDigiCollection alcts,
const CSCCLCTDigiCollection clcts,
const CSCWireDigiCollection wiredc,
const CSCComparatorDigiCollection compdc,
const edm::PSimHitContainer allSimHits 
)
private

Definition at line 2712 of file CSCTriggerPrimitivesReader.cc.

2716  {
2717  // Book histos when called for the first time.
2718  if (!bookedResolHistos)
2719  bookResolHistos();
2720 
2721  // ALCT resolution
2722  CSCAnodeLCTAnalyzer alct_analyzer;
2723  alct_analyzer.setGeometry(geom_);
2724 
2725  for (auto adetUnitIt = alcts->begin(); adetUnitIt != alcts->end(); adetUnitIt++) {
2726  const CSCDetId& id = (*adetUnitIt).first;
2728  continue;
2729  const auto& range = (*adetUnitIt).second;
2730  for (auto digiIt = range.first; digiIt != range.second; digiIt++) {
2731  bool alct_valid = (*digiIt).isValid();
2732  if (alct_valid) {
2733  vector<CSCAnodeLayerInfo> alctInfo = alct_analyzer.getSimInfo(*digiIt, id, wiredc, &allSimHits);
2734 
2735  double hitPhi = -999.0, hitEta = -999.0;
2736  int hitWG = alct_analyzer.nearestWG(alctInfo, hitPhi, hitEta);
2737  if (hitWG >= 0.) {
2738  // Key wire group and key layer id.
2739  int wiregroup = (*digiIt).getKeyWG();
2740 
2741  CSCDetId layerId(id.endcap(), id.station(), id.ring(), id.chamber(), CSCConstants::KEY_ALCT_LAYER);
2742  int endc = id.endcap();
2743  int stat = id.station();
2744  int csctype = getCSCType(id);
2745 
2746  double alctEta = alct_analyzer.getWGEta(layerId, wiregroup);
2747  double deltaEta = alctEta - hitEta;
2748  hResolDeltaEta->Fill(deltaEta);
2749 
2750  double deltaWG = wiregroup - hitWG;
2751  if (debug)
2752  LogTrace("CSCTriggerPrimitivesReader")
2753  << "WG: MC = " << hitWG << " rec = " << wiregroup << " delta = " << deltaWG;
2754  hResolDeltaWG->Fill(deltaWG);
2755 
2756  hEtaRecVsSim->Fill(fabs(hitEta), fabs(alctEta));
2757  hEtaDiffCsc[csctype][0]->Fill(deltaEta);
2758  hEtaDiffCsc[csctype][endc]->Fill(deltaEta);
2759  hAlctVsEta[stat - 1]->Fill(fabs(alctEta));
2760  hEtaDiffVsEta[stat - 1]->Fill(fabs(alctEta), fabs(deltaEta));
2761  hEtaDiffVsWireCsc[csctype]->Fill(wiregroup, deltaEta);
2762  }
2763  // should I comment out this "else"?
2764  //else {
2765  // edm::LogWarning("L1CSCTPEmulatorWrongInput")
2766  // << "+++ Warning in calcResolution(): no matched SimHit"
2767  // << " found! +++\n";
2768  //}
2769  }
2770  }
2771  }
2772 
2773  // CLCT resolution
2774  static const int key_layer = CSCConstants::KEY_CLCT_LAYER;
2775  CSCCathodeLCTAnalyzer clct_analyzer;
2776  clct_analyzer.setGeometry(geom_);
2777 
2778  for (auto cdetUnitIt = clcts->begin(); cdetUnitIt != clcts->end(); cdetUnitIt++) {
2779  const CSCDetId& id = (*cdetUnitIt).first;
2781  continue;
2782  const auto& range = (*cdetUnitIt).second;
2783  for (auto digiIt = range.first; digiIt != range.second; digiIt++) {
2784  bool clct_valid = (*digiIt).isValid();
2785  if (clct_valid) {
2786  vector<CSCCathodeLayerInfo> clctInfo = clct_analyzer.getSimInfo(*digiIt, id, compdc, &allSimHits);
2787 
2788  double hitPhi = -999.0, hitEta = -999.0, deltaStrip = -999.0;
2789  int hitHS = clct_analyzer.nearestHS(clctInfo, hitPhi, hitEta);
2790  if (hitHS >= 0.) {
2791  // Key strip and key layer id.
2792  int halfstrip = (*digiIt).getKeyStrip();
2793  int strip = halfstrip / 2;
2794  int distrip = halfstrip / 4;
2795  int stripType = (*digiIt).getStripType();
2796 
2797  CSCDetId layerId(id.endcap(), id.station(), id.ring(), id.chamber(), key_layer);
2798  int endc = id.endcap();
2799  int stat = id.station();
2800  int csctype = getCSCType(id);
2801 
2802  // 'float strip' is in the units of 'strip', i.e., angular
2803  // widths of each strip. The counting is from 0.0 at the extreme
2804  // edge of the 'first' strip at one edge of the detector.
2805  float fstrip = -999.;
2806  if (stripType == 0) { // di-strip CLCT
2807  fstrip = strip + 1.;
2808  } else { // half-strip CLCT
2809  fstrip = strip + 0.5 * (halfstrip % 2) + 0.25;
2810  }
2811  double clctPhi = clct_analyzer.getStripPhi(layerId, fstrip);
2812  double deltaPhi = clctPhi - hitPhi;
2813  if (deltaPhi < -M_PI)
2814  deltaPhi += 2. * M_PI;
2815  else if (deltaPhi > M_PI)
2816  deltaPhi -= 2. * M_PI;
2817  deltaPhi *= 1000; // in mrad
2818  if (hitPhi < 0)
2819  hitPhi += 2. * M_PI;
2820  if (clctPhi < 0)
2821  clctPhi += 2. * M_PI;
2822  if (debug)
2823  LogTrace("CSCTriggerPrimitivesReader")
2824  << " clctPhi = " << clctPhi << " hitPhi = " << hitPhi << " deltaPhi = " << deltaPhi;
2825 
2826  hResolDeltaPhi->Fill(deltaPhi);
2827  if (stripType == 0) { // di-strip CLCT
2828  deltaStrip = distrip - hitHS / 4;
2829  hResolDeltaDS->Fill(deltaStrip);
2830  hResolDeltaPhiDS->Fill(deltaPhi);
2831  hPhiDiffVsStripCsc[csctype][0]->Fill(distrip, deltaPhi);
2832  } else { // half-strip CLCT
2833  deltaStrip = halfstrip - hitHS;
2834  hResolDeltaHS->Fill(deltaStrip);
2835  hResolDeltaPhiHS->Fill(deltaPhi);
2836  hPhiDiffVsStripCsc[csctype][1]->Fill(halfstrip, deltaPhi);
2837  }
2838  if (debug)
2839  LogTrace("CSCTriggerPrimitivesReader") << "Half-strip: MC = " << hitHS << " rec = " << halfstrip
2840  << " pattern type = " << stripType << " delta = " << deltaStrip;
2841 
2842  hPhiRecVsSim->Fill(hitPhi, clctPhi);
2843  hPhiDiffCsc[csctype][0]->Fill(deltaPhi);
2844  hPhiDiffCsc[csctype][endc]->Fill(deltaPhi);
2845  hPhiDiffCsc[csctype][stripType + 3]->Fill(deltaPhi);
2846  hClctVsPhi[stat - 1]->Fill(clctPhi);
2847  hPhiDiffVsPhi[stat - 1]->Fill(clctPhi, fabs(deltaPhi));
2848 
2849  // Histograms to check phi offsets for various pattern types
2850  if (stripType == 1) { // half-strips
2851  double hsperrad = getHsPerRad(csctype); // halfstrips-per-radian
2852  if ((endc == 1 && (stat == 1 || stat == 2)) || (endc == 2 && (stat == 3 || stat == 4))) {
2853  hPhiDiffPattern[(*digiIt).getPattern()]->Fill(deltaPhi / 1000 * hsperrad);
2854  }
2855  }
2856  }
2857  // should I comment out this "else"?
2858  //else {
2859  // edm::LogWarning("L1CSCTPEmulatorWrongInput")
2860  // << "+++ Warning in calcResolution(): no matched SimHit"
2861  // << " found! +++\n";
2862  //}
2863 
2864  // "True bend", defined as difference in phi between muon hit
2865  // positions in the first and in the sixth layers.
2866  double phi1 = -999.0, phi6 = -999.0;
2867  vector<CSCCathodeLayerInfo>::const_iterator pli;
2868  for (pli = clctInfo.begin(); pli != clctInfo.end(); pli++) {
2869  CSCDetId layerId = pli->getId();
2870  int layer = layerId.layer();
2871  if (layer == 1 || layer == 6) {
2872  // Get simHits in this layer.
2873  for (const auto& psh : allSimHits) {
2874  // Find detId where simHit is located.
2875  CSCDetId hitId = (CSCDetId)psh.detUnitId();
2876  if (hitId == layerId && abs(psh.particleType()) == 13) { // muon hits only
2877  const CSCLayer* csclayer = geom_->layer(layerId);
2878  const auto& thisPoint = csclayer->toGlobal(psh.localPosition());
2879  double phi = thisPoint.phi();
2880  if (layer == 1)
2881  phi1 = phi;
2882  else if (layer == 6)
2883  phi6 = phi;
2884  break; // simply take the first suitable hit.
2885  }
2886  }
2887  }
2888  }
2889  if (phi1 > -99. && phi6 > -99.) {
2890  double deltaPhi = phi1 - phi6;
2891  if (deltaPhi > M_PI)
2892  deltaPhi -= 2. * M_PI;
2893  else if (deltaPhi < -M_PI)
2894  deltaPhi += 2. * M_PI;
2895  int csctype = getCSCType(id);
2896  hTrueBendCsc[csctype]->Fill(deltaPhi * 1000.); // in mrad
2897  }
2898  }
2899  }
2900  }
2901 }

References funct::abs(), badChambers_, bookedResolHistos, bookResolHistos(), relativeConstraints::chamber, checkBadChambers_, debug, spr::deltaEta, SiPixelRawToDigiRegional_cfi::deltaPhi, makeMuonMisalignmentScenario::endcap, geom_, getCSCType(), getHsPerRad(), CSCAnodeLCTAnalyzer::getSimInfo(), CSCCathodeLCTAnalyzer::getSimInfo(), CSCCathodeLCTAnalyzer::getStripPhi(), CSCAnodeLCTAnalyzer::getWGEta(), hAlctVsEta, hClctVsPhi, hEtaDiffCsc, hEtaDiffVsEta, hEtaDiffVsWireCsc, hEtaRecVsSim, hPhiDiffCsc, hPhiDiffPattern, hPhiDiffVsPhi, hPhiDiffVsStripCsc, hPhiRecVsSim, hResolDeltaDS, hResolDeltaEta, hResolDeltaHS, hResolDeltaPhi, hResolDeltaPhiDS, hResolDeltaPhiHS, hResolDeltaWG, hTrueBendCsc, CSCBadChambers::isInBadChamber(), CSCConstants::KEY_ALCT_LAYER, CSCConstants::KEY_CLCT_LAYER, CSCDetId::layer(), CSCGeometry::layer(), LogTrace, M_PI, CSCCathodeLCTAnalyzer::nearestHS(), CSCAnodeLCTAnalyzer::nearestWG(), phi, FastTimerService_cff::range, relativeConstraints::ring, CSCAnodeLCTAnalyzer::setGeometry(), CSCCathodeLCTAnalyzer::setGeometry(), hgcalPlots::stat, relativeConstraints::station, digitizers_cfi::strip, and GeomDet::toGlobal().

Referenced by MCStudies().

◆ chamberIX()

int CSCTriggerPrimitivesReader::chamberIX ( CSCDetId  id)

Definition at line 785 of file CSCTriggerPrimitivesReader.cc.

785  {
786  int ix = 1;
787  if (id.station() != 1) {
788  ix = (id.station() - 2) * 2 + 3 + 1;
789  }
790  ix += id.ring() - 1;
791  if (id.endcap() == 2) {
792  ix *= -1;
793  }
794  return ix;
795 }

References makeMuonMisalignmentScenario::endcap, and relativeConstraints::station.

Referenced by compareALCTs(), compareCLCTs(), and compareLCTs().

◆ chamberIXi()

int CSCTriggerPrimitivesReader::chamberIXi ( CSCDetId  id)

Definition at line 771 of file CSCTriggerPrimitivesReader.cc.

771  {
772  // 1/1 1/2 1/3 2/1 2/2 3/1 3/2 4/1 4/2 -1/1 -1/2 -1/3 -2/1 -2/2 -3/1 -3/2 -4/1 -4/2
773  //ix= 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
774  int ix = 0;
775  if (id.station() != 1) {
776  ix = (id.station() - 2) * 2 + 3;
777  }
778  ix += id.ring() - 1;
779  if (id.endcap() == 2) {
780  ix += 9;
781  }
782  return ix;
783 }

References makeMuonMisalignmentScenario::endcap, and relativeConstraints::station.

Referenced by compareALCTs(), compareCLCTs(), and compareLCTs().

◆ chamberSerial()

int CSCTriggerPrimitivesReader::chamberSerial ( CSCDetId  id)

Definition at line 797 of file CSCTriggerPrimitivesReader.cc.

797  {
798  int st = id.station();
799  int ri = id.ring();
800  int ch = id.chamber();
801  int ec = id.endcap();
802  int kSerial = ch;
803  if (st == 1 && ri == 1)
804  kSerial = ch;
805  if (st == 1 && ri == 2)
806  kSerial = ch + 36;
807  if (st == 1 && ri == 3)
808  kSerial = ch + 72;
809  if (st == 1 && ri == 4)
810  kSerial = ch;
811  if (st == 2 && ri == 1)
812  kSerial = ch + 108;
813  if (st == 2 && ri == 2)
814  kSerial = ch + 126;
815  if (st == 3 && ri == 1)
816  kSerial = ch + 162;
817  if (st == 3 && ri == 2)
818  kSerial = ch + 180;
819  if (st == 4 && ri == 1)
820  kSerial = ch + 216;
821  if (st == 4 && ri == 2)
822  kSerial = ch + 234; // one day...
823  if (ec == 2)
824  kSerial = kSerial + 300;
825  return kSerial;
826 }

Referenced by compareALCTs(), and HotWires().

◆ compare()

void CSCTriggerPrimitivesReader::compare ( const CSCALCTDigiCollection alcts_data,
const CSCALCTDigiCollection alcts_emul,
const CSCCLCTDigiCollection clcts_data,
const CSCCLCTDigiCollection clcts_emul,
const CSCCLCTPreTriggerDigiCollection pretrigs_emul,
const CSCCorrelatedLCTDigiCollection lcts_data,
const CSCCorrelatedLCTDigiCollection lcts_emul 
)
private

Definition at line 1373 of file CSCTriggerPrimitivesReader.cc.

1379  {
1380  // Book histos when called for the first time.
1381  if (!bookedCompHistos)
1382  bookCompHistos();
1383 
1384  // Comparisons
1385  compareALCTs(alcts_data, alcts_emul);
1386  compareCLCTs(clcts_data, clcts_emul, pretrigs_emul);
1387  compareLCTs(lcts_data, lcts_emul, alcts_data, clcts_data);
1388  //compareMPCLCTs(mpclcts_data, mpclcts_emul, alcts_data, clcts_data);
1389 }

References bookCompHistos(), bookedCompHistos, compareALCTs(), compareCLCTs(), and compareLCTs().

Referenced by analyze().

◆ compareALCTs()

void CSCTriggerPrimitivesReader::compareALCTs ( const CSCALCTDigiCollection alcts_data,
const CSCALCTDigiCollection alcts_emul 
)
private

Definition at line 1391 of file CSCTriggerPrimitivesReader.cc.

1392  {
1393  int emul_corr_bx;
1394 
1395  // Should be taken from config. parameters.
1396  int fifo_pretrig = 10;
1397  int fpga_latency = 6;
1398  int l1a_window_width = 7;
1399  // Time offset of raw hits w.r.t. the full 12-bit BXN.
1400  int rawhit_tbin_offset = (fifo_pretrig - fpga_latency) + (l1a_window_width - 1) / 2;
1401  // Extra difference due to additional register stages; determined
1402  // empirically.
1403  int register_delay = 2;
1404  // Loop over all chambers in search for ALCTs.
1405  std::vector<CSCALCTDigi>::const_iterator pd, pe;
1406  for (int endc = 1; endc <= 2; endc++) {
1407  for (int stat = 1; stat <= 4; stat++) {
1408  for (int ring = 1; ring <= maxRing(stat); ring++) {
1409  for (int cham = 1; cham <= 36; cham++) {
1410  // Calculate DetId. 0th layer means whole chamber.
1411  CSCDetId detid(endc, stat, ring, cham, 0);
1412 
1413  // Skip chambers marked as bad.
1415  continue;
1416  std::vector<CSCALCTDigi> alctV_data, alctV_emul;
1417  const auto& drange = alcts_data->get(detid);
1418  for (auto digiIt = drange.first; digiIt != drange.second; digiIt++) {
1419  if ((*digiIt).isValid()) {
1420  alctV_data.push_back(*digiIt);
1421  }
1422  }
1423 
1424  const auto& erange = alcts_emul->get(detid);
1425  std::vector<bool> bookedalctV_emul;
1426  for (auto digiIt = erange.first; digiIt != erange.second; digiIt++) {
1427  if ((*digiIt).isValid()) {
1428  alctV_emul.push_back(*digiIt);
1429  bookedalctV_emul.push_back(false);
1430  }
1431  }
1432 
1433  int ndata = alctV_data.size();
1434  int nemul = alctV_emul.size();
1435 
1436  if (ndata == 0 && nemul == 0)
1437  continue;
1438  bool firstfill = true;
1439 
1440  if (debug or (stat == 1 and ring == 1 and (ndata != nemul))) {
1441  ostringstream strstrm;
1442  strstrm << "\n--- ME" << ((detid.endcap() == 1) ? "+" : "-") << detid.station() << "/" << detid.ring()
1443  << "/" << detid.chamber() << " (sector " << detid.triggerSector() << " trig id. "
1444  << detid.triggerCscId() << "):\n";
1445  strstrm << " **** " << ndata << " valid data ALCTs found:\n";
1446  for (pd = alctV_data.begin(); pd != alctV_data.end(); pd++) {
1447  strstrm << " " << (*pd) << " Full BX = " << (*pd).getFullBX() << "\n";
1448  }
1449  strstrm << " **** " << nemul << " valid emul ALCTs found:\n";
1450  for (pe = alctV_emul.begin(); pe != alctV_emul.end(); pe++) {
1451  strstrm << " " << (*pe);
1452  for (pd = alctV_data.begin(); pd != alctV_data.end(); pd++) {
1453  if ((*pd).getTrknmb() == (*pe).getTrknmb()) {
1454  int emul_bx = (*pe).getBX();
1455  emul_corr_bx = emul_bx - rawhit_tbin_offset + register_delay;
1456  strstrm << " Corr BX = " << emul_corr_bx;
1457  break;
1458  }
1459  }
1460  strstrm << "\n";
1461  }
1462  LogTrace("CSCTriggerPrimitivesReader") << strstrm.str();
1463  //if (stat==1 && ring==1)
1464  // std::cout <<"ME11 CompareALCTs "<< strstrm.str()<< std::endl;
1465  }
1466 
1467  //Data, add HS quality later
1468  int perEv_nStub_data = 0;
1469  int perEv_nStub_emul = 0;
1470  perStub[0].init(RUN_, Event_);
1471  perStub[1].init(RUN_, Event_);
1472  for (pd = alctV_data.begin(); pd != alctV_data.end(); pd++) {
1473  perEv_nStub_data++;
1474  }
1475  perStub[0].t_endcap = endc;
1476  perStub[0].t_station = stat;
1477  perStub[0].t_chamber = cham;
1478  perStub[0].t_ring = ring;
1480  perStub[0].t_nStubs = ndata;
1481  perStub[0].t_nStubs_readout = ndata;
1482  event_tree[0]->Fill();
1483  //Emul
1484  for (pe = alctV_emul.begin(); pe != alctV_emul.end(); pe++) {
1485  perEv_nStub_emul++;
1486  }
1487  perStub[1].t_endcap = endc;
1488  perStub[1].t_station = stat;
1489  perStub[1].t_chamber = cham;
1490  perStub[1].t_ring = ring;
1492  perStub[1].t_nStubs = nemul;
1493  perStub[1].t_nStubs_readout = nemul;
1494  event_tree[1]->Fill();
1495 
1496  int csctype = getCSCType(detid);
1497  hAlctCompFoundCsc[endc - 1][csctype]->Fill(cham);
1498  int mychamber = chamberSerial(detid);
1499  hAlctCompFound->Fill(mychamber);
1500  int ix = chamberIX(detid);
1501  int ix2 = chamberIXi(detid);
1502  // printf("station %i, ring %i, chamber %i, ix+(detid.ring()-1) %i\n",
1503  // detid.station(),detid.ring(),detid.chamber(),ix);
1504  if (detid.station() > 1 && detid.ring() == 1) {
1505  hAlctCompFound2x->Fill(ix, detid.chamber() * 2);
1506  } else {
1507  hAlctCompFound2->Fill(ix, detid.chamber());
1508  }
1509  hAlctCompFound2i->Fill(ix2, detid.chamber());
1510 
1511  if (ndata != nemul) {
1512  LogTrace("CSCTriggerPrimitivesReader")
1513  << " +++ Different numbers of ALCTs found in ME" << ((endc == 1) ? "+" : "-") << stat << "/" << ring
1514  << "/" << cham << ": data = " << ndata << " emulator = " << nemul << " +++\n";
1515  } else {
1516  hAlctCompSameNCsc[endc - 1][csctype]->Fill(cham);
1517  if (detid.station() > 1 && detid.ring() == 1) {
1518  hAlctCompSameN2x->Fill(ix, detid.chamber() * 2);
1519  } else {
1520  hAlctCompSameN2->Fill(ix, detid.chamber());
1521  }
1522  hAlctCompSameN2i->Fill(ix2, detid.chamber());
1523  }
1524 
1525  for (int i = 0; i < ndata; i++) {
1526  if (alctV_data[i].isValid() == 0)
1527  continue;
1528  int data_trknmb = alctV_data[i].getTrknmb();
1529  //int data_quality = alctV_data[i].getQuality();
1530  //int data_accel = alctV_data[i].getAccelerator();
1531  //int data_collB = alctV_data[i].getCollisionB();
1532  int data_wiregroup = alctV_data[i].getKeyWG();
1533  int data_bx = alctV_data[i].getBX();
1534 
1536  stubs_comparison[0].firstfill = firstfill;
1537  if (firstfill)
1538  firstfill = false;
1540  stubs_comparison[0].endcap = endc;
1542  stubs_comparison[0].ring = ring;
1544  stubs_comparison[0].chambertype = detid.iChamberType();
1545  stubs_comparison[0].totStubs_data = ndata;
1546  stubs_comparison[0].totStubs_emul = nemul;
1548  stubs_comparison[0].nStub_data = i + 1;
1549  stubs_comparison[0].has_data = true;
1550  stubs_comparison[0].quality_data = alctV_data[i].getQuality();
1551  stubs_comparison[0].key_WG_data = alctV_data[i].getKeyWG();
1552  stubs_comparison[0].bx_data = data_bx;
1553  stubs_comparison[0].fullbx_data = alctV_data[i].getFullBX();
1554  stubs_comparison[0].trknmb_data = data_trknmb;
1555  GlobalPoint gp_alct_data(getGlobalPosition(detid.rawId(), data_wiregroup, 60));
1556  stubs_comparison[0].eta_data = gp_alct_data.eta();
1557  for (int j = 0; j < nemul; j++) {
1558  if (alctV_emul[j].isValid() == 0)
1559  continue;
1560  if (bookedalctV_emul[j])
1561  continue; //used alct
1562 
1563  int emul_trknmb = alctV_emul[j].getTrknmb();
1564  //int emul_quality = alctV_emul[j].getQuality();
1565  //int emul_accel = alctV_emul[j].getAccelerator();
1566  //int emul_collB = alctV_emul[j].getCollisionB();
1567  int emul_wiregroup = alctV_emul[j].getKeyWG();
1568  int emul_bx = alctV_emul[j].getBX();
1569  // Emulator BX re-calculated for comparison with BX in the data.
1570  emul_corr_bx = emul_bx - rawhit_tbin_offset + register_delay;
1571  if (dataIsAnotherMC_)
1572  emul_corr_bx = emul_bx;
1573 
1574  if (ndata == nemul) {
1575  hAlctCompTotal->Fill(mychamber);
1576  hAlctCompTotalCsc[endc - 1][csctype]->Fill(cham);
1577  if (detid.station() > 1 && detid.ring() == 1) {
1578  hAlctCompTotal2x->Fill(ix, detid.chamber() * 2);
1579  } else {
1580  hAlctCompTotal2->Fill(ix, detid.chamber());
1581  }
1582  hAlctCompTotal2i->Fill(ix2, detid.chamber());
1583  }
1584  if (data_trknmb == emul_trknmb) {
1585  if (abs(data_wiregroup - emul_wiregroup) <= 2) {
1586  hAlctCompMatchCsc[endc - 1][csctype]->Fill(cham);
1587  hAlctCompMatch->Fill(mychamber);
1588  if (detid.station() > 1 && detid.ring() == 1) {
1589  hAlctCompMatch2x->Fill(ix, detid.chamber() * 2);
1590  } else {
1591  hAlctCompMatch2->Fill(ix, detid.chamber());
1592  }
1593  hAlctCompMatch2i->Fill(ix2, detid.chamber());
1594  }
1595  if (debug)
1596  LogTrace("CSCTriggerPrimitivesReader") << " Identical ALCTs #" << data_trknmb;
1597  stubs_comparison[0].nStub_emul = j + 1;
1598  stubs_comparison[0].has_emul = true;
1599  stubs_comparison[0].quality_emul = alctV_emul[j].getQuality();
1600  stubs_comparison[0].key_WG_emul = alctV_emul[j].getKeyWG();
1601  stubs_comparison[0].bx_emul = alctV_emul[j].getBX();
1602  stubs_comparison[0].trknmb_emul = emul_trknmb;
1603  GlobalPoint gp_alct_emul(getGlobalPosition(detid.rawId(), emul_wiregroup, 60));
1604  stubs_comparison[0].eta_emul = gp_alct_emul.eta();
1605  stubs_comparison[0].bx_corr_emul = emul_corr_bx;
1606  bookedalctV_emul[j] = true;
1607  break;
1608  } else {
1609  LogTrace("CSCTriggerPrimitivesReader")
1610  << " Different ALCTs #" << data_trknmb << " in ME" << ((endc == 1) ? "+" : "-") << stat << "/"
1611  << ring << "/" << cham;
1612  }
1613 
1614  } //loop emul
1615  if (debug and stubs_comparison[0].key_WG_data != stubs_comparison[0].key_WG_emul)
1616  LogTrace("CSCTriggerPrimitivesReader")
1617  << " not matched ALCT from data " << alctV_data[i] << " stubs_comparison 0 key_WG_data "
1618  << stubs_comparison[0].key_WG_data << " key_WG_emul " << stubs_comparison[0].key_WG_emul;
1619  //if (stat==1) std::cout <<" stub_tree filled , ring "<< stubs_comparison[0].ring << std::endl;
1620  //cout <<"ALCT data BX "<< stubs_comparison[0].bx_data <<" WG "<< stubs_comparison[0].key_WG_data <<" emul BX "<< stubs_comparison[0].bx_emul<<" emul BX corrected "<< stubs_comparison[0].bx_corr_emul <<" WG "<< stubs_comparison[0].key_WG_emul << endl;
1621  stub_tree[0]->Fill();
1622  } //loop data
1623  for (int i = 0; i < nemul; i++) {
1624  if (alctV_emul[i].isValid() == 0 or bookedalctV_emul[i])
1625  continue;
1626  int emul_bx = alctV_emul[i].getBX();
1628  stubs_comparison[0].firstfill = firstfill;
1629  if (firstfill)
1630  firstfill = false;
1632  stubs_comparison[0].endcap = endc;
1634  stubs_comparison[0].ring = ring;
1636  stubs_comparison[0].chambertype = detid.iChamberType();
1637  stubs_comparison[0].totStubs_data = ndata;
1638  stubs_comparison[0].totStubs_emul = nemul;
1640  stubs_comparison[0].nStub_data = -1;
1641  stubs_comparison[0].nStub_emul = i + 1;
1642  stubs_comparison[0].has_data = false;
1643  stubs_comparison[0].has_emul = true;
1644  stubs_comparison[0].trknmb_emul = alctV_emul[i].getTrknmb();
1645  stubs_comparison[0].quality_emul = alctV_emul[i].getQuality();
1646  stubs_comparison[0].key_WG_emul = alctV_emul[i].getKeyWG();
1647  stubs_comparison[0].bx_emul = alctV_emul[i].getBX();
1648  stubs_comparison[0].fullbx_emul = alctV_emul[i].getFullBX();
1649  GlobalPoint gp_alct_emul(getGlobalPosition(detid.rawId(), alctV_emul[i].getKeyWG(), 60));
1650  stubs_comparison[0].eta_emul = gp_alct_emul.eta();
1651  // Emulator BX re-calculated for comparison with BX in the data.
1652  emul_corr_bx = emul_bx - rawhit_tbin_offset + register_delay;
1653  if (dataIsAnotherMC_)
1654  emul_corr_bx = emul_bx;
1655  stubs_comparison[0].bx_corr_emul = emul_corr_bx;
1656  stub_tree[0]->Fill();
1657  if (debug)
1658  LogTrace("CSCTriggerPrimitivesReader") << "not matched ALCT from emulation " << alctV_emul[i];
1659 
1660  } //loop emul
1661  }
1662  }
1663  }
1664  }
1665 } // compare ALCT

References funct::abs(), badChambers_, MyStubComparison::bx_corr_emul, MyStubComparison::bx_data, MyStubComparison::bx_emul, relativeConstraints::cham, CSCDetId::chamber(), MyStubComparison::chamber, chamberIX(), chamberIXi(), chamberSerial(), MyStubComparison::chambertype, checkBadChambers_, dataIsAnotherMC_, debug, MyStubComparison::endcap, CSCDetId::endcap(), PV3DBase< T, PVType, FrameType >::eta(), MyStubComparison::eta_data, MyStubComparison::eta_emul, Event_, event_tree, eventsAnalyzed, MyStubComparison::firstfill, MyStubComparison::fullbx_data, MyStubComparison::fullbx_emul, getCSCType(), getGlobalPosition(), hAlctCompFound, hAlctCompFound2, hAlctCompFound2i, hAlctCompFound2x, hAlctCompFoundCsc, hAlctCompMatch, hAlctCompMatch2, hAlctCompMatch2i, hAlctCompMatch2x, hAlctCompMatchCsc, hAlctCompSameN2, hAlctCompSameN2i, hAlctCompSameN2x, hAlctCompSameNCsc, hAlctCompTotal, hAlctCompTotal2, hAlctCompTotal2i, hAlctCompTotal2x, hAlctCompTotalCsc, MyStubComparison::has_data, MyStubComparison::has_emul, mps_fire::i, CSCDetId::iChamberType(), TreePerStub::init(), MyStubComparison::init(), CSCBadChambers::isInBadChamber(), dqmiolumiharvest::j, MyStubComparison::key_WG_data, MyStubComparison::key_WG_emul, LogTrace, maxRing(), MyStubComparison::nEvents, MyStubComparison::nStub_data, MyStubComparison::nStub_emul, or, perStub, MyStubComparison::quality_data, MyStubComparison::quality_emul, DetId::rawId(), relativeConstraints::ring, CSCDetId::ring(), MyStubComparison::ring, RUN_, hgcalPlots::stat, CSCDetId::station(), MyStubComparison::station, stub_tree, stubs_comparison, TreePerStub::t_chamber, TreePerStub::t_endcap, TreePerStub::t_EventNumberAnalyzed, TreePerStub::t_nStubs, TreePerStub::t_nStubs_readout, TreePerStub::t_ring, TreePerStub::t_station, MyStubComparison::totStubs_data, MyStubComparison::totStubs_emul, MyStubComparison::totStubs_emul_readout, CSCDetId::triggerCscId(), CSCDetId::triggerSector(), MyStubComparison::trknmb_data, and MyStubComparison::trknmb_emul.

Referenced by compare().

◆ compareCLCTs()

void CSCTriggerPrimitivesReader::compareCLCTs ( const CSCCLCTDigiCollection clcts_data,
const CSCCLCTDigiCollection clcts_emul,
const CSCCLCTPreTriggerDigiCollection pretrigs_emul 
)
private

Definition at line 1667 of file CSCTriggerPrimitivesReader.cc.

1669  {
1670  // Number of Tbins before pre-trigger for raw cathode hits.
1671  const int tbin_cathode_offset = 7;
1672  //const int tbin_cathode_offset = 8;//in MC, it became 8, Tao
1673  const int pretrig_trig_zone = 5; // max distance between CLCT key hs and pretrigger hs
1674 
1675  // Loop over all chambers in search for CLCTs.
1676  std::vector<CSCCLCTDigi>::const_iterator pd, pe;
1677  std::vector<CSCCLCTPreTriggerDigi>::const_iterator pretrig;
1678  perStub[2].init(RUN_, Event_);
1679  perStub[3].init(RUN_, Event_);
1680  for (int endc = 1; endc <= 2; endc++) {
1681  for (int stat = 1; stat <= 4; stat++) {
1682  for (int ring = 1; ring <= maxRing(stat); ring++) {
1683  for (int cham = 1; cham <= 36; cham++) {
1684  // Calculate DetId. 0th layer means whole chamber.
1685  CSCDetId detid(endc, stat, ring, cham, 0);
1686 
1687  // Skip chambers marked as bad.
1689  continue;
1690 
1691  std::vector<CSCCLCTDigi> clctV_data, clctV_emul;
1692  const auto& drange = clcts_data->get(detid);
1693  for (auto digiIt = drange.first; digiIt != drange.second; digiIt++) {
1694  if ((*digiIt).isValid()) {
1695  clctV_data.push_back(*digiIt);
1696  }
1697  }
1698 
1699  const auto& erange = clcts_emul->get(detid);
1700  std::vector<bool> bookedclctV_emul;
1701  for (auto digiIt = erange.first; digiIt != erange.second; digiIt++) {
1702  if ((*digiIt).isValid()) {
1703  for (const auto& pclct : clctV_emul) {
1704  if (digiIt->getBX() != pclct.getBX() and abs(digiIt->getBX() - pclct.getBX()) < 5)
1705  LogTrace("CSCTriggerPrimitivesReader")
1706  << "Two CLCTs very close in timing!!! Special event: first clct " << pclct << " second clct "
1707  << *digiIt << std::endl;
1708  }
1709  clctV_emul.push_back(*digiIt);
1710  bookedclctV_emul.push_back(false);
1711  }
1712  }
1713 
1714  std::vector<CSCCLCTPreTriggerDigi> pretrigV_emul;
1715  const auto& pretrigrange = pretrigs_emul->get(detid);
1716  for (auto pretrigIt = pretrigrange.first; pretrigIt != pretrigrange.second; pretrigIt++) {
1717  if ((*pretrigIt).isValid()) {
1718  pretrigV_emul.push_back(*pretrigIt);
1719  }
1720  }
1721 
1722  int ndata = clctV_data.size();
1723  int nemul = clctV_emul.size();
1724  if (ndata == 0 && nemul == 0)
1725  continue;
1726  bool firstfill = true;
1727  int nemul_readout = 0;
1728  for (pe = clctV_emul.begin(); pe != clctV_emul.end(); pe++) {
1729  for (pd = clctV_data.begin(); pd != clctV_data.end(); pd++) {
1730  int emul_bx = (*pe).getBX();
1731  int corr_bx = ((*pd).getFullBX() + emul_bx - tbin_cathode_offset) & 0x03;
1732  int bx_data = pd->getBX();
1733  //if (corr_bx == bx_data or abs(pe->getKeyStrip() - pd->getKeyStrip())<=1){//if emulated BX after correction is same as data bx, it will be readout
1734  if (corr_bx == bx_data) { //if emulated BX after correction is same as data bx, it will be readout
1735  nemul_readout++;
1736  break;
1737  }
1738  }
1739  }
1740 
1741  if (debug or nemul > ndata or (ndata != nemul) or ndata != nemul_readout) {
1742  LogTrace("CSCTriggerPrimitivesReader")
1743  << " CLCTs from data " << ndata << " CLCTs from emul " << nemul << " readout " << nemul_readout;
1744  ostringstream strstrm;
1745  strstrm << "\n--- ME" << ((detid.endcap() == 1) ? "+" : "-") << detid.station() << "/" << detid.ring()
1746  << "/" << detid.chamber() << " (sector " << detid.triggerSector() << " trig id. "
1747  << detid.triggerCscId() << "):\n";
1748  strstrm << " **** " << ndata << " valid data CLCTs found:\n";
1749  for (pd = clctV_data.begin(); pd != clctV_data.end(); pd++) {
1750  strstrm << " " << (*pd) << " Full BX = " << (*pd).getFullBX() << "\n";
1751  }
1752  strstrm << " **** " << nemul << " valid emul CLCTs found:\n";
1753  for (pe = clctV_emul.begin(); pe != clctV_emul.end(); pe++) {
1754  strstrm << " " << (*pe);
1755  for (pd = clctV_data.begin(); pd != clctV_data.end(); pd++) {
1756  if ((*pd).getTrknmb() == (*pe).getTrknmb() or abs((*pe).getKeyStrip() - (*pd).getKeyStrip()) < 5) {
1757  int emul_bx = (*pe).getBX();
1758  int corr_bx = ((*pd).getFullBX() + emul_bx - tbin_cathode_offset) & 0x03;
1759  strstrm << " Corr BX = " << corr_bx;
1760  break;
1761  }
1762  }
1763  strstrm << "\n";
1764  }
1765  LogTrace("CSCTriggerPrimitivesReader") << strstrm.str();
1766  }
1767  if (nemul_readout > 2) { //reduce nemul_readout to 2 by hand
1768  //cout <<"CLCT matching nemul readout is "<< nemul_readout <<", larger than 2. reduce it to 2 by hand"<<endl;
1769  nemul_readout = 2;
1770  }
1771 
1772  //Per event Fill, From Luca
1773  //Data, add HS quality later
1774  int perEv_nStub_data = 0;
1775  int perEv_nStub_emul = 0;
1776  perStub[2].init(RUN_, Event_);
1777  perStub[3].init(RUN_, Event_);
1778  for (pd = clctV_data.begin(); pd != clctV_data.end(); pd++) {
1779  perEv_nStub_data++;
1780  }
1781  perStub[2].t_endcap = endc;
1782  perStub[2].t_station = stat;
1783  perStub[2].t_chamber = cham;
1784  perStub[2].t_ring = ring;
1786  perStub[2].t_nStubs = ndata;
1787  perStub[2].t_nStubs_readout = ndata;
1788  event_tree[2]->Fill();
1789  //Emul
1790  for (pe = clctV_emul.begin(); pe != clctV_emul.end(); pe++) {
1791  perEv_nStub_emul++;
1792  }
1793  perStub[3].t_endcap = endc;
1794  perStub[3].t_station = stat;
1795  perStub[3].t_chamber = cham;
1796  perStub[3].t_ring = ring;
1798  perStub[3].t_nStubs = nemul;
1799  perStub[3].t_nStubs_readout = nemul_readout;
1800  event_tree[3]->Fill();
1801 
1802  int csctype = getCSCType(detid);
1803  hClctCompFoundCsc[endc - 1][csctype]->Fill(cham);
1804  int ix = chamberIX(detid);
1805  int ix2 = chamberIXi(detid);
1806  if (detid.station() > 1 && detid.ring() == 1) {
1807  hClctCompFound2x->Fill(ix, detid.chamber() * 2);
1808  } else {
1809  hClctCompFound2->Fill(ix, detid.chamber());
1810  }
1811  hClctCompFound2i->Fill(ix2, detid.chamber());
1812  if (ndata != nemul) {
1813  LogTrace("CSCTriggerPrimitivesReader")
1814  //cerr
1815  << " +++ Different numbers of CLCTs found in ME" << ((endc == 1) ? "+" : "-") << stat << "/" << ring
1816  << "/" << cham << ": data = " << ndata << " emulator = " << nemul << " +++\n";
1817  } else {
1818  hClctCompSameNCsc[endc - 1][csctype]->Fill(cham);
1819  if (detid.station() > 1 && detid.ring() == 1) {
1820  hClctCompSameN2x->Fill(ix, detid.chamber() * 2);
1821  } else {
1822  hClctCompSameN2->Fill(ix, detid.chamber());
1823  }
1824  hClctCompSameN2i->Fill(ix2, detid.chamber());
1825  }
1826  int i = -1;
1827  int testwg = 20;
1828  for (pd = clctV_data.begin(); pd != clctV_data.end(); pd++) {
1829  i++;
1830  if ((*pd).isValid() == 0)
1831  continue;
1832  int data_trknmb = (*pd).getTrknmb();
1833  int data_quality = (*pd).getQuality();
1834  int data_pattern = (*pd).getPattern();
1835  int data_striptype = (*pd).getStripType();
1836  int data_bend = (*pd).getBend();
1837  int data_keystrip = (*pd).getKeyStrip();
1838  int data_cfeb = (*pd).getCFEB();
1839  int data_bx = (*pd).getBX();
1840  int fullBX = (*pd).getFullBX(); // 12-bit full BX
1841 
1842  if (data_keystrip >= 128 and stat == 1 and ring == 1)
1843  testwg = 5;
1844  else
1845  testwg = 20;
1846 
1848  stubs_comparison[1].firstfill = firstfill;
1849  if (firstfill)
1850  firstfill = false;
1852  stubs_comparison[1].endcap = endc;
1854  stubs_comparison[1].ring = ring;
1856  stubs_comparison[1].chambertype = detid.iChamberType();
1857  stubs_comparison[1].totStubs_data = ndata;
1858  stubs_comparison[1].totStubs_emul = nemul;
1859  stubs_comparison[1].totStubs_emul_readout = nemul_readout;
1860  stubs_comparison[1].nStub_data = i + 1;
1861  stubs_comparison[1].has_data = true;
1862  stubs_comparison[1].quality_data = (*pd).getQuality();
1863  stubs_comparison[1].key_hs_data = (*pd).getKeyStrip();
1864  stubs_comparison[1].bend_data = (*pd).getBend();
1865  stubs_comparison[1].pattern_data = (*pd).getPattern();
1866  stubs_comparison[1].bx_data = (*pd).getBX();
1867  stubs_comparison[1].fullbx_data = (*pd).getFullBX();
1868  stubs_comparison[1].trknmb_data = data_trknmb;
1869  GlobalPoint gp_clct_data(getGlobalPosition(detid.rawId(), testwg, (*pd).getKeyStrip()));
1870  stubs_comparison[1].phi_data = gp_clct_data.phi();
1871 
1872  int j = -1;
1873  for (pe = clctV_emul.begin(); pe != clctV_emul.end(); pe++) {
1874  j++;
1875  if ((*pe).isValid() == 0)
1876  continue;
1877  if (bookedclctV_emul[j])
1878  continue; //used alct
1879  int emul_trknmb = (*pe).getTrknmb();
1880  int emul_quality = (*pe).getQuality();
1881  int emul_pattern = (*pe).getPattern();
1882  int emul_striptype = (*pe).getStripType();
1883  int emul_bend = (*pe).getBend();
1884  int emul_keystrip = (*pe).getKeyStrip();
1885  int emul_cfeb = (*pe).getCFEB();
1886  int emul_bx = (*pe).getBX();
1887 
1888  if (abs(data_keystrip - emul_keystrip) <= 2) {
1889  // Emulator BX re-calculated using 12-bit full BX number.
1890  // Used for comparison with BX in the data.
1891  int emul_corr_bx = (fullBX + emul_bx - tbin_cathode_offset) & 0x03;
1892  //std::cout <<"CLCT data_bx "<< data_bx <<" emul_corr_bx "<< emul_corr_bx << std::endl;
1893  if (dataIsAnotherMC_)
1894  emul_corr_bx = (emul_bx & 0x03);
1895  if (ndata == nemul) {
1896  hClctCompTotalCsc[endc - 1][csctype]->Fill(cham);
1897  if (detid.station() > 1 && detid.ring() == 1) {
1898  hClctCompTotal2x->Fill(ix, detid.chamber() * 2);
1899  } else {
1900  hClctCompTotal2->Fill(ix, detid.chamber());
1901  }
1902  hClctCompTotal2i->Fill(ix2, detid.chamber());
1903  }
1904  if (data_quality == emul_quality && data_pattern == emul_pattern && data_striptype == emul_striptype &&
1905  data_bend == emul_bend && data_keystrip == emul_keystrip && data_cfeb == emul_cfeb) {
1906  if (ndata == nemul) {
1907  hClctCompMatchCsc[endc - 1][csctype]->Fill(cham);
1908  if (detid.station() > 1 && detid.ring() == 1) {
1909  hClctCompMatch2x->Fill(ix, detid.chamber() * 2);
1910  } else {
1911  hClctCompMatch2->Fill(ix, detid.chamber());
1912  }
1913  hClctCompMatch2i->Fill(ix2, detid.chamber());
1914  }
1915  if (debug)
1916  LogTrace("CSCTriggerPrimitivesReader") << " Identical CLCTs #" << data_trknmb;
1917  } else {
1918  LogTrace("CSCTriggerPrimitivesReader")
1919  << " Different CLCTs #" << data_trknmb << " in ME" << ((endc == 1) ? "+" : "-") << stat
1920  << "/" << ring << "/" << cham << " data_bx " << data_bx << " emul_corr_bx " << emul_corr_bx;
1921  }
1922  stubs_comparison[1].nStub_emul = j + 1;
1923  stubs_comparison[1].has_emul = true;
1924  stubs_comparison[1].quality_emul = (*pe).getQuality();
1925  stubs_comparison[1].key_hs_emul = (*pe).getKeyStrip();
1926  stubs_comparison[1].bend_emul = (*pe).getBend();
1927  stubs_comparison[1].pattern_emul = (*pe).getPattern();
1928  stubs_comparison[1].bx_emul = (*pe).getBX();
1929  stubs_comparison[1].bx_corr_emul = emul_corr_bx;
1930  stubs_comparison[1].trknmb_emul = emul_trknmb;
1931  GlobalPoint gp_clct_emul(getGlobalPosition(detid.rawId(), testwg, (*pe).getKeyStrip()));
1932  stubs_comparison[1].phi_emul = gp_clct_emul.phi();
1933  bookedclctV_emul[j] = true;
1934 
1935  //int mingap_trig_pretrig = pretrig_trig_zone*2;
1936  int num_pretrig = 0;
1937  for (pretrig = pretrigV_emul.begin(); pretrig != pretrigV_emul.end(); pretrig++) {
1938  if ((*pretrig).getBX() != (*pe).getBX())
1939  continue;
1940  int hsgap = std::abs((*pretrig).getKeyStrip() - (*pe).getKeyStrip());
1941  bool samechamber = true;
1942  if (stat == 1 and ring == 1)
1943  samechamber = (((*pretrig).getKeyStrip() < 128 and (*pe).getKeyStrip() < 128) ||
1944  ((*pretrig).getKeyStrip() >= 128 and (*pe).getKeyStrip() >= 128));
1945  if (not samechamber)
1946  continue;
1947 
1948  if (hsgap <= pretrig_trig_zone)
1949  num_pretrig++;
1950  else
1951  continue;
1952  if ((*pretrig).getPattern() > stubs_comparison[1].maxpattern_pretrig)
1953  stubs_comparison[1].maxpattern_pretrig = (*pretrig).getPattern();
1954  if ((*pretrig).getQuality() > stubs_comparison[1].maxquality_pretrig) {
1955  stubs_comparison[1].quality_pretrig = (*pretrig).getQuality();
1956  stubs_comparison[1].key_hs_pretrig = (*pretrig).getKeyStrip();
1957  stubs_comparison[1].bend_pretrig = (*pretrig).getBend();
1958  stubs_comparison[1].pattern_pretrig = (*pretrig).getPattern();
1959  stubs_comparison[1].bx_pretrig = (*pretrig).getBX();
1960  }
1961  }
1962  stubs_comparison[1].npretrig = num_pretrig;
1963  break;
1964  } //if (data_trknmb == emul_trknmb)
1965  } //loop emul
1966  if (debug and stubs_comparison[1].key_hs_data != stubs_comparison[1].key_hs_emul)
1967  LogTrace("CSCTriggerPrimitivesReader")
1968  << "CSCDetid " << detid << " not matched CLCT from data " << (*pd)
1969  << " stubs_comparison 1 key_hs_data " << stubs_comparison[1].key_hs_data << " key_hs_emul "
1970  << stubs_comparison[1].key_hs_emul << endl;
1971  //cout <<"CLCT data BX "<< stubs_comparison[1].bx_data <<" emul BX "<< stubs_comparison[1].bx_emul<<" emul BX corrected "<< stubs_comparison[1].bx_corr_emul << endl;
1972  stub_tree[1]->Fill();
1973  } //loop data
1974  for (int k = 0; k < nemul; k++) {
1975  if (clctV_emul[i].isValid() == 0)
1976  continue;
1977  if (bookedclctV_emul[k])
1978  continue;
1980  stubs_comparison[1].firstfill = firstfill;
1981  if (firstfill)
1982  firstfill = false;
1984  stubs_comparison[1].endcap = endc;
1986  stubs_comparison[1].ring = ring;
1988  stubs_comparison[1].chambertype = detid.iChamberType();
1989  stubs_comparison[1].totStubs_data = ndata;
1990  stubs_comparison[1].totStubs_emul = nemul;
1991  stubs_comparison[1].totStubs_emul_readout = nemul_readout;
1992  stubs_comparison[1].trknmb_emul = clctV_emul[i].getTrknmb();
1993  stubs_comparison[1].nStub_data = -1;
1994  stubs_comparison[1].has_data = false;
1995  stubs_comparison[1].nStub_emul = k + 1;
1996  stubs_comparison[1].has_emul = true;
1997  stubs_comparison[1].quality_emul = clctV_emul[k].getQuality();
1998  stubs_comparison[1].key_hs_emul = clctV_emul[k].getKeyStrip();
1999  stubs_comparison[1].bend_emul = clctV_emul[k].getBend();
2000  stubs_comparison[1].pattern_emul = clctV_emul[k].getPattern();
2001  stubs_comparison[1].bx_emul = clctV_emul[k].getBX();
2002  stubs_comparison[1].fullbx_emul = clctV_emul[k].getFullBX();
2003  if (clctV_emul[k].getKeyStrip() >= 128 and stat == 1 and ring == 1)
2004  testwg = 5;
2005  else
2006  testwg = 20;
2007  // Emulator BX NOT Known from the data.
2008  GlobalPoint gp_clct_emul(getGlobalPosition(detid.rawId(), testwg, clctV_emul[k].getKeyStrip()));
2009  stubs_comparison[1].phi_emul = gp_clct_emul.phi();
2010  bookedclctV_emul[k] = true;
2011  stub_tree[1]->Fill();
2012  }
2013  }
2014  }
2015  }
2016  } // for all chambers
2017 } // compareCLCTs

References funct::abs(), badChambers_, MyStubComparison::bend_data, MyStubComparison::bend_emul, MyStubComparison::bend_pretrig, MyStubComparison::bx_corr_emul, MyStubComparison::bx_data, MyStubComparison::bx_emul, MyStubComparison::bx_pretrig, relativeConstraints::cham, CSCDetId::chamber(), MyStubComparison::chamber, chamberIX(), chamberIXi(), MyStubComparison::chambertype, checkBadChambers_, dataIsAnotherMC_, debug, MyStubComparison::endcap, CSCDetId::endcap(), Event_, event_tree, eventsAnalyzed, MyStubComparison::firstfill, MyStubComparison::fullbx_data, MyStubComparison::fullbx_emul, MuonDigiCollection< IndexType, DigiType >::get(), getCSCType(), getGlobalPosition(), MyStubComparison::has_data, MyStubComparison::has_emul, hClctCompFound2, hClctCompFound2i, hClctCompFound2x, hClctCompFoundCsc, hClctCompMatch2, hClctCompMatch2i, hClctCompMatch2x, hClctCompMatchCsc, hClctCompSameN2, hClctCompSameN2i, hClctCompSameN2x, hClctCompSameNCsc, hClctCompTotal2, hClctCompTotal2i, hClctCompTotal2x, hClctCompTotalCsc, mps_fire::i, CSCDetId::iChamberType(), TreePerStub::init(), MyStubComparison::init(), CSCBadChambers::isInBadChamber(), dqmiolumiharvest::j, dqmdumpme::k, MyStubComparison::key_hs_data, MyStubComparison::key_hs_emul, MyStubComparison::key_hs_pretrig, LogTrace, MyStubComparison::maxpattern_pretrig, MyStubComparison::maxquality_pretrig, maxRing(), MyStubComparison::nEvents, MyStubComparison::npretrig, MyStubComparison::nStub_data, MyStubComparison::nStub_emul, or, MyStubComparison::pattern_data, MyStubComparison::pattern_emul, MyStubComparison::pattern_pretrig, perStub, PV3DBase< T, PVType, FrameType >::phi(), MyStubComparison::phi_data, MyStubComparison::phi_emul, MyStubComparison::quality_data, MyStubComparison::quality_emul, MyStubComparison::quality_pretrig, DetId::rawId(), CSCDetId::ring(), relativeConstraints::ring, MyStubComparison::ring, RUN_, hgcalPlots::stat, CSCDetId::station(), MyStubComparison::station, stub_tree, stubs_comparison, TreePerStub::t_chamber, TreePerStub::t_endcap, TreePerStub::t_EventNumberAnalyzed, TreePerStub::t_nStubs, TreePerStub::t_nStubs_readout, TreePerStub::t_ring, TreePerStub::t_station, MyStubComparison::totStubs_data, MyStubComparison::totStubs_emul, MyStubComparison::totStubs_emul_readout, CSCDetId::triggerCscId(), CSCDetId::triggerSector(), MyStubComparison::trknmb_data, and MyStubComparison::trknmb_emul.

Referenced by compare().

◆ compareLCTs()

void CSCTriggerPrimitivesReader::compareLCTs ( const CSCCorrelatedLCTDigiCollection lcts_data,
const CSCCorrelatedLCTDigiCollection lcts_emul,
const CSCALCTDigiCollection alcts_data,
const CSCCLCTDigiCollection clcts_data 
)
private

Definition at line 2019 of file CSCTriggerPrimitivesReader.cc.

2022  {
2023  // Need ALCT and CLCT digi collections to convert emulator bx into
2024  // hardware bx.
2025  // Loop over all chambers in search for correlated LCTs.
2026  std::vector<CSCCorrelatedLCTDigi>::const_iterator pd, pe;
2027  for (int endc = 1; endc <= 2; endc++) {
2028  for (int stat = 1; stat <= 4; stat++) {
2029  for (int ring = 1; ring <= maxRing(stat); ring++) {
2030  for (int cham = 1; cham <= 36; cham++) {
2031  // Calculate DetId. 0th layer means whole chamber.
2032  CSCDetId detid(endc, stat, ring, cham, 0);
2033 
2034  // Skip chambers marked as bad.
2036  continue;
2037 
2038  std::vector<CSCCorrelatedLCTDigi> lctV_data, lctV_emul;
2039  std::vector<bool> bookedlctV_emul;
2040  const auto& drange = lcts_data->get(detid);
2041  for (auto digiIt = drange.first; digiIt != drange.second; digiIt++) {
2042  if ((*digiIt).isValid()) {
2043  lctV_data.push_back(*digiIt);
2044  }
2045  }
2046 
2047  const auto& erange = lcts_emul->get(detid);
2048  for (auto digiIt = erange.first; digiIt != erange.second; digiIt++) {
2049  if ((*digiIt).isValid()) {
2050  lctV_emul.push_back(*digiIt);
2051  bookedlctV_emul.push_back(false);
2052  }
2053  }
2054 
2055  int ndata = lctV_data.size();
2056  int nemul = lctV_emul.size();
2057  if (ndata == 0 && nemul == 0)
2058  continue;
2059  bool firstfill = true;
2060  int nemul_readout = 0;
2061  for (pe = lctV_emul.begin(); pe != lctV_emul.end(); pe++) {
2062  for (pd = lctV_data.begin(); pd != lctV_data.end(); pd++) {
2063  int bx_data = pd->getBX();
2064  int bx_corr = convertBXofLCT((*pe).getBX(), detid, alcts_data, clcts_data);
2065  if ((bx_data == bx_corr) or (abs(pe->getKeyWG() - pd->getKeyWG()) <= 2)) {
2066  nemul_readout++;
2067  break;
2068  }
2069  }
2070  }
2071 
2072  if (debug or nemul > ndata or (nemul_readout != ndata) or nemul != ndata) {
2073  LogTrace("CSCTriggerPrimitivesReader")
2074  << " LCTs from data " << ndata << " LCTs from emul " << nemul << " readout " << nemul_readout;
2075  ostringstream strstrm;
2076  strstrm << "\n--- ME" << ((detid.endcap() == 1) ? "+" : "-") << detid.station() << "/" << detid.ring()
2077  << "/" << detid.chamber() << " (sector " << detid.triggerSector() << " trig id. "
2078  << detid.triggerCscId() << "):\n";
2079  strstrm << " **** " << ndata << " valid data LCTs found:\n";
2080  for (pd = lctV_data.begin(); pd != lctV_data.end(); pd++) {
2081  strstrm << " " << (*pd);
2082  }
2083  strstrm << "\n **** " << nemul << " valid emul LCTs found:\n";
2084  for (pe = lctV_emul.begin(); pe != lctV_emul.end(); pe++) {
2085  strstrm << " " << (*pe);
2086  strstrm << " corr BX = " << convertBXofLCT((*pe).getBX(), detid, alcts_data, clcts_data);
2087  strstrm << " LCT pattern = " << (*pe).getPattern();
2088  strstrm << "\n";
2089  }
2090  LogTrace("CSCTriggerPrimitivesReader") << strstrm.str();
2091  //std::cout <<"CompareLCTs "<< strstrm.str()<< std::endl;
2092  }
2093  if (nemul_readout > 2) { //reduce nemul_readout to 2 by hand
2094  //cout <<"LCT matching nemul readout is "<< nemul_readout <<", larger than 2. reduce it to 2 by hand"<<endl;
2095  nemul_readout = 2;
2096  }
2097 
2098  //
2099  //Data, add HS quality later
2100  int perEv_nStub_data = 0;
2101  int perEv_nStub_emul = 0;
2102  perStub[4].init(RUN_, Event_);
2103  perStub[5].init(RUN_, Event_);
2104  for (pd = lctV_data.begin(); pd != lctV_data.end(); pd++) {
2105  perEv_nStub_data++;
2106  }
2107  perStub[4].t_endcap = endc;
2108  perStub[4].t_station = stat;
2109  perStub[4].t_chamber = cham;
2110  perStub[4].t_ring = ring;
2112  perStub[4].t_nStubs = ndata;
2113  perStub[4].t_nStubs_readout = ndata;
2114  event_tree[4]->Fill();
2115  //Emul
2116  for (pe = lctV_emul.begin(); pe != lctV_emul.end(); pe++) {
2117  perEv_nStub_emul++;
2118  }
2119  perStub[5].t_endcap = endc;
2120  perStub[5].t_station = stat;
2121  perStub[5].t_chamber = cham;
2122  perStub[5].t_ring = ring;
2124  perStub[5].t_nStubs = nemul;
2125  perStub[5].t_nStubs_readout = nemul_readout;
2126  event_tree[5]->Fill();
2127 
2128  int csctype = getCSCType(detid);
2129  hLctCompFoundCsc[endc - 1][csctype]->Fill(cham);
2130  int ix = chamberIX(detid);
2131  int ix2 = chamberIXi(detid);
2132  if (detid.station() > 1 && detid.ring() == 1) {
2133  hLCTCompFound2x->Fill(ix, detid.chamber() * 2);
2134  } else {
2135  hLCTCompFound2->Fill(ix, detid.chamber());
2136  }
2137  hLCTCompFound2i->Fill(ix2, detid.chamber());
2138  if (ndata != nemul) {
2139  LogTrace("CSCTriggerPrimitivesReader")
2140  //cerr
2141  << " +++ Different numbers of LCTs found in ME" << ((endc == 1) ? "+" : "-") << stat << "/" << ring
2142  << "/" << cham << ": data = " << ndata << " emulator = " << nemul << " +++\n";
2143  } else {
2144  hLctCompSameNCsc[endc - 1][csctype]->Fill(cham);
2145  if (detid.station() > 1 && detid.ring() == 1) {
2146  hLCTCompSameN2x->Fill(ix, detid.chamber() * 2);
2147  } else {
2148  hLCTCompSameN2->Fill(ix, detid.chamber());
2149  }
2150  hLCTCompSameN2i->Fill(ix2, detid.chamber());
2151  }
2152  int i = -1;
2153  for (pd = lctV_data.begin(); pd != lctV_data.end(); pd++) {
2154  i++;
2155  if ((*pd).isValid() == 0)
2156  continue;
2157  int data_trknmb = (*pd).getTrknmb();
2158  int data_quality = (*pd).getQuality();
2159  int data_wiregroup = (*pd).getKeyWG();
2160  int data_keystrip = (*pd).getStrip();
2161  int data_pattern = (*pd).getCLCTPattern();
2162  int data_striptype = (*pd).getStripType();
2163  int data_bend = (*pd).getBend();
2164  int data_bx = (*pd).getBX();
2165 
2167  stubs_comparison[2].firstfill = firstfill;
2168  if (firstfill)
2169  firstfill = false;
2171  stubs_comparison[2].endcap = endc;
2173  stubs_comparison[2].ring = ring;
2175  stubs_comparison[2].chambertype = detid.iChamberType();
2176  stubs_comparison[2].totStubs_data = ndata;
2177  stubs_comparison[2].totStubs_emul = nemul;
2178  stubs_comparison[2].totStubs_emul_readout = nemul_readout;
2179  stubs_comparison[2].nStub_data = i + 1;
2180  stubs_comparison[2].has_data = true;
2181  stubs_comparison[2].quality_data = (*pd).getQuality();
2182  stubs_comparison[2].key_WG_data = (*pd).getKeyWG();
2183  stubs_comparison[2].key_hs_data = (*pd).getStrip();
2184  //cout <<" CSC detid "<< detid <<" LCT in data "<< (*pd) <<" do doesALCTCrossCLCT "<< endl;
2185  stubs_comparison[2].WGcrossHS_data = doesALCTCrossCLCT(detid, (*pd).getKeyWG(), (*pd).getStrip());
2186  stubs_comparison[2].bend_data = (*pd).getBend();
2187  stubs_comparison[2].pattern_data = (*pd).getCLCTPattern();
2188  stubs_comparison[2].bx_data = (*pd).getBX();
2189  stubs_comparison[2].trknmb_data = data_trknmb;
2190  GlobalPoint gp_lct_data(getGlobalPosition(detid.rawId(), (*pd).getKeyWG(), (*pd).getStrip()));
2191  stubs_comparison[2].eta_data = gp_lct_data.eta();
2192  stubs_comparison[2].phi_data = gp_lct_data.phi();
2193  int j = -1;
2194  for (pe = lctV_emul.begin(); pe != lctV_emul.end(); pe++) {
2195  j++;
2196  if ((*pe).isValid() == 0)
2197  continue;
2198  if (bookedlctV_emul[j])
2199  continue; //used alct
2200  int emul_trknmb = (*pe).getTrknmb();
2201  int emul_quality = (*pe).getQuality();
2202  int emul_wiregroup = (*pe).getKeyWG();
2203  int emul_keystrip = (*pe).getStrip();
2204  int emul_pattern = (*pe).getCLCTPattern();
2205  int emul_striptype = (*pe).getStripType();
2206  int emul_bend = (*pe).getBend();
2207  int emul_bx = (*pe).getBX();
2208  if (abs(data_keystrip - emul_keystrip) <= 2 || abs(data_wiregroup - emul_wiregroup) <= 2) {
2209  // Convert emulator BX into hardware BX using full 12-bit
2210  // BX words in ALCT and CLCT digi collections.
2211  int emul_corr_bx = convertBXofLCT(emul_bx, detid, alcts_data, clcts_data);
2212  //std::cout <<"LCT data_bx "<< data_bx <<" emul_corr_bx "<< emul_corr_bx << std::endl;
2213  if (dataIsAnotherMC_)
2214  emul_corr_bx = (emul_bx & 0x01);
2215 
2216  if (ndata == nemul) {
2217  hLctCompTotalCsc[endc - 1][csctype]->Fill(cham);
2218  if (detid.station() > 1 && detid.ring() == 1) {
2219  hLCTCompTotal2x->Fill(ix, detid.chamber() * 2);
2220  } else {
2221  hLCTCompTotal2->Fill(ix, detid.chamber());
2222  }
2223  hLCTCompTotal2i->Fill(ix2, detid.chamber());
2224  }
2225  if (data_quality == emul_quality && data_wiregroup == emul_wiregroup &&
2226  data_keystrip == emul_keystrip && data_pattern == emul_pattern &&
2227  data_striptype == emul_striptype && data_bend == emul_bend) {
2228  if (ndata == nemul) {
2229  hLctCompMatchCsc[endc - 1][csctype]->Fill(cham);
2230  if (detid.station() > 1 && detid.ring() == 1) {
2231  hLCTCompMatch2x->Fill(ix, detid.chamber() * 2);
2232  } else {
2233  hLCTCompMatch2->Fill(ix, detid.chamber());
2234  }
2235  hLCTCompMatch2i->Fill(ix2, detid.chamber());
2236  }
2237  if (debug)
2238  LogTrace("CSCTriggerPrimitivesReader") << " Identical LCTs #" << data_trknmb;
2239  } else {
2240  LogTrace("CSCTriggerPrimitivesReader")
2241  << " Different LCTs #" << data_trknmb << " in ME" << ((endc == 1) ? "+" : "-") << stat
2242  << "/" << ring << "/" << cham << " data_lct bx " << data_bx << " emul bx " << emul_corr_bx;
2243  }
2244  stubs_comparison[2].nStub_emul = j + 1;
2245  stubs_comparison[2].has_emul = true;
2246  stubs_comparison[2].quality_emul = (*pe).getQuality();
2247  stubs_comparison[2].key_WG_emul = (*pe).getKeyWG();
2248  stubs_comparison[2].key_hs_emul = (*pe).getStrip();
2249  stubs_comparison[2].bend_emul = (*pe).getBend();
2250  stubs_comparison[2].pattern_emul = (*pe).getCLCTPattern();
2251  stubs_comparison[2].bx_emul = (*pe).getBX();
2252  //cout <<" CSC detid "<< detid <<" LCT in emul "<< (*pe) <<" do doesALCTCrossCLCT "<< endl;
2253  stubs_comparison[2].WGcrossHS_emul = doesALCTCrossCLCT(detid, (*pe).getKeyWG(), (*pe).getStrip());
2254  stubs_comparison[2].bx_corr_emul = emul_corr_bx;
2255  stubs_comparison[2].trknmb_emul = emul_trknmb;
2256  GlobalPoint gp_lct_emul(getGlobalPosition(detid.rawId(), (*pe).getKeyWG(), (*pe).getStrip()));
2257  stubs_comparison[2].eta_emul = gp_lct_emul.eta();
2258  stubs_comparison[2].phi_emul = gp_lct_emul.phi();
2259  bookedlctV_emul[j] = true;
2260  break;
2261  } //if (data_trknmb == emul_trknmb)
2262  } //loop emul
2263  if (debug and stubs_comparison[2].key_hs_data != stubs_comparison[2].key_hs_emul)
2264  LogTrace("CSCTriggerPrimitivesReader")
2265  << "CSCDetid " << detid << " not matched LCT from Data " << (*pd)
2266  << " stubs_comparison 2 key_hs_data " << stubs_comparison[2].key_hs_data << " key_hs_emul "
2267  << stubs_comparison[2].key_hs_emul << endl;
2268  stub_tree[2]->Fill();
2269  } //loop data
2270  for (int k = 0; k < nemul; k++) {
2271  if (bookedlctV_emul[k])
2272  continue;
2273  if (lctV_emul[i].isValid() == 0)
2274  continue;
2277  stubs_comparison[2].endcap = endc;
2279  stubs_comparison[2].ring = ring;
2281  stubs_comparison[2].chambertype = detid.iChamberType();
2282  stubs_comparison[2].totStubs_data = ndata;
2283  stubs_comparison[2].totStubs_emul = nemul;
2284  stubs_comparison[2].totStubs_emul_readout = nemul_readout;
2285  stubs_comparison[2].trknmb_emul = lctV_emul[i].getTrknmb();
2286  stubs_comparison[2].nStub_data = -1;
2287  stubs_comparison[2].has_data = false;
2288  stubs_comparison[2].nStub_emul = k + 1;
2289  stubs_comparison[2].has_emul = true;
2291  doesALCTCrossCLCT(detid, lctV_emul[k].getKeyWG(), lctV_emul[k].getStrip());
2292  stubs_comparison[2].quality_emul = lctV_emul[k].getQuality();
2293  stubs_comparison[2].key_WG_emul = lctV_emul[k].getKeyWG();
2294  stubs_comparison[2].key_hs_emul = lctV_emul[k].getStrip();
2295  stubs_comparison[2].bend_emul = lctV_emul[k].getBend();
2296  stubs_comparison[2].pattern_emul = lctV_emul[k].getCLCTPattern();
2297  stubs_comparison[2].bx_emul = lctV_emul[k].getBX();
2298  //stubs_comparison[2].fullbx_emul = lctV_emul[k].getFullBX();
2299  // Emulator BX NOT Known from the data.
2300  GlobalPoint gp_lct_emul(getGlobalPosition(detid.rawId(), lctV_emul[k].getKeyWG(), lctV_emul[k].getStrip()));
2301  stubs_comparison[2].eta_emul = gp_lct_emul.eta();
2302  stubs_comparison[2].phi_emul = gp_lct_emul.phi();
2303  bookedlctV_emul[k] = true;
2304  stub_tree[2]->Fill();
2305  }
2306  }
2307  }
2308  }
2309  }
2310 }

References funct::abs(), badChambers_, MyStubComparison::bend_data, MyStubComparison::bend_emul, MyStubComparison::bx_corr_emul, MyStubComparison::bx_data, MyStubComparison::bx_emul, relativeConstraints::cham, CSCDetId::chamber(), MyStubComparison::chamber, chamberIX(), chamberIXi(), MyStubComparison::chambertype, checkBadChambers_, convertBXofLCT(), dataIsAnotherMC_, debug, doesALCTCrossCLCT(), MyStubComparison::endcap, CSCDetId::endcap(), PV3DBase< T, PVType, FrameType >::eta(), MyStubComparison::eta_data, MyStubComparison::eta_emul, Event_, event_tree, eventsAnalyzed, MyStubComparison::firstfill, getCSCType(), getGlobalPosition(), MyStubComparison::has_data, MyStubComparison::has_emul, hLCTCompFound2, hLCTCompFound2i, hLCTCompFound2x, hLctCompFoundCsc, hLCTCompMatch2, hLCTCompMatch2i, hLCTCompMatch2x, hLctCompMatchCsc, hLCTCompSameN2, hLCTCompSameN2i, hLCTCompSameN2x, hLctCompSameNCsc, hLCTCompTotal2, hLCTCompTotal2i, hLCTCompTotal2x, hLctCompTotalCsc, mps_fire::i, CSCDetId::iChamberType(), TreePerStub::init(), MyStubComparison::init(), CSCBadChambers::isInBadChamber(), dqmiolumiharvest::j, dqmdumpme::k, MyStubComparison::key_hs_data, MyStubComparison::key_hs_emul, MyStubComparison::key_WG_data, MyStubComparison::key_WG_emul, LogTrace, maxRing(), MyStubComparison::nEvents, MyStubComparison::nStub_data, MyStubComparison::nStub_emul, or, MyStubComparison::pattern_data, MyStubComparison::pattern_emul, perStub, PV3DBase< T, PVType, FrameType >::phi(), MyStubComparison::phi_data, MyStubComparison::phi_emul, MyStubComparison::quality_data, MyStubComparison::quality_emul, DetId::rawId(), CSCDetId::ring(), relativeConstraints::ring, MyStubComparison::ring, RUN_, hgcalPlots::stat, CSCDetId::station(), MyStubComparison::station, stub_tree, stubs_comparison, TreePerStub::t_chamber, TreePerStub::t_endcap, TreePerStub::t_EventNumberAnalyzed, TreePerStub::t_nStubs, TreePerStub::t_nStubs_readout, TreePerStub::t_ring, TreePerStub::t_station, MyStubComparison::totStubs_data, MyStubComparison::totStubs_emul, MyStubComparison::totStubs_emul_readout, CSCDetId::triggerCscId(), CSCDetId::triggerSector(), MyStubComparison::trknmb_data, MyStubComparison::trknmb_emul, MyStubComparison::WGcrossHS_data, and MyStubComparison::WGcrossHS_emul.

Referenced by compare().

◆ compareMPCLCTs()

void CSCTriggerPrimitivesReader::compareMPCLCTs ( const CSCCorrelatedLCTDigiCollection lcts_data,
const CSCCorrelatedLCTDigiCollection lcts_emul,
const CSCALCTDigiCollection alcts_data,
const CSCCLCTDigiCollection clcts_data 
)
private

Definition at line 2312 of file CSCTriggerPrimitivesReader.cc.

2315  {
2316  // Need ALCT and CLCT digi collections to convert emulator bx into
2317  // hardware bx.
2318  // Loop over all chambers in search for correlated LCTs.
2319  std::vector<CSCCorrelatedLCTDigi>::const_iterator pd, pe;
2320  for (int endc = 1; endc <= 2; endc++) {
2321  for (int stat = 1; stat <= 4; stat++) {
2322  for (int ring = 1; ring <= maxRing(stat); ring++) {
2323  for (int cham = 1; cham <= 36; cham++) {
2324  // Calculate DetId. 0th layer means whole chamber.
2325  CSCDetId detid(endc, stat, ring, cham, 0);
2326 
2327  // Skip chambers marked as bad.
2329  continue;
2330 
2331  std::vector<CSCCorrelatedLCTDigi> lctV_data, lctV_emul;
2332  std::vector<bool> bookedlctV_emul;
2333  const auto& drange = lcts_data->get(detid);
2334  for (auto digiIt = drange.first; digiIt != drange.second; digiIt++) {
2335  if ((*digiIt).isValid()) {
2336  lctV_data.push_back(*digiIt);
2337  }
2338  }
2339 
2340  const auto& erange = lcts_emul->get(detid);
2341  for (auto digiIt = erange.first; digiIt != erange.second; digiIt++) {
2342  if ((*digiIt).isValid()) {
2343  lctV_emul.push_back(*digiIt);
2344  bookedlctV_emul.push_back(false);
2345  }
2346  }
2347 
2348  int ndata = lctV_data.size();
2349  int nemul = lctV_emul.size();
2350  if (ndata == 0 && nemul == 0)
2351  continue;
2352  bool firstfill = true;
2353 
2354  if (debug) {
2355  ostringstream strstrm;
2356  strstrm << "\n--- ME" << ((detid.endcap() == 1) ? "+" : "-") << detid.station() << "/" << detid.ring()
2357  << "/" << detid.chamber() << " (sector " << detid.triggerSector() << " trig id. "
2358  << detid.triggerCscId() << "):\n";
2359  strstrm << " **** " << ndata << " valid data LCTs found:\n";
2360  for (pd = lctV_data.begin(); pd != lctV_data.end(); pd++) {
2361  strstrm << " " << (*pd);
2362  }
2363  strstrm << "\n **** " << nemul << " valid emul LCTs found:\n";
2364  for (pe = lctV_emul.begin(); pe != lctV_emul.end(); pe++) {
2365  strstrm << " " << (*pe);
2366  strstrm << " corr BX = " << convertBXofLCT((*pe).getBX(), detid, alcts_data, clcts_data);
2367  strstrm << " LCT pattern = " << (*pe).getPattern();
2368  strstrm << "\n";
2369  }
2370  LogTrace("CSCTriggerPrimitivesReader") << strstrm.str();
2371  //std::cout <<"CompareLCTs "<< strstrm.str()<< std::endl;
2372  }
2373 
2374  //int ix = chamberIX(detid);
2375  //int ix2 = chamberIXi(detid);
2376  if (ndata != nemul) {
2377  LogTrace("CSCTriggerPrimitivesReader")
2378  << " +++ Different numbers of MPC LCTs found in ME" << ((endc == 1) ? "+" : "-") << stat << "/"
2379  << ring << "/" << cham << ": data = " << ndata << " emulator = " << nemul << " +++\n";
2380  }
2381  /*else {
2382  hLctCompSameNCsc[endc-1][csctype]->Fill(cham);
2383  if(detid.station()>1 && detid.ring()==1) {
2384  hLCTCompSameN2x->Fill(ix,detid.chamber()*2);
2385  }
2386  else {
2387  hLCTCompSameN2->Fill(ix,detid.chamber());
2388  }
2389  hLCTCompSameN2i->Fill(ix2,detid.chamber());
2390  }*/
2391  int i = -1;
2392  for (pd = lctV_data.begin(); pd != lctV_data.end(); pd++) {
2393  i++;
2394  if ((*pd).isValid() == 0)
2395  continue;
2396  int data_trknmb = (*pd).getTrknmb();
2397  int data_quality = (*pd).getQuality();
2398  int data_wiregroup = (*pd).getKeyWG();
2399  int data_keystrip = (*pd).getStrip();
2400  int data_pattern = (*pd).getCLCTPattern();
2401  int data_striptype = (*pd).getStripType();
2402  int data_bend = (*pd).getBend();
2403  int data_bx = (*pd).getBX();
2404 
2406  stubs_comparison[3].firstfill = firstfill;
2407  if (firstfill)
2408  firstfill = false;
2410  stubs_comparison[3].endcap = endc;
2412  stubs_comparison[3].ring = ring;
2414  stubs_comparison[3].chambertype = detid.iChamberType();
2415  stubs_comparison[3].totStubs_data = ndata;
2416  stubs_comparison[3].totStubs_emul = nemul;
2417  stubs_comparison[3].nStub_data = i + 1;
2418  stubs_comparison[3].has_data = true;
2419  stubs_comparison[3].WGcrossHS_data = doesALCTCrossCLCT(detid, (*pd).getKeyWG(), (*pd).getStrip());
2420  stubs_comparison[3].quality_data = (*pd).getQuality();
2421  stubs_comparison[3].key_WG_data = (*pd).getKeyWG();
2422  stubs_comparison[3].key_hs_data = (*pd).getStrip();
2423  stubs_comparison[3].bend_data = (*pd).getBend();
2424  stubs_comparison[3].pattern_data = (*pd).getCLCTPattern();
2425  stubs_comparison[3].bx_data = (*pd).getBX();
2426  stubs_comparison[3].trknmb_data = data_trknmb;
2427  GlobalPoint gp_lct_data(getGlobalPosition(detid.rawId(), (*pd).getKeyWG(), (*pd).getStrip()));
2428  stubs_comparison[3].eta_data = gp_lct_data.eta();
2429  stubs_comparison[3].phi_data = gp_lct_data.phi();
2430  int j = -1;
2431  for (pe = lctV_emul.begin(); pe != lctV_emul.end(); pe++) {
2432  j++;
2433  if ((*pe).isValid() == 0)
2434  continue;
2435  int emul_trknmb = (*pe).getTrknmb();
2436  int emul_quality = (*pe).getQuality();
2437  int emul_wiregroup = (*pe).getKeyWG();
2438  int emul_keystrip = (*pe).getStrip();
2439  int emul_pattern = (*pe).getCLCTPattern();
2440  int emul_striptype = (*pe).getStripType();
2441  int emul_bend = (*pe).getBend();
2442  int emul_bx = (*pe).getBX();
2443  if (data_trknmb == emul_trknmb) {
2444  // Convert emulator BX into hardware BX using full 12-bit
2445  // BX words in ALCT and CLCT digi collections.
2446  int emul_corr_bx = convertBXofLCT(emul_bx, detid, alcts_data, clcts_data);
2447  //std::cout <<"LCT data_bx "<< data_bx <<" emul_corr_bx "<< emul_corr_bx << std::endl;
2448  if (dataIsAnotherMC_)
2449  emul_corr_bx = (emul_bx & 0x01);
2450 
2451  /*if (ndata == nemul) {
2452  hLctCompTotalCsc[endc-1][csctype]->Fill(cham);
2453  if(detid.station()>1 && detid.ring()==1) {
2454  hLCTCompTotal2x->Fill(ix,detid.chamber()*2);
2455  }
2456  else {
2457  hLCTCompTotal2->Fill(ix,detid.chamber());
2458  }
2459  hLCTCompTotal2i->Fill(ix2,detid.chamber());
2460  }*/
2461  if (data_quality == emul_quality && data_wiregroup == emul_wiregroup &&
2462  data_keystrip == emul_keystrip && data_pattern == emul_pattern &&
2463  data_striptype == emul_striptype && data_bend == emul_bend) {
2464  //data_bx == emul_corr_bx) {
2465  /*if (ndata == nemul) {
2466  hLctCompMatchCsc[endc-1][csctype]->Fill(cham);
2467  if(detid.station()>1 && detid.ring()==1) {
2468  hLCTCompMatch2x->Fill(ix,detid.chamber()*2);
2469  }
2470  else {
2471  hLCTCompMatch2->Fill(ix,detid.chamber());
2472  }
2473  hLCTCompMatch2i->Fill(ix2,detid.chamber());
2474  }*/
2475  if (debug)
2476  LogTrace("CSCTriggerPrimitivesReader") << " Identical LCTs #" << data_trknmb;
2477  stubs_comparison[3].nStub_emul = j + 1;
2478  stubs_comparison[3].has_emul = true;
2479  stubs_comparison[3].WGcrossHS_emul = doesALCTCrossCLCT(detid, (*pe).getKeyWG(), (*pe).getStrip());
2480  stubs_comparison[3].quality_emul = (*pe).getQuality();
2481  stubs_comparison[3].key_WG_emul = (*pe).getKeyWG();
2482  stubs_comparison[3].key_hs_emul = (*pe).getStrip();
2483  stubs_comparison[3].bend_emul = (*pe).getBend();
2484  stubs_comparison[3].pattern_emul = (*pe).getCLCTPattern();
2485  stubs_comparison[3].bx_emul = (*pe).getBX();
2486  stubs_comparison[3].bx_corr_emul = emul_corr_bx;
2487  stubs_comparison[3].trknmb_emul = emul_trknmb;
2488  GlobalPoint gp_lct_emul(getGlobalPosition(detid.rawId(), (*pe).getKeyWG(), (*pe).getStrip()));
2489  stubs_comparison[3].eta_emul = gp_lct_emul.eta();
2490  stubs_comparison[3].phi_emul = gp_lct_emul.phi();
2491  bookedlctV_emul[j] = true;
2492  break;
2493  } else {
2494  LogTrace("CSCTriggerPrimitivesReader")
2495  //cerr
2496  << " Different LCTs #" << data_trknmb << " in ME" << ((endc == 1) ? "+" : "-") << stat
2497  << "/" << ring << "/" << cham << " data_lct bx " << data_bx << " emul bx " << emul_corr_bx;
2498  }
2499  }
2500  } //loop emul
2501  if (debug and stubs_comparison[3].key_hs_data != stubs_comparison[3].key_hs_emul)
2502  LogTrace("CSCTriggerPrimitivesReader")
2503  << "stubs_comparison 2 key_hs_data " << stubs_comparison[3].key_hs_data << " key_hs_emul "
2505  stub_tree[3]->Fill();
2506  } //loop data
2507 
2508  for (int k = 0; k < nemul; k++) {
2509  if (bookedlctV_emul[k])
2510  continue;
2512  stubs_comparison[3].firstfill = firstfill;
2513  if (firstfill)
2514  firstfill = false;
2516  stubs_comparison[3].endcap = endc;
2518  stubs_comparison[3].ring = ring;
2520  stubs_comparison[3].chambertype = detid.iChamberType();
2521  stubs_comparison[3].totStubs_data = ndata;
2522  stubs_comparison[3].totStubs_emul = nemul;
2523  stubs_comparison[3].trknmb_emul = lctV_emul[i].getTrknmb();
2524  stubs_comparison[3].nStub_data = -1;
2525  stubs_comparison[3].has_data = false;
2526  stubs_comparison[3].nStub_emul = k + 1;
2527  stubs_comparison[3].has_emul = true;
2529  doesALCTCrossCLCT(detid, lctV_emul[k].getKeyWG(), lctV_emul[k].getStrip());
2530  stubs_comparison[3].quality_emul = lctV_emul[k].getQuality();
2531  stubs_comparison[3].key_WG_emul = lctV_emul[k].getKeyWG();
2532  stubs_comparison[3].key_hs_emul = lctV_emul[k].getStrip();
2533  stubs_comparison[3].bend_emul = lctV_emul[k].getBend();
2534  stubs_comparison[3].pattern_emul = lctV_emul[k].getCLCTPattern();
2535  stubs_comparison[3].bx_emul = lctV_emul[k].getBX();
2536  //stubs_comparison[2].fullbx_emul = lctV_emul[k].getFullBX();
2537  // Emulator BX NOT Known from the data.
2538  GlobalPoint gp_lct_emul(getGlobalPosition(detid.rawId(), lctV_emul[k].getKeyWG(), lctV_emul[k].getStrip()));
2539  stubs_comparison[3].eta_emul = gp_lct_emul.eta();
2540  stubs_comparison[3].phi_emul = gp_lct_emul.phi();
2541  bookedlctV_emul[k] = true;
2542  stub_tree[3]->Fill();
2543  }
2544  } //end loop of chambers
2545  }
2546  }
2547  }
2548 }

References badChambers_, MyStubComparison::bend_data, MyStubComparison::bend_emul, MyStubComparison::bx_corr_emul, MyStubComparison::bx_data, MyStubComparison::bx_emul, relativeConstraints::cham, CSCDetId::chamber(), MyStubComparison::chamber, MyStubComparison::chambertype, checkBadChambers_, convertBXofLCT(), dataIsAnotherMC_, debug, doesALCTCrossCLCT(), MyStubComparison::endcap, CSCDetId::endcap(), PV3DBase< T, PVType, FrameType >::eta(), MyStubComparison::eta_data, MyStubComparison::eta_emul, Event_, eventsAnalyzed, MyStubComparison::firstfill, getGlobalPosition(), MyStubComparison::has_data, MyStubComparison::has_emul, mps_fire::i, CSCDetId::iChamberType(), MyStubComparison::init(), CSCBadChambers::isInBadChamber(), dqmiolumiharvest::j, dqmdumpme::k, MyStubComparison::key_hs_data, MyStubComparison::key_hs_emul, MyStubComparison::key_WG_data, MyStubComparison::key_WG_emul, LogTrace, maxRing(), MyStubComparison::nEvents, MyStubComparison::nStub_data, MyStubComparison::nStub_emul, MyStubComparison::pattern_data, MyStubComparison::pattern_emul, PV3DBase< T, PVType, FrameType >::phi(), MyStubComparison::phi_data, MyStubComparison::phi_emul, MyStubComparison::quality_data, MyStubComparison::quality_emul, DetId::rawId(), CSCDetId::ring(), relativeConstraints::ring, MyStubComparison::ring, RUN_, hgcalPlots::stat, CSCDetId::station(), MyStubComparison::station, stub_tree, stubs_comparison, MyStubComparison::totStubs_data, MyStubComparison::totStubs_emul, CSCDetId::triggerCscId(), CSCDetId::triggerSector(), MyStubComparison::trknmb_data, MyStubComparison::trknmb_emul, MyStubComparison::WGcrossHS_data, and MyStubComparison::WGcrossHS_emul.

◆ convertBXofLCT()

int CSCTriggerPrimitivesReader::convertBXofLCT ( const int  emul_bx,
const CSCDetId detid,
const CSCALCTDigiCollection alcts_data,
const CSCCLCTDigiCollection clcts_data 
)
private

Definition at line 2550 of file CSCTriggerPrimitivesReader.cc.

2553  {
2554  int full_anode_bx = -999;
2555  //int full_cathode_bx = -999;
2556  int lct_bx = -999;
2557  int tbin_anode_offset = 5; // 2007, run 14419.
2558 
2559  // Extract full 12-bit anode BX word from ALCT collections.
2560  const auto& arange = alcts_data->get(detid);
2561  for (auto digiIt = arange.first; digiIt != arange.second; digiIt++) {
2562  if ((*digiIt).isValid()) {
2563  full_anode_bx = (*digiIt).getFullBX();
2564  break;
2565  }
2566  }
2567 
2568  // Extract full 12-bit cathode BX word from CLCT collections.
2569  const auto& crange = clcts_data->get(detid);
2570  for (auto digiIt = crange.first; digiIt != crange.second; digiIt++) {
2571  if ((*digiIt).isValid()) {
2572  //full_cathode_bx = (*digiIt).getFullBX();
2573  break;
2574  }
2575  }
2576 
2577  // Use these 12-bit BX's to convert emulator BX into hardware BX.
2578  if (full_anode_bx == -999) {
2579  // What to do???
2580  edm::LogWarning("L1CSCTPEmulatorWrongInput") << "+++ Warning in convertBXofLCT(): full anode BX is not available!"
2581  << " +++\n";
2582  } else {
2583  // LCT BX has two bits: the least-significant bit is the LSB of ALCT BX;
2584  // the MSB is 1/0 depending on whether the 12-bit full cathode BX is 0
2585  // or not.
2586  lct_bx = (full_anode_bx + emul_bx - tbin_anode_offset) & 0x01;
2587  // SV, 12/Jun/08: it looks like this bit is never set - docu must be
2588  // wrong.
2589  //lct_bx = lct_bx | ((full_cathode_bx == 0) << 1);
2590  }
2591  //std::cout <<"convertBXofLCT old emul_bx "<< emul_bx <<" new lct bx "<< lct_bx <<" ful_anode_bx "<< full_anode_bx << std::endl;
2592  return lct_bx;
2593 }

Referenced by compareLCTs(), and compareMPCLCTs().

◆ doesALCTCrossCLCT()

bool CSCTriggerPrimitivesReader::doesALCTCrossCLCT ( CSCDetId  id,
int  key_wg,
int  key_hs 
) const
private

Definition at line 4655 of file CSCTriggerPrimitivesReader.cc.

4655  {
4656  bool isME11 = (id.station() == 1 and (id.ring() == 1 or id.ring() == 4));
4657  if (not isME11)
4658  return true;
4659 
4660  int theEndcap = (id.endcap() == 1) ? 1 : 2;
4661 
4662  if (key_hs > CSCConstants::MAX_HALF_STRIP_ME1B) {
4663  key_hs = key_hs - CSCConstants::MAX_HALF_STRIP_ME1B - 1; //convert it from 128-223 -> 0-95
4664  if (!gangedME1a) {
4665  // wrap around ME11 HS number for -z endcap
4666  if (theEndcap == 2)
4668  if (key_hs >= lut_wg_vs_hs_me1a[key_wg][0] && key_hs <= lut_wg_vs_hs_me1a[key_wg][1])
4669  return true;
4670  return false;
4671  } else {
4672  if (theEndcap == 2)
4673  key_hs = CSCConstants::MAX_HALF_STRIP_ME1A_GANGED - key_hs;
4674  if (key_hs >= lut_wg_vs_hs_me1ag[key_wg][0] && key_hs <= lut_wg_vs_hs_me1ag[key_wg][1])
4675  return true;
4676  return false;
4677  }
4678  }
4679  if (key_hs <= CSCConstants::MAX_HALF_STRIP_ME1B) {
4680  if (theEndcap == 2)
4681  key_hs = CSCConstants::MAX_HALF_STRIP_ME1B - key_hs;
4682  if (key_hs >= lut_wg_vs_hs_me1b[key_wg][0] && key_hs <= lut_wg_vs_hs_me1b[key_wg][1])
4683  return true;
4684  }
4685  return false;
4686 }

References gangedME1a, lut_wg_vs_hs_me1a, lut_wg_vs_hs_me1ag, lut_wg_vs_hs_me1b, CSCConstants::MAX_HALF_STRIP_ME1A_GANGED, CSCConstants::MAX_HALF_STRIP_ME1A_UNGANGED, CSCConstants::MAX_HALF_STRIP_ME1B, or, and relativeConstraints::ring.

Referenced by compareLCTs(), and compareMPCLCTs().

◆ drawALCTHistos()

void CSCTriggerPrimitivesReader::drawALCTHistos ( )
private

Definition at line 3043 of file CSCTriggerPrimitivesReader.cc.

3043  {
3044  TCanvas* c1 = new TCanvas("c1", "", 0, 0, 500, 640);
3045  string fname = resultsFileNamesPrefix_ + "alcts.ps";
3046  TPostScript* ps = new TPostScript(fname.c_str(), 111);
3047 
3048  TPad* pad[MAXPAGES];
3049  for (int i_page = 0; i_page < MAXPAGES; i_page++) {
3050  pad[i_page] = new TPad("", "", .05, .05, .93, .93);
3051  }
3052 
3053  int page = 1;
3054  TText t;
3055  t.SetTextFont(32);
3056  t.SetTextSize(0.025);
3057  char pagenum[7], titl[50];
3058  TPaveLabel* title;
3059 
3060  int max_idh = plotME42 ? CSC_TYPES : CSC_TYPES - 1;
3061 
3062  ps->NewPage();
3063  c1->Clear();
3064  c1->cd(0);
3065  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, "Number of ALCTs");
3066  title->SetFillColor(10);
3067  title->Draw();
3068  sprintf(pagenum, "- %d -", page);
3069  t.DrawText(0.9, 0.02, pagenum);
3070  gStyle->SetOptStat(111110);
3071  pad[page]->Draw();
3072  pad[page]->Divide(1, 3);
3073  pad[page]->cd(1);
3074  hAlctPerEvent->Draw();
3075  pad[page]->cd(2);
3076  hAlctPerChamber->Draw();
3077  for (int i = 0; i < CSC_TYPES; i++) {
3078  hAlctPerCSC->GetXaxis()->SetBinLabel(i + 1, csc_type[i].c_str());
3079  }
3080  // Should be multiplied by 40/nevents to convert to MHz
3081  pad[page]->cd(3);
3082  hAlctPerCSC->Draw();
3083  page++;
3084  c1->Update();
3085 
3086  for (int endc = 0; endc < MAX_ENDCAPS; endc++) {
3087  ps->NewPage();
3088  c1->Clear();
3089  c1->cd(0);
3090  sprintf(titl, "ALCTs per chamber, endcap %d", endc + 1);
3091  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, titl);
3092  title->SetFillColor(10);
3093  title->Draw();
3094  sprintf(pagenum, "- %d -", page);
3095  t.DrawText(0.9, 0.02, pagenum);
3096  gStyle->SetOptStat(10);
3097  pad[page]->Draw();
3098  pad[page]->Divide(2, 5);
3099  for (int idh = 0; idh < max_idh; idh++) {
3100  if (!plotME1A && idh == 3)
3101  continue;
3102  hAlctCsc[endc][idh]->SetMinimum(0.0);
3103  pad[page]->cd(idh + 1);
3104  hAlctCsc[endc][idh]->Draw();
3105  }
3106  page++;
3107  c1->Update();
3108  }
3109 
3110  ps->NewPage();
3111  c1->Clear();
3112  c1->cd(0);
3113  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, "ALCT quantities");
3114  title->SetFillColor(10);
3115  title->Draw();
3116  sprintf(pagenum, "- %d -", page);
3117  t.DrawText(0.9, 0.02, pagenum);
3118  gStyle->SetOptStat(111110);
3119  pad[page]->Draw();
3120  pad[page]->Divide(2, 3);
3121  pad[page]->cd(1);
3122  hAlctValid->Draw();
3123  pad[page]->cd(2);
3124  hAlctQuality->Draw();
3125  pad[page]->cd(3);
3126  hAlctAccel->Draw();
3127  pad[page]->cd(4);
3128  hAlctCollis->Draw();
3129  pad[page]->cd(5);
3130  hAlctKeyGroup->Draw();
3131  pad[page]->cd(6);
3132  hAlctBXN->Draw();
3133  page++;
3134  c1->Update();
3135 
3136  ps->Close();
3137  delete c1;
3138 }

References alignmentValidation::c1, csc_type, CSC_TYPES, alignmentValidation::fname, hAlctAccel, hAlctBXN, hAlctCollis, hAlctCsc, hAlctKeyGroup, hAlctPerChamber, hAlctPerCSC, hAlctPerEvent, hAlctQuality, hAlctValid, mps_fire::i, MAX_ENDCAPS, MAXPAGES, MainPageGenerator::page, plotME1A, plotME42, resultsFileNamesPrefix_, submitPVValidationJobs::t, and runGCPTkAlMap::title.

Referenced by endJob().

◆ drawCLCTHistos()

void CSCTriggerPrimitivesReader::drawCLCTHistos ( )
private

Definition at line 3140 of file CSCTriggerPrimitivesReader.cc.

3140  {
3141  TCanvas* c1 = new TCanvas("c1", "", 0, 0, 500, 640);
3142  string fname = resultsFileNamesPrefix_ + "clcts.ps";
3143  TPostScript* ps = new TPostScript(fname.c_str(), 111);
3144 
3145  TPad* pad[MAXPAGES];
3146  for (int i_page = 0; i_page < MAXPAGES; i_page++) {
3147  pad[i_page] = new TPad("", "", .05, .05, .93, .93);
3148  }
3149 
3150  int page = 1;
3151  TText t;
3152  t.SetTextFont(32);
3153  t.SetTextSize(0.025);
3154  char pagenum[7], titl[50];
3155  TPaveLabel* title;
3156 
3157  ps->NewPage();
3158  c1->Clear();
3159  c1->cd(0);
3160  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, "Number of CLCTs");
3161  title->SetFillColor(10);
3162  title->Draw();
3163  sprintf(pagenum, "- %d -", page);
3164  t.DrawText(0.9, 0.02, pagenum);
3165  gStyle->SetOptStat(111110);
3166  pad[page]->Draw();
3167  pad[page]->Divide(1, 3);
3168  pad[page]->cd(1);
3169  hClctPerEvent->Draw();
3170 
3171  int max_idh = plotME42 ? CSC_TYPES : CSC_TYPES - 1;
3172 
3173  edm::LogInfo("CSCTriggerPrimitivesReader") << "\n";
3174  int nbins = hClctPerChamber->GetNbinsX();
3175  for (int ibin = 1; ibin <= nbins; ibin++) {
3176  double f_bin = hClctPerChamber->GetBinContent(ibin);
3177  edm::LogInfo("CSCTriggerPrimitivesReader") << " # CLCTs/chamber: " << ibin - 1 << "; events: " << f_bin << endl;
3178  }
3179 
3180  pad[page]->cd(2);
3181  hClctPerChamber->Draw();
3182  for (int i = 0; i < CSC_TYPES; i++) {
3183  hClctPerCSC->GetXaxis()->SetBinLabel(i + 1, csc_type[i].c_str());
3184  }
3185  // Should be multiplied by 40/nevents to convert to MHz
3186  pad[page]->cd(3);
3187  hClctPerCSC->Draw();
3188  page++;
3189  c1->Update();
3190 
3191  for (int endc = 0; endc < MAX_ENDCAPS; endc++) {
3192  ps->NewPage();
3193  c1->Clear();
3194  c1->cd(0);
3195  sprintf(titl, "CLCTs per chamber, endcap %d", endc + 1);
3196  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, titl);
3197  title->SetFillColor(10);
3198  title->Draw();
3199  sprintf(pagenum, "- %d -", page);
3200  t.DrawText(0.9, 0.02, pagenum);
3201  gStyle->SetOptStat(10);
3202  pad[page]->Draw();
3203  pad[page]->Divide(2, 5);
3204  for (int idh = 0; idh < max_idh; idh++) {
3205  if (!plotME1A && idh == 3)
3206  continue;
3207  hClctCsc[endc][idh]->SetMinimum(0.0);
3208  pad[page]->cd(idh + 1);
3209  hClctCsc[endc][idh]->Draw();
3210  }
3211  page++;
3212  c1->Update();
3213  }
3214 
3215  ps->NewPage();
3216  c1->Clear();
3217  c1->cd(0);
3218  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, "CLCT quantities");
3219  title->SetFillColor(10);
3220  title->Draw();
3221  sprintf(pagenum, "- %d -", page);
3222  t.DrawText(0.9, 0.02, pagenum);
3223  gStyle->SetOptStat(111110);
3224  pad[page]->Draw();
3225  pad[page]->Divide(2, 4);
3226  pad[page]->cd(1);
3227  hClctValid->Draw();
3228  pad[page]->cd(2);
3229  hClctQuality->Draw();
3230  pad[page]->cd(3);
3231  hClctSign->Draw();
3232  hClctPattern[1]->SetTitle("CLCT pattern #");
3233  pad[page]->cd(4);
3234  hClctPattern[1]->Draw();
3235  pad[page]->cd(5);
3236  hClctCFEB->Draw();
3237  pad[page]->cd(7);
3238  hClctKeyStrip[1]->Draw();
3239  pad[page]->cd(8);
3240  hClctBXN->Draw();
3241  page++;
3242  c1->Update();
3243 
3244  ps->NewPage();
3245  c1->Clear();
3246  c1->cd(0);
3247  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, "CLCT bend for various chamber types, halfstrips");
3248  title->SetFillColor(10);
3249  title->Draw();
3250  sprintf(pagenum, "- %d -", page);
3251  t.DrawText(0.9, 0.02, pagenum);
3252  gStyle->SetOptStat(110);
3253  pad[page]->Draw();
3254  pad[page]->Divide(2, 5);
3255  for (int idh = 0; idh < max_idh; idh++) {
3256  if (!plotME1A && idh == 3)
3257  continue;
3258  pad[page]->cd(idh + 1);
3259  hClctBendCsc[idh][1]->GetXaxis()->SetTitle("Pattern bend");
3260  hClctBendCsc[idh][1]->GetYaxis()->SetTitle("Number of LCTs");
3261  hClctBendCsc[idh][1]->Draw();
3262  }
3263  page++;
3264  c1->Update();
3265 
3266  ps->Close();
3267  delete c1;
3268 }

References alignmentValidation::c1, csc_type, CSC_TYPES, alignmentValidation::fname, hClctBendCsc, hClctBXN, hClctCFEB, hClctCsc, hClctKeyStrip, hClctPattern, hClctPerChamber, hClctPerCSC, hClctPerEvent, hClctQuality, hClctSign, hClctValid, mps_fire::i, MAX_ENDCAPS, MAXPAGES, LaserClient_cfi::nbins, MainPageGenerator::page, plotME1A, plotME42, resultsFileNamesPrefix_, submitPVValidationJobs::t, and runGCPTkAlMap::title.

Referenced by endJob().

◆ drawCompHistos()

void CSCTriggerPrimitivesReader::drawCompHistos ( )
private

Definition at line 3503 of file CSCTriggerPrimitivesReader.cc.

3503  {
3504  TCanvas* c1 = new TCanvas("c1", "", 0, 0, 500, 640);
3505  string fname = resultsFileNamesPrefix_ + "lcts_comp.ps";
3506  TPostScript* ps = new TPostScript(fname.c_str(), 111);
3507 
3508  TPad* pad[MAXPAGES];
3509  for (int i_page = 0; i_page < MAXPAGES; i_page++) {
3510  pad[i_page] = new TPad("", "", .05, .05, .93, .93);
3511  }
3512 
3513  int page = 1;
3514  TText t;
3515  t.SetTextFont(32);
3516  t.SetTextSize(0.025);
3517  char pagenum[15];
3518  TPaveLabel* title;
3519  Int_t nbins;
3520 
3521  TText teff;
3522  teff.SetTextFont(32);
3523  teff.SetTextSize(0.08);
3524  char eff[25], titl[60];
3525 
3526  int max_idh = plotME42 ? CSC_TYPES : CSC_TYPES - 1;
3527 
3528  for (int endc = 0; endc < MAX_ENDCAPS; endc++) { // endcaps
3529  ps->NewPage();
3530  c1->Clear();
3531  c1->cd(0);
3532  sprintf(titl, "ALCT firmware-emulator: match in number found, endcap %d", endc + 1);
3533  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, titl);
3534  title->SetFillColor(10);
3535  title->Draw();
3536  sprintf(pagenum, "- %d -", page);
3537  t.DrawText(0.9, 0.02, pagenum);
3538  //gStyle->SetOptStat(110010);
3539  gStyle->SetOptStat(0);
3540  pad[page]->Draw();
3541  pad[page]->Divide(2, 5);
3542  TH1F* hAlctFoundEffVsCsc[MAX_ENDCAPS][CSC_TYPES];
3543  for (int idh = 0; idh < max_idh; idh++) {
3544  if (!plotME1A && idh == 3)
3545  continue;
3546  hAlctFoundEffVsCsc[endc][idh] = (TH1F*)hAlctCompFoundCsc[endc][idh]->Clone();
3547  hAlctFoundEffVsCsc[endc][idh]->Divide(hAlctCompSameNCsc[endc][idh], hAlctCompFoundCsc[endc][idh], 1., 1., "B");
3548  nbins = hAlctCompFoundCsc[endc][idh]->GetNbinsX();
3549  for (Int_t ibin = 1; ibin <= nbins; ibin++) {
3550  if (hAlctCompFoundCsc[endc][idh]->GetBinContent(ibin) == 0) {
3551  hAlctFoundEffVsCsc[endc][idh]->SetBinContent(ibin, -1.);
3552  hAlctFoundEffVsCsc[endc][idh]->SetBinError(ibin, 0.);
3553  }
3554  }
3555  gPad->Update();
3556  gStyle->SetStatX(0.65);
3557  hAlctFoundEffVsCsc[endc][idh]->SetMinimum(-0.05);
3558  hAlctFoundEffVsCsc[endc][idh]->SetMaximum(1.05);
3559  hAlctFoundEffVsCsc[endc][idh]->GetXaxis()->SetTitleOffset(0.7);
3560  hAlctFoundEffVsCsc[endc][idh]->GetYaxis()->SetTitleOffset(0.8);
3561  hAlctFoundEffVsCsc[endc][idh]->GetXaxis()->SetLabelSize(0.06); // default=0.04
3562  hAlctFoundEffVsCsc[endc][idh]->GetYaxis()->SetLabelSize(0.06); // default=0.04
3563  hAlctFoundEffVsCsc[endc][idh]->GetXaxis()->SetTitleSize(0.07); // default=0.05
3564  hAlctFoundEffVsCsc[endc][idh]->GetYaxis()->SetTitleSize(0.07); // default=0.05
3565  hAlctFoundEffVsCsc[endc][idh]->GetXaxis()->SetTitle("CSC id");
3566  hAlctFoundEffVsCsc[endc][idh]->GetYaxis()->SetTitle("% of same number found");
3567  pad[page]->cd(idh + 1);
3568  hAlctFoundEffVsCsc[endc][idh]->Draw("e");
3569  double numer = hAlctCompSameNCsc[endc][idh]->Integral();
3570  double denom = hAlctCompFoundCsc[endc][idh]->Integral();
3571  double ratio = 0.0, error = 0.0;
3572  if (denom > 0.) {
3573  ratio = numer / denom;
3574  error = sqrt(ratio * (1. - ratio) / denom);
3575  }
3576  sprintf(eff, "eff = (%4.1f +/- %4.1f)%%", ratio * 100., error * 100.);
3577  teff.DrawTextNDC(0.3, 0.5, eff);
3578  }
3579  page++;
3580  c1->Update();
3581  }
3582 
3583  for (int endc = 0; endc < MAX_ENDCAPS; endc++) { // endcaps
3584  ps->NewPage();
3585  c1->Clear();
3586  c1->cd(0);
3587  sprintf(titl, "ALCT firmware-emulator: exact match, endcap %d", endc + 1);
3588  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, titl);
3589  title->SetFillColor(10);
3590  title->Draw();
3591  sprintf(pagenum, "- %d -", page);
3592  t.DrawText(0.9, 0.02, pagenum);
3593  //gStyle->SetOptStat(110010);
3594  gStyle->SetOptStat(0);
3595  pad[page]->Draw();
3596  pad[page]->Divide(2, 5);
3597  TH1F* hAlctMatchEffVsCsc[MAX_ENDCAPS][CSC_TYPES];
3598  for (int idh = 0; idh < max_idh; idh++) {
3599  if (!plotME1A && idh == 3)
3600  continue;
3601  hAlctMatchEffVsCsc[endc][idh] = (TH1F*)hAlctCompTotalCsc[endc][idh]->Clone();
3602  hAlctMatchEffVsCsc[endc][idh]->Divide(hAlctCompMatchCsc[endc][idh], hAlctCompTotalCsc[endc][idh], 1., 1., "B");
3603  nbins = hAlctCompTotalCsc[endc][idh]->GetNbinsX();
3604  for (Int_t ibin = 1; ibin <= nbins; ibin++) {
3605  if (hAlctCompTotalCsc[endc][idh]->GetBinContent(ibin) == 0) {
3606  hAlctMatchEffVsCsc[endc][idh]->SetBinContent(ibin, -1.);
3607  hAlctMatchEffVsCsc[endc][idh]->SetBinError(ibin, 0.);
3608  }
3609  }
3610  gPad->Update();
3611  gStyle->SetStatX(0.65);
3612  hAlctMatchEffVsCsc[endc][idh]->SetMinimum(-0.05);
3613  hAlctMatchEffVsCsc[endc][idh]->SetMaximum(1.05);
3614  hAlctMatchEffVsCsc[endc][idh]->GetXaxis()->SetTitleOffset(0.7);
3615  hAlctMatchEffVsCsc[endc][idh]->GetYaxis()->SetTitleOffset(0.8);
3616  hAlctMatchEffVsCsc[endc][idh]->GetXaxis()->SetLabelSize(0.06);
3617  hAlctMatchEffVsCsc[endc][idh]->GetYaxis()->SetLabelSize(0.06);
3618  hAlctMatchEffVsCsc[endc][idh]->GetXaxis()->SetTitleSize(0.07);
3619  hAlctMatchEffVsCsc[endc][idh]->GetYaxis()->SetTitleSize(0.07);
3620  hAlctMatchEffVsCsc[endc][idh]->GetXaxis()->SetTitle("CSC id");
3621  hAlctMatchEffVsCsc[endc][idh]->GetYaxis()->SetTitle("% of exact match");
3622  pad[page]->cd(idh + 1);
3623  hAlctMatchEffVsCsc[endc][idh]->Draw("e");
3624  double numer = hAlctCompMatchCsc[endc][idh]->Integral();
3625  double denom = hAlctCompTotalCsc[endc][idh]->Integral();
3626  double ratio = 0.0, error = 0.0;
3627  if (denom > 0.) {
3628  ratio = numer / denom;
3629  error = sqrt(ratio * (1. - ratio) / denom);
3630  }
3631  sprintf(eff, "eff = (%4.1f +/- %4.1f)%%", ratio * 100., error * 100.);
3632  teff.DrawTextNDC(0.3, 0.5, eff);
3633  }
3634  page++;
3635  c1->Update();
3636  }
3637 
3638  for (int endc = 0; endc < MAX_ENDCAPS; endc++) {
3639  ps->NewPage();
3640  c1->Clear();
3641  c1->cd(0);
3642  sprintf(titl, "CLCT firmware-emulator: match in number found, endcap %d", endc + 1);
3643  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, titl);
3644  title->SetFillColor(10);
3645  title->Draw();
3646  sprintf(pagenum, "- %d -", page);
3647  t.DrawText(0.9, 0.02, pagenum);
3648  //gStyle->SetOptStat(110010);
3649  gStyle->SetOptStat(0);
3650  pad[page]->Draw();
3651  pad[page]->Divide(2, 5);
3652  TH1F* hClctFoundEffVsCsc[MAX_ENDCAPS][CSC_TYPES];
3653  for (int idh = 0; idh < max_idh; idh++) {
3654  if (!plotME1A && idh == 3)
3655  continue;
3656  hClctFoundEffVsCsc[endc][idh] = (TH1F*)hClctCompFoundCsc[endc][idh]->Clone();
3657  hClctFoundEffVsCsc[endc][idh]->Divide(hClctCompSameNCsc[endc][idh], hClctCompFoundCsc[endc][idh], 1., 1., "B");
3658  nbins = hClctCompFoundCsc[endc][idh]->GetNbinsX();
3659  for (Int_t ibin = 1; ibin <= nbins; ibin++) {
3660  if (hClctCompFoundCsc[endc][idh]->GetBinContent(ibin) == 0) {
3661  hClctFoundEffVsCsc[endc][idh]->SetBinContent(ibin, -1.);
3662  hClctFoundEffVsCsc[endc][idh]->SetBinError(ibin, 0.);
3663  }
3664  }
3665  gPad->Update();
3666  gStyle->SetStatX(0.65);
3667  hClctFoundEffVsCsc[endc][idh]->SetMinimum(-0.05);
3668  hClctFoundEffVsCsc[endc][idh]->SetMaximum(1.05);
3669  hClctFoundEffVsCsc[endc][idh]->GetXaxis()->SetTitleOffset(0.7);
3670  hClctFoundEffVsCsc[endc][idh]->GetYaxis()->SetTitleOffset(0.8);
3671  hClctFoundEffVsCsc[endc][idh]->GetXaxis()->SetLabelSize(0.06);
3672  hClctFoundEffVsCsc[endc][idh]->GetYaxis()->SetLabelSize(0.06);
3673  hClctFoundEffVsCsc[endc][idh]->GetXaxis()->SetTitleSize(0.07);
3674  hClctFoundEffVsCsc[endc][idh]->GetYaxis()->SetTitleSize(0.07);
3675  hClctFoundEffVsCsc[endc][idh]->GetXaxis()->SetTitle("CSC id");
3676  hClctFoundEffVsCsc[endc][idh]->GetYaxis()->SetTitle("% of same number found");
3677  pad[page]->cd(idh + 1);
3678  hClctFoundEffVsCsc[endc][idh]->Draw("e");
3679  double numer = hClctCompSameNCsc[endc][idh]->Integral();
3680  double denom = hClctCompFoundCsc[endc][idh]->Integral();
3681  double ratio = 0.0, error = 0.0;
3682  if (denom > 0.) {
3683  ratio = numer / denom;
3684  error = sqrt(ratio * (1. - ratio) / denom);
3685  }
3686  sprintf(eff, "eff = (%4.1f +/- %4.1f)%%", ratio * 100., error * 100.);
3687  teff.DrawTextNDC(0.3, 0.5, eff);
3688  }
3689  page++;
3690  c1->Update();
3691  }
3692 
3693  for (int endc = 0; endc < MAX_ENDCAPS; endc++) {
3694  ps->NewPage();
3695  c1->Clear();
3696  c1->cd(0);
3697  sprintf(titl, "CLCT firmware-emulator: exact match, endcap %d", endc + 1);
3698  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, titl);
3699  title->SetFillColor(10);
3700  title->Draw();
3701  sprintf(pagenum, "- %d -", page);
3702  t.DrawText(0.9, 0.02, pagenum);
3703  //gStyle->SetOptStat(110010);
3704  gStyle->SetOptStat(0);
3705  pad[page]->Draw();
3706  pad[page]->Divide(2, 5);
3707  TH1F* hClctMatchEffVsCsc[MAX_ENDCAPS][CSC_TYPES];
3708  for (int idh = 0; idh < max_idh; idh++) {
3709  if (!plotME1A && idh == 3)
3710  continue;
3711  hClctMatchEffVsCsc[endc][idh] = (TH1F*)hClctCompTotalCsc[endc][idh]->Clone();
3712  hClctMatchEffVsCsc[endc][idh]->Divide(hClctCompMatchCsc[endc][idh], hClctCompTotalCsc[endc][idh], 1., 1., "B");
3713  nbins = hClctCompTotalCsc[endc][idh]->GetNbinsX();
3714  for (Int_t ibin = 1; ibin <= nbins; ibin++) {
3715  if (hClctCompTotalCsc[endc][idh]->GetBinContent(ibin) == 0) {
3716  hClctMatchEffVsCsc[endc][idh]->SetBinContent(ibin, -1.);
3717  hClctMatchEffVsCsc[endc][idh]->SetBinError(ibin, 0.);
3718  }
3719  }
3720  gPad->Update();
3721  gStyle->SetStatX(0.65);
3722  hClctMatchEffVsCsc[endc][idh]->SetMinimum(-0.05);
3723  hClctMatchEffVsCsc[endc][idh]->SetMaximum(1.05);
3724  hClctMatchEffVsCsc[endc][idh]->GetXaxis()->SetTitleOffset(0.7);
3725  hClctMatchEffVsCsc[endc][idh]->GetYaxis()->SetTitleOffset(0.8);
3726  hClctMatchEffVsCsc[endc][idh]->GetXaxis()->SetLabelSize(0.06);
3727  hClctMatchEffVsCsc[endc][idh]->GetYaxis()->SetLabelSize(0.06);
3728  hClctMatchEffVsCsc[endc][idh]->GetXaxis()->SetTitleSize(0.07);
3729  hClctMatchEffVsCsc[endc][idh]->GetYaxis()->SetTitleSize(0.07);
3730  hClctMatchEffVsCsc[endc][idh]->GetXaxis()->SetTitle("CSC id");
3731  hClctMatchEffVsCsc[endc][idh]->GetYaxis()->SetTitle("% of exact match");
3732  pad[page]->cd(idh + 1);
3733  hClctMatchEffVsCsc[endc][idh]->Draw("e");
3734  double numer = hClctCompMatchCsc[endc][idh]->Integral();
3735  double denom = hClctCompTotalCsc[endc][idh]->Integral();
3736  double ratio = 0.0, error = 0.0;
3737  if (denom > 0.) {
3738  ratio = numer / denom;
3739  error = sqrt(ratio * (1. - ratio) / denom);
3740  }
3741  sprintf(eff, "eff = (%4.1f +/- %4.1f)%%", ratio * 100., error * 100.);
3742  teff.DrawTextNDC(0.3, 0.5, eff);
3743  }
3744  page++;
3745  c1->Update();
3746  }
3747 
3748  for (int endc = 0; endc < MAX_ENDCAPS; endc++) {
3749  ps->NewPage();
3750  c1->Clear();
3751  c1->cd(0);
3752  sprintf(titl, "LCT firmware-emulator: match in number found, endcap %d", endc + 1);
3753  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, titl);
3754  title->SetFillColor(10);
3755  title->Draw();
3756  sprintf(pagenum, "- %d -", page);
3757  t.DrawText(0.9, 0.02, pagenum);
3758  //gStyle->SetOptStat(110010);
3759  gStyle->SetOptStat(0);
3760  pad[page]->Draw();
3761  pad[page]->Divide(2, 5);
3762  TH1F* hLctFoundEffVsCsc[MAX_ENDCAPS][CSC_TYPES];
3763  for (int idh = 0; idh < max_idh; idh++) {
3764  if (!plotME1A && idh == 3)
3765  continue;
3766  hLctFoundEffVsCsc[endc][idh] = (TH1F*)hLctCompFoundCsc[endc][idh]->Clone();
3767  hLctFoundEffVsCsc[endc][idh]->Divide(hLctCompSameNCsc[endc][idh], hLctCompFoundCsc[endc][idh], 1., 1., "B");
3768  nbins = hLctCompFoundCsc[endc][idh]->GetNbinsX();
3769  for (Int_t ibin = 1; ibin <= nbins; ibin++) {
3770  if (hLctCompFoundCsc[endc][idh]->GetBinContent(ibin) == 0) {
3771  hLctFoundEffVsCsc[endc][idh]->SetBinContent(ibin, -1.);
3772  hLctFoundEffVsCsc[endc][idh]->SetBinError(ibin, 0.);
3773  }
3774  }
3775  gPad->Update();
3776  gStyle->SetStatX(0.65);
3777  hLctFoundEffVsCsc[endc][idh]->SetMinimum(-0.05);
3778  hLctFoundEffVsCsc[endc][idh]->SetMaximum(1.05);
3779  hLctFoundEffVsCsc[endc][idh]->GetXaxis()->SetTitleOffset(0.7);
3780  hLctFoundEffVsCsc[endc][idh]->GetYaxis()->SetTitleOffset(0.8);
3781  hLctFoundEffVsCsc[endc][idh]->GetXaxis()->SetLabelSize(0.06);
3782  hLctFoundEffVsCsc[endc][idh]->GetYaxis()->SetLabelSize(0.06);
3783  hLctFoundEffVsCsc[endc][idh]->GetXaxis()->SetTitleSize(0.07);
3784  hLctFoundEffVsCsc[endc][idh]->GetYaxis()->SetTitleSize(0.07);
3785  hLctFoundEffVsCsc[endc][idh]->GetXaxis()->SetTitle("CSC id");
3786  hLctFoundEffVsCsc[endc][idh]->GetYaxis()->SetTitle("% of same number found");
3787  pad[page]->cd(idh + 1);
3788  hLctFoundEffVsCsc[endc][idh]->Draw("e");
3789  double numer = hLctCompSameNCsc[endc][idh]->Integral();
3790  double denom = hLctCompFoundCsc[endc][idh]->Integral();
3791  double ratio = 0.0, error = 0.0;
3792  if (denom > 0.) {
3793  ratio = numer / denom;
3794  error = sqrt(ratio * (1. - ratio) / denom);
3795  }
3796  sprintf(eff, "eff = (%4.1f +/- %4.1f)%%", ratio * 100., error * 100.);
3797  teff.DrawTextNDC(0.3, 0.5, eff);
3798  }
3799  page++;
3800  c1->Update();
3801  }
3802 
3803  for (int endc = 0; endc < MAX_ENDCAPS; endc++) {
3804  ps->NewPage();
3805  c1->Clear();
3806  c1->cd(0);
3807  sprintf(titl, "LCT firmware-emulator: exact match, endcap %d", endc + 1);
3808  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, titl);
3809  title->SetFillColor(10);
3810  title->Draw();
3811  sprintf(pagenum, "- %d -", page);
3812  t.DrawText(0.9, 0.02, pagenum);
3813  //gStyle->SetOptStat(110010);
3814  gStyle->SetOptStat(0);
3815  pad[page]->Draw();
3816  pad[page]->Divide(2, 5);
3817  TH1F* hLctMatchEffVsCsc[MAX_ENDCAPS][CSC_TYPES];
3818  for (int idh = 0; idh < max_idh; idh++) {
3819  if (!plotME1A && idh == 3)
3820  continue;
3821  hLctMatchEffVsCsc[endc][idh] = (TH1F*)hLctCompTotalCsc[endc][idh]->Clone();
3822  hLctMatchEffVsCsc[endc][idh]->Divide(hLctCompMatchCsc[endc][idh], hLctCompTotalCsc[endc][idh], 1., 1., "B");
3823  nbins = hLctCompTotalCsc[endc][idh]->GetNbinsX();
3824  for (Int_t ibin = 1; ibin <= nbins; ibin++) {
3825  if (hLctCompTotalCsc[endc][idh]->GetBinContent(ibin) == 0) {
3826  hLctMatchEffVsCsc[endc][idh]->SetBinContent(ibin, -1.);
3827  hLctMatchEffVsCsc[endc][idh]->SetBinError(ibin, 0.);
3828  }
3829  }
3830  gPad->Update();
3831  gStyle->SetStatX(0.65);
3832  hLctMatchEffVsCsc[endc][idh]->SetMinimum(-0.05);
3833  hLctMatchEffVsCsc[endc][idh]->SetMaximum(1.05);
3834  hLctMatchEffVsCsc[endc][idh]->GetXaxis()->SetTitleOffset(0.7);
3835  hLctMatchEffVsCsc[endc][idh]->GetYaxis()->SetTitleOffset(0.8);
3836  hLctMatchEffVsCsc[endc][idh]->GetXaxis()->SetLabelSize(0.06);
3837  hLctMatchEffVsCsc[endc][idh]->GetYaxis()->SetLabelSize(0.06);
3838  hLctMatchEffVsCsc[endc][idh]->GetXaxis()->SetTitleSize(0.07);
3839  hLctMatchEffVsCsc[endc][idh]->GetYaxis()->SetTitleSize(0.07);
3840  hLctMatchEffVsCsc[endc][idh]->GetXaxis()->SetTitle("CSC id");
3841  hLctMatchEffVsCsc[endc][idh]->GetYaxis()->SetTitle("% of exact match");
3842  pad[page]->cd(idh + 1);
3843  hLctMatchEffVsCsc[endc][idh]->Draw("e");
3844  double numer = hLctCompMatchCsc[endc][idh]->Integral();
3845  double denom = hLctCompTotalCsc[endc][idh]->Integral();
3846  double ratio = 0.0, error = 0.0;
3847  if (denom > 0.) {
3848  ratio = numer / denom;
3849  error = sqrt(ratio * (1. - ratio) / denom);
3850  }
3851  sprintf(eff, "eff = (%4.1f +/- %4.1f)%%", ratio * 100., error * 100.);
3852  teff.DrawTextNDC(0.3, 0.5, eff);
3853  }
3854  page++;
3855  c1->Update();
3856  }
3857 
3858  ps->Close();
3859  delete c1;
3860 }

References alignmentValidation::c1, CSC_TYPES, makePileupJSON::denom, relativeConstraints::error, alignmentValidation::fname, hAlctCompFoundCsc, hAlctCompMatchCsc, hAlctCompSameNCsc, hAlctCompTotalCsc, hClctCompFoundCsc, hClctCompMatchCsc, hClctCompSameNCsc, hClctCompTotalCsc, hLctCompFoundCsc, hLctCompMatchCsc, hLctCompSameNCsc, hLctCompTotalCsc, MAX_ENDCAPS, MAXPAGES, LaserClient_cfi::nbins, MainPageGenerator::page, plotME1A, plotME42, particleFlowDisplacedVertex_cfi::ratio, resultsFileNamesPrefix_, mathSSE::sqrt(), submitPVValidationJobs::t, and runGCPTkAlMap::title.

Referenced by endJob().

◆ drawEfficHistos()

void CSCTriggerPrimitivesReader::drawEfficHistos ( )
private

Definition at line 4250 of file CSCTriggerPrimitivesReader.cc.

4250  {
4251  TCanvas* c1 = new TCanvas("c1", "", 0, 0, 500, 700);
4252  string fname = resultsFileNamesPrefix_ + "lcts_effic.ps";
4253  TPostScript* ps = new TPostScript(fname.c_str(), 111);
4254 
4255  TPad* pad[MAXPAGES];
4256  for (int i_page = 0; i_page < MAXPAGES; i_page++) {
4257  pad[i_page] = new TPad("", "", .05, .05, .93, .93);
4258  }
4259 
4260  int page = 1;
4261  TText t;
4262  t.SetTextFont(32);
4263  t.SetTextSize(0.025);
4264  char pagenum[7];
4265  TPaveLabel* title;
4266  char histtitle[60];
4267 
4268  gStyle->SetOptDate(0);
4269  gStyle->SetTitleSize(0.1, ""); // size for pad title; default is 0.02
4270 
4271  int max_idh = plotME42 ? CSC_TYPES : CSC_TYPES - 1;
4272 
4273  ps->NewPage();
4274  c1->Clear();
4275  c1->cd(0);
4276  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, "ALCT efficiency vs #eta");
4277  title->SetFillColor(10);
4278  title->Draw();
4279  sprintf(pagenum, "- %d -", page);
4280  t.DrawText(0.9, 0.02, pagenum);
4281  gStyle->SetOptStat(0);
4282  pad[page]->Draw();
4283  pad[page]->Divide(2, 2);
4284  TH1F* hALCTEffVsEta[MAX_STATIONS];
4285  for (int istation = 0; istation < MAX_STATIONS; istation++) {
4286  hALCTEffVsEta[istation] = (TH1F*)hEfficHitsEta[istation]->Clone();
4287  hALCTEffVsEta[istation]->Divide(hEfficALCTEta[istation], hEfficHitsEta[istation], 1., 1., "B");
4288  hALCTEffVsEta[istation]->GetXaxis()->SetTitleOffset(1.2);
4289  hALCTEffVsEta[istation]->GetXaxis()->SetTitle("#eta");
4290  hALCTEffVsEta[istation]->SetMaximum(1.05);
4291  sprintf(histtitle, "ALCT efficiency vs #eta, station %d", istation + 1);
4292  hALCTEffVsEta[istation]->SetTitle(histtitle);
4293  pad[page]->cd(istation + 1);
4294  hALCTEffVsEta[istation]->Draw();
4295  }
4296  page++;
4297  c1->Update();
4298 
4299  c1->Clear();
4300  c1->cd(0);
4301  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, "ALCT efficiency vs #eta");
4302  title->SetFillColor(10);
4303  title->Draw();
4304  sprintf(pagenum, "- %d -", page);
4305  t.DrawText(0.9, 0.02, pagenum);
4306  gStyle->SetOptStat(11111);
4307  pad[page]->Draw();
4308  pad[page]->Divide(2, 5);
4309  TH1F* hALCTEffVsEtaCsc[CSC_TYPES];
4310  for (int idh = 0; idh < max_idh; idh++) {
4311  if (!plotME1A && idh == 3)
4312  continue;
4313  hALCTEffVsEtaCsc[idh] = (TH1F*)hEfficHitsEtaCsc[idh]->Clone();
4314  hALCTEffVsEtaCsc[idh]->Divide(hEfficALCTEtaCsc[idh], hEfficHitsEtaCsc[idh], 1., 1., "B");
4315  if (idh == 3 || idh == 4 || idh == 6 || idh == 8) {
4316  gPad->Update();
4317  gStyle->SetStatX(0.43);
4318  } else {
4319  gPad->Update();
4320  gStyle->SetStatX(1.00);
4321  }
4322  hALCTEffVsEtaCsc[idh]->GetXaxis()->SetTitle("#eta");
4323  hALCTEffVsEtaCsc[idh]->GetXaxis()->SetTitleOffset(0.8);
4324  hALCTEffVsEtaCsc[idh]->GetXaxis()->SetTitleSize(0.07); // default=0.05
4325  hALCTEffVsEtaCsc[idh]->GetXaxis()->SetLabelSize(0.10); // default=0.04
4326  hALCTEffVsEtaCsc[idh]->GetYaxis()->SetLabelSize(0.10);
4327  hALCTEffVsEtaCsc[idh]->SetLabelOffset(0.012, "XY");
4328  hALCTEffVsEtaCsc[idh]->SetMinimum(0.50);
4329  hALCTEffVsEtaCsc[idh]->SetMaximum(1.05);
4330  hALCTEffVsEtaCsc[idh]->SetTitle(csc_type[idh].c_str());
4331  hALCTEffVsEtaCsc[idh]->SetTitleSize(0.1, "");
4332  hALCTEffVsEtaCsc[idh]->SetLineWidth(2);
4333  hALCTEffVsEtaCsc[idh]->SetLineColor(4);
4334  pad[page]->cd(idh + 1);
4335  gPad->SetGrid(1);
4336  hALCTEffVsEtaCsc[idh]->Draw();
4337  }
4338  page++;
4339  c1->Update();
4340 
4341  ps->NewPage();
4342  c1->Clear();
4343  c1->cd(0);
4344  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, "CLCT efficiency vs #eta");
4345  title->SetFillColor(10);
4346  title->Draw();
4347  sprintf(pagenum, "- %d -", page);
4348  t.DrawText(0.9, 0.02, pagenum);
4349  gStyle->SetOptStat(0);
4350  pad[page]->Draw();
4351  pad[page]->Divide(2, 2);
4352  TH1F* hCLCTEffVsEta[MAX_STATIONS];
4353  for (int istation = 0; istation < MAX_STATIONS; istation++) {
4354  hCLCTEffVsEta[istation] = (TH1F*)hEfficHitsEta[istation]->Clone();
4355  hCLCTEffVsEta[istation]->Divide(hEfficCLCTEta[istation], hEfficHitsEta[istation], 1., 1., "B");
4356  hCLCTEffVsEta[istation]->GetXaxis()->SetTitleOffset(1.2);
4357  hCLCTEffVsEta[istation]->GetXaxis()->SetTitle("#eta");
4358  hCLCTEffVsEta[istation]->SetMaximum(1.05);
4359  sprintf(histtitle, "CLCT efficiency vs #eta, station %d", istation + 1);
4360  hCLCTEffVsEta[istation]->SetTitle(histtitle);
4361  pad[page]->cd(istation + 1);
4362  hCLCTEffVsEta[istation]->Draw();
4363  }
4364  page++;
4365  c1->Update();
4366 
4367  c1->Clear();
4368  c1->cd(0);
4369  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, "CLCT efficiency vs #eta");
4370  title->SetFillColor(10);
4371  title->Draw();
4372  sprintf(pagenum, "- %d -", page);
4373  t.DrawText(0.9, 0.02, pagenum);
4374  gStyle->SetOptStat(111110);
4375  pad[page]->Draw();
4376  pad[page]->Divide(2, 5);
4377  TH1F* hCLCTEffVsEtaCsc[CSC_TYPES];
4378  for (int idh = 0; idh < max_idh; idh++) {
4379  if (!plotME1A && idh == 3)
4380  continue;
4381  hCLCTEffVsEtaCsc[idh] = (TH1F*)hEfficHitsEtaCsc[idh]->Clone();
4382  hCLCTEffVsEtaCsc[idh]->Divide(hEfficCLCTEtaCsc[idh], hEfficHitsEtaCsc[idh], 1., 1., "B");
4383  if (idh == 3 || idh == 4 || idh == 6 || idh == 8) {
4384  gPad->Update();
4385  gStyle->SetStatX(0.43);
4386  } else {
4387  gPad->Update();
4388  gStyle->SetStatX(1.00);
4389  }
4390  hCLCTEffVsEtaCsc[idh]->GetXaxis()->SetTitle("#eta");
4391  hCLCTEffVsEtaCsc[idh]->GetXaxis()->SetTitleOffset(0.8);
4392  hCLCTEffVsEtaCsc[idh]->GetXaxis()->SetTitleSize(0.07); // default=0.05
4393  hCLCTEffVsEtaCsc[idh]->GetXaxis()->SetLabelSize(0.10); // default=0.04
4394  hCLCTEffVsEtaCsc[idh]->GetYaxis()->SetLabelSize(0.10);
4395  hCLCTEffVsEtaCsc[idh]->SetLabelOffset(0.012, "XY");
4396  hCLCTEffVsEtaCsc[idh]->SetMinimum(0.50);
4397  hCLCTEffVsEtaCsc[idh]->SetMaximum(1.05);
4398  hCLCTEffVsEtaCsc[idh]->SetTitle(csc_type[idh].c_str());
4399  hCLCTEffVsEtaCsc[idh]->SetLineWidth(2);
4400  hCLCTEffVsEtaCsc[idh]->SetLineColor(4);
4401  pad[page]->cd(idh + 1);
4402  gPad->SetGrid(1);
4403  hCLCTEffVsEtaCsc[idh]->Draw();
4404  }
4405  page++;
4406  c1->Update();
4407 
4408  ps->Close();
4409  delete c1;
4410 }

References alignmentValidation::c1, csc_type, CSC_TYPES, alignmentValidation::fname, hEfficALCTEta, hEfficALCTEtaCsc, hEfficCLCTEta, hEfficCLCTEtaCsc, hEfficHitsEta, hEfficHitsEtaCsc, MAX_STATIONS, MAXPAGES, MainPageGenerator::page, plotME1A, plotME42, resultsFileNamesPrefix_, submitPVValidationJobs::t, and runGCPTkAlMap::title.

Referenced by endJob().

◆ drawHistosForTalks()

void CSCTriggerPrimitivesReader::drawHistosForTalks ( )
private

Definition at line 4412 of file CSCTriggerPrimitivesReader.cc.

4412  {
4413  TCanvas* c1 = new TCanvas("c1", "", 0, 0, 500, 640);
4414  TCanvas* c2 = new TCanvas("c2", "", 0, 0, 540, 540);
4415 
4416  TPad* pad[MAXPAGES];
4417  for (int i_page = 0; i_page < MAXPAGES; i_page++) {
4418  pad[i_page] = new TPad("", "", .07, .07, .93, .93);
4419  }
4420 
4421  int page = 1;
4422  TPaveLabel* title;
4423  gStyle->SetOptDate(0);
4424 
4425  int max_idh = plotME42 ? CSC_TYPES : CSC_TYPES - 1;
4426 
4427  TPostScript* eps1 = new TPostScript("clcts.eps", 113);
4428  eps1->NewPage();
4429  c1->Clear();
4430  c1->cd(0);
4431  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, "CLCT quantities");
4432  title->SetFillColor(10);
4433  title->Draw();
4434  pad[page]->Draw();
4435  pad[page]->Divide(2, 3);
4436  pad[page]->cd(1);
4437  hClctQuality->Draw();
4438  pad[page]->cd(2);
4439  hClctSign->Draw();
4440  TH1F* hClctPatternTot = (TH1F*)hClctPattern[0]->Clone();
4441  hClctPatternTot->SetTitle("CLCT pattern #");
4442  hClctPatternTot->Add(hClctPattern[0], hClctPattern[1], 1., 1.);
4443  pad[page]->cd(3);
4444  hClctPatternTot->Draw();
4445  hClctPattern[0]->SetLineStyle(2);
4446  hClctPattern[0]->Draw("same");
4447  hClctPattern[1]->SetLineStyle(3);
4448  hClctPattern[1]->Draw("same");
4449  pad[page]->cd(4);
4450  hClctCFEB->Draw();
4451  pad[page]->cd(5);
4452  hClctStripType->Draw();
4453  TH1F* hClctKeyStripTot = (TH1F*)hClctKeyStrip[0]->Clone();
4454  hClctKeyStripTot->SetTitle("CLCT key strip #");
4455  hClctKeyStripTot->Add(hClctKeyStrip[0], hClctKeyStrip[1], 1., 1.);
4456  pad[page]->cd(6);
4457  hClctKeyStripTot->Draw();
4458  page++;
4459  c1->Update();
4460  c1->Print("asdf.png");
4461  eps1->Close();
4462 
4463  // Resolution histograms.
4464  if (bookedResolHistos) {
4465  gStyle->SetTitleSize(0.055, ""); // size for pad title; default is 0.02
4466 
4467  TPostScript* eps2 = new TPostScript("alct_deltaWG.eps", 113);
4468  eps2->NewPage();
4469  c2->Clear();
4470  c2->cd(0);
4471  gStyle->SetOptStat(0);
4472  pad[page]->Draw();
4473  pad[page]->Divide(1, 1);
4474  hResolDeltaWG->GetXaxis()->SetTitle("WG_{rec} - WG_{sim}");
4475  hResolDeltaWG->GetXaxis()->SetTitleOffset(1.2);
4476  hResolDeltaWG->GetYaxis()->SetTitle("Entries");
4477  hResolDeltaWG->GetYaxis()->SetTitleOffset(1.9);
4478  hResolDeltaWG->GetXaxis()->SetLabelSize(0.04);
4479  hResolDeltaWG->GetYaxis()->SetLabelSize(0.04);
4480  pad[page]->cd(1);
4481  hResolDeltaWG->Draw();
4482  page++;
4483  c2->Update();
4484  eps2->Close();
4485 
4486  TPostScript* eps3 = new TPostScript("clct_deltaHS.eps", 113);
4487  eps3->NewPage();
4488  c2->Clear();
4489  c2->cd(0);
4490  pad[page]->Draw();
4491  pad[page]->Divide(1, 1);
4492  hResolDeltaHS->GetXaxis()->SetTitle("HS_{rec} - HS_{sim}");
4493  hResolDeltaHS->GetXaxis()->SetTitleOffset(1.2);
4494  hResolDeltaHS->GetYaxis()->SetTitle("Entries");
4495  hResolDeltaHS->GetYaxis()->SetTitleOffset(1.7);
4496  hResolDeltaHS->GetXaxis()->SetLabelSize(0.04); // default=0.04
4497  hResolDeltaHS->GetYaxis()->SetLabelSize(0.04);
4498  pad[page]->cd(1);
4499  hResolDeltaHS->Draw();
4500  page++;
4501  c2->Update();
4502  eps3->Close();
4503 
4504  TPostScript* eps4 = new TPostScript("clct_deltaDS.eps", 113);
4505  eps4->NewPage();
4506  c2->Clear();
4507  c2->cd(0);
4508  gStyle->SetOptStat(0);
4509  pad[page]->Draw();
4510  pad[page]->Divide(1, 1);
4511  hResolDeltaDS->GetXaxis()->SetTitle("DS_{rec} - DS_{sim}");
4512  hResolDeltaDS->GetXaxis()->SetTitleOffset(1.2);
4513  hResolDeltaDS->GetYaxis()->SetTitle("Entries");
4514  hResolDeltaDS->GetYaxis()->SetTitleOffset(1.6);
4515  hResolDeltaDS->GetXaxis()->SetLabelSize(0.04); // default=0.04
4516  hResolDeltaDS->GetYaxis()->SetLabelSize(0.04);
4517  pad[page]->cd(1);
4518  hResolDeltaDS->Draw();
4519  page++;
4520  c2->Update();
4521  eps4->Close();
4522 
4523  TPostScript* eps5 = new TPostScript("clct_deltaPhi_hs.eps", 113);
4524  eps5->NewPage();
4525  c1->Clear();
4526  c1->cd(0);
4527  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, "#phi_rec-#phi_sim (mrad), halfstrips only");
4528  title->SetFillColor(10);
4529  title->Draw();
4530  gStyle->SetTitleSize(0.1, ""); // size for pad title; default is 0.02
4531  gStyle->SetOptStat(111110);
4532  pad[page]->Draw();
4533  pad[page]->Divide(2, 5);
4534  for (int idh = 0; idh < max_idh; idh++) {
4535  if (!plotME1A && idh == 3)
4536  continue;
4537  pad[page]->cd(idh + 1);
4538  hPhiDiffCsc[idh][4]->Draw();
4539  //if (hPhiDiffCsc[idh][4]->GetEntries() > 1)
4540  //hPhiDiffCsc[idh][4]->Fit("gaus","Q");
4541  //hPhiDiffCsc[idh][4]->GetXaxis()->SetTitle("#phi_{rec} - #phi_{sim} (mrad)");
4542  //hPhiDiffCsc[idh][4]->GetXaxis()->SetTitleSize(0.06);
4543  //hPhiDiffCsc[idh][4]->GetXaxis()->SetTitleOffset(0.9);
4544  hPhiDiffCsc[idh][4]->GetYaxis()->SetTitle("Entries ");
4545  hPhiDiffCsc[idh][4]->GetYaxis()->SetTitleSize(0.07);
4546  hPhiDiffCsc[idh][4]->GetYaxis()->SetTitleOffset(1.0);
4547  hPhiDiffCsc[idh][4]->GetXaxis()->SetLabelSize(0.10); // default=0.04
4548  hPhiDiffCsc[idh][4]->GetYaxis()->SetLabelSize(0.10);
4549  hPhiDiffCsc[idh][4]->SetLabelOffset(0.012, "XY");
4550  }
4551  page++;
4552  c1->Update();
4553  eps5->Close();
4554  }
4555 
4556  // Efficiency histograms.
4557  if (bookedEfficHistos) {
4558  TPostScript* eps6 = new TPostScript("alct_effic.eps", 113);
4559  eps6->NewPage();
4560  c1->Clear();
4561  c1->cd(0);
4562  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, "ALCT efficiency vs #eta");
4563  title->SetFillColor(10);
4564  title->Draw();
4565  gStyle->SetOptStat(0);
4566  pad[page]->Draw();
4567  pad[page]->Divide(2, 5);
4568  TH1F* hALCTEffVsEtaCsc[CSC_TYPES];
4569  for (int idh = 0; idh < max_idh; idh++) {
4570  if (!plotME1A && idh == 3)
4571  continue;
4572  hALCTEffVsEtaCsc[idh] = (TH1F*)hEfficHitsEtaCsc[idh]->Clone();
4573  hALCTEffVsEtaCsc[idh]->Divide(hEfficALCTEtaCsc[idh], hEfficHitsEtaCsc[idh], 1., 1., "B");
4574  hALCTEffVsEtaCsc[idh]->GetXaxis()->SetTitle("#eta");
4575  hALCTEffVsEtaCsc[idh]->GetXaxis()->SetTitleOffset(0.8);
4576  hALCTEffVsEtaCsc[idh]->GetXaxis()->SetTitleSize(0.07); // default=0.05
4577  hALCTEffVsEtaCsc[idh]->GetXaxis()->SetLabelSize(0.10); // default=0.04
4578  hALCTEffVsEtaCsc[idh]->GetYaxis()->SetLabelSize(0.10);
4579  hALCTEffVsEtaCsc[idh]->SetLabelOffset(0.012, "XY");
4580  hALCTEffVsEtaCsc[idh]->SetMinimum(0.50);
4581  hALCTEffVsEtaCsc[idh]->SetMaximum(1.05);
4582  hALCTEffVsEtaCsc[idh]->SetTitle(csc_type[idh].c_str());
4583  hALCTEffVsEtaCsc[idh]->SetTitleSize(0.1, "");
4584  hALCTEffVsEtaCsc[idh]->SetLineWidth(2);
4585  hALCTEffVsEtaCsc[idh]->SetLineColor(4);
4586  hALCTEffVsEtaCsc[idh]->SetLineColor(4);
4587  pad[page]->cd(idh + 1);
4588  gPad->SetGrid(1);
4589  hALCTEffVsEtaCsc[idh]->Draw();
4590  }
4591  page++;
4592  c1->Update();
4593  eps6->Close();
4594 
4595  TPostScript* eps7 = new TPostScript("clct_effic.eps", 113);
4596  eps7->NewPage();
4597  c1->Clear();
4598  c1->cd(0);
4599  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, "CLCT efficiency vs #eta");
4600  title->SetFillColor(10);
4601  title->Draw();
4602  gStyle->SetOptStat(0);
4603  pad[page]->Draw();
4604  pad[page]->Divide(2, 5);
4605  TH1F* hCLCTEffVsEtaCsc[CSC_TYPES];
4606  for (int idh = 0; idh < max_idh; idh++) {
4607  if (!plotME1A && idh == 3)
4608  continue;
4609  hCLCTEffVsEtaCsc[idh] = (TH1F*)hEfficHitsEtaCsc[idh]->Clone();
4610  hCLCTEffVsEtaCsc[idh]->Divide(hEfficCLCTEtaCsc[idh], hEfficHitsEtaCsc[idh], 1., 1., "B");
4611  hCLCTEffVsEtaCsc[idh]->GetXaxis()->SetTitle("#eta");
4612  hCLCTEffVsEtaCsc[idh]->GetXaxis()->SetTitleOffset(0.8);
4613  hCLCTEffVsEtaCsc[idh]->GetXaxis()->SetTitleSize(0.07); // default=0.05
4614  hCLCTEffVsEtaCsc[idh]->GetXaxis()->SetLabelSize(0.10); // default=0.04
4615  hCLCTEffVsEtaCsc[idh]->GetYaxis()->SetLabelSize(0.10);
4616  hCLCTEffVsEtaCsc[idh]->SetLabelOffset(0.012, "XY");
4617  hCLCTEffVsEtaCsc[idh]->SetMinimum(0.50);
4618  hCLCTEffVsEtaCsc[idh]->SetMaximum(1.05);
4619  hCLCTEffVsEtaCsc[idh]->SetTitle(csc_type[idh].c_str());
4620  hCLCTEffVsEtaCsc[idh]->SetLineWidth(2);
4621  hCLCTEffVsEtaCsc[idh]->SetLineColor(4);
4622  pad[page]->cd(idh + 1);
4623  gPad->SetGrid(1);
4624  hCLCTEffVsEtaCsc[idh]->Draw();
4625  }
4626  page++;
4627  c1->Update();
4628  eps7->Close();
4629  }
4630  delete c1;
4631  delete c2;
4632 }

References bookedEfficHistos, bookedResolHistos, alignmentValidation::c1, csc_type, CSC_TYPES, hClctCFEB, hClctKeyStrip, hClctPattern, hClctQuality, hClctSign, hClctStripType, hEfficALCTEtaCsc, hEfficCLCTEtaCsc, hEfficHitsEtaCsc, hPhiDiffCsc, hResolDeltaDS, hResolDeltaHS, hResolDeltaWG, MAXPAGES, MainPageGenerator::page, plotME1A, plotME42, and runGCPTkAlMap::title.

◆ drawLCTMPCHistos()

void CSCTriggerPrimitivesReader::drawLCTMPCHistos ( )
private

Definition at line 3402 of file CSCTriggerPrimitivesReader.cc.

3402  {
3403  TCanvas* c1 = new TCanvas("c1", "", 0, 0, 500, 640);
3404  string fname = resultsFileNamesPrefix_ + "lcts_mpc.ps";
3405  TPostScript* ps = new TPostScript(fname.c_str(), 111);
3406 
3407  TPad* pad[MAXPAGES];
3408  for (int i_page = 0; i_page < MAXPAGES; i_page++) {
3409  pad[i_page] = new TPad("", "", .05, .05, .93, .93);
3410  }
3411 
3412  int page = 1;
3413  TText t;
3414  t.SetTextFont(32);
3415  t.SetTextSize(0.025);
3416  char pagenum[7];
3417  TPaveLabel* title;
3418 
3419  ps->NewPage();
3420  c1->Clear();
3421  c1->cd(0);
3422  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, "Number of LCTs");
3423  title->SetFillColor(10);
3424  title->Draw();
3425  sprintf(pagenum, "- %d -", page);
3426  t.DrawText(0.9, 0.02, pagenum);
3427  gStyle->SetOptStat(111110);
3428  pad[page]->Draw();
3429  pad[page]->Divide(1, 3);
3430  pad[page]->cd(1);
3431  hLctMPCPerEvent->Draw();
3432  for (int i = 0; i < CSC_TYPES; i++) {
3433  hLctMPCPerCSC->GetXaxis()->SetBinLabel(i + 1, csc_type[i].c_str());
3434  hCorrLctMPCPerCSC->GetXaxis()->SetBinLabel(i + 1, csc_type[i].c_str());
3435  }
3436  // Should be multiplied by 40/nevents to convert to MHz
3437  pad[page]->cd(2);
3438  hLctMPCPerCSC->Draw();
3439  pad[page]->cd(3);
3440  hCorrLctMPCPerCSC->Draw();
3441  page++;
3442  c1->Update();
3443 
3444  ps->NewPage();
3445  c1->Clear();
3446  c1->cd(0);
3447  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, "LCT geometry");
3448  title->SetFillColor(10);
3449  title->Draw();
3450  sprintf(pagenum, "- %d -", page);
3451  t.DrawText(0.9, 0.02, pagenum);
3452  gStyle->SetOptStat(110110);
3453  pad[page]->Draw();
3454  pad[page]->Divide(2, 4);
3455  pad[page]->cd(1);
3456  hLctMPCEndcap->Draw();
3457  pad[page]->cd(2);
3458  hLctMPCStation->Draw();
3459  pad[page]->cd(3);
3460  hLctMPCSector->Draw();
3461  pad[page]->cd(4);
3462  hLctMPCRing->Draw();
3463  for (int istat = 0; istat < MAX_STATIONS; istat++) {
3464  pad[page]->cd(istat + 5);
3465  hLctMPCChamber[istat]->Draw();
3466  }
3467  page++;
3468  c1->Update();
3469 
3470  ps->NewPage();
3471  c1->Clear();
3472  c1->cd(0);
3473  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, "LCT quantities");
3474  title->SetFillColor(10);
3475  title->Draw();
3476  sprintf(pagenum, "- %d -", page);
3477  t.DrawText(0.9, 0.02, pagenum);
3478  pad[page]->Draw();
3479  pad[page]->Divide(2, 4);
3480  pad[page]->cd(1);
3481  hLctMPCValid->Draw();
3482  pad[page]->cd(2);
3483  hLctMPCQuality->Draw();
3484  pad[page]->cd(3);
3485  hLctMPCKeyGroup->Draw();
3486  pad[page]->cd(4);
3487  hLctMPCKeyStrip->Draw();
3488  pad[page]->cd(5);
3489  hLctMPCStripType->Draw();
3490  pad[page]->cd(6);
3491  hLctMPCPattern->Draw();
3492  pad[page]->cd(7);
3493  hLctMPCBend->Draw();
3494  pad[page]->cd(8);
3495  hLctMPCBXN->Draw();
3496  page++;
3497  c1->Update();
3498 
3499  ps->Close();
3500  delete c1;
3501 }

References alignmentValidation::c1, csc_type, CSC_TYPES, alignmentValidation::fname, hCorrLctMPCPerCSC, hLctMPCBend, hLctMPCBXN, hLctMPCChamber, hLctMPCEndcap, hLctMPCKeyGroup, hLctMPCKeyStrip, hLctMPCPattern, hLctMPCPerCSC, hLctMPCPerEvent, hLctMPCQuality, hLctMPCRing, hLctMPCSector, hLctMPCStation, hLctMPCStripType, hLctMPCValid, mps_fire::i, MAX_STATIONS, MAXPAGES, MainPageGenerator::page, resultsFileNamesPrefix_, submitPVValidationJobs::t, and runGCPTkAlMap::title.

◆ drawLCTTMBHistos()

void CSCTriggerPrimitivesReader::drawLCTTMBHistos ( )
private

Definition at line 3270 of file CSCTriggerPrimitivesReader.cc.

3270  {
3271  TCanvas* c1 = new TCanvas("c1", "", 0, 0, 500, 640);
3272  string fname = resultsFileNamesPrefix_ + "lcts_tmb.ps";
3273  TPostScript* ps = new TPostScript(fname.c_str(), 111);
3274 
3275  TPad* pad[MAXPAGES];
3276  for (int i_page = 0; i_page < MAXPAGES; i_page++) {
3277  pad[i_page] = new TPad("", "", .05, .05, .93, .93);
3278  }
3279 
3280  int page = 1;
3281  TText t;
3282  t.SetTextFont(32);
3283  t.SetTextSize(0.025);
3284  char pagenum[7], titl[50];
3285  TPaveLabel* title;
3286 
3287  int max_idh = plotME42 ? CSC_TYPES : CSC_TYPES - 1;
3288 
3289  ps->NewPage();
3290  c1->Clear();
3291  c1->cd(0);
3292  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, "Number of LCTs");
3293  title->SetFillColor(10);
3294  title->Draw();
3295  sprintf(pagenum, "- %d -", page);
3296  t.DrawText(0.9, 0.02, pagenum);
3297  gStyle->SetOptStat(111110);
3298  pad[page]->Draw();
3299  pad[page]->Divide(2, 2);
3300  pad[page]->cd(1);
3301  hLctTMBPerEvent->Draw();
3302  pad[page]->cd(2);
3303  hLctTMBPerChamber->Draw();
3304  c1->Update();
3305  for (int i = 0; i < CSC_TYPES; i++) {
3306  hLctTMBPerCSC->GetXaxis()->SetBinLabel(i + 1, csc_type[i].c_str());
3307  hCorrLctTMBPerCSC->GetXaxis()->SetBinLabel(i + 1, csc_type[i].c_str());
3308  }
3309  // Should be multiplied by 40/nevents to convert to MHz
3310  pad[page]->cd(3);
3311  hLctTMBPerCSC->Draw();
3312  pad[page]->cd(4);
3313  hCorrLctTMBPerCSC->Draw();
3314  gStyle->SetOptStat(1110);
3315  page++;
3316  c1->Update();
3317 
3318  ps->NewPage();
3319  c1->Clear();
3320  c1->cd(0);
3321  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, "LCT geometry");
3322  title->SetFillColor(10);
3323  title->Draw();
3324  sprintf(pagenum, "- %d -", page);
3325  t.DrawText(0.9, 0.02, pagenum);
3326  gStyle->SetOptStat(110110);
3327  pad[page]->Draw();
3328  pad[page]->Divide(2, 4);
3329  pad[page]->cd(1);
3330  hLctTMBEndcap->Draw();
3331  pad[page]->cd(2);
3332  hLctTMBStation->Draw();
3333  pad[page]->cd(3);
3334  hLctTMBSector->Draw();
3335  pad[page]->cd(4);
3336  hLctTMBRing->Draw();
3337  for (int istat = 0; istat < MAX_STATIONS; istat++) {
3338  pad[page]->cd(istat + 5);
3339  hLctTMBChamber[istat]->Draw();
3340  }
3341  page++;
3342  c1->Update();
3343 
3344  for (int endc = 0; endc < MAX_ENDCAPS; endc++) {
3345  ps->NewPage();
3346  c1->Clear();
3347  c1->cd(0);
3348  sprintf(titl, "LCTs per chamber, endcap %d", endc + 1);
3349  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, titl);
3350  title->SetFillColor(10);
3351  title->Draw();
3352  sprintf(pagenum, "- %d -", page);
3353  t.DrawText(0.9, 0.02, pagenum);
3354  gStyle->SetOptStat(10);
3355  pad[page]->Draw();
3356  pad[page]->Divide(2, 5);
3357  for (int idh = 0; idh < max_idh; idh++) {
3358  if (!plotME1A && idh == 3)
3359  continue;
3360  hLctTMBCsc[endc][idh]->SetMinimum(0.0);
3361  pad[page]->cd(idh + 1);
3362  hLctTMBCsc[endc][idh]->Draw();
3363  }
3364  page++;
3365  c1->Update();
3366  }
3367 
3368  ps->NewPage();
3369  c1->Clear();
3370  c1->cd(0);
3371  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, "LCT quantities");
3372  title->SetFillColor(10);
3373  title->Draw();
3374  sprintf(pagenum, "- %d -", page);
3375  t.DrawText(0.9, 0.02, pagenum);
3376  gStyle->SetOptStat(110110);
3377  pad[page]->Draw();
3378  pad[page]->Divide(2, 4);
3379  pad[page]->cd(1);
3380  hLctTMBValid->Draw();
3381  pad[page]->cd(2);
3382  hLctTMBQuality->Draw();
3383  pad[page]->cd(3);
3384  hLctTMBKeyGroup->Draw();
3385  pad[page]->cd(4);
3386  hLctTMBKeyStrip->Draw();
3387  pad[page]->cd(5);
3388  hLctTMBStripType->Draw();
3389  pad[page]->cd(6);
3390  hLctTMBPattern->Draw();
3391  pad[page]->cd(7);
3392  hLctTMBBend->Draw();
3393  pad[page]->cd(8);
3394  hLctTMBBXN->Draw();
3395  page++;
3396  c1->Update();
3397 
3398  ps->Close();
3399  delete c1;
3400 }

References alignmentValidation::c1, csc_type, CSC_TYPES, alignmentValidation::fname, hCorrLctTMBPerCSC, hLctTMBBend, hLctTMBBXN, hLctTMBChamber, hLctTMBCsc, hLctTMBEndcap, hLctTMBKeyGroup, hLctTMBKeyStrip, hLctTMBPattern, hLctTMBPerChamber, hLctTMBPerCSC, hLctTMBPerEvent, hLctTMBQuality, hLctTMBRing, hLctTMBSector, hLctTMBStation, hLctTMBStripType, hLctTMBValid, mps_fire::i, MAX_ENDCAPS, MAX_STATIONS, MAXPAGES, MainPageGenerator::page, plotME1A, plotME42, resultsFileNamesPrefix_, submitPVValidationJobs::t, and runGCPTkAlMap::title.

Referenced by endJob().

◆ drawResolHistos()

void CSCTriggerPrimitivesReader::drawResolHistos ( )
private

Definition at line 3862 of file CSCTriggerPrimitivesReader.cc.

3862  {
3863  TCanvas* c1 = new TCanvas("c1", "", 0, 0, 500, 640);
3864  string fname = resultsFileNamesPrefix_ + "lcts_resol.ps";
3865  TPostScript* ps = new TPostScript(fname.c_str(), 111);
3866 
3867  TPad* pad[MAXPAGES];
3868  for (int i_page = 0; i_page < MAXPAGES; i_page++) {
3869  pad[i_page] = new TPad("", "", .05, .05, .93, .93);
3870  }
3871 
3872  int page = 1;
3873  TText t;
3874  t.SetTextFont(32);
3875  t.SetTextSize(0.025);
3876  char pagenum[7];
3877  TPaveLabel* title;
3878 
3879  int max_idh = plotME42 ? CSC_TYPES : CSC_TYPES - 1;
3880 
3881  ps->NewPage();
3882  c1->Clear();
3883  c1->cd(0);
3884  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, "ALCT resolution");
3885  title->SetFillColor(10);
3886  title->Draw();
3887  sprintf(pagenum, "- %d -", page);
3888  t.DrawText(0.9, 0.02, pagenum);
3889  gStyle->SetOptStat(111110);
3890  pad[page]->Draw();
3891  pad[page]->Divide(2, 2);
3892  gStyle->SetStatX(1.00);
3893  gStyle->SetStatY(0.65);
3894  pad[page]->cd(1);
3895  hEtaRecVsSim->SetMarkerSize(0.2);
3896  hEtaRecVsSim->Draw();
3897  gPad->Update();
3898  gStyle->SetStatX(1.00);
3899  gStyle->SetStatY(0.995);
3900  hResolDeltaWG->GetXaxis()->SetTitle("WG_{rec} - WG_{sim}");
3901  hResolDeltaWG->GetXaxis()->SetTitleOffset(1.2);
3902  hResolDeltaWG->GetYaxis()->SetTitle("Entries");
3903  hResolDeltaWG->GetYaxis()->SetTitleOffset(1.9);
3904  hResolDeltaWG->GetXaxis()->SetLabelSize(0.03);
3905  hResolDeltaWG->GetYaxis()->SetLabelSize(0.03);
3906  pad[page]->cd(3);
3907  hResolDeltaWG->Draw();
3908  hResolDeltaEta->GetXaxis()->SetNdivisions(505); // twice fewer divisions
3909  hResolDeltaEta->GetXaxis()->SetLabelSize(0.04);
3910  hResolDeltaEta->GetYaxis()->SetLabelSize(0.04);
3911  pad[page]->cd(4);
3912  hResolDeltaEta->Draw();
3913  hResolDeltaEta->Fit("gaus", "Q");
3914  page++;
3915  c1->Update();
3916 
3917  ps->NewPage();
3918  c1->Clear();
3919  c1->cd(0);
3920  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, "#eta_rec-#eta_sim");
3921  title->SetFillColor(10);
3922  title->Draw();
3923  sprintf(pagenum, "- %d -", page);
3924  t.DrawText(0.9, 0.02, pagenum);
3925  pad[page]->Draw();
3926  pad[page]->Divide(2, 5);
3927  for (int idh = 0; idh < max_idh; idh++) {
3928  if (!plotME1A && idh == 3)
3929  continue;
3930  hEtaDiffCsc[idh][0]->GetXaxis()->SetLabelSize(0.07); // default=0.04
3931  hEtaDiffCsc[idh][0]->GetYaxis()->SetLabelSize(0.07);
3932  pad[page]->cd(idh + 1);
3933  hEtaDiffCsc[idh][0]->Draw();
3934  if (hEtaDiffCsc[idh][0]->GetEntries() > 1)
3935  hEtaDiffCsc[idh][0]->Fit("gaus", "Q");
3936  }
3937  page++;
3938  c1->Update();
3939 
3940  ps->NewPage();
3941  c1->Clear();
3942  c1->cd(0);
3943  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, "#eta_rec-#eta_sim, endcap1");
3944  title->SetFillColor(10);
3945  title->Draw();
3946  sprintf(pagenum, "- %d -", page);
3947  t.DrawText(0.9, 0.02, pagenum);
3948  pad[page]->Draw();
3949  pad[page]->Divide(2, 5);
3950  for (int idh = 0; idh < max_idh; idh++) {
3951  if (!plotME1A && idh == 3)
3952  continue;
3953  hEtaDiffCsc[idh][1]->GetXaxis()->SetLabelSize(0.07); // default=0.04
3954  hEtaDiffCsc[idh][1]->GetYaxis()->SetLabelSize(0.07);
3955  pad[page]->cd(idh + 1);
3956  hEtaDiffCsc[idh][1]->Draw();
3957  if (hEtaDiffCsc[idh][1]->GetEntries() > 1)
3958  hEtaDiffCsc[idh][1]->Fit("gaus", "Q");
3959  }
3960  page++;
3961  c1->Update();
3962 
3963  ps->NewPage();
3964  c1->Clear();
3965  c1->cd(0);
3966  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, "#eta_rec-#eta_sim, endcap2");
3967  title->SetFillColor(10);
3968  title->Draw();
3969  sprintf(pagenum, "- %d -", page);
3970  t.DrawText(0.9, 0.02, pagenum);
3971  pad[page]->Draw();
3972  pad[page]->Divide(2, 5);
3973  for (int idh = 0; idh < max_idh; idh++) {
3974  if (!plotME1A && idh == 3)
3975  continue;
3976  hEtaDiffCsc[idh][2]->GetXaxis()->SetLabelSize(0.07); // default=0.04
3977  hEtaDiffCsc[idh][2]->GetYaxis()->SetLabelSize(0.07);
3978  pad[page]->cd(idh + 1);
3979  hEtaDiffCsc[idh][2]->Draw();
3980  if (hEtaDiffCsc[idh][2]->GetEntries() > 1)
3981  hEtaDiffCsc[idh][2]->Fit("gaus", "Q");
3982  }
3983  page++;
3984  c1->Update();
3985 
3986  ps->NewPage();
3987  c1->Clear();
3988  c1->cd(0);
3989  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, "#LT#eta_rec-#eta_sim#GT vs #eta_rec");
3990  title->SetFillColor(10);
3991  title->Draw();
3992  sprintf(pagenum, "- %d -", page);
3993  t.DrawText(0.9, 0.02, pagenum);
3994  //gStyle->SetOptStat(0);
3995  pad[page]->Draw();
3996  pad[page]->Divide(2, 2);
3997  TH1F* hMeanEtaDiffVsEta[MAX_STATIONS];
3998  for (int istation = 0; istation < MAX_STATIONS; istation++) {
3999  hMeanEtaDiffVsEta[istation] = (TH1F*)hEtaDiffVsEta[istation]->Clone();
4000  hMeanEtaDiffVsEta[istation]->Divide(hEtaDiffVsEta[istation], hAlctVsEta[istation], 1., 1.);
4001  hMeanEtaDiffVsEta[istation]->GetXaxis()->SetTitleOffset(1.2);
4002  hMeanEtaDiffVsEta[istation]->GetXaxis()->SetTitle("#eta");
4003  hMeanEtaDiffVsEta[istation]->SetMaximum(0.05);
4004  pad[page]->cd(istation + 1);
4005  hMeanEtaDiffVsEta[istation]->Draw();
4006  }
4007  page++;
4008  c1->Update();
4009 
4010  c1->Clear();
4011  c1->cd(0);
4012  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, "#eta_rec-#eta_sim vs wiregroup");
4013  title->SetFillColor(10);
4014  title->Draw();
4015  sprintf(pagenum, "- %d -", page);
4016  t.DrawText(0.9, 0.02, pagenum);
4017  pad[page]->Draw();
4018  pad[page]->Divide(2, 5);
4019  for (int idh = 0; idh < max_idh; idh++) {
4020  if (!plotME1A && idh == 3)
4021  continue;
4022  pad[page]->cd(idh + 1);
4023  hEtaDiffVsWireCsc[idh]->SetMarkerSize(0.2);
4024  hEtaDiffVsWireCsc[idh]->GetXaxis()->SetTitle("Wiregroup");
4025  hEtaDiffVsWireCsc[idh]->GetXaxis()->SetTitleSize(0.07);
4026  hEtaDiffVsWireCsc[idh]->GetXaxis()->SetTitleOffset(1.2);
4027  hEtaDiffVsWireCsc[idh]->GetYaxis()->SetTitle("#eta_rec-#eta_sim");
4028  hEtaDiffVsWireCsc[idh]->GetYaxis()->SetTitleSize(0.07);
4029  hEtaDiffVsWireCsc[idh]->GetXaxis()->SetLabelSize(0.07); // default=0.04
4030  hEtaDiffVsWireCsc[idh]->GetYaxis()->SetLabelSize(0.07);
4031  hEtaDiffVsWireCsc[idh]->Draw();
4032  }
4033  page++;
4034  c1->Update();
4035 
4036  ps->NewPage();
4037  c1->Clear();
4038  c1->cd(0);
4039  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, "#phi resolution");
4040  title->SetFillColor(10);
4041  title->Draw();
4042  sprintf(pagenum, "- %d -", page);
4043  t.DrawText(0.9, 0.02, pagenum);
4044  gStyle->SetOptStat(111110);
4045  pad[page]->Draw();
4046  pad[page]->Divide(2, 2);
4047  gStyle->SetStatX(1.00);
4048  gStyle->SetStatY(0.65);
4049  pad[page]->cd(1);
4050  hPhiRecVsSim->SetMarkerSize(0.2);
4051  hPhiRecVsSim->Draw();
4052  gPad->Update();
4053  gStyle->SetStatX(1.00);
4054  gStyle->SetStatY(0.995);
4055  hResolDeltaPhi->GetXaxis()->SetLabelSize(0.04);
4056  hResolDeltaPhi->GetYaxis()->SetLabelSize(0.04);
4057  pad[page]->cd(2);
4058  hResolDeltaPhi->Draw();
4059  hResolDeltaPhi->Fit("gaus", "Q");
4060  hResolDeltaHS->GetXaxis()->SetTitle("HS_{rec} - HS_{sim}");
4061  hResolDeltaHS->GetXaxis()->SetTitleOffset(1.2);
4062  hResolDeltaHS->GetYaxis()->SetTitle("Entries");
4063  hResolDeltaHS->GetYaxis()->SetTitleOffset(1.7);
4064  hResolDeltaHS->GetXaxis()->SetLabelSize(0.03);
4065  hResolDeltaHS->GetYaxis()->SetLabelSize(0.03);
4066  pad[page]->cd(3);
4067  hResolDeltaHS->Draw();
4068  hResolDeltaDS->GetXaxis()->SetTitle("DS_{rec} - DS_{sim}");
4069  hResolDeltaDS->GetXaxis()->SetTitleOffset(1.2);
4070  hResolDeltaDS->GetYaxis()->SetTitle("Entries");
4071  hResolDeltaDS->GetYaxis()->SetTitleOffset(1.6);
4072  hResolDeltaDS->GetXaxis()->SetLabelSize(0.04);
4073  hResolDeltaDS->GetYaxis()->SetLabelSize(0.04);
4074  pad[page]->cd(4);
4075  hResolDeltaDS->Draw();
4076  page++;
4077  c1->Update();
4078 
4079  ps->NewPage();
4080  c1->Clear();
4081  c1->cd(0);
4082  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, "#phi_rec-#phi_sim (mrad)");
4083  title->SetFillColor(10);
4084  title->Draw();
4085  sprintf(pagenum, "- %d -", page);
4086  t.DrawText(0.9, 0.02, pagenum);
4087  pad[page]->Draw();
4088  pad[page]->Divide(2, 5);
4089  for (int idh = 0; idh < max_idh; idh++) {
4090  if (!plotME1A && idh == 3)
4091  continue;
4092  hPhiDiffCsc[idh][0]->GetXaxis()->SetLabelSize(0.07); // default=0.04
4093  hPhiDiffCsc[idh][0]->GetYaxis()->SetLabelSize(0.07);
4094  pad[page]->cd(idh + 1);
4095  hPhiDiffCsc[idh][0]->Draw();
4096  if (hPhiDiffCsc[idh][0]->GetEntries() > 1)
4097  hPhiDiffCsc[idh][0]->Fit("gaus", "Q");
4098  }
4099  page++;
4100  c1->Update();
4101 
4102  ps->NewPage();
4103  c1->Clear();
4104  c1->cd(0);
4105  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, "#phi_rec-#phi_sim (mrad), endcap1");
4106  title->SetFillColor(10);
4107  title->Draw();
4108  sprintf(pagenum, "- %d -", page);
4109  t.DrawText(0.9, 0.02, pagenum);
4110  pad[page]->Draw();
4111  pad[page]->Divide(2, 5);
4112  for (int idh = 0; idh < max_idh; idh++) {
4113  if (!plotME1A && idh == 3)
4114  continue;
4115  hPhiDiffCsc[idh][1]->GetXaxis()->SetLabelSize(0.07); // default=0.04
4116  hPhiDiffCsc[idh][1]->GetYaxis()->SetLabelSize(0.07);
4117  pad[page]->cd(idh + 1);
4118  hPhiDiffCsc[idh][1]->Draw();
4119  if (hPhiDiffCsc[idh][1]->GetEntries() > 1)
4120  hPhiDiffCsc[idh][1]->Fit("gaus", "Q");
4121  }
4122  page++;
4123  c1->Update();
4124 
4125  ps->NewPage();
4126  c1->Clear();
4127  c1->cd(0);
4128  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, "#phi_rec-#phi_sim (mrad), endcap2");
4129  title->SetFillColor(10);
4130  title->Draw();
4131  sprintf(pagenum, "- %d -", page);
4132  t.DrawText(0.9, 0.02, pagenum);
4133  pad[page]->Draw();
4134  pad[page]->Divide(2, 5);
4135  for (int idh = 0; idh < max_idh; idh++) {
4136  if (!plotME1A && idh == 3)
4137  continue;
4138  hPhiDiffCsc[idh][2]->GetXaxis()->SetLabelSize(0.07); // default=0.04
4139  hPhiDiffCsc[idh][2]->GetYaxis()->SetLabelSize(0.07);
4140  pad[page]->cd(idh + 1);
4141  hPhiDiffCsc[idh][2]->Draw();
4142  if (hPhiDiffCsc[idh][2]->GetEntries() > 1)
4143  hPhiDiffCsc[idh][2]->Fit("gaus", "Q");
4144  }
4145  page++;
4146  c1->Update();
4147 
4148  ps->NewPage();
4149  c1->Clear();
4150  c1->cd(0);
4151  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, "#LT#phi_rec-#phi_sim#GT (mrad) vs #phi_rec");
4152  title->SetFillColor(10);
4153  title->Draw();
4154  sprintf(pagenum, "- %d -", page);
4155  t.DrawText(0.9, 0.02, pagenum);
4156  gStyle->SetOptStat(0);
4157  pad[page]->Draw();
4158  pad[page]->Divide(2, 2);
4159  TH1F* hMeanPhiDiffVsPhi[MAX_STATIONS];
4160  for (int istation = 0; istation < MAX_STATIONS; istation++) {
4161  hMeanPhiDiffVsPhi[istation] = (TH1F*)hPhiDiffVsPhi[istation]->Clone();
4162  hMeanPhiDiffVsPhi[istation]->Divide(hPhiDiffVsPhi[istation], hClctVsPhi[istation], 1., 1.);
4163  hMeanPhiDiffVsPhi[istation]->GetXaxis()->SetTitleOffset(1.2);
4164  hMeanPhiDiffVsPhi[istation]->GetYaxis()->SetTitleOffset(1.7);
4165  hMeanPhiDiffVsPhi[istation]->GetXaxis()->SetTitle("#phi");
4166  hMeanPhiDiffVsPhi[istation]->GetYaxis()->SetTitle("#LT#phi_rec-#phi_sim#GT (mrad)");
4167  hMeanPhiDiffVsPhi[istation]->SetMaximum(5.);
4168  pad[page]->cd(istation + 1);
4169  hMeanPhiDiffVsPhi[istation]->Draw();
4170  }
4171  page++;
4172  c1->Update();
4173 
4174  c1->Clear();
4175  c1->cd(0);
4176  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, "#phi_rec-#phi_sim (mrad) vs halfstrip #");
4177  title->SetFillColor(10);
4178  title->Draw();
4179  sprintf(pagenum, "- %d -", page);
4180  t.DrawText(0.9, 0.02, pagenum);
4181  gStyle->SetOptStat(0);
4182  pad[page]->Draw();
4183  pad[page]->Divide(2, 5);
4184  for (int idh = 0; idh < max_idh; idh++) {
4185  if (!plotME1A && idh == 3)
4186  continue;
4187  pad[page]->cd(idh + 1);
4188  hPhiDiffVsStripCsc[idh][1]->SetMarkerSize(0.2);
4189  hPhiDiffVsStripCsc[idh][1]->GetXaxis()->SetTitle("Halfstrip");
4190  hPhiDiffVsStripCsc[idh][1]->GetXaxis()->SetTitleOffset(1.4);
4191  hPhiDiffVsStripCsc[idh][1]->GetYaxis()->SetTitle("#phi_rec-#phi_sim (mrad)");
4192  hPhiDiffVsStripCsc[idh][1]->GetXaxis()->SetLabelSize(0.07); // default=0.04
4193  hPhiDiffVsStripCsc[idh][1]->GetYaxis()->SetLabelSize(0.07);
4194  hPhiDiffVsStripCsc[idh][1]->Draw();
4195  }
4196  page++;
4197  c1->Update();
4198 
4199  c1->Clear();
4200  c1->cd(0);
4201  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, "#phi_rec-#phi_sim, halfstrips only, different patterns");
4202  title->SetFillColor(10);
4203  title->Draw();
4204  sprintf(pagenum, "- %d -", page);
4205  t.DrawText(0.9, 0.02, pagenum);
4206  gStyle->SetOptStat(111110);
4207  pad[page]->Draw();
4208  pad[page]->Divide(3, 3);
4209  int min_pattern, max_pattern;
4210  min_pattern = 2;
4211  max_pattern = CSCConstants::NUM_CLCT_PATTERNS;
4212  for (int idh = min_pattern; idh < max_pattern; idh++) {
4213  hPhiDiffPattern[idh]->GetXaxis()->SetTitle("Halfstrip");
4214  hPhiDiffPattern[idh]->GetXaxis()->SetTitleOffset(1.2);
4215  pad[page]->cd(idh - min_pattern + 1);
4216  hPhiDiffPattern[idh]->Draw();
4217  // if (hPhiDiffPattern[idh]->GetEntries() > 1)
4218  // hPhiDiffPattern[idh]->Fit("gaus","Q");
4219  }
4220  page++;
4221  c1->Update();
4222 
4223  ps->NewPage();
4224  c1->Clear();
4225  c1->cd(0);
4226  title = new TPaveLabel(0.1, 0.94, 0.9, 0.98, "#phi_1-#phi_6 (mrad), muon SimHits");
4227  title->SetFillColor(10);
4228  title->Draw();
4229  sprintf(pagenum, "- %d -", page);
4230  t.DrawText(0.9, 0.02, pagenum);
4231  pad[page]->Draw();
4232  pad[page]->Divide(2, 5);
4233  for (int idh = 0; idh < max_idh; idh++) {
4234  if (!plotME1A && idh == 3)
4235  continue;
4236  hTrueBendCsc[idh]->GetYaxis()->SetTitle("Entries");
4237  hTrueBendCsc[idh]->GetYaxis()->SetTitleSize(0.07);
4238  hTrueBendCsc[idh]->GetXaxis()->SetLabelSize(0.07); // default=0.04
4239  hTrueBendCsc[idh]->GetYaxis()->SetLabelSize(0.07);
4240  pad[page]->cd(idh + 1);
4241  hTrueBendCsc[idh]->Draw();
4242  }
4243  page++;
4244  c1->Update();
4245 
4246  ps->Close();
4247  delete c1;
4248 }

References alignmentValidation::c1, CSC_TYPES, alignmentValidation::fname, hAlctVsEta, hClctVsPhi, hEtaDiffCsc, hEtaDiffVsEta, hEtaDiffVsWireCsc, hEtaRecVsSim, hPhiDiffCsc, hPhiDiffPattern, hPhiDiffVsPhi, hPhiDiffVsStripCsc, hPhiRecVsSim, hResolDeltaDS, hResolDeltaEta, hResolDeltaHS, hResolDeltaPhi, hResolDeltaWG, hTrueBendCsc, MAX_STATIONS, MAXPAGES, CSCConstants::NUM_CLCT_PATTERNS, MainPageGenerator::page, plotME1A, plotME42, resultsFileNamesPrefix_, submitPVValidationJobs::t, and runGCPTkAlMap::title.

Referenced by endJob().

◆ endJob()

void CSCTriggerPrimitivesReader::endJob ( void  )
overridevirtual

Write to ROOT file, make plots, etc.

Reimplemented from edm::EDAnalyzer.

Definition at line 502 of file CSCTriggerPrimitivesReader.cc.

502  {
503  // Note: all operations involving ROOT should be placed here and not in the
504  // destructor.
505  // Plot histos if they were booked/filled.
506  if (printps) {
507  if (bookedALCTHistos)
508  drawALCTHistos();
509  if (bookedCLCTHistos)
510  drawCLCTHistos();
511  if (bookedLCTTMBHistos)
513  //if (bookedLCTMPCHistos) drawLCTMPCHistos();
514 
515  if (bookedCompHistos)
516  drawCompHistos();
517 
518  if (bookedResolHistos)
519  drawResolHistos();
520  if (bookedEfficHistos)
521  drawEfficHistos();
522  }
523  //drawHistosForTalks();
524 
525  //theFile->cd();
526  //theFile->Write();
527  //theFile->Close();
528 
529  // Job summary.
530  edm::LogInfo("CSCTriggerPrimitivesReader")
531  << "\n Average number of ALCTs/event = " << static_cast<float>(numALCT) / eventsAnalyzed << endl;
532  edm::LogInfo("CSCTriggerPrimitivesReader")
533  << " Average number of CLCTs/event = " << static_cast<float>(numCLCT) / eventsAnalyzed << endl;
534  edm::LogInfo("CSCTriggerPrimitivesReader")
535  << " Average number of TMB LCTs/event = " << static_cast<float>(numLCTTMB) / eventsAnalyzed << endl;
536  edm::LogInfo("CSCTriggerPrimitivesReader")
537  << " Average number of MPC LCTs/event = " << static_cast<float>(numLCTMPC) / eventsAnalyzed << endl;
538 
539  if (bookedEfficHistos) {
540  {
541  edm::LogInfo("CSCTriggerPrimitivesReader") << "\n ALCT efficiencies:";
542  double tot_simh = 0.0, tot_alct = 0.0;
543  for (int idh = 0; idh < CSC_TYPES; idh++) {
544  double simh = hEfficHitsEtaCsc[idh]->Integral();
545  double alct = hEfficALCTEtaCsc[idh]->Integral();
546  double eff = 0.;
547  if (simh > 0)
548  eff = alct / simh;
549  edm::LogInfo("CSCTriggerPrimitivesReader")
550  << " " << csc_type[idh] << ": alct = " << alct << ", simh = " << simh << " eff = " << eff;
551  tot_simh += simh;
552  tot_alct += alct;
553  }
554  edm::LogInfo("CSCTriggerPrimitivesReader")
555  << " overall: alct = " << tot_alct << ", simh = " << tot_simh << " eff = " << tot_alct / tot_simh;
556  }
557 
558  {
559  edm::LogInfo("CSCTriggerPrimitivesReader") << "\n CLCT efficiencies:";
560  double tot_simh = 0.0, tot_clct = 0.0;
561  for (int idh = 0; idh < CSC_TYPES; idh++) {
562  double simh = hEfficHitsEtaCsc[idh]->Integral();
563  double clct = hEfficCLCTEtaCsc[idh]->Integral();
564  double eff = 0.;
565  if (simh > 0.)
566  eff = clct / simh;
567  edm::LogInfo("CSCTriggerPrimitivesReader")
568  << " " << csc_type[idh] << ": clct = " << clct << ", simh = " << simh << " eff = " << eff;
569  tot_simh += simh;
570  tot_clct += clct;
571  }
572  edm::LogInfo("CSCTriggerPrimitivesReader")
573  << " overall: clct = " << tot_clct << ", simh = " << tot_simh << " eff = " << tot_clct / tot_simh;
574  }
575  }
576 
577  if (bookedResolHistos) {
578  double cor = 0.0, tot = 0.0;
579  cor = hResolDeltaHS->GetBinContent(hResolDeltaHS->FindBin(0.));
580  tot = hResolDeltaHS->GetEntries();
581  edm::LogInfo("CSCTriggerPrimitivesReader")
582  << "\n Correct half-strip assigned in " << cor << "/" << tot << " = " << cor / tot << " of half-strip CLCTs";
583  //cor = hResolDeltaDS->GetBinContent(hResolDeltaDS->FindBin(0.));
584  //tot = hResolDeltaDS->GetEntries();
585  //edm::LogInfo("CSCTriggerPrimitivesReader")
586  // << " Correct di-strip assigned in " << cor << "/" << tot
587  // << " = " << cor/tot << " of di-strip CLCTs";
588  cor = hResolDeltaWG->GetBinContent(hResolDeltaWG->FindBin(0.));
589  tot = hResolDeltaWG->GetEntries();
590  edm::LogInfo("CSCTriggerPrimitivesReader")
591  << " Correct wire group assigned in " << cor << "/" << tot << " = " << cor / tot << " of ALCTs";
592  }
593 }

References bookedALCTHistos, bookedCLCTHistos, bookedCompHistos, bookedEfficHistos, bookedLCTTMBHistos, bookedResolHistos, csc_type, CSC_TYPES, drawALCTHistos(), drawCLCTHistos(), drawCompHistos(), drawEfficHistos(), drawLCTTMBHistos(), drawResolHistos(), eventsAnalyzed, hEfficALCTEtaCsc, hEfficCLCTEtaCsc, hEfficHitsEtaCsc, hResolDeltaHS, hResolDeltaWG, numALCT, numCLCT, numLCTMPC, numLCTTMB, and printps.

◆ fillALCTHistos()

void CSCTriggerPrimitivesReader::fillALCTHistos ( const CSCALCTDigiCollection alcts)
private

Definition at line 1125 of file CSCTriggerPrimitivesReader.cc.

1125  {
1126  // Book histos when called for the first time.
1127  if (!bookedALCTHistos)
1128  bookALCTHistos();
1129 
1130  int nValidALCTs = 0;
1131  for (auto detUnitIt = alcts->begin(); detUnitIt != alcts->end(); detUnitIt++) {
1132  int nValidALCTsPerCSC = 0;
1133  const CSCDetId& id = (*detUnitIt).first;
1135  continue;
1136  const auto& range = (*detUnitIt).second;
1137  for (auto digiIt = range.first; digiIt != range.second; digiIt++) {
1138  bool alct_valid = (*digiIt).isValid();
1139  hAlctValid->Fill(alct_valid);
1140  if (alct_valid) {
1141  hAlctQuality->Fill((*digiIt).getQuality());
1142  hAlctAccel->Fill((*digiIt).getAccelerator());
1143  hAlctCollis->Fill((*digiIt).getCollisionB());
1144  hAlctKeyGroup->Fill((*digiIt).getKeyWG());
1145  hAlctBXN->Fill((*digiIt).getBX());
1146 
1147  int csctype = getCSCType(id);
1148  hAlctPerCSC->Fill(csctype);
1149  hAlctCsc[id.endcap() - 1][csctype]->Fill(id.chamber());
1150 
1151  if (csctype == 0)
1152  hAlctKeyGroupME11->Fill((*digiIt).getKeyWG());
1153 
1154  nValidALCTs++;
1155  nValidALCTsPerCSC++;
1156 
1157  if (debug)
1158  LogTrace("CSCTriggerPrimitivesReader")
1159  << (*digiIt) << " found in ME" << ((id.endcap() == 1) ? "+" : "-") << id.station() << "/" << id.ring()
1160  << "/" << id.chamber() << " (sector " << id.triggerSector() << " trig id. " << id.triggerCscId() << ")";
1161  //cout << "raw id = " << id.rawId() << endl;
1162  }
1163  }
1164  hAlctPerChamber->Fill(nValidALCTsPerCSC);
1165  }
1166  hAlctPerEvent->Fill(nValidALCTs);
1167  if (debug)
1168  LogTrace("CSCTriggerPrimitivesReader") << nValidALCTs << " valid ALCTs found in this event";
1169  numALCT += nValidALCTs;
1170 }

References badChambers_, bookALCTHistos(), bookedALCTHistos, relativeConstraints::chamber, checkBadChambers_, debug, getCSCType(), hAlctAccel, hAlctBXN, hAlctCollis, hAlctCsc, hAlctKeyGroup, hAlctKeyGroupME11, hAlctPerChamber, hAlctPerCSC, hAlctPerEvent, hAlctQuality, hAlctValid, CSCBadChambers::isInBadChamber(), LogTrace, numALCT, and FastTimerService_cff::range.

Referenced by analyze().

◆ fillCLCTHistos()

void CSCTriggerPrimitivesReader::fillCLCTHistos ( const CSCCLCTDigiCollection clcts)
private

Definition at line 1172 of file CSCTriggerPrimitivesReader.cc.

1172  {
1173  // Book histos when called for the first time.
1174  if (!bookedCLCTHistos)
1175  bookCLCTHistos();
1176 
1177  int nValidCLCTs = 0;
1178  for (auto detUnitIt = clcts->begin(); detUnitIt != clcts->end(); detUnitIt++) {
1179  int nValidCLCTsPerCSC = 0;
1180  const CSCDetId& id = (*detUnitIt).first;
1182  continue;
1183  const auto& range = (*detUnitIt).second;
1184  for (auto digiIt = range.first; digiIt != range.second; digiIt++) {
1185  bool clct_valid = (*digiIt).isValid();
1186  hClctValid->Fill(clct_valid);
1187  if (clct_valid) {
1188  int striptype = (*digiIt).getStripType();
1189  int keystrip = (*digiIt).getKeyStrip(); // halfstrip #
1190  if (striptype == 0)
1191  keystrip /= 4; // distrip # for distrip ptns
1192  hClctQuality->Fill((*digiIt).getQuality());
1193  hClctStripType->Fill(striptype);
1194  hClctSign->Fill((*digiIt).getBend());
1195  hClctCFEB->Fill((*digiIt).getCFEB());
1196  hClctBXN->Fill((*digiIt).getBX());
1197  hClctKeyStrip[striptype]->Fill(keystrip);
1198  hClctPattern[striptype]->Fill((*digiIt).getPattern());
1199 
1200  int csctype = getCSCType(id);
1201  hClctPerCSC->Fill(csctype);
1202  hClctCsc[id.endcap() - 1][csctype]->Fill(id.chamber());
1203 
1204  if (striptype == 1 && csctype == 0)
1205  hClctKeyStripME11->Fill(keystrip);
1206 
1207  int phibend;
1208  int pattern = (*digiIt).getPattern();
1209  phibend = ptype_TMB07[pattern];
1210  hClctBendCsc[csctype][striptype]->Fill(abs(phibend));
1211 
1212  if (striptype == 0) // distrips
1213  hClctKeyStripCsc[csctype]->Fill(keystrip);
1214 
1215  nValidCLCTs++;
1216  nValidCLCTsPerCSC++;
1217 
1218  if (debug)
1219  LogTrace("CSCTriggerPrimitivesReader")
1220  << (*digiIt) << " found in ME" << ((id.endcap() == 1) ? "+" : "-") << id.station() << "/" << id.ring()
1221  << "/" << id.chamber() << " (sector " << id.triggerSector() << " trig id. " << id.triggerCscId() << ")";
1222  }
1223  }
1224  hClctPerChamber->Fill(nValidCLCTsPerCSC);
1225  }
1226  hClctPerEvent->Fill(nValidCLCTs);
1227  if (debug)
1228  LogTrace("CSCTriggerPrimitivesReader") << nValidCLCTs << " valid CLCTs found in this event";
1229  numCLCT += nValidCLCTs;
1230 }

References funct::abs(), badChambers_, bookCLCTHistos(), bookedCLCTHistos, relativeConstraints::chamber, checkBadChambers_, debug, getCSCType(), hClctBendCsc, hClctBXN, hClctCFEB, hClctCsc, hClctKeyStrip, hClctKeyStripCsc, hClctKeyStripME11, hClctPattern, hClctPerChamber, hClctPerCSC, hClctPerEvent, hClctQuality, hClctSign, hClctStripType, hClctValid, CSCBadChambers::isInBadChamber(), LogTrace, numCLCT, topSingleLeptonDQM_PU_cfi::pattern, ptype_TMB07, and FastTimerService_cff::range.

Referenced by analyze().

◆ fillLCTMPCHistos()

void CSCTriggerPrimitivesReader::fillLCTMPCHistos ( const CSCCorrelatedLCTDigiCollection lcts)
private

Definition at line 1304 of file CSCTriggerPrimitivesReader.cc.

1304  {
1305  // Book histos when called for the first time.
1306  if (!bookedLCTMPCHistos)
1307  bookLCTMPCHistos();
1308 
1309  int nValidLCTs = 0;
1310  bool alct_valid, clct_valid;
1311 
1312  for (auto detUnitIt = lcts->begin(); detUnitIt != lcts->end(); detUnitIt++) {
1313  const CSCDetId& id = (*detUnitIt).first;
1315  continue;
1316  const auto& range = (*detUnitIt).second;
1317  for (auto digiIt = range.first; digiIt != range.second; digiIt++) {
1318  bool lct_valid = (*digiIt).isValid();
1319  hLctMPCValid->Fill(lct_valid);
1320  if (lct_valid) {
1321  hLctMPCEndcap->Fill(id.endcap());
1322  hLctMPCStation->Fill(id.station());
1323  hLctMPCSector->Fill(id.triggerSector());
1324  hLctMPCRing->Fill(id.ring());
1325  hLctMPCChamber[id.station() - 1]->Fill(id.triggerCscId());
1326 
1327  int quality = (*digiIt).getQuality();
1328  hLctMPCQuality->Fill(quality);
1329  hLctMPCBXN->Fill((*digiIt).getBX());
1330 
1331  alct_valid = (quality != 0 && quality != 2);
1332  if (alct_valid) {
1333  hLctMPCKeyGroup->Fill((*digiIt).getKeyWG());
1334  }
1335 
1336  clct_valid = (quality != 0 && quality != 1);
1337  if (clct_valid) {
1338  hLctMPCKeyStrip->Fill((*digiIt).getStrip());
1339  hLctMPCStripType->Fill(1.);
1340  hLctMPCPattern->Fill((*digiIt).getPattern());
1341  hLctMPCBend->Fill((*digiIt).getBend());
1342  }
1343 
1344  int csctype = getCSCType(id);
1345  hLctMPCPerCSC->Fill(csctype);
1346  // Truly correlated LCTs; for DAQ
1347  if (alct_valid && clct_valid)
1348  hCorrLctMPCPerCSC->Fill(csctype);
1349 
1350  if (alct_valid && csctype == 0) {
1351  hLctMPCKeyGroupME11->Fill((*digiIt).getKeyWG());
1352  }
1353  if (clct_valid && csctype == 0) {
1354  hLctMPCKeyStripME11->Fill((*digiIt).getStrip());
1355  }
1356 
1357  nValidLCTs++;
1358 
1359  if (debug)
1360  LogTrace("CSCTriggerPrimitivesReader")
1361  << "MPC " << (*digiIt) << " found in ME" << ((id.endcap() == 1) ? "+" : "-") << id.station() << "/"
1362  << id.ring() << "/" << id.chamber() << " (sector " << id.triggerSector() << " trig id. "
1363  << id.triggerCscId() << ")";
1364  }
1365  }
1366  }
1367  hLctMPCPerEvent->Fill(nValidLCTs);
1368  if (debug)
1369  LogTrace("CSCTriggerPrimitivesReader") << nValidLCTs << " MPC LCTs found in this event";
1370  numLCTMPC += nValidLCTs;
1371 }

References badChambers_, bookedLCTMPCHistos, bookLCTMPCHistos(), checkBadChambers_, debug, makeMuonMisalignmentScenario::endcap, getCSCType(), hCorrLctMPCPerCSC, hLctMPCBend, hLctMPCBXN, hLctMPCChamber, hLctMPCEndcap, hLctMPCKeyGroup, hLctMPCKeyGroupME11, hLctMPCKeyStrip, hLctMPCKeyStripME11, hLctMPCPattern, hLctMPCPerCSC, hLctMPCPerEvent, hLctMPCQuality, hLctMPCRing, hLctMPCSector, hLctMPCStation, hLctMPCStripType, hLctMPCValid, CSCBadChambers::isInBadChamber(), LogTrace, numLCTMPC, qcdUeDQM_cfi::quality, FastTimerService_cff::range, relativeConstraints::ring, relativeConstraints::station, triggerCscId(), and triggerSector().

◆ fillLCTTMBHistos()

void CSCTriggerPrimitivesReader::fillLCTTMBHistos ( const CSCCorrelatedLCTDigiCollection lcts)
private

Definition at line 1232 of file CSCTriggerPrimitivesReader.cc.

1232  {
1233  // Book histos when called for the first time.
1234  if (!bookedLCTTMBHistos)
1235  bookLCTTMBHistos();
1236 
1237  int nValidLCTs = 0;
1238  bool alct_valid, clct_valid;
1239 
1240  for (auto detUnitIt = lcts->begin(); detUnitIt != lcts->end(); detUnitIt++) {
1241  int nValidLCTsPerCSC = 0;
1242  const CSCDetId& id = (*detUnitIt).first;
1244  continue;
1245  const auto& range = (*detUnitIt).second;
1246  for (auto digiIt = range.first; digiIt != range.second; digiIt++) {
1247  bool lct_valid = (*digiIt).isValid();
1248  hLctTMBValid->Fill(lct_valid);
1249  if (lct_valid) {
1250  hLctTMBEndcap->Fill(id.endcap());
1251  hLctTMBStation->Fill(id.station());
1252  hLctTMBSector->Fill(id.triggerSector());
1253  hLctTMBRing->Fill(id.ring());
1254  hLctTMBChamber[id.station() - 1]->Fill(id.triggerCscId());
1255 
1256  int quality = (*digiIt).getQuality();
1257  hLctTMBQuality->Fill(quality);
1258  hLctTMBBXN->Fill((*digiIt).getBX());
1259 
1260  alct_valid = (quality != 0 && quality != 2);
1261  if (alct_valid) {
1262  hLctTMBKeyGroup->Fill((*digiIt).getKeyWG());
1263  }
1264 
1265  clct_valid = (quality != 0 && quality != 1);
1266  if (clct_valid) {
1267  hLctTMBKeyStrip->Fill((*digiIt).getStrip());
1268  hLctTMBStripType->Fill(1.);
1269  hLctTMBPattern->Fill((*digiIt).getPattern());
1270  hLctTMBBend->Fill((*digiIt).getBend());
1271  }
1272 
1273  int csctype = getCSCType(id);
1274  hLctTMBPerCSC->Fill(csctype);
1275  hLctTMBCsc[id.endcap() - 1][csctype]->Fill(id.chamber());
1276  // Truly correlated LCTs; for DAQ
1277  if (alct_valid && clct_valid)
1278  hCorrLctTMBPerCSC->Fill(csctype);
1279 
1280  if (alct_valid && csctype == 0) {
1281  hLctTMBKeyGroupME11->Fill((*digiIt).getKeyWG());
1282  }
1283  if (clct_valid && csctype == 0) {
1284  hLctTMBKeyStripME11->Fill((*digiIt).getStrip());
1285  }
1286 
1287  nValidLCTs++;
1288  nValidLCTsPerCSC++;
1289 
1290  if (debug)
1291  LogTrace("CSCTriggerPrimitivesReader")
1292  << (*digiIt) << " found in ME" << ((id.endcap() == 1) ? "+" : "-") << id.station() << "/" << id.ring()
1293  << "/" << id.chamber() << " (sector " << id.triggerSector() << " trig id. " << id.triggerCscId() << ")";
1294  }
1295  }
1296  hLctTMBPerChamber->Fill(nValidLCTsPerCSC);
1297  }
1298  hLctTMBPerEvent->Fill(nValidLCTs);
1299  if (debug)
1300  LogTrace("CSCTriggerPrimitivesReader") << nValidLCTs << " valid LCTs found in this event";
1301  numLCTTMB += nValidLCTs;
1302 }

References badChambers_, bookedLCTTMBHistos, bookLCTTMBHistos(), relativeConstraints::chamber, checkBadChambers_, debug, makeMuonMisalignmentScenario::endcap, getCSCType(), hCorrLctTMBPerCSC, hLctTMBBend, hLctTMBBXN, hLctTMBChamber, hLctTMBCsc, hLctTMBEndcap, hLctTMBKeyGroup, hLctTMBKeyGroupME11, hLctTMBKeyStrip, hLctTMBKeyStripME11, hLctTMBPattern, hLctTMBPerChamber, hLctTMBPerCSC, hLctTMBPerEvent, hLctTMBQuality, hLctTMBRing, hLctTMBSector, hLctTMBStation, hLctTMBStripType, hLctTMBValid, CSCBadChambers::isInBadChamber(), LogTrace, numLCTTMB, qcdUeDQM_cfi::quality, FastTimerService_cff::range, relativeConstraints::ring, relativeConstraints::station, triggerCscId(), and triggerSector().

Referenced by analyze().

◆ getCSCType()

int CSCTriggerPrimitivesReader::getCSCType ( const CSCDetId id)
private

Definition at line 4689 of file CSCTriggerPrimitivesReader.cc.

4689  {
4690  int type = -999;
4691 
4692  if (id.station() == 1) {
4693  type = (id.triggerCscId() - 1) / 3;
4694  if (id.ring() == 4) {
4695  type = 3;
4696  }
4697  } else { // stations 2-4
4698  type = 3 + id.ring() + 2 * (id.station() - 2);
4699  }
4700 
4701  assert(type >= 0 && type < CSC_TYPES);
4702  return type;
4703 }

References cms::cuda::assert(), CSC_TYPES, relativeConstraints::ring, and relativeConstraints::station.

Referenced by calcEfficiency(), calcResolution(), compareALCTs(), compareCLCTs(), compareLCTs(), fillALCTHistos(), fillCLCTHistos(), fillLCTMPCHistos(), and fillLCTTMBHistos().

◆ getGlobalPosition()

GlobalPoint CSCTriggerPrimitivesReader::getGlobalPosition ( unsigned int  rawId,
int  keWg,
int  keyHS 
) const
private

Definition at line 4634 of file CSCTriggerPrimitivesReader.cc.

4634  {
4635  // taken from https://github.com/cms-sw/cmssw/blob/dc9f78b6af4ad56c9342cf14041b6485a60b0691/L1Trigger/CSCTriggerPrimitives/src/CSCTriggerPrimitivesReaderGEM.cc
4636  CSCDetId cscId = CSCDetId(rawId);
4637  int ring = cscId.ring();
4638  if (cscId.station() == 1 and cscId.ring() == 1 and (lut_wg_vs_hs_me1b[keyWg][0] < 0 || keyHS >= 128)) {
4639  ring = 4;
4640  if (keyHS >= 128)
4641  keyHS = keyHS - 128;
4642  }
4643 
4644  CSCDetId key_id(cscId.endcap(), cscId.station(), ring, cscId.chamber(), CSCConstants::KEY_CLCT_LAYER);
4645  auto cscChamber = geom_->chamber(cscId);
4646  float fractional_strip = 0.5 * (keyHS + 1) - 0.25;
4647  auto layer_geo = cscChamber->layer(CSCConstants::KEY_CLCT_LAYER)->geometry();
4648  // LCT::getKeyWG() also starts from 0
4649  float wire = layer_geo->middleWireOfGroup(keyWg + 1);
4650  LocalPoint csc_intersect = layer_geo->intersectionOfStripAndWire(fractional_strip, wire);
4651  GlobalPoint csc_gp = geom_->idToDet(key_id)->surface().toGlobal(csc_intersect);
4652  return csc_gp;
4653 }

References CSCDetId::chamber(), CSCGeometry::chamber(), CSCDetId::endcap(), geom_, CSCLayer::geometry(), CSCGeometry::idToDet(), CSCConstants::KEY_CLCT_LAYER, CSCChamber::layer(), lut_wg_vs_hs_me1b, CSCLayerGeometry::middleWireOfGroup(), CSCDetId::ring(), relativeConstraints::ring, CSCDetId::station(), GeomDet::surface(), and Surface::toGlobal().

Referenced by compareALCTs(), compareCLCTs(), compareLCTs(), and compareMPCLCTs().

◆ getHsPerRad()

double CSCTriggerPrimitivesReader::getHsPerRad ( const int  idh)
private

Definition at line 4706 of file CSCTriggerPrimitivesReader.cc.

4706 { return (NCHAMBERS[idh] * MAX_HS[idh] / TWOPI); }

References MAX_HS, NCHAMBERS, and TWOPI.

Referenced by calcResolution().

◆ HotWires()

void CSCTriggerPrimitivesReader::HotWires ( const edm::Event iEvent)

Definition at line 2595 of file CSCTriggerPrimitivesReader.cc.

2595  {
2596  if (!bookedHotWireHistos)
2599  // iEvent.getByLabel(wireDigiProducer_.label(), wireDigiProducer_.instance(), wires);
2600  iEvent.getByToken(wireDigi_token_, wires);
2601 
2602  int serial_old = -1;
2603  for (auto dWDiter = wires->begin(); dWDiter != wires->end(); dWDiter++) {
2604  CSCDetId id = (CSCDetId)(*dWDiter).first;
2605  int serial = chamberSerial(id) - 1;
2606  // printf("serial %i\n",serial);
2607  std::vector<CSCWireDigi>::const_iterator wireIter = (*dWDiter).second.first;
2608  std::vector<CSCWireDigi>::const_iterator lWire = (*dWDiter).second.second;
2609  bool has_layer = false;
2610  for (; wireIter != lWire; ++wireIter) {
2611  has_layer = true;
2612  int i_layer = id.layer() - 1;
2613  int i_wire = wireIter->getWireGroup() - 1;
2614  int nbins = wireIter->getTimeBinsOn().size();
2615  int serial2 = serial * (6 * 112) + i_layer * 112 + i_wire;
2616  /*
2617  printf("endcap %i, station %i, ring %i, chamber %i, serial %i, serial2 %i, layer %i, wg %i\n",
2618  id.endcap(), id.station(), id.ring(), id.chamber(), serial, serial2, i_layer, i_wire);
2619  */
2620  hHotWire1->Fill(serial2, nbins);
2621  /*
2622  if(id.station()==1) {
2623  printf("ring %i, chamber type %i, wg %i\n",id.ring(),id.iChamberType(),i_wire);
2624  }
2625  */
2626  }
2627  if (serial_old != serial && has_layer) {
2628  // nHotCham[serial]++;
2629  hHotCham1->Fill(serial);
2630  // printf("serial %i filled\n",serial);
2631  serial_old = serial;
2632  }
2633  }
2634 }

References bookedHotWireHistos, bookHotWireHistos(), chamberSerial(), hHotCham1, hHotWire1, iEvent, LaserClient_cfi::nbins, wireDigi_token_, and DigiDM_cff::wires.

Referenced by analyze().

◆ maxRing()

int CSCTriggerPrimitivesReader::maxRing ( int  station)
private

Definition at line 353 of file CSCTriggerPrimitivesReader.cc.

353  {
354  if (station == 1) {
355  if (plotME1A)
356  return 4;
357  else
358  return 3;
359  }
360  return 2;
361 }

References plotME1A, and relativeConstraints::station.

Referenced by compareALCTs(), compareCLCTs(), compareLCTs(), and compareMPCLCTs().

◆ MCStudies()

void CSCTriggerPrimitivesReader::MCStudies ( const edm::Event ev,
const CSCALCTDigiCollection alcts,
const CSCCLCTDigiCollection clcts 
)
private

Definition at line 2636 of file CSCTriggerPrimitivesReader.cc.

2638  {
2639  // MC particles, if any.
2640  //edm::Handle<edm::HepMCProduct> mcp;
2641  //ev.getByLabel("source", mcp);
2642  //ev.getByType(mcp);
2643  vector<edm::Handle<edm::HepMCProduct> > allhepmcp;
2644  // Use "getManyByType" to be able to check the existence of MC info.
2645  ev.getManyByType(allhepmcp);
2646 
2647  //cout << "HepMC info: " << allhepmcp.size() << endl;
2648  if (!allhepmcp.empty()) {
2649  const HepMC::GenEvent& mc = allhepmcp[0]->getHepMCData();
2650  int i = 0;
2651  for (HepMC::GenEvent::particle_const_iterator p = mc.particles_begin(); p != mc.particles_end(); ++p) {
2652  int id = (*p)->pdg_id();
2653  double phitmp = (*p)->momentum().phi();
2654  if (phitmp < 0)
2655  phitmp += 2. * M_PI;
2656  if (debug)
2657  LogDebug("CSCTriggerPrimitivesReader")
2658  << "MC part #" << ++i << ": id = " << id << ", status = " << (*p)->status()
2659  << "\n pX = " << (*p)->momentum().x() << ", pY = " << (*p)->momentum().y()
2660  << ", pT = " << (*p)->momentum().perp() << " GeV"
2661  << ", p = " << (*p)->momentum().rho() << " GeV"
2662  << "\n eta = " << (*p)->momentum().pseudoRapidity() << ", phi = " << phitmp << " ("
2663  << phitmp * 180. / M_PI << " deg)";
2664  }
2665 
2666  // If hepMC info is there, try to get wire and comparator digis,
2667  // and SimHits.
2671  // ev.getByLabel(wireDigiProducer_.label(), wireDigiProducer_.instance(),
2672  // wireDigis);
2673  // ev.getByLabel(compDigiProducer_.label(), compDigiProducer_.instance(),
2674  // compDigis);
2675  // ev.getByLabel(simHitProducer_.label(), simHitProducer_.instance(),
2676  // simHits);
2677  ev.getByToken(wireDigi_token_, wireDigis);
2678  ev.getByToken(compDigi_token_, compDigis);
2679  ev.getByToken(simHit_token_, simHitsH);
2680  const edm::PSimHitContainer& simHits = *simHitsH.product();
2681 
2682  if (!wireDigis.isValid()) {
2683  edm::LogWarning("L1CSCTPEmulatorWrongInput")
2684  << "+++ Warning: Collection of wire digis with label" << wireDigiProducer_.label()
2685  << " requested, but not found in the event... Skipping the rest +++\n";
2686  return;
2687  }
2688  if (!compDigis.isValid()) {
2689  edm::LogWarning("L1CSCTPEmulatorWrongInput")
2690  << "+++ Warning: Collection of comparator digis with label" << compDigiProducer_.label()
2691  << " requested, but not found in the event... Skipping the rest +++\n";
2692  return;
2693  }
2694  if (!simHitsH.isValid()) {
2695  edm::LogWarning("L1CSCTPEmulatorWrongInput")
2696  << "+++ Warning: Collection of SimHits with label" << simHitProducer_.label()
2697  << " requested, but not found in the event... Skipping the rest +++\n";
2698  return;
2699  }
2700 
2701  if (debug)
2702  LogTrace("CSCTriggerPrimitivesReader") << " #CSC SimHits: " << simHits.size();
2703 
2704  // MC-based resolution studies.
2705  calcResolution(alcts, clcts, wireDigis.product(), compDigis.product(), simHits);
2706 
2707  // MC-based efficiency studies.
2708  calcEfficiency(alcts, clcts, simHits);
2709  }
2710 }

References calcEfficiency(), calcResolution(), compDigi_token_, compDigiProducer_, debug, ev, mps_fire::i, edm::HandleBase::isValid(), edm::InputTag::label(), LogDebug, LogTrace, M_PI, CaloTowersParam_cfi::mc, AlCaHLTBitMon_ParallelJobs::p, edm::Handle< T >::product(), simHit_token_, simHitProducer_, FastTrackerRecHitCombiner_cfi::simHits, wireDigi_token_, and wireDigiProducer_.

Referenced by analyze().

◆ setRootStyle()

void CSCTriggerPrimitivesReader::setRootStyle ( )
private

Definition at line 598 of file CSCTriggerPrimitivesReader.cc.

598  {
599  TH1::AddDirectory(false);
600 
601  gROOT->SetStyle("Plain");
602  gStyle->SetFillColor(0);
603  gStyle->SetOptDate();
604  gStyle->SetOptStat(111110);
605  gStyle->SetOptFit(1111);
606  gStyle->SetPadTickX(1);
607  gStyle->SetPadTickY(1);
608  gStyle->SetMarkerSize(0.5);
609  gStyle->SetMarkerStyle(8);
610  gStyle->SetGridStyle(3);
611  gStyle->SetPaperSize(TStyle::kA4);
612  gStyle->SetStatW(0.25); // width of statistics box; default is 0.19
613  gStyle->SetStatH(0.10); // height of statistics box; default is 0.1
614  gStyle->SetStatFormat("6.4g"); // leave default format for now
615  gStyle->SetTitleSize(0.055, ""); // size for pad title; default is 0.02
616  // Really big; useful for talks.
617  //gStyle->SetTitleSize(0.1, ""); // size for pad title; default is 0.02
618  gStyle->SetLabelSize(0.05, "XYZ"); // size for axis labels; default is 0.04
619  gStyle->SetStatFontSize(0.06); // size for stat. box
620  gStyle->SetTitleFont(32, "XYZ"); // times-bold-italic font (p. 153) for axes
621  gStyle->SetTitleFont(32, ""); // same for pad title
622  gStyle->SetLabelFont(32, "XYZ"); // same for axis labels
623  gStyle->SetStatFont(32); // same for stat. box
624  gStyle->SetLabelOffset(0.006, "Y"); // default is 0.005
625 }

Referenced by CSCTriggerPrimitivesReader().

Member Data Documentation

◆ alcts_d_token_

edm::EDGetTokenT<CSCALCTDigiCollection> CSCTriggerPrimitivesReader::alcts_d_token_
private

Definition at line 183 of file CSCTriggerPrimitivesReader.h.

Referenced by analyze(), and CSCTriggerPrimitivesReader().

◆ alcts_e_token_

edm::EDGetTokenT<CSCALCTDigiCollection> CSCTriggerPrimitivesReader::alcts_e_token_
private

Definition at line 187 of file CSCTriggerPrimitivesReader.h.

Referenced by analyze(), and CSCTriggerPrimitivesReader().

◆ badChambers_

const CSCBadChambers* CSCTriggerPrimitivesReader::badChambers_
private

◆ bookedALCTHistos

bool CSCTriggerPrimitivesReader::bookedALCTHistos = false
staticprivate

Definition at line 230 of file CSCTriggerPrimitivesReader.h.

Referenced by bookALCTHistos(), endJob(), and fillALCTHistos().

◆ bookedCLCTHistos

bool CSCTriggerPrimitivesReader::bookedCLCTHistos = false
staticprivate

Definition at line 231 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCLCTHistos(), endJob(), and fillCLCTHistos().

◆ bookedCompHistos

bool CSCTriggerPrimitivesReader::bookedCompHistos = false
staticprivate

Definition at line 235 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), compare(), and endJob().

◆ bookedEfficHistos

bool CSCTriggerPrimitivesReader::bookedEfficHistos = false
staticprivate

◆ bookedHotWireHistos

bool CSCTriggerPrimitivesReader::bookedHotWireHistos = false
staticprivate

Definition at line 229 of file CSCTriggerPrimitivesReader.h.

Referenced by bookHotWireHistos(), and HotWires().

◆ bookedLCTMPCHistos

bool CSCTriggerPrimitivesReader::bookedLCTMPCHistos = false
staticprivate

Definition at line 233 of file CSCTriggerPrimitivesReader.h.

Referenced by bookLCTMPCHistos(), and fillLCTMPCHistos().

◆ bookedLCTTMBHistos

bool CSCTriggerPrimitivesReader::bookedLCTTMBHistos = false
staticprivate

Definition at line 232 of file CSCTriggerPrimitivesReader.h.

Referenced by bookLCTTMBHistos(), endJob(), and fillLCTTMBHistos().

◆ bookedResolHistos

bool CSCTriggerPrimitivesReader::bookedResolHistos = false
staticprivate

◆ checkBadChambers_

bool CSCTriggerPrimitivesReader::checkBadChambers_
private

◆ clcts_d_token_

edm::EDGetTokenT<CSCCLCTDigiCollection> CSCTriggerPrimitivesReader::clcts_d_token_
private

Definition at line 184 of file CSCTriggerPrimitivesReader.h.

Referenced by analyze(), and CSCTriggerPrimitivesReader().

◆ clcts_e_token_

edm::EDGetTokenT<CSCCLCTDigiCollection> CSCTriggerPrimitivesReader::clcts_e_token_
private

Definition at line 188 of file CSCTriggerPrimitivesReader.h.

Referenced by analyze(), and CSCTriggerPrimitivesReader().

◆ compDigi_token_

edm::EDGetTokenT<CSCComparatorDigiCollection> CSCTriggerPrimitivesReader::compDigi_token_
private

Definition at line 181 of file CSCTriggerPrimitivesReader.h.

Referenced by CSCTriggerPrimitivesReader(), and MCStudies().

◆ compDigiProducer_

edm::InputTag CSCTriggerPrimitivesReader::compDigiProducer_
private

Definition at line 177 of file CSCTriggerPrimitivesReader.h.

Referenced by CSCTriggerPrimitivesReader(), and MCStudies().

◆ csc_type

const string CSCTriggerPrimitivesReader::csc_type
staticprivate
Initial value:
= {
"ME1/1", "ME1/2", "ME1/3", "ME1/A", "ME2/1", "ME2/2", "ME3/1", "ME3/2", "ME4/1", "ME4/2"}

Definition at line 212 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCLCTHistos(), bookEfficHistos(), bookResolHistos(), drawALCTHistos(), drawCLCTHistos(), drawEfficHistos(), drawHistosForTalks(), drawLCTMPCHistos(), drawLCTTMBHistos(), and endJob().

◆ csc_type_minus

const string CSCTriggerPrimitivesReader::csc_type_minus
staticprivate
Initial value:
= {
"ME-1/1", "ME-1/2", "ME-1/3", "ME-1/A", "ME-2/1", "ME-2/2", "ME-3/1", "ME-3/2", "ME-4/1", "ME-4/2"}

Definition at line 214 of file CSCTriggerPrimitivesReader.h.

Referenced by bookALCTHistos(), bookCLCTHistos(), bookCompHistos(), and bookLCTTMBHistos().

◆ csc_type_plus

const string CSCTriggerPrimitivesReader::csc_type_plus
staticprivate
Initial value:
= {
"ME+1/1", "ME+1/2", "ME+1/3", "ME+1/A", "ME+2/1", "ME+2/2", "ME+3/1", "ME+3/2", "ME+4/1", "ME+4/2"}

Definition at line 213 of file CSCTriggerPrimitivesReader.h.

Referenced by bookALCTHistos(), bookCLCTHistos(), bookCompHistos(), and bookLCTTMBHistos().

◆ cscGeomToken_

edm::ESGetToken<CSCGeometry, MuonGeometryRecord> CSCTriggerPrimitivesReader::cscGeomToken_
private

Definition at line 192 of file CSCTriggerPrimitivesReader.h.

Referenced by analyze(), and CSCTriggerPrimitivesReader().

◆ dataIsAnotherMC_

bool CSCTriggerPrimitivesReader::dataIsAnotherMC_
private

◆ dataLctsIn_

bool CSCTriggerPrimitivesReader::dataLctsIn_
private

Definition at line 160 of file CSCTriggerPrimitivesReader.h.

Referenced by analyze(), and CSCTriggerPrimitivesReader().

◆ debug

bool CSCTriggerPrimitivesReader::debug
private

◆ emulLctsIn_

bool CSCTriggerPrimitivesReader::emulLctsIn_
private

Definition at line 161 of file CSCTriggerPrimitivesReader.h.

Referenced by analyze(), and CSCTriggerPrimitivesReader().

◆ Event_

int CSCTriggerPrimitivesReader::Event_
private

◆ event_tree

TTree* CSCTriggerPrimitivesReader::event_tree[6]
private

◆ eventsAnalyzed

int CSCTriggerPrimitivesReader::eventsAnalyzed
private

◆ gangedME1a

bool CSCTriggerPrimitivesReader::gangedME1a
private

Definition at line 163 of file CSCTriggerPrimitivesReader.h.

Referenced by CSCTriggerPrimitivesReader(), and doesALCTCrossCLCT().

◆ geom_

const CSCGeometry* CSCTriggerPrimitivesReader::geom_
private

◆ hAlctAccel

TH1F * CSCTriggerPrimitivesReader::hAlctAccel
private

Definition at line 325 of file CSCTriggerPrimitivesReader.h.

Referenced by bookALCTHistos(), drawALCTHistos(), and fillALCTHistos().

◆ hAlctBXN

TH1F* CSCTriggerPrimitivesReader::hAlctBXN
private

Definition at line 326 of file CSCTriggerPrimitivesReader.h.

Referenced by bookALCTHistos(), drawALCTHistos(), and fillALCTHistos().

◆ hAlctCollis

TH1F * CSCTriggerPrimitivesReader::hAlctCollis
private

Definition at line 325 of file CSCTriggerPrimitivesReader.h.

Referenced by bookALCTHistos(), drawALCTHistos(), and fillALCTHistos().

◆ hAlctCompFound

TH1F* CSCTriggerPrimitivesReader::hAlctCompFound
private

Definition at line 352 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), and compareALCTs().

◆ hAlctCompFound2

TH2F* CSCTriggerPrimitivesReader::hAlctCompFound2
private

Definition at line 353 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), and compareALCTs().

◆ hAlctCompFound2i

TH2F* CSCTriggerPrimitivesReader::hAlctCompFound2i
private

Definition at line 355 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), and compareALCTs().

◆ hAlctCompFound2x

TH2F* CSCTriggerPrimitivesReader::hAlctCompFound2x
private

Definition at line 354 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), and compareALCTs().

◆ hAlctCompFoundCsc

TH1F* CSCTriggerPrimitivesReader::hAlctCompFoundCsc[MAX_ENDCAPS][CSC_TYPES]
private

Definition at line 413 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), compareALCTs(), and drawCompHistos().

◆ hAlctCompMatch

TH1F* CSCTriggerPrimitivesReader::hAlctCompMatch
private

Definition at line 362 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), and compareALCTs().

◆ hAlctCompMatch2

TH2F* CSCTriggerPrimitivesReader::hAlctCompMatch2
private

Definition at line 363 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), and compareALCTs().

◆ hAlctCompMatch2i

TH2F* CSCTriggerPrimitivesReader::hAlctCompMatch2i
private

Definition at line 365 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), and compareALCTs().

◆ hAlctCompMatch2x

TH2F* CSCTriggerPrimitivesReader::hAlctCompMatch2x
private

Definition at line 364 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), and compareALCTs().

◆ hAlctCompMatchCsc

TH1F* CSCTriggerPrimitivesReader::hAlctCompMatchCsc[MAX_ENDCAPS][CSC_TYPES]
private

Definition at line 416 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), compareALCTs(), and drawCompHistos().

◆ hAlctCompSameN

TH1F* CSCTriggerPrimitivesReader::hAlctCompSameN
private

Definition at line 357 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos().

◆ hAlctCompSameN2

TH2F* CSCTriggerPrimitivesReader::hAlctCompSameN2
private

Definition at line 358 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), and compareALCTs().

◆ hAlctCompSameN2i

TH2F* CSCTriggerPrimitivesReader::hAlctCompSameN2i
private

Definition at line 360 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), and compareALCTs().

◆ hAlctCompSameN2x

TH2F* CSCTriggerPrimitivesReader::hAlctCompSameN2x
private

Definition at line 359 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), and compareALCTs().

◆ hAlctCompSameNCsc

TH1F* CSCTriggerPrimitivesReader::hAlctCompSameNCsc[MAX_ENDCAPS][CSC_TYPES]
private

Definition at line 414 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), compareALCTs(), and drawCompHistos().

◆ hAlctCompTotal

TH1F* CSCTriggerPrimitivesReader::hAlctCompTotal
private

Definition at line 367 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), and compareALCTs().

◆ hAlctCompTotal2

TH2F* CSCTriggerPrimitivesReader::hAlctCompTotal2
private

Definition at line 368 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), and compareALCTs().

◆ hAlctCompTotal2i

TH2F* CSCTriggerPrimitivesReader::hAlctCompTotal2i
private

Definition at line 370 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), and compareALCTs().

◆ hAlctCompTotal2x

TH2F* CSCTriggerPrimitivesReader::hAlctCompTotal2x
private

Definition at line 369 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), and compareALCTs().

◆ hAlctCompTotalCsc

TH1F* CSCTriggerPrimitivesReader::hAlctCompTotalCsc[MAX_ENDCAPS][CSC_TYPES]
private

Definition at line 415 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), compareALCTs(), and drawCompHistos().

◆ hAlctCsc

TH1F* CSCTriggerPrimitivesReader::hAlctCsc[MAX_ENDCAPS][CSC_TYPES]
private

Definition at line 324 of file CSCTriggerPrimitivesReader.h.

Referenced by bookALCTHistos(), drawALCTHistos(), and fillALCTHistos().

◆ hAlctKeyGroup

TH1F * CSCTriggerPrimitivesReader::hAlctKeyGroup
private

Definition at line 325 of file CSCTriggerPrimitivesReader.h.

Referenced by bookALCTHistos(), drawALCTHistos(), and fillALCTHistos().

◆ hAlctKeyGroupME11

TH1F* CSCTriggerPrimitivesReader::hAlctKeyGroupME11
private

Definition at line 452 of file CSCTriggerPrimitivesReader.h.

Referenced by bookALCTHistos(), and fillALCTHistos().

◆ hAlctPerChamber

TH1F * CSCTriggerPrimitivesReader::hAlctPerChamber
private

Definition at line 323 of file CSCTriggerPrimitivesReader.h.

Referenced by bookALCTHistos(), drawALCTHistos(), and fillALCTHistos().

◆ hAlctPerCSC

TH1F * CSCTriggerPrimitivesReader::hAlctPerCSC
private

Definition at line 323 of file CSCTriggerPrimitivesReader.h.

Referenced by bookALCTHistos(), drawALCTHistos(), and fillALCTHistos().

◆ hAlctPerEvent

TH1F* CSCTriggerPrimitivesReader::hAlctPerEvent
private

Definition at line 323 of file CSCTriggerPrimitivesReader.h.

Referenced by bookALCTHistos(), drawALCTHistos(), and fillALCTHistos().

◆ hAlctQuality

TH1F * CSCTriggerPrimitivesReader::hAlctQuality
private

Definition at line 325 of file CSCTriggerPrimitivesReader.h.

Referenced by bookALCTHistos(), drawALCTHistos(), and fillALCTHistos().

◆ hAlctValid

TH1F* CSCTriggerPrimitivesReader::hAlctValid
private

Definition at line 325 of file CSCTriggerPrimitivesReader.h.

Referenced by bookALCTHistos(), drawALCTHistos(), and fillALCTHistos().

◆ hAlctVsEta

TH1F* CSCTriggerPrimitivesReader::hAlctVsEta[MAX_STATIONS]
private

Definition at line 432 of file CSCTriggerPrimitivesReader.h.

Referenced by bookResolHistos(), calcResolution(), and drawResolHistos().

◆ hClctBendCsc

TH1F* CSCTriggerPrimitivesReader::hClctBendCsc[CSC_TYPES][2]
private

Definition at line 333 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCLCTHistos(), drawCLCTHistos(), and fillCLCTHistos().

◆ hClctBXN

TH1F* CSCTriggerPrimitivesReader::hClctBXN
private

Definition at line 331 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCLCTHistos(), drawCLCTHistos(), and fillCLCTHistos().

◆ hClctCFEB

TH1F * CSCTriggerPrimitivesReader::hClctCFEB
private

◆ hClctCompFound

TH1F* CSCTriggerPrimitivesReader::hClctCompFound
private

Definition at line 372 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos().

◆ hClctCompFound2

TH2F* CSCTriggerPrimitivesReader::hClctCompFound2
private

Definition at line 373 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), and compareCLCTs().

◆ hClctCompFound2i

TH2F* CSCTriggerPrimitivesReader::hClctCompFound2i
private

Definition at line 375 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), and compareCLCTs().

◆ hClctCompFound2x

TH2F* CSCTriggerPrimitivesReader::hClctCompFound2x
private

Definition at line 374 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), and compareCLCTs().

◆ hClctCompFoundCsc

TH1F* CSCTriggerPrimitivesReader::hClctCompFoundCsc[MAX_ENDCAPS][CSC_TYPES]
private

Definition at line 418 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), compareCLCTs(), and drawCompHistos().

◆ hClctCompMatch

TH1F* CSCTriggerPrimitivesReader::hClctCompMatch
private

Definition at line 381 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos().

◆ hClctCompMatch2

TH2F* CSCTriggerPrimitivesReader::hClctCompMatch2
private

Definition at line 382 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), and compareCLCTs().

◆ hClctCompMatch2i

TH2F* CSCTriggerPrimitivesReader::hClctCompMatch2i
private

Definition at line 384 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), and compareCLCTs().

◆ hClctCompMatch2x

TH2F* CSCTriggerPrimitivesReader::hClctCompMatch2x
private

Definition at line 383 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), and compareCLCTs().

◆ hClctCompMatchCsc

TH1F* CSCTriggerPrimitivesReader::hClctCompMatchCsc[MAX_ENDCAPS][CSC_TYPES]
private

Definition at line 421 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), compareCLCTs(), and drawCompHistos().

◆ hClctCompSameN

TH1F* CSCTriggerPrimitivesReader::hClctCompSameN
private

Definition at line 376 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos().

◆ hClctCompSameN2

TH2F* CSCTriggerPrimitivesReader::hClctCompSameN2
private

Definition at line 377 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), and compareCLCTs().

◆ hClctCompSameN2i

TH2F* CSCTriggerPrimitivesReader::hClctCompSameN2i
private

Definition at line 379 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), and compareCLCTs().

◆ hClctCompSameN2x

TH2F* CSCTriggerPrimitivesReader::hClctCompSameN2x
private

Definition at line 378 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), and compareCLCTs().

◆ hClctCompSameNCsc

TH1F* CSCTriggerPrimitivesReader::hClctCompSameNCsc[MAX_ENDCAPS][CSC_TYPES]
private

Definition at line 419 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), compareCLCTs(), and drawCompHistos().

◆ hClctCompTotal

TH1F* CSCTriggerPrimitivesReader::hClctCompTotal
private

Definition at line 386 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos().

◆ hClctCompTotal2

TH2F* CSCTriggerPrimitivesReader::hClctCompTotal2
private

Definition at line 387 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), and compareCLCTs().

◆ hClctCompTotal2i

TH2F* CSCTriggerPrimitivesReader::hClctCompTotal2i
private

Definition at line 389 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), and compareCLCTs().

◆ hClctCompTotal2x

TH2F* CSCTriggerPrimitivesReader::hClctCompTotal2x
private

Definition at line 388 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), and compareCLCTs().

◆ hClctCompTotalCsc

TH1F* CSCTriggerPrimitivesReader::hClctCompTotalCsc[MAX_ENDCAPS][CSC_TYPES]
private

Definition at line 420 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), compareCLCTs(), and drawCompHistos().

◆ hClctCsc

TH1F* CSCTriggerPrimitivesReader::hClctCsc[MAX_ENDCAPS][CSC_TYPES]
private

Definition at line 329 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCLCTHistos(), drawCLCTHistos(), and fillCLCTHistos().

◆ hClctKeyStrip

TH1F* CSCTriggerPrimitivesReader::hClctKeyStrip[2]
private

◆ hClctKeyStripCsc

TH1F * CSCTriggerPrimitivesReader::hClctKeyStripCsc[CSC_TYPES]
private

Definition at line 333 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCLCTHistos(), and fillCLCTHistos().

◆ hClctKeyStripME11

TH1F* CSCTriggerPrimitivesReader::hClctKeyStripME11
private

Definition at line 453 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCLCTHistos(), and fillCLCTHistos().

◆ hClctPattern

TH1F * CSCTriggerPrimitivesReader::hClctPattern[2]
private

◆ hClctPerChamber

TH1F * CSCTriggerPrimitivesReader::hClctPerChamber
private

Definition at line 328 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCLCTHistos(), drawCLCTHistos(), and fillCLCTHistos().

◆ hClctPerCSC

TH1F * CSCTriggerPrimitivesReader::hClctPerCSC
private

Definition at line 328 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCLCTHistos(), drawCLCTHistos(), and fillCLCTHistos().

◆ hClctPerEvent

TH1F* CSCTriggerPrimitivesReader::hClctPerEvent
private

Definition at line 328 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCLCTHistos(), drawCLCTHistos(), and fillCLCTHistos().

◆ hClctQuality

TH1F * CSCTriggerPrimitivesReader::hClctQuality
private

◆ hClctSign

TH1F * CSCTriggerPrimitivesReader::hClctSign
private

◆ hClctStripType

TH1F * CSCTriggerPrimitivesReader::hClctStripType
private

◆ hClctValid

TH1F* CSCTriggerPrimitivesReader::hClctValid
private

Definition at line 330 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCLCTHistos(), drawCLCTHistos(), and fillCLCTHistos().

◆ hClctVsPhi

TH1F* CSCTriggerPrimitivesReader::hClctVsPhi[MAX_STATIONS]
private

Definition at line 440 of file CSCTriggerPrimitivesReader.h.

Referenced by bookResolHistos(), calcResolution(), and drawResolHistos().

◆ hCorrLctMPCPerCSC

TH1F * CSCTriggerPrimitivesReader::hCorrLctMPCPerCSC
private

◆ hCorrLctTMBPerCSC

TH1F * CSCTriggerPrimitivesReader::hCorrLctTMBPerCSC
private

◆ hEfficALCTEta

TH1F* CSCTriggerPrimitivesReader::hEfficALCTEta[MAX_STATIONS]
private

Definition at line 448 of file CSCTriggerPrimitivesReader.h.

Referenced by bookEfficHistos(), calcEfficiency(), and drawEfficHistos().

◆ hEfficALCTEtaCsc

TH1F* CSCTriggerPrimitivesReader::hEfficALCTEtaCsc[CSC_TYPES]
private

◆ hEfficCLCTEta

TH1F * CSCTriggerPrimitivesReader::hEfficCLCTEta[MAX_STATIONS]
private

Definition at line 448 of file CSCTriggerPrimitivesReader.h.

Referenced by bookEfficHistos(), calcEfficiency(), and drawEfficHistos().

◆ hEfficCLCTEtaCsc

TH1F * CSCTriggerPrimitivesReader::hEfficCLCTEtaCsc[CSC_TYPES]
private

◆ hEfficHitsEta

TH1F* CSCTriggerPrimitivesReader::hEfficHitsEta[MAX_STATIONS]
private

Definition at line 447 of file CSCTriggerPrimitivesReader.h.

Referenced by bookEfficHistos(), calcEfficiency(), and drawEfficHistos().

◆ hEfficHitsEtaCsc

TH1F* CSCTriggerPrimitivesReader::hEfficHitsEtaCsc[CSC_TYPES]
private

◆ hEtaDiffCsc

TH1F* CSCTriggerPrimitivesReader::hEtaDiffCsc[CSC_TYPES][3]
private

Definition at line 434 of file CSCTriggerPrimitivesReader.h.

Referenced by bookResolHistos(), calcResolution(), and drawResolHistos().

◆ hEtaDiffVsEta

TH1F* CSCTriggerPrimitivesReader::hEtaDiffVsEta[MAX_STATIONS]
private

Definition at line 433 of file CSCTriggerPrimitivesReader.h.

Referenced by bookResolHistos(), calcResolution(), and drawResolHistos().

◆ hEtaDiffVsWireCsc

TH2F* CSCTriggerPrimitivesReader::hEtaDiffVsWireCsc[CSC_TYPES]
private

Definition at line 435 of file CSCTriggerPrimitivesReader.h.

Referenced by bookResolHistos(), calcResolution(), and drawResolHistos().

◆ hEtaRecVsSim

TH2F* CSCTriggerPrimitivesReader::hEtaRecVsSim
private

Definition at line 430 of file CSCTriggerPrimitivesReader.h.

Referenced by bookResolHistos(), calcResolution(), and drawResolHistos().

◆ hHotCham1

TH1F * CSCTriggerPrimitivesReader::hHotCham1
private

Definition at line 320 of file CSCTriggerPrimitivesReader.h.

Referenced by bookHotWireHistos(), and HotWires().

◆ hHotWire1

TH1F* CSCTriggerPrimitivesReader::hHotWire1
private

Definition at line 320 of file CSCTriggerPrimitivesReader.h.

Referenced by bookHotWireHistos(), and HotWires().

◆ hLCTCompFound

TH1F* CSCTriggerPrimitivesReader::hLCTCompFound
private

Definition at line 391 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos().

◆ hLCTCompFound2

TH2F* CSCTriggerPrimitivesReader::hLCTCompFound2
private

Definition at line 392 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), and compareLCTs().

◆ hLCTCompFound2i

TH2F* CSCTriggerPrimitivesReader::hLCTCompFound2i
private

Definition at line 394 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), and compareLCTs().

◆ hLCTCompFound2x

TH2F* CSCTriggerPrimitivesReader::hLCTCompFound2x
private

Definition at line 393 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), and compareLCTs().

◆ hLctCompFoundCsc

TH1F* CSCTriggerPrimitivesReader::hLctCompFoundCsc[MAX_ENDCAPS][CSC_TYPES]
private

Definition at line 423 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), compareLCTs(), and drawCompHistos().

◆ hLCTCompMatch

TH1F* CSCTriggerPrimitivesReader::hLCTCompMatch
private

Definition at line 401 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos().

◆ hLCTCompMatch2

TH2F* CSCTriggerPrimitivesReader::hLCTCompMatch2
private

Definition at line 402 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), and compareLCTs().

◆ hLCTCompMatch2i

TH2F* CSCTriggerPrimitivesReader::hLCTCompMatch2i
private

Definition at line 404 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), and compareLCTs().

◆ hLCTCompMatch2x

TH2F* CSCTriggerPrimitivesReader::hLCTCompMatch2x
private

Definition at line 403 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), and compareLCTs().

◆ hLctCompMatchCsc

TH1F* CSCTriggerPrimitivesReader::hLctCompMatchCsc[MAX_ENDCAPS][CSC_TYPES]
private

Definition at line 426 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), compareLCTs(), and drawCompHistos().

◆ hLCTCompSameN

TH1F* CSCTriggerPrimitivesReader::hLCTCompSameN
private

Definition at line 396 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos().

◆ hLCTCompSameN2

TH2F* CSCTriggerPrimitivesReader::hLCTCompSameN2
private

Definition at line 397 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), and compareLCTs().

◆ hLCTCompSameN2i

TH2F* CSCTriggerPrimitivesReader::hLCTCompSameN2i
private

Definition at line 399 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), and compareLCTs().

◆ hLCTCompSameN2x

TH2F* CSCTriggerPrimitivesReader::hLCTCompSameN2x
private

Definition at line 398 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), and compareLCTs().

◆ hLctCompSameNCsc

TH1F* CSCTriggerPrimitivesReader::hLctCompSameNCsc[MAX_ENDCAPS][CSC_TYPES]
private

Definition at line 424 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), compareLCTs(), and drawCompHistos().

◆ hLCTCompTotal

TH1F* CSCTriggerPrimitivesReader::hLCTCompTotal
private

Definition at line 406 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos().

◆ hLCTCompTotal2

TH2F* CSCTriggerPrimitivesReader::hLCTCompTotal2
private

Definition at line 407 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), and compareLCTs().

◆ hLCTCompTotal2i

TH2F* CSCTriggerPrimitivesReader::hLCTCompTotal2i
private

Definition at line 409 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), and compareLCTs().

◆ hLCTCompTotal2x

TH2F* CSCTriggerPrimitivesReader::hLCTCompTotal2x
private

Definition at line 408 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), and compareLCTs().

◆ hLctCompTotalCsc

TH1F* CSCTriggerPrimitivesReader::hLctCompTotalCsc[MAX_ENDCAPS][CSC_TYPES]
private

Definition at line 425 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCompHistos(), compareLCTs(), and drawCompHistos().

◆ hLctMPCBend

TH1F * CSCTriggerPrimitivesReader::hLctMPCBend
private

◆ hLctMPCBXN

TH1F * CSCTriggerPrimitivesReader::hLctMPCBXN
private

◆ hLctMPCChamber

TH1F* CSCTriggerPrimitivesReader::hLctMPCChamber[MAX_STATIONS]
private

◆ hLctMPCEndcap

TH1F* CSCTriggerPrimitivesReader::hLctMPCEndcap
private

◆ hLctMPCKeyGroup

TH1F * CSCTriggerPrimitivesReader::hLctMPCKeyGroup
private

◆ hLctMPCKeyGroupME11

TH1F* CSCTriggerPrimitivesReader::hLctMPCKeyGroupME11
private

Definition at line 456 of file CSCTriggerPrimitivesReader.h.

Referenced by bookLCTMPCHistos(), and fillLCTMPCHistos().

◆ hLctMPCKeyStrip

TH1F* CSCTriggerPrimitivesReader::hLctMPCKeyStrip
private

◆ hLctMPCKeyStripME11

TH1F* CSCTriggerPrimitivesReader::hLctMPCKeyStripME11
private

Definition at line 457 of file CSCTriggerPrimitivesReader.h.

Referenced by bookLCTMPCHistos(), and fillLCTMPCHistos().

◆ hLctMPCPattern

TH1F* CSCTriggerPrimitivesReader::hLctMPCPattern
private

◆ hLctMPCPerCSC

TH1F * CSCTriggerPrimitivesReader::hLctMPCPerCSC
private

◆ hLctMPCPerEvent

TH1F* CSCTriggerPrimitivesReader::hLctMPCPerEvent
private

◆ hLctMPCQuality

TH1F * CSCTriggerPrimitivesReader::hLctMPCQuality
private

◆ hLctMPCRing

TH1F * CSCTriggerPrimitivesReader::hLctMPCRing
private

◆ hLctMPCSector

TH1F * CSCTriggerPrimitivesReader::hLctMPCSector
private

◆ hLctMPCStation

TH1F * CSCTriggerPrimitivesReader::hLctMPCStation
private

◆ hLctMPCStripType

TH1F * CSCTriggerPrimitivesReader::hLctMPCStripType
private

◆ hLctMPCValid

TH1F* CSCTriggerPrimitivesReader::hLctMPCValid
private

◆ hLctTMBBend

TH1F * CSCTriggerPrimitivesReader::hLctTMBBend
private

◆ hLctTMBBXN

TH1F * CSCTriggerPrimitivesReader::hLctTMBBXN
private

◆ hLctTMBChamber

TH1F* CSCTriggerPrimitivesReader::hLctTMBChamber[MAX_STATIONS]
private

◆ hLctTMBCsc

TH1F * CSCTriggerPrimitivesReader::hLctTMBCsc[MAX_ENDCAPS][CSC_TYPES]
private

◆ hLctTMBEndcap

TH1F* CSCTriggerPrimitivesReader::hLctTMBEndcap
private

◆ hLctTMBKeyGroup

TH1F * CSCTriggerPrimitivesReader::hLctTMBKeyGroup
private

◆ hLctTMBKeyGroupME11

TH1F* CSCTriggerPrimitivesReader::hLctTMBKeyGroupME11
private

Definition at line 454 of file CSCTriggerPrimitivesReader.h.

Referenced by bookLCTTMBHistos(), and fillLCTTMBHistos().

◆ hLctTMBKeyStrip

TH1F* CSCTriggerPrimitivesReader::hLctTMBKeyStrip
private

◆ hLctTMBKeyStripME11

TH1F* CSCTriggerPrimitivesReader::hLctTMBKeyStripME11
private

Definition at line 455 of file CSCTriggerPrimitivesReader.h.

Referenced by bookLCTTMBHistos(), and fillLCTTMBHistos().

◆ hLctTMBPattern

TH1F* CSCTriggerPrimitivesReader::hLctTMBPattern
private

◆ hLctTMBPerChamber

TH1F * CSCTriggerPrimitivesReader::hLctTMBPerChamber
private

◆ hLctTMBPerCSC

TH1F* CSCTriggerPrimitivesReader::hLctTMBPerCSC
private

◆ hLctTMBPerEvent

TH1F* CSCTriggerPrimitivesReader::hLctTMBPerEvent
private

◆ hLctTMBQuality

TH1F * CSCTriggerPrimitivesReader::hLctTMBQuality
private

◆ hLctTMBRing

TH1F * CSCTriggerPrimitivesReader::hLctTMBRing
private

◆ hLctTMBSector

TH1F * CSCTriggerPrimitivesReader::hLctTMBSector
private

◆ hLctTMBStation

TH1F * CSCTriggerPrimitivesReader::hLctTMBStation
private

◆ hLctTMBStripType

TH1F * CSCTriggerPrimitivesReader::hLctTMBStripType
private

◆ hLctTMBValid

TH1F* CSCTriggerPrimitivesReader::hLctTMBValid
private

◆ hPhiDiffCsc

TH1F* CSCTriggerPrimitivesReader::hPhiDiffCsc[CSC_TYPES][5]
private

◆ hPhiDiffPattern

TH1F* CSCTriggerPrimitivesReader::hPhiDiffPattern[CSCConstants::NUM_CLCT_PATTERNS]
private

Definition at line 445 of file CSCTriggerPrimitivesReader.h.

Referenced by bookResolHistos(), calcResolution(), and drawResolHistos().

◆ hPhiDiffVsPhi

TH1F* CSCTriggerPrimitivesReader::hPhiDiffVsPhi[MAX_STATIONS]
private

Definition at line 441 of file CSCTriggerPrimitivesReader.h.

Referenced by bookResolHistos(), calcResolution(), and drawResolHistos().

◆ hPhiDiffVsStripCsc

TH2F* CSCTriggerPrimitivesReader::hPhiDiffVsStripCsc[CSC_TYPES][2]
private

Definition at line 443 of file CSCTriggerPrimitivesReader.h.

Referenced by bookResolHistos(), calcResolution(), and drawResolHistos().

◆ hPhiRecVsSim

TH2F* CSCTriggerPrimitivesReader::hPhiRecVsSim
private

Definition at line 437 of file CSCTriggerPrimitivesReader.h.

Referenced by bookResolHistos(), calcResolution(), and drawResolHistos().

◆ hResolDeltaDS

TH1F * CSCTriggerPrimitivesReader::hResolDeltaDS
private

◆ hResolDeltaEta

TH1F * CSCTriggerPrimitivesReader::hResolDeltaEta
private

Definition at line 431 of file CSCTriggerPrimitivesReader.h.

Referenced by bookResolHistos(), calcResolution(), and drawResolHistos().

◆ hResolDeltaHS

TH1F* CSCTriggerPrimitivesReader::hResolDeltaHS
private

◆ hResolDeltaPhi

TH1F* CSCTriggerPrimitivesReader::hResolDeltaPhi
private

Definition at line 439 of file CSCTriggerPrimitivesReader.h.

Referenced by bookResolHistos(), calcResolution(), and drawResolHistos().

◆ hResolDeltaPhiDS

TH1F * CSCTriggerPrimitivesReader::hResolDeltaPhiDS
private

Definition at line 439 of file CSCTriggerPrimitivesReader.h.

Referenced by bookResolHistos(), and calcResolution().

◆ hResolDeltaPhiHS

TH1F * CSCTriggerPrimitivesReader::hResolDeltaPhiHS
private

Definition at line 439 of file CSCTriggerPrimitivesReader.h.

Referenced by bookResolHistos(), and calcResolution().

◆ hResolDeltaWG

TH1F* CSCTriggerPrimitivesReader::hResolDeltaWG
private

◆ hTrueBendCsc

TH1F* CSCTriggerPrimitivesReader::hTrueBendCsc[CSC_TYPES]
private

Definition at line 444 of file CSCTriggerPrimitivesReader.h.

Referenced by bookResolHistos(), calcResolution(), and drawResolHistos().

◆ lctProducerData_

std::string CSCTriggerPrimitivesReader::lctProducerData_
private

Definition at line 172 of file CSCTriggerPrimitivesReader.h.

Referenced by CSCTriggerPrimitivesReader().

◆ lctProducerEmul_

std::string CSCTriggerPrimitivesReader::lctProducerEmul_
private

Definition at line 174 of file CSCTriggerPrimitivesReader.h.

Referenced by CSCTriggerPrimitivesReader().

◆ lcts_mpc_d_token_

edm::EDGetTokenT<CSCCorrelatedLCTDigiCollection> CSCTriggerPrimitivesReader::lcts_mpc_d_token_
private

Definition at line 186 of file CSCTriggerPrimitivesReader.h.

Referenced by analyze(), and CSCTriggerPrimitivesReader().

◆ lcts_mpc_e_token_

edm::EDGetTokenT<CSCCorrelatedLCTDigiCollection> CSCTriggerPrimitivesReader::lcts_mpc_e_token_
private

Definition at line 191 of file CSCTriggerPrimitivesReader.h.

Referenced by analyze(), and CSCTriggerPrimitivesReader().

◆ lcts_tmb_d_token_

edm::EDGetTokenT<CSCCorrelatedLCTDigiCollection> CSCTriggerPrimitivesReader::lcts_tmb_d_token_
private

Definition at line 185 of file CSCTriggerPrimitivesReader.h.

Referenced by analyze(), and CSCTriggerPrimitivesReader().

◆ lcts_tmb_e_token_

edm::EDGetTokenT<CSCCorrelatedLCTDigiCollection> CSCTriggerPrimitivesReader::lcts_tmb_e_token_
private

Definition at line 190 of file CSCTriggerPrimitivesReader.h.

Referenced by analyze(), and CSCTriggerPrimitivesReader().

◆ lut_wg_vs_hs_me1a

const int CSCTriggerPrimitivesReader::lut_wg_vs_hs_me1a
staticprivate
Initial value:
= {
{0, 95}, {0, 95}, {0, 95}, {0, 95}, {0, 95}, {0, 95}, {0, 95}, {0, 95}, {0, 95}, {0, 95},
{0, 95}, {0, 95}, {0, 77}, {0, 61}, {0, 39}, {0, 22}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1},
{-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1},
{-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1},
{-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}}

Definition at line 221 of file CSCTriggerPrimitivesReader.h.

Referenced by doesALCTCrossCLCT().

◆ lut_wg_vs_hs_me1ag

const int CSCTriggerPrimitivesReader::lut_wg_vs_hs_me1ag
staticprivate
Initial value:
= {
{0, 31}, {0, 31}, {0, 31}, {0, 31}, {0, 31}, {0, 31}, {0, 31}, {0, 31}, {0, 31}, {0, 31},
{0, 31}, {0, 31}, {0, 31}, {0, 31}, {0, 31}, {0, 22}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1},
{-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1},
{-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1},
{-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}}

Definition at line 222 of file CSCTriggerPrimitivesReader.h.

Referenced by doesALCTCrossCLCT().

◆ lut_wg_vs_hs_me1b

const int CSCTriggerPrimitivesReader::lut_wg_vs_hs_me1b
staticprivate
Initial value:
= {
{-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1},
{100, 127}, {73, 127}, {47, 127}, {22, 127}, {0, 127}, {0, 127}, {0, 127}, {0, 127}, {0, 127}, {0, 127},
{0, 127}, {0, 127}, {0, 127}, {0, 127}, {0, 127}, {0, 127}, {0, 127}, {0, 127}, {0, 127}, {0, 127},
{0, 127}, {0, 127}, {0, 127}, {0, 127}, {0, 127}, {0, 127}, {0, 127}, {0, 127}, {0, 127}, {0, 127},
{0, 127}, {0, 127}, {0, 127}, {0, 127}, {0, 105}, {0, 93}, {0, 78}, {0, 63}}

Definition at line 220 of file CSCTriggerPrimitivesReader.h.

Referenced by doesALCTCrossCLCT(), and getGlobalPosition().

◆ MAX_HS

const int CSCTriggerPrimitivesReader::MAX_HS
staticprivate
Initial value:
= {
128, 160, 128, 96, 160, 160, 160, 160, 160, 160}

Definition at line 217 of file CSCTriggerPrimitivesReader.h.

Referenced by bookCLCTHistos(), bookResolHistos(), and getHsPerRad().

◆ MAX_WG

const int CSCTriggerPrimitivesReader::MAX_WG
staticprivate
Initial value:
= {
48, 64, 32, 48, 112, 64, 96, 64, 96, 64}

Definition at line 216 of file CSCTriggerPrimitivesReader.h.

Referenced by bookResolHistos().

◆ mpclctProducerData_

std::string CSCTriggerPrimitivesReader::mpclctProducerData_
private

Definition at line 173 of file CSCTriggerPrimitivesReader.h.

Referenced by CSCTriggerPrimitivesReader().

◆ NCHAMBERS

const int CSCTriggerPrimitivesReader::NCHAMBERS = {36, 36, 36, 36, 18, 36, 18, 36, 18, 36}
staticprivate

◆ numALCT

int CSCTriggerPrimitivesReader::numALCT = 0
staticprivate

Definition at line 224 of file CSCTriggerPrimitivesReader.h.

Referenced by endJob(), and fillALCTHistos().

◆ numCLCT

int CSCTriggerPrimitivesReader::numCLCT = 0
staticprivate

Definition at line 225 of file CSCTriggerPrimitivesReader.h.

Referenced by endJob(), and fillCLCTHistos().

◆ numLCTMPC

int CSCTriggerPrimitivesReader::numLCTMPC = 0
staticprivate

Definition at line 227 of file CSCTriggerPrimitivesReader.h.

Referenced by endJob(), and fillLCTMPCHistos().

◆ numLCTTMB

int CSCTriggerPrimitivesReader::numLCTTMB = 0
staticprivate

Definition at line 226 of file CSCTriggerPrimitivesReader.h.

Referenced by endJob(), and fillLCTTMBHistos().

◆ pBadToken_

edm::ESGetToken<CSCBadChambers, CSCBadChambersRcd> CSCTriggerPrimitivesReader::pBadToken_
private

Definition at line 193 of file CSCTriggerPrimitivesReader.h.

Referenced by analyze(), and CSCTriggerPrimitivesReader().

◆ perStub

TreePerStub CSCTriggerPrimitivesReader::perStub[6]
private

◆ plotME1A

bool CSCTriggerPrimitivesReader::plotME1A
private

◆ plotME42

bool CSCTriggerPrimitivesReader::plotME42
private

◆ pretrigs_e_token_

edm::EDGetTokenT<CSCCLCTPreTriggerDigiCollection> CSCTriggerPrimitivesReader::pretrigs_e_token_
private

Definition at line 189 of file CSCTriggerPrimitivesReader.h.

Referenced by analyze(), and CSCTriggerPrimitivesReader().

◆ printps

bool CSCTriggerPrimitivesReader::printps = false
staticprivate

Definition at line 240 of file CSCTriggerPrimitivesReader.h.

Referenced by CSCTriggerPrimitivesReader(), and endJob().

◆ ptype_TMB07

const int CSCTriggerPrimitivesReader::ptype_TMB07
staticprivate
Initial value:
= {
-999, -5, 4, -4, 3, -3, 2, -2, 1, -1, 0}

Definition at line 218 of file CSCTriggerPrimitivesReader.h.

Referenced by bookResolHistos(), and fillCLCTHistos().

◆ resultsFileNamesPrefix_

std::string CSCTriggerPrimitivesReader::resultsFileNamesPrefix_
private

◆ rootFileName

std::string CSCTriggerPrimitivesReader::rootFileName
private

Definition at line 146 of file CSCTriggerPrimitivesReader.h.

◆ RUN_

int CSCTriggerPrimitivesReader::RUN_
private

◆ simHit_token_

edm::EDGetTokenT<edm::PSimHitContainer> CSCTriggerPrimitivesReader::simHit_token_
private

Definition at line 179 of file CSCTriggerPrimitivesReader.h.

Referenced by CSCTriggerPrimitivesReader(), and MCStudies().

◆ simHitProducer_

edm::InputTag CSCTriggerPrimitivesReader::simHitProducer_
private

Definition at line 175 of file CSCTriggerPrimitivesReader.h.

Referenced by CSCTriggerPrimitivesReader(), and MCStudies().

◆ stub_tree

TTree* CSCTriggerPrimitivesReader::stub_tree[4]
private

◆ stubs_comparison

MyStubComparison CSCTriggerPrimitivesReader::stubs_comparison[4]
private

◆ TWOPI

const double CSCTriggerPrimitivesReader::TWOPI = 2. * M_PI
staticprivate

Definition at line 209 of file CSCTriggerPrimitivesReader.h.

Referenced by bookResolHistos(), and getHsPerRad().

◆ wireDigi_token_

edm::EDGetTokenT<CSCWireDigiCollection> CSCTriggerPrimitivesReader::wireDigi_token_
private

Definition at line 180 of file CSCTriggerPrimitivesReader.h.

Referenced by CSCTriggerPrimitivesReader(), HotWires(), and MCStudies().

◆ wireDigiProducer_

edm::InputTag CSCTriggerPrimitivesReader::wireDigiProducer_
private

Definition at line 176 of file CSCTriggerPrimitivesReader.h.

Referenced by CSCTriggerPrimitivesReader(), and MCStudies().

CSCTriggerPrimitivesReader::hAlctCompMatch2i
TH2F * hAlctCompMatch2i
Definition: CSCTriggerPrimitivesReader.h:365
CSCTriggerPrimitivesReader::hAlctCompTotalCsc
TH1F * hAlctCompTotalCsc[MAX_ENDCAPS][CSC_TYPES]
Definition: CSCTriggerPrimitivesReader.h:415
CSCTriggerPrimitivesReader::hClctBendCsc
TH1F * hClctBendCsc[CSC_TYPES][2]
Definition: CSCTriggerPrimitivesReader.h:333
MyStubComparison::quality_data
Int_t quality_data
Definition: CSCTriggerPrimitivesReader.h:89
CSCTriggerPrimitivesReader::clcts_e_token_
edm::EDGetTokenT< CSCCLCTDigiCollection > clcts_e_token_
Definition: CSCTriggerPrimitivesReader.h:188
CSCTriggerPrimitivesReader::hResolDeltaWG
TH1F * hResolDeltaWG
Definition: CSCTriggerPrimitivesReader.h:431
edm::ESHandle::product
T const * product() const
Definition: ESHandle.h:86
CSCTriggerPrimitivesReader::lut_wg_vs_hs_me1a
static const int lut_wg_vs_hs_me1a[48][2]
Definition: CSCTriggerPrimitivesReader.h:221
RandomServiceHelper.t2
t2
Definition: RandomServiceHelper.py:257
CSCTriggerPrimitivesReader::MCStudies
void MCStudies(const edm::Event &ev, const CSCALCTDigiCollection *alcts, const CSCCLCTDigiCollection *clcts)
Definition: CSCTriggerPrimitivesReader.cc:2636
CSCTriggerPrimitivesReader::hAlctQuality
TH1F * hAlctQuality
Definition: CSCTriggerPrimitivesReader.h:325
CSCTriggerPrimitivesReader::dataLctsIn_
bool dataLctsIn_
Definition: CSCTriggerPrimitivesReader.h:160
CSCTriggerPrimitivesReader::hLCTCompFound2x
TH2F * hLCTCompFound2x
Definition: CSCTriggerPrimitivesReader.h:393
FastTimerService_cff.range
range
Definition: FastTimerService_cff.py:34
CSCTriggerPrimitivesReader::bookResolHistos
void bookResolHistos()
Definition: CSCTriggerPrimitivesReader.cc:1012
TreePerStub::t_ring
Int_t t_ring
Definition: CSCTriggerPrimitivesReader.h:62
CSCCathodeLCTAnalyzer::getStripPhi
double getStripPhi(const CSCDetId &layerId, const float strip)
Definition: CSCCathodeLCTAnalyzer.cc:401
CSCTriggerPrimitivesReader::csc_type_minus
static const std::string csc_type_minus[CSC_TYPES]
Definition: CSCTriggerPrimitivesReader.h:214
CSCTriggerPrimitivesReader::hEfficCLCTEtaCsc
TH1F * hEfficCLCTEtaCsc[CSC_TYPES]
Definition: CSCTriggerPrimitivesReader.h:450
CSCTriggerPrimitivesReader::numLCTTMB
static int numLCTTMB
Definition: CSCTriggerPrimitivesReader.h:226
runGCPTkAlMap.title
string title
Definition: runGCPTkAlMap.py:94
MyStubComparison::has_emul
Bool_t has_emul
Definition: CSCTriggerPrimitivesReader.h:87
CSCTriggerPrimitivesReader::hLCTCompTotal
TH1F * hLCTCompTotal
Definition: CSCTriggerPrimitivesReader.h:406
mps_fire.i
i
Definition: mps_fire.py:428
CSCTriggerPrimitivesReader::drawCompHistos
void drawCompHistos()
Definition: CSCTriggerPrimitivesReader.cc:3503
CSCTriggerPrimitivesReader::stubs_comparison
MyStubComparison stubs_comparison[4]
Definition: CSCTriggerPrimitivesReader.h:312
CSCTriggerPrimitivesReader::MAX_HS
static const int MAX_HS[CSC_TYPES]
Definition: CSCTriggerPrimitivesReader.h:217
CSCTriggerPrimitivesReader::bookLCTMPCHistos
void bookLCTMPCHistos()
Definition: CSCTriggerPrimitivesReader.cc:828
CSCTriggerPrimitivesReader::hClctCompTotal2i
TH2F * hClctCompTotal2i
Definition: CSCTriggerPrimitivesReader.h:389
MyStubComparison::chamber
Int_t chamber
Definition: CSCTriggerPrimitivesReader.h:81
CSCChamber::layer
const CSCLayer * layer(CSCDetId id) const
Return the layer corresponding to the given id.
Definition: CSCChamber.cc:30
CSCAnodeLCTAnalyzer::getSimInfo
std::vector< CSCAnodeLayerInfo > getSimInfo(const CSCALCTDigi &alct, const CSCDetId &alctId, const CSCWireDigiCollection *wiredc, const edm::PSimHitContainer *allSimHits)
Definition: CSCAnodeLCTAnalyzer.cc:16
CSCTriggerPrimitivesReader::hLctTMBStripType
TH1F * hLctTMBStripType
Definition: CSCTriggerPrimitivesReader.h:340
CSCTriggerPrimitivesReader::hClctCompTotal2x
TH2F * hClctCompTotal2x
Definition: CSCTriggerPrimitivesReader.h:388
CSCTriggerPrimitivesReader::hAlctCompFound
TH1F * hAlctCompFound
Definition: CSCTriggerPrimitivesReader.h:352
CSCTriggerPrimitivesReader::hCorrLctMPCPerCSC
TH1F * hCorrLctMPCPerCSC
Definition: CSCTriggerPrimitivesReader.h:343
CSCTriggerPrimitivesReader::lctProducerData_
std::string lctProducerData_
Definition: CSCTriggerPrimitivesReader.h:172
edm::Handle::product
T const * product() const
Definition: Handle.h:70
MyStubComparison::bookTree
TTree * bookTree(TTree *t, const std::string &name="Stub_compare")
Definition: CSCTriggerPrimitivesReader.cc:211
CSCTriggerPrimitivesReader::hEfficALCTEta
TH1F * hEfficALCTEta[MAX_STATIONS]
Definition: CSCTriggerPrimitivesReader.h:448
CSCTriggerPrimitivesReader::hLctMPCQuality
TH1F * hLctMPCQuality
Definition: CSCTriggerPrimitivesReader.h:346
CSCTriggerPrimitivesReader::checkBadChambers_
bool checkBadChambers_
Definition: CSCTriggerPrimitivesReader.h:199
CSCTriggerPrimitivesReader::hEfficHitsEta
TH1F * hEfficHitsEta[MAX_STATIONS]
Definition: CSCTriggerPrimitivesReader.h:447
makePileupJSON.denom
denom
Definition: makePileupJSON.py:147
CSCTriggerPrimitivesReader::hLctMPCKeyGroup
TH1F * hLctMPCKeyGroup
Definition: CSCTriggerPrimitivesReader.h:346
CSCTriggerPrimitivesReader::numLCTMPC
static int numLCTMPC
Definition: CSCTriggerPrimitivesReader.h:227
CSCTriggerPrimitivesReader::maxRing
int maxRing(int station)
Definition: CSCTriggerPrimitivesReader.cc:353
TreePerStub::t_endcap
Int_t t_endcap
Definition: CSCTriggerPrimitivesReader.h:63
CSCTriggerPrimitivesReader::gangedME1a
bool gangedME1a
Definition: CSCTriggerPrimitivesReader.h:163
CSCAnodeLCTAnalyzer::setGeometry
void setGeometry(const CSCGeometry *geom)
Definition: CSCAnodeLCTAnalyzer.cc:329
CSCTriggerPrimitivesReader::hAlctKeyGroup
TH1F * hAlctKeyGroup
Definition: CSCTriggerPrimitivesReader.h:325
CSCTriggerPrimitivesReader::hPhiRecVsSim
TH2F * hPhiRecVsSim
Definition: CSCTriggerPrimitivesReader.h:437
CaloTowersParam_cfi.mc
mc
Definition: CaloTowersParam_cfi.py:8
CSCTriggerPrimitivesReader::hLCTCompTotal2i
TH2F * hLCTCompTotal2i
Definition: CSCTriggerPrimitivesReader.h:409
CSCTriggerPrimitivesReader::chamberSerial
int chamberSerial(CSCDetId id)
Definition: CSCTriggerPrimitivesReader.cc:797
MyStubComparison::eta_data
Float_t eta_data
Definition: CSCTriggerPrimitivesReader.h:118
CSCTriggerPrimitivesReader::hLctMPCKeyGroupME11
TH1F * hLctMPCKeyGroupME11
Definition: CSCTriggerPrimitivesReader.h:456
CSCTriggerPrimitivesReader::mpclctProducerData_
std::string mpclctProducerData_
Definition: CSCTriggerPrimitivesReader.h:173
CSCTriggerPrimitivesReader::hEtaDiffVsWireCsc
TH2F * hEtaDiffVsWireCsc[CSC_TYPES]
Definition: CSCTriggerPrimitivesReader.h:435
CSCTriggerPrimitivesReader::hAlctCompSameN2
TH2F * hAlctCompSameN2
Definition: CSCTriggerPrimitivesReader.h:358
relativeConstraints.cham
cham
Definition: relativeConstraints.py:69
CSCTriggerPrimitivesReader::hClctCompSameN
TH1F * hClctCompSameN
Definition: CSCTriggerPrimitivesReader.h:376
CSCTriggerPrimitivesReader::hAlctBXN
TH1F * hAlctBXN
Definition: CSCTriggerPrimitivesReader.h:326
CSCTriggerPrimitivesReader::getCSCType
int getCSCType(const CSCDetId &id)
Definition: CSCTriggerPrimitivesReader.cc:4689
MyStubComparison::quality_emul
Int_t quality_emul
Definition: CSCTriggerPrimitivesReader.h:92
CSCTriggerPrimitivesReader::hLCTCompFound2
TH2F * hLCTCompFound2
Definition: CSCTriggerPrimitivesReader.h:392
MyStubComparison::nEvents
Int_t nEvents
Definition: CSCTriggerPrimitivesReader.h:72
CSCTriggerPrimitivesReader::hClctCompSameN2i
TH2F * hClctCompSameN2i
Definition: CSCTriggerPrimitivesReader.h:379
CSCTriggerPrimitivesReader::bookedResolHistos
static bool bookedResolHistos
Definition: CSCTriggerPrimitivesReader.h:237
relativeConstraints.station
station
Definition: relativeConstraints.py:67
CSCDetId::ring
int ring() const
Definition: CSCDetId.h:68
DigiDM_cff.wires
wires
Definition: DigiDM_cff.py:33
CSCTriggerPrimitivesReader::hAlctCompMatch2x
TH2F * hAlctCompMatch2x
Definition: CSCTriggerPrimitivesReader.h:364
digitizers_cfi.strip
strip
Definition: digitizers_cfi.py:19
CSCTriggerPrimitivesReader::hLCTCompFound2i
TH2F * hLCTCompFound2i
Definition: CSCTriggerPrimitivesReader.h:394
AlCaHLTBitMon_ParallelJobs.p
p
Definition: AlCaHLTBitMon_ParallelJobs.py:153
CSCGeometry::idToDet
const GeomDet * idToDet(DetId) const override
Definition: CSCGeometry.cc:91
MyStubComparison::pattern_data
Int_t pattern_data
Definition: CSCTriggerPrimitivesReader.h:106
CSCTriggerPrimitivesReader::hClctKeyStripME11
TH1F * hClctKeyStripME11
Definition: CSCTriggerPrimitivesReader.h:453
gather_cfg.cout
cout
Definition: gather_cfg.py:144
CSCTriggerPrimitivesReader::pretrigs_e_token_
edm::EDGetTokenT< CSCCLCTPreTriggerDigiCollection > pretrigs_e_token_
Definition: CSCTriggerPrimitivesReader.h:189
CSCTriggerPrimitivesReader::hLCTCompSameN2i
TH2F * hLCTCompSameN2i
Definition: CSCTriggerPrimitivesReader.h:399
CSCTriggerPrimitivesReader::hLctMPCChamber
TH1F * hLctMPCChamber[MAX_STATIONS]
Definition: CSCTriggerPrimitivesReader.h:345
CSCTriggerPrimitivesReader::hClctCompTotal
TH1F * hClctCompTotal
Definition: CSCTriggerPrimitivesReader.h:386
CSCTriggerPrimitivesReader::pBadToken_
edm::ESGetToken< CSCBadChambers, CSCBadChambersRcd > pBadToken_
Definition: CSCTriggerPrimitivesReader.h:193
CSCTriggerPrimitivesReader::hResolDeltaPhiHS
TH1F * hResolDeltaPhiHS
Definition: CSCTriggerPrimitivesReader.h:439
CSCTriggerPrimitivesReader::hAlctCompFoundCsc
TH1F * hAlctCompFoundCsc[MAX_ENDCAPS][CSC_TYPES]
Definition: CSCTriggerPrimitivesReader.h:413
CSCTriggerPrimitivesReader::hAlctKeyGroupME11
TH1F * hAlctKeyGroupME11
Definition: CSCTriggerPrimitivesReader.h:452
CSCTriggerPrimitivesReader::hHotWire1
TH1F * hHotWire1
Definition: CSCTriggerPrimitivesReader.h:320
CSCTriggerPrimitivesReader::hLCTCompMatch2i
TH2F * hLCTCompMatch2i
Definition: CSCTriggerPrimitivesReader.h:404
CSCTriggerPrimitivesReader::TWOPI
static const double TWOPI
Definition: CSCTriggerPrimitivesReader.h:209
cms::cuda::assert
assert(be >=bs)
CSCTriggerPrimitivesReader::lcts_tmb_e_token_
edm::EDGetTokenT< CSCCorrelatedLCTDigiCollection > lcts_tmb_e_token_
Definition: CSCTriggerPrimitivesReader.h:190
CSCTriggerPrimitivesReader::hLCTCompSameN
TH1F * hLCTCompSameN
Definition: CSCTriggerPrimitivesReader.h:396
FastTrackerRecHitCombiner_cfi.simHits
simHits
Definition: FastTrackerRecHitCombiner_cfi.py:5
CSCTriggerPrimitivesReader::hLCTCompSameN2x
TH2F * hLCTCompSameN2x
Definition: CSCTriggerPrimitivesReader.h:398
CSCTriggerPrimitivesReader::hLCTCompMatch
TH1F * hLCTCompMatch
Definition: CSCTriggerPrimitivesReader.h:401
CSCConstants::KEY_ALCT_LAYER
Definition: CSCConstants.h:46
CSCTriggerPrimitivesReader::bookedCLCTHistos
static bool bookedCLCTHistos
Definition: CSCTriggerPrimitivesReader.h:231
CSCTriggerPrimitivesReader::bookedCompHistos
static bool bookedCompHistos
Definition: CSCTriggerPrimitivesReader.h:235
CSCLayer
Definition: CSCLayer.h:24
CSCTriggerPrimitivesReader::hAlctCompTotal2i
TH2F * hAlctCompTotal2i
Definition: CSCTriggerPrimitivesReader.h:370
CSCTriggerPrimitivesReader::chamberIX
int chamberIX(CSCDetId id)
Definition: CSCTriggerPrimitivesReader.cc:785
CSCTriggerPrimitivesReader::emulLctsIn_
bool emulLctsIn_
Definition: CSCTriggerPrimitivesReader.h:161
CSCTriggerPrimitivesReader::hLctTMBCsc
TH1F * hLctTMBCsc[MAX_ENDCAPS][CSC_TYPES]
Definition: CSCTriggerPrimitivesReader.h:338
CSCTriggerPrimitivesReader::badChambers_
const CSCBadChambers * badChambers_
Definition: CSCTriggerPrimitivesReader.h:156
CSCTriggerPrimitivesReader::hEfficALCTEtaCsc
TH1F * hEfficALCTEtaCsc[CSC_TYPES]
Definition: CSCTriggerPrimitivesReader.h:450
CSCTriggerPrimitivesReader::hLctMPCBXN
TH1F * hLctMPCBXN
Definition: CSCTriggerPrimitivesReader.h:348
CSCTriggerPrimitivesReader::MAX_ENDCAPS
Definition: CSCTriggerPrimitivesReader.h:207
edm::ParameterSet::getUntrackedParameter
T getUntrackedParameter(std::string const &, T const &) const
CSCTriggerPrimitivesReader::bookCLCTHistos
void bookCLCTHistos()
Definition: CSCTriggerPrimitivesReader.cc:670
CSCTriggerPrimitivesReader::hClctPerEvent
TH1F * hClctPerEvent
Definition: CSCTriggerPrimitivesReader.h:328
indexGen.s2
s2
Definition: indexGen.py:107
CSCTriggerPrimitivesReader::hAlctValid
TH1F * hAlctValid
Definition: CSCTriggerPrimitivesReader.h:325
MyStubComparison::pattern_emul
Int_t pattern_emul
Definition: CSCTriggerPrimitivesReader.h:107
edm::LogInfo
Log< level::Info, false > LogInfo
Definition: MessageLogger.h:125
CSCTriggerPrimitivesReader::hTrueBendCsc
TH1F * hTrueBendCsc[CSC_TYPES]
Definition: CSCTriggerPrimitivesReader.h:444
CSCTriggerPrimitivesReader::hLCTCompMatch2x
TH2F * hLCTCompMatch2x
Definition: CSCTriggerPrimitivesReader.h:403
makeMuonMisalignmentScenario.endcap
endcap
Definition: makeMuonMisalignmentScenario.py:320
CSCTriggerPrimitivesReader::hPhiDiffPattern
TH1F * hPhiDiffPattern[CSCConstants::NUM_CLCT_PATTERNS]
Definition: CSCTriggerPrimitivesReader.h:445
CSCTriggerPrimitivesReader::hLctTMBChamber
TH1F * hLctTMBChamber[MAX_STATIONS]
Definition: CSCTriggerPrimitivesReader.h:338
CSCTriggerPrimitivesReader::simHit_token_
edm::EDGetTokenT< edm::PSimHitContainer > simHit_token_
Definition: CSCTriggerPrimitivesReader.h:179
CSCTriggerPrimitivesReader::hResolDeltaPhiDS
TH1F * hResolDeltaPhiDS
Definition: CSCTriggerPrimitivesReader.h:439
edm::Handle< CSCALCTDigiCollection >
relativeConstraints.error
error
Definition: relativeConstraints.py:53
CSCTriggerPrimitivesReader::clcts_d_token_
edm::EDGetTokenT< CSCCLCTDigiCollection > clcts_d_token_
Definition: CSCTriggerPrimitivesReader.h:184
edm::LogWarning
Log< level::Warning, false > LogWarning
Definition: MessageLogger.h:122
CSCTriggerPrimitivesReader::bookedLCTMPCHistos
static bool bookedLCTMPCHistos
Definition: CSCTriggerPrimitivesReader.h:233
MyStubComparison::WGcrossHS_data
Bool_t WGcrossHS_data
Definition: CSCTriggerPrimitivesReader.h:108
singleTopDQM_cfi.setup
setup
Definition: singleTopDQM_cfi.py:37
CSCTriggerPrimitivesReader::hResolDeltaDS
TH1F * hResolDeltaDS
Definition: CSCTriggerPrimitivesReader.h:438
CSCTriggerPrimitivesReader::hAlctPerCSC
TH1F * hAlctPerCSC
Definition: CSCTriggerPrimitivesReader.h:323
HepMC::GenEvent
Definition: hepmc_rootio.cc:9
CSCTriggerPrimitivesReader::CSC_TYPES
Definition: CSCTriggerPrimitivesReader.h:207
MyStubComparison::bx_corr_emul
Int_t bx_corr_emul
Definition: CSCTriggerPrimitivesReader.h:95
CSCTriggerPrimitivesReader::hHotCham1
TH1F * hHotCham1
Definition: CSCTriggerPrimitivesReader.h:320
CSCTriggerPrimitivesReader::drawCLCTHistos
void drawCLCTHistos()
Definition: CSCTriggerPrimitivesReader.cc:3140
CSCTriggerPrimitivesReader::hAlctVsEta
TH1F * hAlctVsEta[MAX_STATIONS]
Definition: CSCTriggerPrimitivesReader.h:432
MyStubComparison::bend_emul
Int_t bend_emul
Definition: CSCTriggerPrimitivesReader.h:93
TreePerStub::t_chamber
Int_t t_chamber
Definition: CSCTriggerPrimitivesReader.h:61
edm::InputTag::label
std::string const & label() const
Definition: InputTag.h:36
CSCTriggerPrimitivesReader::hClctCompTotal2
TH2F * hClctCompTotal2
Definition: CSCTriggerPrimitivesReader.h:387
GeomDet::surface
const Plane & surface() const
The nominal surface of the GeomDet.
Definition: GeomDet.h:37
CSCTriggerPrimitivesReader::hClctKeyStripCsc
TH1F * hClctKeyStripCsc[CSC_TYPES]
Definition: CSCTriggerPrimitivesReader.h:333
TreePerStub::t_station
Int_t t_station
Definition: CSCTriggerPrimitivesReader.h:64
CSCTriggerPrimitivesReader::hLctMPCPattern
TH1F * hLctMPCPattern
Definition: CSCTriggerPrimitivesReader.h:348
CSCTriggerPrimitivesReader::hClctCompMatch2
TH2F * hClctCompMatch2
Definition: CSCTriggerPrimitivesReader.h:382
alignCSCRings.s
s
Definition: alignCSCRings.py:92
MyStubComparison::totStubs_emul
Int_t totStubs_emul
Definition: CSCTriggerPrimitivesReader.h:77
CSCTriggerPrimitivesReader::hLctTMBValid
TH1F * hLctTMBValid
Definition: CSCTriggerPrimitivesReader.h:339
CSCAnodeLCTAnalyzer::nearestWG
int nearestWG(const std::vector< CSCAnodeLayerInfo > &allLayerInfo, double &closestPhi, double &closestEta)
Definition: CSCAnodeLCTAnalyzer.cc:242
RandomServiceHelper.t1
t1
Definition: RandomServiceHelper.py:256
CSCTriggerPrimitivesReader::hAlctCollis
TH1F * hAlctCollis
Definition: CSCTriggerPrimitivesReader.h:325
CSCTriggerPrimitivesReader::hClctCompFound2
TH2F * hClctCompFound2
Definition: CSCTriggerPrimitivesReader.h:373
CSCTriggerPrimitivesReader::hClctCompFound
TH1F * hClctCompFound
Definition: CSCTriggerPrimitivesReader.h:372
hgcalPlots.stat
stat
Definition: hgcalPlots.py:1119
spr::deltaEta
static const double deltaEta
Definition: CaloConstants.h:8
SiPixelRawToDigiRegional_cfi.deltaPhi
deltaPhi
Definition: SiPixelRawToDigiRegional_cfi.py:9
CSCTriggerPrimitivesReader::hLctMPCBend
TH1F * hLctMPCBend
Definition: CSCTriggerPrimitivesReader.h:348
FrontierCondition_GT_autoExpress_cfi.t0
t0
Definition: FrontierCondition_GT_autoExpress_cfi.py:148
CSCTriggerPrimitivesReader::hLctCompTotalCsc
TH1F * hLctCompTotalCsc[MAX_ENDCAPS][CSC_TYPES]
Definition: CSCTriggerPrimitivesReader.h:425
MyStubComparison::bx_emul
Int_t bx_emul
Definition: CSCTriggerPrimitivesReader.h:94
CSCTriggerPrimitivesReader::hPhiDiffVsPhi
TH1F * hPhiDiffVsPhi[MAX_STATIONS]
Definition: CSCTriggerPrimitivesReader.h:441
MyStubComparison::nStub_emul
Int_t nStub_emul
Definition: CSCTriggerPrimitivesReader.h:80
CSCTriggerPrimitivesReader::hClctCompSameNCsc
TH1F * hClctCompSameNCsc[MAX_ENDCAPS][CSC_TYPES]
Definition: CSCTriggerPrimitivesReader.h:419
CSCTriggerPrimitivesReader::fillLCTTMBHistos
void fillLCTTMBHistos(const CSCCorrelatedLCTDigiCollection *lcts)
Definition: CSCTriggerPrimitivesReader.cc:1232
CSCTriggerPrimitivesReader::MAXPAGES
Definition: CSCTriggerPrimitivesReader.h:208
CSCTriggerPrimitivesReader::hLctTMBPattern
TH1F * hLctTMBPattern
Definition: CSCTriggerPrimitivesReader.h:341
CSCTriggerPrimitivesReader::chamberIXi
int chamberIXi(CSCDetId id)
Definition: CSCTriggerPrimitivesReader.cc:771
CSCTriggerPrimitivesReader::compDigiProducer_
edm::InputTag compDigiProducer_
Definition: CSCTriggerPrimitivesReader.h:177
mathSSE::sqrt
T sqrt(T t)
Definition: SSEVec.h:19
CSCTriggerPrimitivesReader::hClctKeyStrip
TH1F * hClctKeyStrip[2]
Definition: CSCTriggerPrimitivesReader.h:332
CSCConstants::NUM_LAYERS
Definition: CSCConstants.h:46
Surface::toGlobal
GlobalPoint toGlobal(const Point2DBase< Scalar, LocalTag > lp) const
Definition: Surface.h:79
CSCDetId::layer
int layer() const
Definition: CSCDetId.h:56
MyStubComparison::key_WG_data
Int_t key_WG_data
Definition: CSCTriggerPrimitivesReader.h:110
CSCTriggerPrimitivesReader::hAlctCompTotal
TH1F * hAlctCompTotal
Definition: CSCTriggerPrimitivesReader.h:367
edm::ESHandle< CSCGeometry >
CSCTriggerPrimitivesReader::getHsPerRad
double getHsPerRad(const int idh)
Definition: CSCTriggerPrimitivesReader.cc:4706
CSCTriggerPrimitivesReader::compareALCTs
void compareALCTs(const CSCALCTDigiCollection *alcts_data, const CSCALCTDigiCollection *alcts_emul)
Definition: CSCTriggerPrimitivesReader.cc:1391
CSCTriggerPrimitivesReader::hEfficCLCTEta
TH1F * hEfficCLCTEta[MAX_STATIONS]
Definition: CSCTriggerPrimitivesReader.h:448
LaserClient_cfi.nbins
nbins
Definition: LaserClient_cfi.py:51
CSCLayerGeometry::middleWireOfGroup
float middleWireOfGroup(int wireGroup) const
Definition: CSCLayerGeometry.h:191
MyStubComparison::key_hs_emul
Int_t key_hs_emul
Definition: CSCTriggerPrimitivesReader.h:113
MyStubComparison::maxpattern_pretrig
Int_t maxpattern_pretrig
Definition: CSCTriggerPrimitivesReader.h:103
CSCTriggerPrimitivesReader::hAlctPerChamber
TH1F * hAlctPerChamber
Definition: CSCTriggerPrimitivesReader.h:323
CSCLayer::geometry
const CSCLayerGeometry * geometry() const
Definition: CSCLayer.h:44
CSCTriggerPrimitivesReader::lctProducerEmul_
std::string lctProducerEmul_
Definition: CSCTriggerPrimitivesReader.h:174
CSCTriggerPrimitivesReader::bookedHotWireHistos
static bool bookedHotWireHistos
Definition: CSCTriggerPrimitivesReader.h:229
dqmdumpme.k
k
Definition: dqmdumpme.py:60
CSCTriggerPrimitivesReader::hLctTMBPerCSC
TH1F * hLctTMBPerCSC
Definition: CSCTriggerPrimitivesReader.h:336
Point3DBase< float, LocalTag >
CSCTriggerPrimitivesReader::hAlctCompTotal2
TH2F * hAlctCompTotal2
Definition: CSCTriggerPrimitivesReader.h:368
CSCTriggerPrimitivesReader::hClctCompMatch
TH1F * hClctCompMatch
Definition: CSCTriggerPrimitivesReader.h:381
CSCTriggerPrimitivesReader::hLctTMBKeyStrip
TH1F * hLctTMBKeyStrip
Definition: CSCTriggerPrimitivesReader.h:340
CSCTriggerPrimitivesReader::bookCompHistos
void bookCompHistos()
Definition: CSCTriggerPrimitivesReader.cc:863
CSCTriggerPrimitivesReader::hLctMPCEndcap
TH1F * hLctMPCEndcap
Definition: CSCTriggerPrimitivesReader.h:344
CSCTriggerPrimitivesReader::hAlctCompMatch2
TH2F * hAlctCompMatch2
Definition: CSCTriggerPrimitivesReader.h:363
CSCTriggerPrimitivesReader::drawEfficHistos
void drawEfficHistos()
Definition: CSCTriggerPrimitivesReader.cc:4250
particleFlowDisplacedVertex_cfi.ratio
ratio
Definition: particleFlowDisplacedVertex_cfi.py:93
CSCTriggerPrimitivesReader::hClctBXN
TH1F * hClctBXN
Definition: CSCTriggerPrimitivesReader.h:331
MyStubComparison::npretrig
Int_t npretrig
Definition: CSCTriggerPrimitivesReader.h:96
CSCTriggerPrimitivesReader::hLCTCompTotal2x
TH2F * hLCTCompTotal2x
Definition: CSCTriggerPrimitivesReader.h:408
CSCTriggerPrimitivesReader::hClctCompFound2x
TH2F * hClctCompFound2x
Definition: CSCTriggerPrimitivesReader.h:374
TreePerStub::t_nStubs
Int_t t_nStubs
Definition: CSCTriggerPrimitivesReader.h:55
CSCTriggerPrimitivesReader::alcts_e_token_
edm::EDGetTokenT< CSCALCTDigiCollection > alcts_e_token_
Definition: CSCTriggerPrimitivesReader.h:187
MyStubComparison::bx_data
Int_t bx_data
Definition: CSCTriggerPrimitivesReader.h:91
CSCTriggerPrimitivesReader::hClctCompFound2i
TH2F * hClctCompFound2i
Definition: CSCTriggerPrimitivesReader.h:375
MyStubComparison::nStub_data
Int_t nStub_data
Definition: CSCTriggerPrimitivesReader.h:79
CSCTriggerPrimitivesReader::hAlctCompTotal2x
TH2F * hAlctCompTotal2x
Definition: CSCTriggerPrimitivesReader.h:369
MuonTCMETValueMapProducer_cff.nLayers
nLayers
Definition: MuonTCMETValueMapProducer_cff.py:38
CSCTriggerPrimitivesReader::hLctTMBSector
TH1F * hLctTMBSector
Definition: CSCTriggerPrimitivesReader.h:337
CSCTriggerPrimitivesReader::hLctMPCKeyStripME11
TH1F * hLctMPCKeyStripME11
Definition: CSCTriggerPrimitivesReader.h:457
CSCTriggerPrimitivesReader::hClctCompMatchCsc
TH1F * hClctCompMatchCsc[MAX_ENDCAPS][CSC_TYPES]
Definition: CSCTriggerPrimitivesReader.h:421
MyStubComparison::key_WG_emul
Int_t key_WG_emul
Definition: CSCTriggerPrimitivesReader.h:111
CSCTriggerPrimitivesReader::hClctCFEB
TH1F * hClctCFEB
Definition: CSCTriggerPrimitivesReader.h:330
CSCBadChambers::isInBadChamber
bool isInBadChamber(IndexType ichamber) const
Is the chamber with index 'ichamber' flagged as bad?
Definition: CSCBadChambers.cc:4
MyStubComparison::totStubs_emul_readout
Int_t totStubs_emul_readout
Definition: CSCTriggerPrimitivesReader.h:78
CSCTriggerPrimitivesReader::debug
bool debug
Definition: CSCTriggerPrimitivesReader.h:145
CSCTriggerPrimitivesReader::hLctCompMatchCsc
TH1F * hLctCompMatchCsc[MAX_ENDCAPS][CSC_TYPES]
Definition: CSCTriggerPrimitivesReader.h:426
CSCTriggerPrimitivesReader::hClctCompSameN2x
TH2F * hClctCompSameN2x
Definition: CSCTriggerPrimitivesReader.h:378
CSCTriggerPrimitivesReader::lut_wg_vs_hs_me1b
static const int lut_wg_vs_hs_me1b[48][2]
Definition: CSCTriggerPrimitivesReader.h:220
CSCTriggerPrimitivesReader::compDigi_token_
edm::EDGetTokenT< CSCComparatorDigiCollection > compDigi_token_
Definition: CSCTriggerPrimitivesReader.h:181
CSCTriggerPrimitivesReader::hLctTMBPerChamber
TH1F * hLctTMBPerChamber
Definition: CSCTriggerPrimitivesReader.h:335
CSCTriggerPrimitivesReader::resultsFileNamesPrefix_
std::string resultsFileNamesPrefix_
Definition: CSCTriggerPrimitivesReader.h:196
CSCTriggerPrimitivesReader::fillCLCTHistos
void fillCLCTHistos(const CSCCLCTDigiCollection *clcts)
Definition: CSCTriggerPrimitivesReader.cc:1172
GeomDet::toGlobal
GlobalPoint toGlobal(const Local2DPoint &lp) const
Conversion to the global R.F. from the R.F. of the GeomDet.
Definition: GeomDet.h:49
LogDebug
#define LogDebug(id)
Definition: MessageLogger.h:223
CSCTriggerPrimitivesReader::hLctMPCKeyStrip
TH1F * hLctMPCKeyStrip
Definition: CSCTriggerPrimitivesReader.h:347
CSCTriggerPrimitivesReader::calcEfficiency
void calcEfficiency(const CSCALCTDigiCollection *alcts, const CSCCLCTDigiCollection *clcts, const edm::PSimHitContainer &allSimHits)
Definition: CSCTriggerPrimitivesReader.cc:2903
edm::ParameterSet
Definition: ParameterSet.h:47
CSCTriggerPrimitivesReader::eventsAnalyzed
int eventsAnalyzed
Definition: CSCTriggerPrimitivesReader.h:144
CSCTriggerPrimitivesReader::setRootStyle
void setRootStyle()
Definition: CSCTriggerPrimitivesReader.cc:598
MyStubComparison::bend_data
Int_t bend_data
Definition: CSCTriggerPrimitivesReader.h:90
MyStubComparison::firstfill
Bool_t firstfill
Definition: CSCTriggerPrimitivesReader.h:75
CSCTriggerPrimitivesReader::compareCLCTs
void compareCLCTs(const CSCCLCTDigiCollection *clcts_data, const CSCCLCTDigiCollection *clcts_emul, const CSCCLCTPreTriggerDigiCollection *pretrigs_emul)
Definition: CSCTriggerPrimitivesReader.cc:1667
CSCTriggerPrimitivesReader::event_tree
TTree * event_tree[6]
Definition: CSCTriggerPrimitivesReader.h:316
CSCTriggerPrimitivesReader::hClctStripType
TH1F * hClctStripType
Definition: CSCTriggerPrimitivesReader.h:330
CSCTriggerPrimitivesReader::hClctVsPhi
TH1F * hClctVsPhi[MAX_STATIONS]
Definition: CSCTriggerPrimitivesReader.h:440
MyStubComparison::phi_data
Float_t phi_data
Definition: CSCTriggerPrimitivesReader.h:120
CSCTriggerPrimitivesReader::Event_
int Event_
Definition: CSCTriggerPrimitivesReader.h:150
CSCTriggerPrimitivesReader::hClctCompTotalCsc
TH1F * hClctCompTotalCsc[MAX_ENDCAPS][CSC_TYPES]
Definition: CSCTriggerPrimitivesReader.h:420
type
type
Definition: SiPixelVCal_PayloadInspector.cc:37
CSCTriggerPrimitivesReader::hAlctCompSameN2i
TH2F * hAlctCompSameN2i
Definition: CSCTriggerPrimitivesReader.h:360
CSCTriggerPrimitivesReader::plotME1A
bool plotME1A
Definition: CSCTriggerPrimitivesReader.h:166
CSCTriggerPrimitivesReader::hLctMPCStripType
TH1F * hLctMPCStripType
Definition: CSCTriggerPrimitivesReader.h:347
CSCTriggerPrimitivesReader::hLctMPCRing
TH1F * hLctMPCRing
Definition: CSCTriggerPrimitivesReader.h:344
CSCTriggerPrimitivesReader::hLctMPCValid
TH1F * hLctMPCValid
Definition: CSCTriggerPrimitivesReader.h:346
CSCConstants::MAX_HALF_STRIP_ME1B
Definition: CSCConstants.h:39
gainCalibHelper::gainCalibPI::type
type
Definition: SiPixelGainCalibHelper.h:39
CSCTriggerPrimitivesReader::hLctTMBBend
TH1F * hLctTMBBend
Definition: CSCTriggerPrimitivesReader.h:341
CSCTriggerPrimitivesReader::hAlctCompSameNCsc
TH1F * hAlctCompSameNCsc[MAX_ENDCAPS][CSC_TYPES]
Definition: CSCTriggerPrimitivesReader.h:414
CSCDetId
Definition: CSCDetId.h:26
CSCTriggerPrimitivesReader::ptype_TMB07
static const int ptype_TMB07[CSCConstants::NUM_CLCT_PATTERNS]
Definition: CSCTriggerPrimitivesReader.h:218
CSCTriggerPrimitivesReader::hClctCompFoundCsc
TH1F * hClctCompFoundCsc[MAX_ENDCAPS][CSC_TYPES]
Definition: CSCTriggerPrimitivesReader.h:418
PV3DBase::eta
T eta() const
Definition: PV3DBase.h:73
CSCTriggerPrimitivesReader::hLctMPCPerEvent
TH1F * hLctMPCPerEvent
Definition: CSCTriggerPrimitivesReader.h:343
MyStubComparison::bend_pretrig
Int_t bend_pretrig
Definition: CSCTriggerPrimitivesReader.h:99
CSCTriggerPrimitivesReader::numCLCT
static int numCLCT
Definition: CSCTriggerPrimitivesReader.h:225
edm::Service< TFileService >
CSCTriggerPrimitivesReader::hLctCompSameNCsc
TH1F * hLctCompSameNCsc[MAX_ENDCAPS][CSC_TYPES]
Definition: CSCTriggerPrimitivesReader.h:424
CSCTriggerPrimitivesReader::bookedEfficHistos
static bool bookedEfficHistos
Definition: CSCTriggerPrimitivesReader.h:238
CSCTriggerPrimitivesReader::hPhiDiffCsc
TH1F * hPhiDiffCsc[CSC_TYPES][5]
Definition: CSCTriggerPrimitivesReader.h:442
CSCTriggerPrimitivesReader::hResolDeltaHS
TH1F * hResolDeltaHS
Definition: CSCTriggerPrimitivesReader.h:438
iEvent
int iEvent
Definition: GenABIO.cc:224
testProducerWithPsetDescEmpty_cfi.u1
u1
Definition: testProducerWithPsetDescEmpty_cfi.py:49
CSCTriggerPrimitivesReader::hLCTCompSameN2
TH2F * hLCTCompSameN2
Definition: CSCTriggerPrimitivesReader.h:397
alignmentValidation.c1
c1
do drawing
Definition: alignmentValidation.py:1025
CSCTriggerPrimitivesReader::drawLCTTMBHistos
void drawLCTTMBHistos()
Definition: CSCTriggerPrimitivesReader.cc:3270
M_PI
#define M_PI
Definition: BXVectorInputProducer.cc:49
topSingleLeptonDQM_PU_cfi.pattern
pattern
Definition: topSingleLeptonDQM_PU_cfi.py:39
CSCTriggerPrimitivesReader::hClctPerChamber
TH1F * hClctPerChamber
Definition: CSCTriggerPrimitivesReader.h:328
CSCTriggerPrimitivesReader::hAlctPerEvent
TH1F * hAlctPerEvent
Definition: CSCTriggerPrimitivesReader.h:323
CSCTriggerPrimitivesReader::wireDigiProducer_
edm::InputTag wireDigiProducer_
Definition: CSCTriggerPrimitivesReader.h:176
MuonDigiCollection::get
Range get(const IndexType &index) const
return the digis for a given DetUnit
Definition: MuonDigiCollection.h:121
CSCTriggerPrimitivesReader::hAlctCompFound2i
TH2F * hAlctCompFound2i
Definition: CSCTriggerPrimitivesReader.h:355
CSCTriggerPrimitivesReader::hAlctAccel
TH1F * hAlctAccel
Definition: CSCTriggerPrimitivesReader.h:325
CSCTriggerPrimitivesReader::hLctTMBStation
TH1F * hLctTMBStation
Definition: CSCTriggerPrimitivesReader.h:337
CSCDetId::chamber
int chamber() const
Definition: CSCDetId.h:62
TreePerStub::t_EventNumberAnalyzed
Int_t t_EventNumberAnalyzed
Definition: CSCTriggerPrimitivesReader.h:52
CSCTriggerPrimitivesReader::hLctTMBPerEvent
TH1F * hLctTMBPerEvent
Definition: CSCTriggerPrimitivesReader.h:335
CSCTriggerPrimitivesReader::hLctTMBRing
TH1F * hLctTMBRing
Definition: CSCTriggerPrimitivesReader.h:337
CSCTriggerPrimitivesReader::hEtaDiffCsc
TH1F * hEtaDiffCsc[CSC_TYPES][3]
Definition: CSCTriggerPrimitivesReader.h:434
CSCTriggerPrimitivesReader::lcts_mpc_d_token_
edm::EDGetTokenT< CSCCorrelatedLCTDigiCollection > lcts_mpc_d_token_
Definition: CSCTriggerPrimitivesReader.h:186
CSCTriggerPrimitivesReader::hClctCompMatch2i
TH2F * hClctCompMatch2i
Definition: CSCTriggerPrimitivesReader.h:384
CSCTriggerPrimitivesReader::hAlctCsc
TH1F * hAlctCsc[MAX_ENDCAPS][CSC_TYPES]
Definition: CSCTriggerPrimitivesReader.h:324
CSCTriggerPrimitivesReader::bookLCTTMBHistos
void bookLCTTMBHistos()
Definition: CSCTriggerPrimitivesReader.cc:723
CSCTriggerPrimitivesReader::printps
static bool printps
Definition: CSCTriggerPrimitivesReader.h:240
CSCTriggerPrimitivesReader::hClctCompMatch2x
TH2F * hClctCompMatch2x
Definition: CSCTriggerPrimitivesReader.h:383
CSCTriggerPrimitivesReader::hLctTMBKeyGroupME11
TH1F * hLctTMBKeyGroupME11
Definition: CSCTriggerPrimitivesReader.h:454
CSCTriggerPrimitivesReader::bookedLCTTMBHistos
static bool bookedLCTTMBHistos
Definition: CSCTriggerPrimitivesReader.h:232
MyStubComparison::ring
Int_t ring
Definition: CSCTriggerPrimitivesReader.h:82
CSCTriggerPrimitivesReader::MAX_STATIONS
Definition: CSCTriggerPrimitivesReader.h:207
CSCTriggerPrimitivesReader::hClctCsc
TH1F * hClctCsc[MAX_ENDCAPS][CSC_TYPES]
Definition: CSCTriggerPrimitivesReader.h:329
CSCTriggerPrimitivesReader::compare
void compare(const CSCALCTDigiCollection *alcts_data, const CSCALCTDigiCollection *alcts_emul, const CSCCLCTDigiCollection *clcts_data, const CSCCLCTDigiCollection *clcts_emul, const CSCCLCTPreTriggerDigiCollection *pretrigs_emul, const CSCCorrelatedLCTDigiCollection *lcts_data, const CSCCorrelatedLCTDigiCollection *lcts_emul)
Definition: CSCTriggerPrimitivesReader.cc:1373
CSCTriggerPrimitivesReader::NCHAMBERS
static const int NCHAMBERS[CSC_TYPES]
Definition: CSCTriggerPrimitivesReader.h:215
CSCConstants::MAX_HALF_STRIP_ME1A_UNGANGED
Definition: CSCConstants.h:37
CSCCathodeLCTAnalyzer::getSimInfo
std::vector< CSCCathodeLayerInfo > getSimInfo(const CSCCLCTDigi &clct, const CSCDetId &clctId, const CSCComparatorDigiCollection *compdc, const edm::PSimHitContainer *allSimHits)
Definition: CSCCathodeLCTAnalyzer.cc:16
CSCTriggerPrimitivesReader::hClctPerCSC
TH1F * hClctPerCSC
Definition: CSCTriggerPrimitivesReader.h:328
MyStubComparison::key_hs_pretrig
Int_t key_hs_pretrig
Definition: CSCTriggerPrimitivesReader.h:101
DDAxes::phi
CSCTriggerPrimitivesReader::hLctCompFoundCsc
TH1F * hLctCompFoundCsc[MAX_ENDCAPS][CSC_TYPES]
Definition: CSCTriggerPrimitivesReader.h:423
alignmentValidation.fname
string fname
main script
Definition: alignmentValidation.py:959
CSCTriggerPrimitivesReader::drawALCTHistos
void drawALCTHistos()
Definition: CSCTriggerPrimitivesReader.cc:3043
MyStubComparison::maxquality_pretrig
Int_t maxquality_pretrig
Definition: CSCTriggerPrimitivesReader.h:98
CSCTriggerPrimitivesReader::hLCTCompFound
TH1F * hLCTCompFound
Definition: CSCTriggerPrimitivesReader.h:391
MyStubComparison::station
Int_t station
Definition: CSCTriggerPrimitivesReader.h:84
CSCTriggerPrimitivesReader::hEtaRecVsSim
TH2F * hEtaRecVsSim
Definition: CSCTriggerPrimitivesReader.h:430
CSCTriggerPrimitivesReader::hLctMPCStation
TH1F * hLctMPCStation
Definition: CSCTriggerPrimitivesReader.h:344
CSCTriggerPrimitivesReader::lut_wg_vs_hs_me1ag
static const int lut_wg_vs_hs_me1ag[48][2]
Definition: CSCTriggerPrimitivesReader.h:222
CSCGeometry::layer
const CSCLayer * layer(CSCDetId id) const
Return the layer corresponding to given DetId.
Definition: CSCGeometry.cc:105
CSCTriggerPrimitivesReader::hAlctCompMatch
TH1F * hAlctCompMatch
Definition: CSCTriggerPrimitivesReader.h:362
CSCTriggerPrimitivesReader::bookEfficHistos
void bookEfficHistos()
Definition: CSCTriggerPrimitivesReader.cc:1093
TreePerStub::bookTree
TTree * bookTree(TTree *t, const std::string &name="TreePerStub")
Definition: CSCTriggerPrimitivesReader.cc:137
CSCTriggerPrimitivesReader::plotME42
bool plotME42
Definition: CSCTriggerPrimitivesReader.h:169
CSCTriggerPrimitivesReader::hEtaDiffVsEta
TH1F * hEtaDiffVsEta[MAX_STATIONS]
Definition: CSCTriggerPrimitivesReader.h:433
CSCTriggerPrimitivesReader::hResolDeltaEta
TH1F * hResolDeltaEta
Definition: CSCTriggerPrimitivesReader.h:431
qcdUeDQM_cfi.quality
quality
Definition: qcdUeDQM_cfi.py:31
CSCTriggerPrimitivesReader::hAlctCompFound2x
TH2F * hAlctCompFound2x
Definition: CSCTriggerPrimitivesReader.h:354
CSCTriggerPrimitivesReader::numALCT
static int numALCT
Definition: CSCTriggerPrimitivesReader.h:224
CSCTriggerPrimitivesReader::fillALCTHistos
void fillALCTHistos(const CSCALCTDigiCollection *alcts)
Definition: CSCTriggerPrimitivesReader.cc:1125
CSCDetId::endcap
int endcap() const
Definition: CSCDetId.h:85
CSCTriggerPrimitivesReader::hLctTMBEndcap
TH1F * hLctTMBEndcap
Definition: CSCTriggerPrimitivesReader.h:337
MainPageGenerator.page
page
Definition: MainPageGenerator.py:300
TreePerStub::init
void init(int run, int event)
Definition: CSCTriggerPrimitivesReader.cc:123
CSCTriggerPrimitivesReader::hLctTMBQuality
TH1F * hLctTMBQuality
Definition: CSCTriggerPrimitivesReader.h:339
CSCTriggerPrimitivesReader::hAlctCompMatchCsc
TH1F * hAlctCompMatchCsc[MAX_ENDCAPS][CSC_TYPES]
Definition: CSCTriggerPrimitivesReader.h:416
CSCCathodeLCTAnalyzer::nearestHS
int nearestHS(const std::vector< CSCCathodeLayerInfo > &allLayerInfo, double &closestPhi, double &closestEta)
Definition: CSCCathodeLCTAnalyzer.cc:304
CSCAnodeLCTAnalyzer::getWGEta
double getWGEta(const CSCDetId &layerId, const int wiregroup)
Definition: CSCAnodeLCTAnalyzer.cc:331
ev
bool ev
Definition: Hydjet2Hadronizer.cc:95
MyStubComparison::fullbx_data
Int_t fullbx_data
Definition: CSCTriggerPrimitivesReader.h:104
CSCTriggerPrimitivesReader::hAlctCompSameN
TH1F * hAlctCompSameN
Definition: CSCTriggerPrimitivesReader.h:357
MyStubComparison::WGcrossHS_emul
Bool_t WGcrossHS_emul
Definition: CSCTriggerPrimitivesReader.h:109
CSCTriggerPrimitivesReader::hPhiDiffVsStripCsc
TH2F * hPhiDiffVsStripCsc[CSC_TYPES][2]
Definition: CSCTriggerPrimitivesReader.h:443
CSCTriggerPrimitivesReader::hClctValid
TH1F * hClctValid
Definition: CSCTriggerPrimitivesReader.h:330
CSCTriggerPrimitivesReader::hAlctCompFound2
TH2F * hAlctCompFound2
Definition: CSCTriggerPrimitivesReader.h:353
CSCConstants::KEY_CLCT_LAYER
Definition: CSCConstants.h:46
CSCTriggerPrimitivesReader::cscGeomToken_
edm::ESGetToken< CSCGeometry, MuonGeometryRecord > cscGeomToken_
Definition: CSCTriggerPrimitivesReader.h:192
relativeConstraints.ring
ring
Definition: relativeConstraints.py:68
CSCTriggerPrimitivesReader::convertBXofLCT
int convertBXofLCT(const int emul_bx, const CSCDetId &detid, const CSCALCTDigiCollection *alcts_data, const CSCCLCTDigiCollection *clcts_data)
Definition: CSCTriggerPrimitivesReader.cc:2550
CSCTriggerPrimitivesReader::wireDigi_token_
edm::EDGetTokenT< CSCWireDigiCollection > wireDigi_token_
Definition: CSCTriggerPrimitivesReader.h:180
relativeConstraints.chamber
chamber
Definition: relativeConstraints.py:53
CSCTriggerPrimitivesReader::bookedALCTHistos
static bool bookedALCTHistos
Definition: CSCTriggerPrimitivesReader.h:230
CSCTriggerPrimitivesReader::getGlobalPosition
GlobalPoint getGlobalPosition(unsigned int rawId, int keWg, int keyHS) const
Definition: CSCTriggerPrimitivesReader.cc:4634
or
The Signals That Services Can Subscribe To This is based on ActivityRegistry and is current per Services can connect to the signals distributed by the ActivityRegistry in order to monitor the activity of the application Each possible callback has some defined which we here list in angle e< void, edm::EventID const &, edm::Timestamp const & > We also list in braces which AR_WATCH_USING_METHOD_ is used for those or
Definition: Activities.doc:12
edm::ParameterSet::getParameter
T getParameter(std::string const &) const
Definition: ParameterSet.h:303
CSCTriggerPrimitivesReader::simHitProducer_
edm::InputTag simHitProducer_
Definition: CSCTriggerPrimitivesReader.h:175
CSCTriggerPrimitivesReader::bookHotWireHistos
void bookHotWireHistos()
Definition: CSCTriggerPrimitivesReader.cc:630
CSCTriggerPrimitivesReader::hClctQuality
TH1F * hClctQuality
Definition: CSCTriggerPrimitivesReader.h:330
CSCTriggerPrimitivesReader::hCorrLctTMBPerCSC
TH1F * hCorrLctTMBPerCSC
Definition: CSCTriggerPrimitivesReader.h:336
MyStubComparison::trknmb_data
Int_t trknmb_data
Definition: CSCTriggerPrimitivesReader.h:114
CSCCathodeLCTAnalyzer::setGeometry
void setGeometry(const CSCGeometry *geom)
Definition: CSCCathodeLCTAnalyzer.cc:399
MyStubComparison::fullbx_emul
Int_t fullbx_emul
Definition: CSCTriggerPrimitivesReader.h:105
CSCTriggerPrimitivesReader::alcts_d_token_
edm::EDGetTokenT< CSCALCTDigiCollection > alcts_d_token_
Definition: CSCTriggerPrimitivesReader.h:183
CSCTriggerPrimitivesReader::perStub
TreePerStub perStub[6]
Definition: CSCTriggerPrimitivesReader.h:315
MyStubComparison::has_data
Bool_t has_data
Definition: CSCTriggerPrimitivesReader.h:86
CSCTriggerPrimitivesReader::hClctPattern
TH1F * hClctPattern[2]
Definition: CSCTriggerPrimitivesReader.h:332
funct::abs
Abs< T >::type abs(const T &t)
Definition: Abs.h:22
LogTrace
#define LogTrace(id)
Definition: MessageLogger.h:224
MyStubComparison::endcap
Int_t endcap
Definition: CSCTriggerPrimitivesReader.h:83
CSCTriggerPrimitivesReader::compareLCTs
void compareLCTs(const CSCCorrelatedLCTDigiCollection *lcts_data, const CSCCorrelatedLCTDigiCollection *lcts_emul, const CSCALCTDigiCollection *alcts_data, const CSCCLCTDigiCollection *clcts_data)
Definition: CSCTriggerPrimitivesReader.cc:2019
edm::PSimHitContainer
std::vector< PSimHit > PSimHitContainer
Definition: PSimHitContainer.h:11
CSCConstants::NUM_CLCT_PATTERNS
Definition: CSCConstants.h:52
CSCTriggerPrimitivesReader::hEfficHitsEtaCsc
TH1F * hEfficHitsEtaCsc[CSC_TYPES]
Definition: CSCTriggerPrimitivesReader.h:449
CSCDetId::station
int station() const
Definition: CSCDetId.h:79
CSCTriggerPrimitivesReader::hClctSign
TH1F * hClctSign
Definition: CSCTriggerPrimitivesReader.h:330
CSCTriggerPrimitivesReader::calcResolution
void calcResolution(const CSCALCTDigiCollection *alcts, const CSCCLCTDigiCollection *clcts, const CSCWireDigiCollection *wiredc, const CSCComparatorDigiCollection *compdc, const edm::PSimHitContainer &allSimHits)
Definition: CSCTriggerPrimitivesReader.cc:2712
CSCTriggerPrimitivesReader::hLctMPCSector
TH1F * hLctMPCSector
Definition: CSCTriggerPrimitivesReader.h:344
CSCTriggerPrimitivesReader::csc_type_plus
static const std::string csc_type_plus[CSC_TYPES]
Definition: CSCTriggerPrimitivesReader.h:213
MyStubComparison::key_hs_data
Int_t key_hs_data
Definition: CSCTriggerPrimitivesReader.h:112
dqmiolumiharvest.j
j
Definition: dqmiolumiharvest.py:66
CSCTriggerPrimitivesReader::stub_tree
TTree * stub_tree[4]
Definition: CSCTriggerPrimitivesReader.h:313
edm::HandleBase::isValid
bool isValid() const
Definition: HandleBase.h:70
MetAnalyzer.u2
u2
Definition: MetAnalyzer.py:61
MyStubComparison::trknmb_emul
Int_t trknmb_emul
Definition: CSCTriggerPrimitivesReader.h:115
CSCTriggerPrimitivesReader::lcts_tmb_d_token_
edm::EDGetTokenT< CSCCorrelatedLCTDigiCollection > lcts_tmb_d_token_
Definition: CSCTriggerPrimitivesReader.h:185
MyStubComparison::chambertype
Int_t chambertype
Definition: CSCTriggerPrimitivesReader.h:85
CSCTriggerPrimitivesReader::drawResolHistos
void drawResolHistos()
Definition: CSCTriggerPrimitivesReader.cc:3862
CSCTriggerPrimitivesReader::HotWires
void HotWires(const edm::Event &iEvent)
Definition: CSCTriggerPrimitivesReader.cc:2595
triggerCscId
Int_t triggerCscId(Int_t station, Int_t ring, Int_t chamber) const
Definition: triggerCscIdSector.h:21
CSCTriggerPrimitivesReader::hLctMPCPerCSC
TH1F * hLctMPCPerCSC
Definition: CSCTriggerPrimitivesReader.h:343
submitPVValidationJobs.t
string t
Definition: submitPVValidationJobs.py:644
MyStubComparison::phi_emul
Float_t phi_emul
Definition: CSCTriggerPrimitivesReader.h:121
MyStubComparison::init
void init(int run, int event)
Definition: CSCTriggerPrimitivesReader.cc:160
CSCTriggerPrimitivesReader::hLCTCompTotal2
TH2F * hLCTCompTotal2
Definition: CSCTriggerPrimitivesReader.h:407
edm::InputTag
Definition: InputTag.h:15
CSCTriggerPrimitivesReader::MAX_WG
static const int MAX_WG[CSC_TYPES]
Definition: CSCTriggerPrimitivesReader.h:216
MyStubComparison::pattern_pretrig
Int_t pattern_pretrig
Definition: CSCTriggerPrimitivesReader.h:102
CSCTriggerPrimitivesReader::hLctTMBBXN
TH1F * hLctTMBBXN
Definition: CSCTriggerPrimitivesReader.h:341
MyStubComparison::eta_emul
Float_t eta_emul
Definition: CSCTriggerPrimitivesReader.h:119
TreePerStub::t_nStubs_readout
Int_t t_nStubs_readout
Definition: CSCTriggerPrimitivesReader.h:56
CSCGeometry::chamber
const CSCChamber * chamber(CSCDetId id) const
Return the chamber corresponding to given DetId.
Definition: CSCGeometry.cc:100
CSCConstants::MAX_HALF_STRIP_ME1A_GANGED
Definition: CSCConstants.h:35
CSCAnodeLCTAnalyzer
Definition: CSCAnodeLCTAnalyzer.h:25
CSCTriggerPrimitivesReader::dataIsAnotherMC_
bool dataIsAnotherMC_
Definition: CSCTriggerPrimitivesReader.h:202
CSCTriggerPrimitivesReader::doesALCTCrossCLCT
bool doesALCTCrossCLCT(CSCDetId id, int key_wg, int key_hs) const
Definition: CSCTriggerPrimitivesReader.cc:4655
CSCTriggerPrimitivesReader::hLctTMBKeyGroup
TH1F * hLctTMBKeyGroup
Definition: CSCTriggerPrimitivesReader.h:339
CSCTriggerPrimitivesReader::hLctTMBKeyStripME11
TH1F * hLctTMBKeyStripME11
Definition: CSCTriggerPrimitivesReader.h:455
MyStubComparison::bx_pretrig
Int_t bx_pretrig
Definition: CSCTriggerPrimitivesReader.h:100
TFileService::make
T * make(const Args &... args) const
make new ROOT object
Definition: TFileService.h:64
MyStubComparison::totStubs_data
Int_t totStubs_data
Definition: CSCTriggerPrimitivesReader.h:76
CSCTriggerPrimitivesReader::hLCTCompMatch2
TH2F * hLCTCompMatch2
Definition: CSCTriggerPrimitivesReader.h:402
triggerSector
Int_t triggerSector(Int_t station, Int_t ring, Int_t chamber) const
Definition: triggerCscIdSector.h:3
CSCTriggerPrimitivesReader::bookALCTHistos
void bookALCTHistos()
Definition: CSCTriggerPrimitivesReader.cc:637
CSCCathodeLCTAnalyzer
Definition: CSCCathodeLCTAnalyzer.h:25
CSCTriggerPrimitivesReader::geom_
const CSCGeometry * geom_
Definition: CSCTriggerPrimitivesReader.h:153
MyStubComparison::quality_pretrig
Int_t quality_pretrig
Definition: CSCTriggerPrimitivesReader.h:97
CSCTriggerPrimitivesReader::lcts_mpc_e_token_
edm::EDGetTokenT< CSCCorrelatedLCTDigiCollection > lcts_mpc_e_token_
Definition: CSCTriggerPrimitivesReader.h:191
CSCTriggerPrimitivesReader::csc_type
static const std::string csc_type[CSC_TYPES]
Definition: CSCTriggerPrimitivesReader.h:212
CSCTriggerPrimitivesReader::hClctCompSameN2
TH2F * hClctCompSameN2
Definition: CSCTriggerPrimitivesReader.h:377
CSCTriggerPrimitivesReader::RUN_
int RUN_
Definition: CSCTriggerPrimitivesReader.h:149
CSCTriggerPrimitivesReader::hResolDeltaPhi
TH1F * hResolDeltaPhi
Definition: CSCTriggerPrimitivesReader.h:439
CSCTriggerPrimitivesReader::hAlctCompSameN2x
TH2F * hAlctCompSameN2x
Definition: CSCTriggerPrimitivesReader.h:359