CMS 3D CMS Logo

List of all members | Public Member Functions | Static Public Member Functions | Protected Member Functions | Static Private Member Functions | Private Attributes
BPHMonitor Class Reference

#include <BPHMonitor.h>

Inheritance diagram for BPHMonitor:
DQMEDAnalyzer edm::one::EDProducer< edm::Accumulator, edm::EndLuminosityBlockProducer, edm::EndRunProducer, edm::one::WatchLuminosityBlocks, edm::one::WatchRuns > edm::one::EDProducerBase edm::ProducerBase edm::EDConsumerBase edm::ProductRegistryHelper

Public Member Functions

 BPHMonitor (const edm::ParameterSet &)
 
void case11_selection (const float &dimuonCL, const float &jpsi_cos, const GlobalPoint &displacementFromBeamspotJpsi, const GlobalError &jerr, const edm::Handle< reco::TrackCollection > &trHandle, const std::string &hltpath, const edm::Handle< trigger::TriggerEvent > &handleTriggerEvent, const reco::Muon &m, const reco::Muon &m1, const edm::ESHandle< MagneticField > &bFieldHandle, const reco::BeamSpot &vertexBeamSpot, MonitorElement *phi1, MonitorElement *eta1, MonitorElement *pT1, MonitorElement *phi2, MonitorElement *eta2, MonitorElement *pT2)
 
 ~BPHMonitor () override
 
- Public Member Functions inherited from DQMEDAnalyzer
void accumulate (edm::Event const &ev, edm::EventSetup const &es) final
 
void beginLuminosityBlock (edm::LuminosityBlock const &lumi, edm::EventSetup const &setup) override
 
void beginRun (edm::Run const &run, edm::EventSetup const &setup) final
 
virtual void dqmBeginRun (edm::Run const &, edm::EventSetup const &)
 
 DQMEDAnalyzer ()
 
 DQMEDAnalyzer (DQMEDAnalyzer const &)=delete
 
 DQMEDAnalyzer (DQMEDAnalyzer &&)=delete
 
void endLuminosityBlock (edm::LuminosityBlock const &, edm::EventSetup const &) override
 
void endLuminosityBlockProduce (edm::LuminosityBlock &lumi, edm::EventSetup const &setup) final
 
void endRun (edm::Run const &run, edm::EventSetup const &setup) override
 
void endRunProduce (edm::Run &run, edm::EventSetup const &setup) override
 
 ~DQMEDAnalyzer () override=default
 
- Public Member Functions inherited from edm::one::EDProducer< edm::Accumulator, edm::EndLuminosityBlockProducer, edm::EndRunProducer, edm::one::WatchLuminosityBlocks, edm::one::WatchRuns >
 EDProducer ()=default
 
SerialTaskQueueglobalLuminosityBlocksQueue () final
 
SerialTaskQueueglobalRunsQueue () final
 
bool hasAbilityToProduceInLumis () const final
 
bool hasAbilityToProduceInRuns () const final
 
bool wantsGlobalLuminosityBlocks () const final
 
bool wantsGlobalRuns () const final
 
- Public Member Functions inherited from edm::one::EDProducerBase
 EDProducerBase ()
 
ModuleDescription const & moduleDescription () const
 
bool wantsStreamLuminosityBlocks () const
 
bool wantsStreamRuns () const
 
 ~EDProducerBase () override
 
- Public Member Functions inherited from edm::ProducerBase
void callWhenNewProductsRegistered (std::function< void(BranchDescription const &)> const &func)
 
std::vector< edm::ProductResolverIndex > const & indiciesForPutProducts (BranchType iBranchType) const
 
 ProducerBase ()
 
std::vector< edm::ProductResolverIndex > const & putTokenIndexToProductResolverIndex () const
 
void registerProducts (ProducerBase *, ProductRegistry *, ModuleDescription const &)
 
std::function< void(BranchDescription const &)> registrationCallback () const
 used by the fwk to register list of products More...
 
void resolvePutIndicies (BranchType iBranchType, ModuleToResolverIndicies const &iIndicies, std::string const &moduleLabel)
 
 ~ProducerBase () noexcept(false) 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 const &)=delete
 
 EDConsumerBase (EDConsumerBase &&)=default
 
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
 
EDConsumerBase const & operator= (EDConsumerBase const &)=delete
 
EDConsumerBaseoperator= (EDConsumerBase &&)=default
 
bool registeredToConsume (ProductResolverIndex, bool, BranchType) const
 
bool registeredToConsumeMany (TypeID const &, BranchType) const
 
ProductResolverIndexAndSkipBit uncheckedIndexFrom (EDGetToken) const
 
void updateLookup (BranchType iBranchType, ProductResolverIndexHelper const &, bool iPrefetchMayGet)
 
virtual ~EDConsumerBase () noexcept(false)
 

Static Public Member Functions

static void fillDescriptions (edm::ConfigurationDescriptions &descriptions)
 
static void fillHistoLSPSetDescription (edm::ParameterSetDescription &pset)
 
static void fillHistoPSetDescription (edm::ParameterSetDescription &pset)
 
- Static Public Member Functions inherited from edm::one::EDProducerBase
static const std::string & baseType ()
 
static void fillDescriptions (ConfigurationDescriptions &descriptions)
 
static void prevalidate (ConfigurationDescriptions &descriptions)
 

Protected Member Functions

void analyze (edm::Event const &iEvent, edm::EventSetup const &iSetup) override
 
void bookHistograms (DQMStore::IBooker &, edm::Run const &, edm::EventSetup const &) override
 
void bookME (DQMStore::IBooker &, METME &me, std::string &histname, std::string &histtitle, int &nbins, double &xmin, double &xmax)
 
void bookME (DQMStore::IBooker &, METME &me, std::string &histname, std::string &histtitle, std::vector< double > binningX)
 
void bookME (DQMStore::IBooker &, METME &me, std::string &histname, std::string &histtitle, int &nbinsX, double &xmin, double &xmax, double &ymin, double &ymax)
 
void bookME (DQMStore::IBooker &, METME &me, std::string &histname, std::string &histtitle, int &nbinsX, double &xmin, double &xmax, int &nbinsY, double &ymin, double &ymax)
 
void bookME (DQMStore::IBooker &, METME &me, std::string &histname, std::string &histtitle, std::vector< double > binningX, std::vector< double > binningY)
 
void bookME (DQMStore::IBooker &, METME &me, std::string &histname, std::string &histtitle, MEbinning &binning)
 
template<typename T >
bool matchToTrigger (const std::string &theTriggerName, T t, edm::Handle< trigger::TriggerEvent > handleTriggerEvent)
 
void setMETitle (METME &me, std::string titleX, std::string titleY)
 
- Protected Member Functions inherited from edm::EDConsumerBase
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > consumes (edm::InputTag const &tag)
 
EDGetToken consumes (const TypeToGet &id, edm::InputTag const &tag)
 
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 ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > mayConsume (edm::InputTag const &tag)
 
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 
template<BranchType B>
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 

Static Private Member Functions

static MEbinning getHistoPSet (edm::ParameterSet pset)
 

Private Attributes

edm::InputTag bsInputTag_
 
edm::EDGetTokenT< reco::BeamSpotbsToken_
 
MEbinning cos_binning_
 
MEbinning d0_binning_
 
MEbinning dca_binning_
 
GenericTriggerEventFlagden_genTriggerEventFlag_
 
METME DiMuDCA_
 
METME DiMudR_
 
METME DiMuDS_
 
METME DiMuEta_
 
METME DiMuMass_
 
METME DiMuPhi_
 
METME DiMuProb_
 
METME DiMuPt_
 
METME DiMuPVcos_
 
StringCutObjectSelector< reco::Candidate::LorentzVector, true > DMSelection_ref
 
MEbinning dR_binning_
 
MEbinning ds_binning_
 
int enum_
 
MEbinning eta_binning_
 
std::string folderName_
 
std::string histoSuffix_
 
edm::EDGetTokenT< trigger::TriggerEventhltInputTag_
 
std::vector< std::string > hltpaths_den
 
std::vector< std::string > hltpaths_num
 
edm::EDGetTokenT< edm::TriggerResultshltTrigResTag_
 
int Jpsi_
 
double kaon_mass
 
int L3_
 
MEbinning mass_binning_
 
double maxmass_
 
double maxmassJpsi
 
double maxmassJpsiTk
 
double maxmassTkTk
 
double maxmassUpsilon
 
double min_dR
 
double mincos
 
double minDS
 
double minmass_
 
double minmassJpsi
 
double minmassJpsiTk
 
double minmassTkTk
 
double minmassUpsilon
 
double minprob
 
METME mu1d0_
 
METME mu1Eta_
 
METME mu1Phi_
 
METME mu1Pt_
 
METME mu1z0_
 
METME mu2d0_
 
METME mu2Eta_
 
METME mu2Phi_
 
METME mu2Pt_
 
METME mu2z0_
 
METME mu3d0_
 
METME mu3Eta_
 
METME mu3Phi_
 
METME mu3Pt_
 
METME mu3z0_
 
double mu_mass
 
METME mud0_
 
METME muEta_
 
edm::InputTag muoInputTag_
 
StringCutObjectSelector< reco::Muon, true > muoSelection_
 
StringCutObjectSelector< reco::Muon, true > muoSelection_probe
 
StringCutObjectSelector< reco::Muon, true > muoSelection_ref
 
StringCutObjectSelector< reco::Muon, true > muoSelection_tag
 
edm::EDGetTokenT< reco::MuonCollectionmuoToken_
 
METME muPhi_
 
METME muPt_
 
METME muz0_
 
int nmuons_
 
GenericTriggerEventFlagnum_genTriggerEventFlag_
 
METME phEta_
 
MEbinning phi_binning_
 
edm::InputTag phInputTag_
 
METME phPhi_
 
METME phPt_
 
edm::EDGetTokenT< reco::PhotonCollectionphToken_
 
MEbinning prob_binning_
 
MEbinning pt_binning_
 
int seagull_
 
bool tnp_
 
edm::InputTag trInputTag_
 
int trOrMu_
 
StringCutObjectSelector< reco::Track, true > trSelection_
 
StringCutObjectSelector< reco::Track, true > trSelection_ref
 
edm::EDGetTokenT< reco::TrackCollectiontrToken_
 
int Upsilon_
 
std::vector< bool > warningPrinted4token_
 
MEbinning z0_binning_
 

Additional Inherited Members

- Public Types inherited from edm::one::EDProducerBase
typedef EDProducerBase ModuleType
 
- Public Types inherited from edm::ProducerBase
using ModuleToResolverIndicies = std::unordered_multimap< std::string, std::tuple< edm::TypeID const *, const char *, edm::ProductResolverIndex >>
 
typedef ProductRegistryHelper::TypeLabelList TypeLabelList
 
- Public Types inherited from edm::EDConsumerBase
typedef ProductLabels Labels
 
- Protected Attributes inherited from DQMEDAnalyzer
edm::EDPutTokenT< DQMTokenlumiToken_
 
edm::EDPutTokenT< DQMTokenrunToken_
 

Detailed Description

Definition at line 68 of file BPHMonitor.h.

Constructor & Destructor Documentation

BPHMonitor::BPHMonitor ( const edm::ParameterSet iConfig)

Definition at line 12 of file BPHMonitor.cc.

References METME::denominator, DiMuDCA_, DiMudR_, DiMuDS_, DiMuEta_, DiMuMass_, DiMuPhi_, DiMuProb_, DiMuPt_, DiMuPVcos_, mu1Eta_, mu1Phi_, mu1Pt_, mu2Eta_, mu2Phi_, mu2Pt_, mu3Eta_, mu3Phi_, mu3Pt_, mud0_, muEta_, muPhi_, muPt_, muz0_, METME::numerator, phEta_, phPhi_, phPt_, and warningPrinted4token_.

12  :
13  folderName_ ( iConfig.getParameter<std::string>("FolderName") )
14  , muoInputTag_ ( iConfig.getParameter<edm::InputTag>("muons") )
15  , bsInputTag_ ( iConfig.getParameter<edm::InputTag>("beamSpot") )
16  , trInputTag_ ( iConfig.getParameter<edm::InputTag>("tracks") )
17  , phInputTag_ ( iConfig.getParameter<edm::InputTag>("photons") )
18  , muoToken_ ( mayConsume<reco::MuonCollection> ( muoInputTag_ ) )
19  , bsToken_ ( mayConsume<reco::BeamSpot> ( bsInputTag_ ) )
20  , trToken_ ( mayConsume<reco::TrackCollection> ( trInputTag_ ) )
21  , phToken_ ( mayConsume<reco::PhotonCollection> ( phInputTag_ ) )
22  , phi_binning_ ( getHistoPSet (iConfig.getParameter<edm::ParameterSet>("histoPSet").getParameter<edm::ParameterSet> ("phiPSet") ) )
23  , pt_binning_ ( getHistoPSet (iConfig.getParameter<edm::ParameterSet>("histoPSet").getParameter<edm::ParameterSet> ("ptPSet") ) )
24  , eta_binning_ ( getHistoPSet (iConfig.getParameter<edm::ParameterSet>("histoPSet").getParameter<edm::ParameterSet> ("etaPSet") ) )
25  , d0_binning_ ( getHistoPSet (iConfig.getParameter<edm::ParameterSet>("histoPSet").getParameter<edm::ParameterSet> ("d0PSet") ) )
26  , z0_binning_ ( getHistoPSet (iConfig.getParameter<edm::ParameterSet>("histoPSet").getParameter<edm::ParameterSet> ("z0PSet") ) )
27  , dR_binning_ ( getHistoPSet (iConfig.getParameter<edm::ParameterSet>("histoPSet").getParameter<edm::ParameterSet> ("dRPSet") ) )
28  , mass_binning_ ( getHistoPSet (iConfig.getParameter<edm::ParameterSet>("histoPSet").getParameter<edm::ParameterSet> ("massPSet") ) )
29  , dca_binning_ ( getHistoPSet (iConfig.getParameter<edm::ParameterSet>("histoPSet").getParameter<edm::ParameterSet> ("dcaPSet") ) )
30  , ds_binning_ ( getHistoPSet (iConfig.getParameter<edm::ParameterSet>("histoPSet").getParameter<edm::ParameterSet> ("dsPSet") ) )
31  , cos_binning_ ( getHistoPSet (iConfig.getParameter<edm::ParameterSet>("histoPSet").getParameter<edm::ParameterSet> ("cosPSet") ) )
32  , prob_binning_ ( getHistoPSet (iConfig.getParameter<edm::ParameterSet>("histoPSet").getParameter<edm::ParameterSet> ("probPSet") ) )
33  , num_genTriggerEventFlag_(new GenericTriggerEventFlag(iConfig.getParameter<edm::ParameterSet>("numGenericTriggerEventPSet"),consumesCollector(), *this))
34  , den_genTriggerEventFlag_(new GenericTriggerEventFlag(iConfig.getParameter<edm::ParameterSet>("denGenericTriggerEventPSet"),consumesCollector(), *this))
35  , muoSelection_ ( iConfig.getParameter<std::string>("muoSelection") )
36  , muoSelection_ref ( iConfig.getParameter<std::string>("muoSelection_ref") )
37  , muoSelection_tag ( iConfig.getParameter<std::string>("muoSelection_tag") )
38  , muoSelection_probe ( iConfig.getParameter<std::string>("muoSelection_probe") )
39  , nmuons_ ( iConfig.getParameter<int>("nmuons" ) )
40  , tnp_ ( iConfig.getParameter<bool>("tnp" ) )
41  , L3_ ( iConfig.getParameter<int>("L3" ) )
42  , trOrMu_ ( iConfig.getParameter<int>("trOrMu" ) )
43  , Jpsi_ ( iConfig.getParameter<int>("Jpsi" ) )
44  , Upsilon_ ( iConfig.getParameter<int>("Upsilon" ) ) // if ==1 path with Upsilon constraint
45  , enum_ ( iConfig.getParameter<int>("enum" ) )
46  , seagull_ ( iConfig.getParameter<int>("seagull" ) )
47  , maxmass_ ( iConfig.getParameter<double>("maxmass" ) )
48  , minmass_ ( iConfig.getParameter<double>("minmass" ) )
49  , maxmassJpsi ( iConfig.getParameter<double>("maxmassJpsi" ) )
50  , minmassJpsi ( iConfig.getParameter<double>("minmassJpsi" ) )
51  , maxmassUpsilon ( iConfig.getParameter<double>("maxmassUpsilon" ) )
52  , minmassUpsilon ( iConfig.getParameter<double>("minmassUpsilon" ) )
53  , maxmassTkTk ( iConfig.getParameter<double>("maxmassTkTk" ) )
54  , minmassTkTk ( iConfig.getParameter<double>("minmassTkTk" ) )
55  , maxmassJpsiTk ( iConfig.getParameter<double>("maxmassJpsiTk" ) )
56  , minmassJpsiTk ( iConfig.getParameter<double>("minmassJpsiTk" ) )
57  , kaon_mass ( iConfig.getParameter<double>("kaon_mass" ) )
58  , mu_mass ( iConfig.getParameter<double>("mu_mass" ) )
59  , min_dR ( iConfig.getParameter<double>("min_dR" ) )
60  , minprob ( iConfig.getParameter<double>("minprob" ) )
61  , mincos ( iConfig.getParameter<double>("mincos" ) )
62  , minDS ( iConfig.getParameter<double>("minDS" ) )
63  , hltTrigResTag_ (mayConsume<edm::TriggerResults>( iConfig.getParameter<edm::ParameterSet>("denGenericTriggerEventPSet").getParameter<edm::InputTag>("hltInputTag")))
64  , hltInputTag_ (mayConsume<trigger::TriggerEvent>( iConfig.getParameter<edm::InputTag>("hltTriggerSummaryAOD"))) /* mia : you should make it configurable !!!" */
65  , hltpaths_num ( iConfig.getParameter<edm::ParameterSet>("numGenericTriggerEventPSet").getParameter<std::vector<std::string>>("hltPaths"))
66  , hltpaths_den ( iConfig.getParameter<edm::ParameterSet>("denGenericTriggerEventPSet").getParameter<std::vector<std::string>>("hltPaths"))
67  , trSelection_ ( iConfig.getParameter<std::string>("muoSelection") )
68  , trSelection_ref ( iConfig.getParameter<std::string>("trSelection_ref") )
69  , DMSelection_ref ( iConfig.getParameter<std::string>("DMSelection_ref") )
70 {
71 
72  muPhi_.numerator = nullptr;
73  muPhi_.denominator = nullptr;
74  muEta_.numerator = nullptr;
75  muEta_.denominator = nullptr;
76  muPt_.numerator = nullptr;
77  muPt_.denominator = nullptr;
78  mud0_.numerator = nullptr;
79  mud0_.denominator = nullptr;
80  muz0_.numerator = nullptr;
81  muz0_.denominator = nullptr;
82 
83  mu1Phi_.numerator = nullptr;
84  mu1Phi_.denominator = nullptr;
85  mu1Eta_.numerator = nullptr;
86  mu1Eta_.denominator = nullptr;
87  mu1Pt_.numerator = nullptr;
88  mu1Pt_.denominator = nullptr;
89 
90  mu2Phi_.numerator = nullptr;
91  mu2Phi_.denominator = nullptr;
92  mu2Eta_.numerator = nullptr;
93  mu2Eta_.denominator = nullptr;
94  mu2Pt_.numerator = nullptr;
95  mu2Pt_.denominator = nullptr;
96 
97  mu3Phi_.numerator = nullptr;
98  mu3Phi_.denominator = nullptr;
99  mu3Eta_.numerator = nullptr;
100  mu3Eta_.denominator = nullptr;
101  mu3Pt_.numerator = nullptr;
102  mu3Pt_.denominator = nullptr;
103 
104  phPhi_.numerator = nullptr;
105  phPhi_.denominator = nullptr;
106  phEta_.numerator = nullptr;
107  phEta_.denominator = nullptr;
108  phPt_.numerator = nullptr;
109  phPt_.denominator = nullptr;
110 
111 
112  DiMuPhi_.numerator = nullptr;
113  DiMuPhi_.denominator = nullptr;
114  DiMuEta_.numerator = nullptr;
115  DiMuEta_.denominator = nullptr;
116  DiMuPt_.numerator = nullptr;
117  DiMuPt_.denominator = nullptr;
118  DiMuPVcos_.numerator = nullptr;
119  DiMuPVcos_.denominator = nullptr;
120  DiMuProb_.numerator = nullptr;
121  DiMuProb_.denominator = nullptr;
122  DiMuDS_.numerator = nullptr;
123  DiMuDS_.denominator = nullptr;
124  DiMuDCA_.numerator = nullptr;
125  DiMuDCA_.denominator = nullptr;
126  DiMuMass_.numerator = nullptr;
127  DiMuMass_.denominator = nullptr;
128  DiMudR_.numerator = nullptr;
129  DiMudR_.denominator = nullptr;
130 
131 
132  // this vector has to be alligned to the the number of Tokens accessed by this module
133  warningPrinted4token_.push_back(false); // MuonCollection
134  warningPrinted4token_.push_back(false); // BeamSpot
135  warningPrinted4token_.push_back(false); // TrackCollection
136  warningPrinted4token_.push_back(false); // PhotonCollection
137 
138 }
MEbinning z0_binning_
Definition: BPHMonitor.h:119
int seagull_
Definition: BPHMonitor.h:180
MonitorElement * numerator
Definition: BPHMonitor.h:60
T getParameter(std::string const &) const
METME mu2Phi_
Definition: BPHMonitor.h:138
int Upsilon_
Definition: BPHMonitor.h:178
METME DiMuDCA_
Definition: BPHMonitor.h:160
METME phEta_
Definition: BPHMonitor.h:152
StringCutObjectSelector< reco::Muon, true > muoSelection_tag
Definition: BPHMonitor.h:171
METME phPt_
Definition: BPHMonitor.h:153
StringCutObjectSelector< reco::Candidate::LorentzVector, true > DMSelection_ref
Definition: BPHMonitor.h:204
double maxmassJpsiTk
Definition: BPHMonitor.h:189
double kaon_mass
Definition: BPHMonitor.h:191
METME mu2Pt_
Definition: BPHMonitor.h:140
METME muPt_
Definition: BPHMonitor.h:129
METME mu1Eta_
Definition: BPHMonitor.h:134
METME phPhi_
Definition: BPHMonitor.h:151
edm::EDGetTokenT< reco::MuonCollection > muoToken_
Definition: BPHMonitor.h:110
edm::InputTag bsInputTag_
Definition: BPHMonitor.h:106
std::string folderName_
Definition: BPHMonitor.h:102
METME mu2Eta_
Definition: BPHMonitor.h:139
METME DiMuPhi_
Definition: BPHMonitor.h:154
METME mu3Pt_
Definition: BPHMonitor.h:145
Provides a code based selection for trigger and DCS information in order to have no failing filters i...
MEbinning eta_binning_
Definition: BPHMonitor.h:117
edm::EDGetTokenT< trigger::TriggerEvent > hltInputTag_
Definition: BPHMonitor.h:199
double maxmassTkTk
Definition: BPHMonitor.h:187
edm::EDGetTokenT< reco::TrackCollection > trToken_
Definition: BPHMonitor.h:112
double minmass_
Definition: BPHMonitor.h:182
double minprob
Definition: BPHMonitor.h:195
METME mu1Phi_
Definition: BPHMonitor.h:133
METME DiMuEta_
Definition: BPHMonitor.h:155
MEbinning dca_binning_
Definition: BPHMonitor.h:122
MEbinning pt_binning_
Definition: BPHMonitor.h:116
double mincos
Definition: BPHMonitor.h:196
double maxmassJpsi
Definition: BPHMonitor.h:183
std::vector< bool > warningPrinted4token_
Definition: BPHMonitor.h:206
edm::InputTag muoInputTag_
Definition: BPHMonitor.h:105
ConsumesCollector consumesCollector()
Use a ConsumesCollector to gather consumes information from helper functions.
MEbinning dR_binning_
Definition: BPHMonitor.h:120
double mu_mass
Definition: BPHMonitor.h:192
GenericTriggerEventFlag * den_genTriggerEventFlag_
Definition: BPHMonitor.h:168
MonitorElement * denominator
Definition: BPHMonitor.h:61
METME DiMuDS_
Definition: BPHMonitor.h:159
MEbinning phi_binning_
Definition: BPHMonitor.h:115
MEbinning ds_binning_
Definition: BPHMonitor.h:123
edm::EDGetTokenT< edm::TriggerResults > hltTrigResTag_
Definition: BPHMonitor.h:198
StringCutObjectSelector< reco::Track, true > trSelection_
Definition: BPHMonitor.h:202
double maxmass_
Definition: BPHMonitor.h:181
MEbinning prob_binning_
Definition: BPHMonitor.h:125
MEbinning cos_binning_
Definition: BPHMonitor.h:124
std::vector< std::string > hltpaths_den
Definition: BPHMonitor.h:201
StringCutObjectSelector< reco::Muon, true > muoSelection_
Definition: BPHMonitor.h:169
METME muz0_
Definition: BPHMonitor.h:131
METME DiMuProb_
Definition: BPHMonitor.h:158
MEbinning d0_binning_
Definition: BPHMonitor.h:118
double minmassJpsiTk
Definition: BPHMonitor.h:190
edm::EDGetTokenT< reco::PhotonCollection > phToken_
Definition: BPHMonitor.h:113
edm::EDGetTokenT< reco::BeamSpot > bsToken_
Definition: BPHMonitor.h:111
double minDS
Definition: BPHMonitor.h:197
StringCutObjectSelector< reco::Muon, true > muoSelection_ref
Definition: BPHMonitor.h:170
double minmassUpsilon
Definition: BPHMonitor.h:186
static MEbinning getHistoPSet(edm::ParameterSet pset)
Definition: BPHMonitor.cc:146
StringCutObjectSelector< reco::Muon, true > muoSelection_probe
Definition: BPHMonitor.h:172
double maxmassUpsilon
Definition: BPHMonitor.h:185
double minmassTkTk
Definition: BPHMonitor.h:188
METME muEta_
Definition: BPHMonitor.h:128
edm::InputTag trInputTag_
Definition: BPHMonitor.h:107
METME DiMuMass_
Definition: BPHMonitor.h:161
METME DiMuPt_
Definition: BPHMonitor.h:156
MEbinning mass_binning_
Definition: BPHMonitor.h:121
METME mud0_
Definition: BPHMonitor.h:130
METME mu1Pt_
Definition: BPHMonitor.h:135
METME mu3Phi_
Definition: BPHMonitor.h:143
std::vector< std::string > hltpaths_num
Definition: BPHMonitor.h:200
METME mu3Eta_
Definition: BPHMonitor.h:144
double minmassJpsi
Definition: BPHMonitor.h:184
edm::InputTag phInputTag_
Definition: BPHMonitor.h:108
METME DiMuPVcos_
Definition: BPHMonitor.h:157
METME DiMudR_
Definition: BPHMonitor.h:162
GenericTriggerEventFlag * num_genTriggerEventFlag_
Definition: BPHMonitor.h:167
METME muPhi_
Definition: BPHMonitor.h:127
StringCutObjectSelector< reco::Track, true > trSelection_ref
Definition: BPHMonitor.h:203
double min_dR
Definition: BPHMonitor.h:193
BPHMonitor::~BPHMonitor ( )
override

Definition at line 140 of file BPHMonitor.cc.

References den_genTriggerEventFlag_, and num_genTriggerEventFlag_.

141 {
144 }
GenericTriggerEventFlag * den_genTriggerEventFlag_
Definition: BPHMonitor.h:168
GenericTriggerEventFlag * num_genTriggerEventFlag_
Definition: BPHMonitor.h:167

Member Function Documentation

void BPHMonitor::analyze ( edm::Event const &  iEvent,
edm::EventSetup const &  iSetup 
)
overrideprotectedvirtual

Reimplemented from DQMEDAnalyzer.

Definition at line 354 of file BPHMonitor.cc.

References GenericTriggerEventFlag::accept(), ecalDrivenElectronSeedsParameters_cff::beamSpot, bsInputTag_, bsToken_, ClosestApproachInRPhi::calculate(), case11_selection(), reco::Vertex::chi2(), hiPixelPairStep_cff::deltaPhi, reco::deltaR(), den_genTriggerEventFlag_, METME::denominator, DiMuDCA_, DiMudR_, DiMuDS_, DiMuEta_, DiMuMass_, DiMuPhi_, DiMuProb_, DiMuPt_, DiMuPVcos_, ClosestApproachInRPhi::distance(), DMSelection_ref, reco::BeamSpot::dxdz(), reco::BeamSpot::dydz(), SiPixelPhase1TrackClustersV_cfi::e3, enum_, reco::tau::disc::Eta(), MonitorElement::Fill(), edm::EventSetup::get(), edm::Event::getByToken(), reco::TrackBase::highPurity, hltInputTag_, hltpaths_den, hltpaths_num, mps_fire::i, createfilelist::int, edm::HandleBase::isValid(), TrajectoryStateClosestToPoint::isValid(), TransientVertex::isValid(), Jpsi_, kaon_mass, edm::InputTag::label(), funct::m, matchToTrigger(), maxmass_, maxmassJpsi, maxmassJpsiTk, maxmassUpsilon, min_dR, mincos, minDS, minmass_, minmassJpsi, minmassJpsiTk, minmassUpsilon, minprob, reco::TrackBase::momentum(), mu1Eta_, mu1Phi_, mu1Pt_, mu2Eta_, mu2Phi_, mu2Pt_, mu3Eta_, mu3Phi_, mu3Pt_, mu_mass, muEta_, muoInputTag_, muoSelection_, muoSelection_ref, muoToken_, muPhi_, muPt_, reco::Vertex::ndof(), num_genTriggerEventFlag_, METME::numerator, GenericTriggerEventFlag::on(), AlCaHLTBitMon_ParallelJobs::p, p1, p2, p3, p4, PV3DBase< T, PVType, FrameType >::perp(), phEta_, colinearityKinematic::Phi, phInputTag_, phPhi_, phPt_, phToken_, TransientVertex::position(), TransientVertex::positionError(), EnergyCorrector::pt, reco::tau::disc::Pt(), reco::TrackBase::px(), reco::TrackBase::py(), reco::TrackBase::pz(), reco::TrackBase::quality(), GlobalErrorBase< T, ErrorWeightType >::rerr(), seagull_, trigger::TriggerEvent::sizeFilters(), mathSSE::sqrt(), AlCaHLTBitMon_QueryRunRegistry::string, lumiQTWidget::t, TrajectoryStateClosestToPoint::theState(), tnp_, trInputTag_, trSelection_ref, trToken_, Upsilon_, KalmanVertexFitter::vertex(), warningPrinted4token_, PV3DBase< T, PVType, FrameType >::x(), reco::BeamSpot::x0(), PV3DBase< T, PVType, FrameType >::y(), reco::BeamSpot::y0(), PV3DBase< T, PVType, FrameType >::z(), and reco::BeamSpot::z0().

354  {
355 
357  iEvent.getByToken( bsToken_, beamSpot);
358  if ( !beamSpot.isValid() ) {
359  if (!warningPrinted4token_[0]) {
360  warningPrinted4token_[0] = true;
361  edm::LogWarning("BPHMonitor") << "skipping events because the collection " << bsInputTag_.label().c_str() << " is not available";
362  }
363  return;
364  }
365 
367  iEvent.getByToken( muoToken_, muoHandle );
368  if ( !muoHandle.isValid() ) {
369  if (!warningPrinted4token_[1]) {
370  warningPrinted4token_[1] = true;
371  edm::LogWarning("BPHMonitor") << "skipping events because the collection " << muoInputTag_.label().c_str() << " is not available";
372  }
373  return;
374  }
375 
377  iEvent.getByToken( trToken_, trHandle );
378  if ( !trHandle.isValid() ) {
379  if (!warningPrinted4token_[2]) {
380  warningPrinted4token_[2] = true;
381  edm::LogWarning("BPHMonitor") << "skipping events because the collection " << trInputTag_.label().c_str() << " is not available";
382  }
383  return;
384  }
385 
387  iEvent.getByToken( phToken_, phHandle );
388 
389  edm::Handle<edm::TriggerResults> handleTriggerTrigRes;
390 
391  edm::Handle<trigger::TriggerEvent> handleTriggerEvent;
392  edm::ESHandle<MagneticField> bFieldHandle;
393  // Filter out events if Trigger Filtering is requested
394  double PrescaleWeight = 1;
395 
396  if (tnp_> 0) { // TnP method
397  if (den_genTriggerEventFlag_->on() && ! den_genTriggerEventFlag_->accept( iEvent, iSetup) ) return;
398  iEvent.getByToken( hltInputTag_, handleTriggerEvent);
399  if (handleTriggerEvent->sizeFilters()== 0) return;
400  const std::string & hltpath = hltpaths_num[0];
401  std::vector<reco::Muon> tagMuons;
402  for ( auto const & m : *muoHandle ) { // applying tag selection
403  if (false && !matchToTrigger(hltpath,m, handleTriggerEvent)) continue;
404  if ( muoSelection_ref( m ) ) tagMuons.push_back(m);
405  }
406  for (int i = 0; i<int(tagMuons.size());i++) {
407  for ( auto const & m : *muoHandle ) {
408  if (false && !matchToTrigger(hltpath,m, handleTriggerEvent)) continue;
409  if ((tagMuons[i].pt() == m.pt())) continue; // not the same
410  if ((tagMuons[i].p4()+m.p4()).M() >minmass_&& (tagMuons[i].p4()+m.p4()).M() <maxmass_) { // near to J/psi mass
411  muPhi_.denominator->Fill(m.phi());
412  muEta_.denominator->Fill(m.eta());
413  muPt_.denominator ->Fill(m.pt());
414  if (muoSelection_( m )) {
415  muPhi_.numerator->Fill(m.phi(),PrescaleWeight);
416  muEta_.numerator->Fill(m.eta(),PrescaleWeight);
417  muPt_.numerator ->Fill(m.pt(),PrescaleWeight);
418  }
419  }
420  }
421 
422  }
423 
424 
425  }
426  else { // reference method
427  if (den_genTriggerEventFlag_->on() && ! den_genTriggerEventFlag_->accept( iEvent, iSetup) ) return;
428  iEvent.getByToken( hltInputTag_, handleTriggerEvent);
429  if (handleTriggerEvent->sizeFilters()== 0) return;
430  const std::string & hltpath = hltpaths_den[0];
431  for (auto const & m : *muoHandle ) {
432  if (false && !matchToTrigger(hltpath,m, handleTriggerEvent)) continue;
433  if (!muoSelection_ref(m)) continue;
434  for (auto const & m1 : *muoHandle ) {
435  if (&m - &(*muoHandle)[0] >= &m1 - &(*muoHandle)[0]) continue;
436  //if (m1.pt() == m.pt()) continue; // probably not needed if using the above check
437  if (!muoSelection_ref(m1)) continue;
438  if (false && !matchToTrigger(hltpath,m1, handleTriggerEvent)) continue;
439  if (enum_ != 10) {
440  if (!DMSelection_ref(m1.p4() + m.p4())) continue;
441  if (m.charge()*m1.charge() > 0 ) continue;
442  }
443  iSetup.get<IdealMagneticFieldRecord>().get(bFieldHandle);
444  const reco::BeamSpot& vertexBeamSpot = *beamSpot;
445  std::vector<reco::TransientTrack> j_tks;
446  reco::TransientTrack mu1TT(m.track(), &(*bFieldHandle));
447  reco::TransientTrack mu2TT(m1.track(), &(*bFieldHandle));
448  j_tks.push_back(mu1TT);
449  j_tks.push_back(mu2TT);
450  KalmanVertexFitter jkvf;
451  TransientVertex jtv = jkvf.vertex(j_tks);
452  if (!jtv.isValid()) continue;
453  reco::Vertex jpsivertex = jtv;
454  float dimuonCL = 0;
455  if ( (jpsivertex.chi2() >= 0) && (jpsivertex.ndof() > 0) ) // I think these values are "unphysical"(no one will need to change them ever)so the can be fixed
456  dimuonCL = TMath::Prob(jpsivertex.chi2(), jpsivertex.ndof() );
457  math::XYZVector jpperp(m.px() + m1.px() ,
458  m.py() + m1.py() ,
459  0.);
460  GlobalPoint jVertex = jtv.position();
461  GlobalError jerr = jtv.positionError();
462  GlobalPoint displacementFromBeamspotJpsi( -1*((vertexBeamSpot.x0() - jVertex.x()) + (jVertex.z() - vertexBeamSpot.z0()) * vertexBeamSpot.dxdz()),
463  -1*((vertexBeamSpot.y0() - jVertex.y()) + (jVertex.z() - vertexBeamSpot.z0()) * vertexBeamSpot.dydz()),
464  0);
465  reco::Vertex::Point vperpj(displacementFromBeamspotJpsi.x(), displacementFromBeamspotJpsi.y(), 0.);
466  float jpsi_cos = vperpj.Dot(jpperp) / (vperpj.R()*jpperp.R());
467  TrajectoryStateClosestToPoint mu1TS = mu1TT.impactPointTSCP();
468  TrajectoryStateClosestToPoint mu2TS = mu2TT.impactPointTSCP();
470  if (mu1TS.isValid() && mu2TS.isValid()) {
471  cApp.calculate(mu1TS.theState(), mu2TS.theState());
472  }
473  double DiMuMass = (m1.p4()+m.p4()).M();
474  switch(enum_) { // enum_ = 1...9, represents different sets of variables for different paths, we want to have different hists for different paths
475  case 1: tnp_=true; // already filled hists for tnp method
476  case 2:
477  if ((Jpsi_) && (!Upsilon_)) {
478  if (DiMuMass> maxmassJpsi || DiMuMass< minmassJpsi) continue;
479  }
480  if ((!Jpsi_) && (Upsilon_)) {
481  if (DiMuMass> maxmassUpsilon || DiMuMass< minmassUpsilon) continue;
482  }
483  if (dimuonCL < minprob) continue;
484  mu1Phi_.denominator->Fill(m.phi());
485  mu1Eta_.denominator->Fill(m.eta());
486  mu1Pt_.denominator ->Fill(m.pt());
487  mu2Phi_.denominator->Fill(m1.phi());
488  mu2Eta_.denominator->Fill(m1.eta());
489  mu2Pt_.denominator ->Fill(m1.pt());
490  DiMuPt_.denominator ->Fill((m1.p4()+m.p4()).Pt() );
491  DiMuEta_.denominator ->Fill((m1.p4()+m.p4()).Eta() );
492  DiMuPhi_.denominator ->Fill((m1.p4()+m.p4()).Phi());
493  break;
494  case 3:
495  if ((Jpsi_) && (!Upsilon_)) {
496  if (DiMuMass> maxmassJpsi || DiMuMass< minmassJpsi) continue;
497  }
498  if ((!Jpsi_) && (Upsilon_)) {
499  if (DiMuMass> maxmassUpsilon || DiMuMass< minmassUpsilon) continue;
500  }
501  if (dimuonCL < minprob) continue;
502  mu1Eta_.denominator->Fill(m.eta());
503  mu1Pt_.denominator ->Fill(m.pt());
504  mu2Eta_.denominator->Fill(m1.eta());
505  mu2Pt_.denominator ->Fill(m1.pt());
506  break;
507  case 4:
508  if (dimuonCL < minprob) continue;
509  DiMuMass_.denominator ->Fill(DiMuMass);
510  if ((Jpsi_) && (!Upsilon_)) {
511  if (DiMuMass> maxmassJpsi || DiMuMass< minmassJpsi) continue;
512  }
513  if ((!Jpsi_) && (Upsilon_)) {
514  if (DiMuMass> maxmassUpsilon || DiMuMass< minmassUpsilon) continue;
515  }
516  mu1Phi_.denominator->Fill(m.phi());
517  mu1Eta_.denominator->Fill(m.eta());
518  mu1Pt_.denominator ->Fill(m.pt());
519  mu2Phi_.denominator->Fill(m1.phi());
520  mu2Eta_.denominator->Fill(m1.eta());
521  mu2Pt_.denominator ->Fill(m1.pt());
522  DiMuPt_.denominator ->Fill((m1.p4()+m.p4()).Pt() );
523  DiMuEta_.denominator ->Fill((m1.p4()+m.p4()).Eta() );
524  DiMuPhi_.denominator ->Fill((m1.p4()+m.p4()).Phi());
526  break;
527  case 5:
528  if (dimuonCL < minprob) continue;
529  if ((Jpsi_) && (!Upsilon_)) {
530  if (DiMuMass> maxmassJpsi || DiMuMass< minmassJpsi) continue;
531  }
532 
533  if ((!Jpsi_) && (Upsilon_)) {
534  if (DiMuMass> maxmassUpsilon || DiMuMass< minmassUpsilon) continue;
535  }
536  mu1Phi_.denominator->Fill(m.phi());
537  mu1Eta_.denominator->Fill(m.eta());
538  mu1Pt_.denominator ->Fill(m.pt());
539  mu2Phi_.denominator->Fill(m1.phi());
540  mu2Eta_.denominator->Fill(m1.eta());
541  mu2Pt_.denominator ->Fill(m1.pt());
542  DiMuPt_.denominator ->Fill((m1.p4()+m.p4()).Pt() );
543  DiMuEta_.denominator ->Fill((m1.p4()+m.p4()).Eta() );
544  DiMuPhi_.denominator ->Fill((m1.p4()+m.p4()).Phi());
546  break;
547  case 6:
548  if (dimuonCL < minprob) continue;
549  if ((Jpsi_) && (!Upsilon_)) {
550  if (DiMuMass> maxmassJpsi || DiMuMass< minmassJpsi) continue;
551  }
552  if ((!Jpsi_) && (Upsilon_)) {
553  if (DiMuMass> maxmassUpsilon || DiMuMass< minmassUpsilon) continue;
554  }
555  for (auto const & m2 : *muoHandle) { // triple muon paths
556  if (false && !matchToTrigger(hltpath,m2, handleTriggerEvent)) continue;
557  if (m2.pt() == m.pt()) continue;
558  mu1Phi_.denominator->Fill(m.phi());
559  mu1Eta_.denominator->Fill(m.eta());
560  mu1Pt_.denominator ->Fill(m.pt());
561  mu2Phi_.denominator->Fill(m1.phi());
562  mu2Eta_.denominator->Fill(m1.eta());
563  mu2Pt_.denominator ->Fill(m1.pt());
564  mu3Phi_.denominator->Fill(m2.phi());
565  mu3Eta_.denominator->Fill(m2.eta());
566  mu3Pt_.denominator ->Fill(m2.pt());
567  }
568  break;
569 
570  case 7: // the hists for photon monitoring will be filled on 515 line
571  tnp_=false;
572  break;
573 
574  case 8: // vtx monitoring, filling probability, DS, DCA, cos of pointing angle to the PV, eta, pT of dimuon
575  if ((Jpsi_) && (!Upsilon_)) {
576  if (DiMuMass> maxmassJpsi || DiMuMass< minmassJpsi) continue;
577  }
578 
579  if ((!Jpsi_) && (Upsilon_)) {
580  if (DiMuMass> maxmassUpsilon || DiMuMass< minmassUpsilon) continue;
581  }
582 
583  DiMuProb_.denominator ->Fill( dimuonCL);
584  if (dimuonCL < minprob) continue;
585  DiMuDS_.denominator ->Fill( displacementFromBeamspotJpsi.perp() / sqrt(jerr.rerr(displacementFromBeamspotJpsi)));
586  DiMuPVcos_.denominator ->Fill(jpsi_cos );
587  DiMuPt_.denominator ->Fill((m1.p4()+m.p4()).Pt() );
588  DiMuEta_.denominator ->Fill((m1.p4()+m.p4()).Eta() );
589  DiMuDCA_.denominator ->Fill( cApp.distance());
590  break;
591  case 9:
592  if (dimuonCL < minprob) continue;
593  if (fabs(jpsi_cos) < mincos) continue;
594  if ((displacementFromBeamspotJpsi.perp() / sqrt(jerr.rerr(displacementFromBeamspotJpsi))) < minDS) continue;
595 
596  if (trHandle.isValid()) {
598 
599  for (auto const & t : *trHandle) {
600 
601  if (!trSelection_ref(t)) continue;
602  if (false && !matchToTrigger(hltpath,t, handleTriggerEvent)) continue;
603  const reco::Track& itrk1 = t ;
604 
605  if ((reco::deltaR(t,m1) <= min_dR)) continue; // checking overlapping
606  if ((reco::deltaR(t,m) <= min_dR)) continue;
607 
608  if (! itrk1.quality(reco::TrackBase::highPurity)) continue;
609 
611  double trackMass2 = kaon_mass * kaon_mass;
612  double MuMass2 = mu_mass * mu_mass; // 0.1056583745 *0.1056583745;
613  double e1 = sqrt(m.momentum().Mag2() + MuMass2 );
614  double e2 = sqrt(m1.momentum().Mag2() + MuMass2 );
615  double e3 = sqrt(itrk1.momentum().Mag2() + trackMass2 );
616 
617  p1 = reco::Particle::LorentzVector(m.px() , m.py() , m.pz() , e1 );
618  p2 = reco::Particle::LorentzVector(m1.px() , m1.py() , m1.pz() , e2 );
619  p3 = reco::Particle::LorentzVector(itrk1.px(), itrk1.py(), itrk1.pz(), e3 );
620  pB = p1 + p2 + p3;
621  if ( pB.mass() > maxmassJpsiTk || pB.mass() < minmassJpsiTk) continue;
622  reco::TransientTrack trTT(itrk1, &(*bFieldHandle));
623 
624  std::vector<reco::TransientTrack> t_tks;
625  t_tks.push_back(mu1TT);
626  t_tks.push_back(mu2TT);
627  t_tks.push_back(trTT);
628 
629  KalmanVertexFitter kvf;
630  TransientVertex tv = kvf.vertex(t_tks);
631  reco::Vertex vertex = tv;
632  if (!tv.isValid()) continue;
633  float JpsiTkCL = 0;
634  if ((vertex.chi2() >= 0.0) && (vertex.ndof() > 0) )
635  JpsiTkCL = TMath::Prob(vertex.chi2(), vertex.ndof() );
636  math::XYZVector pperp(m.px() + m1.px() + itrk1.px(),
637  m.py() + m1.py() + itrk1.py(),
638  0.);
639  GlobalPoint secondaryVertex = tv.position();
640  GlobalError err = tv.positionError();
641  GlobalPoint displacementFromBeamspot( -1*((vertexBeamSpot.x0() - secondaryVertex.x()) +
642  (secondaryVertex.z() - vertexBeamSpot.z0()) * vertexBeamSpot.dxdz()),
643  -1*((vertexBeamSpot.y0() - secondaryVertex.y()) +
644  (secondaryVertex.z() - vertexBeamSpot.z0()) * vertexBeamSpot.dydz()),
645  0);
646  reco::Vertex::Point vperp(displacementFromBeamspot.x(),displacementFromBeamspot.y(),0.);
647  float jpsiKcos = vperp.Dot(pperp) / (vperp.R()*pperp.R());
648  if (JpsiTkCL < minprob) continue;
649  if (fabs(jpsiKcos) < mincos) continue;
650  if ((displacementFromBeamspot.perp() / sqrt(err.rerr(displacementFromBeamspot)))<minDS) continue;
651  muPhi_.denominator->Fill(t.phi());
652  muEta_.denominator->Fill(t.eta());
653  muPt_.denominator ->Fill(t.pt());
654 
656  }
657  }
658  break;
659  case 10:
660  if (trHandle.isValid()) {
661  for (auto const & t : *trHandle) {
662  if (!trSelection_ref(t)) continue;
663  if (false && !matchToTrigger(hltpath,t, handleTriggerEvent)) continue;
664  const reco::Track& itrk1 = t ;
665  if ((reco::deltaR(t,m1) <= min_dR)) continue; // checking overlapping
666  if ((reco::deltaR(t,m) <= min_dR)) continue;
667  if (! itrk1.quality(reco::TrackBase::highPurity)) continue;
669  double trackMass2 = kaon_mass * kaon_mass;
670  double MuMass2 = mu_mass * mu_mass; // 0.1056583745 *0.1056583745;
671  double e2 = sqrt(m1.momentum().Mag2() + MuMass2 );
672  double e3 = sqrt(itrk1.momentum().Mag2() + trackMass2 );
673  p2 = reco::Particle::LorentzVector(m1.px() , m1.py() , m1.pz() , e2 );
674  p3 = reco::Particle::LorentzVector(itrk1.px(), itrk1.py(), itrk1.pz(), e3 );
675  pB = p2 + p3;
676  if ( pB.mass() > maxmassJpsiTk || pB.mass()< minmassJpsiTk) continue;
677  reco::TransientTrack trTT(itrk1, &(*bFieldHandle));
678  std::vector<reco::TransientTrack> t_tks;
679  t_tks.push_back(mu2TT);
680  t_tks.push_back(trTT);
681  KalmanVertexFitter kvf;
682  TransientVertex tv = kvf.vertex(t_tks);
683  reco::Vertex vertex = tv;
684  if (!tv.isValid()) continue;
685  float JpsiTkCL = 0;
686  if ((vertex.chi2() >= 0.0) && (vertex.ndof() > 0) )
687  JpsiTkCL = TMath::Prob(vertex.chi2(), vertex.ndof() );
688  math::XYZVector pperp(m1.px() + itrk1.px(),
689  m1.py() + itrk1.py(),
690  0.);
691  GlobalPoint secondaryVertex = tv.position();
692  GlobalError err = tv.positionError();
693  GlobalPoint displacementFromBeamspot( -1*((vertexBeamSpot.x0() - secondaryVertex.x()) +
694  (secondaryVertex.z() - vertexBeamSpot.z0()) * vertexBeamSpot.dxdz()),
695  -1*((vertexBeamSpot.y0() - secondaryVertex.y()) +
696  (secondaryVertex.z() - vertexBeamSpot.z0()) * vertexBeamSpot.dydz()),
697  0);
698  reco::Vertex::Point vperp(displacementFromBeamspot.x(),displacementFromBeamspot.y(),0.);
699  if (JpsiTkCL<minprob) continue;
700  muPhi_.denominator->Fill(m1.phi());
701  muEta_.denominator->Fill(m1.eta());
702  muPt_.denominator ->Fill(m1.pt());
703  }
704  }
705  break;
706  case 11:
707  case11_selection(dimuonCL, jpsi_cos, displacementFromBeamspotJpsi, jerr, trHandle, hltpath, handleTriggerEvent, m, m1, bFieldHandle, vertexBeamSpot, mu1Phi_.denominator, mu1Eta_.denominator, mu1Pt_.denominator, mu2Phi_.denominator, mu2Eta_.denominator, mu2Pt_.denominator);
708  break;
709  }
710  }
711  }
712 
713 
714  if (enum_ == 7) { // photons
715  const std::string & hltpath = hltpaths_den[0];
716  if ( phHandle.isValid() ) {
717  for (auto const & p : *phHandle) {
718  if (false && !matchToTrigger(hltpath,p, handleTriggerEvent)) continue;
719  phPhi_.denominator->Fill(p.phi());
720  phEta_.denominator->Fill(p.eta());
721  phPt_.denominator ->Fill(p.pt());
722  }
723  } else {
724  if (!warningPrinted4token_[3]) {
725  warningPrinted4token_[3] = true;
726  if ( phInputTag_.label().empty() )
727  edm::LogWarning("BPHMonitor") << "PhotonCollection not set";
728  else
729  edm::LogWarning("BPHMonitor") << "skipping events because the collection " << phInputTag_.label().c_str() << " is not available";
730  }
731  // if Handle is not valid, because the InputTag has been mis-configured, then skip the event
732  if ( !phInputTag_.label().empty() ) return;
733  }
734  }
735  //
737  // filling numerator hists
738  if (num_genTriggerEventFlag_->on() && ! num_genTriggerEventFlag_->accept( iEvent, iSetup) ) return;
739  iEvent.getByToken( hltInputTag_, handleTriggerEvent);
740  if (handleTriggerEvent->sizeFilters()== 0) return;
741  const std::string & hltpath1 = hltpaths_num[0];
742  for (auto const & m : *muoHandle ) {
743  if (false && !matchToTrigger(hltpath1,m, handleTriggerEvent)) continue;
744  if (!muoSelection_ref(m)) continue;
745  for (auto const & m1 : *muoHandle ) {
746  if (seagull_ && ((m.charge()* deltaPhi(m.phi(), m1.phi())) > 0.) ) continue;
747  if (m.charge()*m1.charge() > 0 ) continue;
748  if (m1.pt() == m.pt()) continue;
749  if (!muoSelection_ref(m1)) continue;
750  if (false && !matchToTrigger(hltpath1,m1, handleTriggerEvent)) continue;
751  if (!DMSelection_ref(m1.p4() + m.p4())) continue;
752  iSetup.get<IdealMagneticFieldRecord>().get(bFieldHandle);
753  const reco::BeamSpot& vertexBeamSpot = *beamSpot;
754  std::vector<reco::TransientTrack> j_tks;
755  reco::TransientTrack mu1TT(m.track(), &(*bFieldHandle));
756  reco::TransientTrack mu2TT(m1.track(), &(*bFieldHandle));
757  j_tks.push_back(mu1TT);
758  j_tks.push_back(mu2TT);
759  KalmanVertexFitter jkvf;
760  TransientVertex jtv = jkvf.vertex(j_tks);
761  if (!jtv.isValid()) continue;
762  reco::Vertex jpsivertex = jtv;
763  float dimuonCL = 0;
764  if ( (jpsivertex.chi2() >= 0) && (jpsivertex.ndof() > 0) ) // I think these values are "unphysical"(no one will need to change them ever)so the can be fixed
765  dimuonCL = TMath::Prob(jpsivertex.chi2(), jpsivertex.ndof() );
766  math::XYZVector jpperp(m.px() + m1.px() ,
767  m.py() + m1.py() ,
768  0.);
769  GlobalPoint jVertex = jtv.position();
770  GlobalError jerr = jtv.positionError();
771  GlobalPoint displacementFromBeamspotJpsi( -1*((vertexBeamSpot.x0() - jVertex.x()) + (jVertex.z() - vertexBeamSpot.z0()) * vertexBeamSpot.dxdz()),
772  -1*((vertexBeamSpot.y0() - jVertex.y()) + (jVertex.z() - vertexBeamSpot.z0()) * vertexBeamSpot.dydz()),
773  0);
774  reco::Vertex::Point vperpj(displacementFromBeamspotJpsi.x(), displacementFromBeamspotJpsi.y(), 0.);
775  float jpsi_cos = vperpj.Dot(jpperp) / (vperpj.R()*jpperp.R());
776  TrajectoryStateClosestToPoint mu1TS = mu1TT.impactPointTSCP();
777  TrajectoryStateClosestToPoint mu2TS = mu2TT.impactPointTSCP();
779  if (mu1TS.isValid() && mu2TS.isValid()) {
780  cApp.calculate(mu1TS.theState(), mu2TS.theState());
781  }
782  double DiMuMass = (m1.p4()+m.p4()).M();
783  switch(enum_) { // enum_ = 1...9, represents different sets of variables for different paths, we want to have different hists for different paths
784  case 1: tnp_=true; // already filled hists for tnp method
785  case 2:
786  if ((Jpsi_) && (!Upsilon_)) {
787  if (DiMuMass> maxmassJpsi || DiMuMass< minmassJpsi) continue;
788  }
789  if ((!Jpsi_) && (Upsilon_)) {
790  if (DiMuMass> maxmassUpsilon || DiMuMass< minmassUpsilon) continue;
791  }
792  if (dimuonCL < minprob) continue;
793  mu1Phi_.numerator->Fill(m.phi(),PrescaleWeight);
794  mu1Eta_.numerator->Fill(m.eta(),PrescaleWeight);
795  mu1Pt_.numerator ->Fill(m.pt(),PrescaleWeight);
796  mu2Phi_.numerator->Fill(m1.phi(),PrescaleWeight);
797  mu2Eta_.numerator->Fill(m1.eta(),PrescaleWeight);
798  mu2Pt_.numerator ->Fill(m1.pt(),PrescaleWeight);
799  DiMuPt_.numerator ->Fill((m1.p4()+m.p4()).Pt() ,PrescaleWeight);
800  DiMuEta_.numerator ->Fill((m1.p4()+m.p4()).Eta() ,PrescaleWeight);
801  DiMuPhi_.numerator ->Fill((m1.p4()+m.p4()).Phi(),PrescaleWeight);
802  break;
803  case 3:
804  if ((Jpsi_) && (!Upsilon_)) {
805  if (DiMuMass> maxmassJpsi || DiMuMass< minmassJpsi) continue;
806  }
807 
808  if ((!Jpsi_) && (Upsilon_)) {
809  if (DiMuMass> maxmassUpsilon || DiMuMass< minmassUpsilon) continue;
810  }
811  if (dimuonCL < minprob) continue;
812  mu1Eta_.numerator->Fill(m.eta(),PrescaleWeight);
813  mu1Pt_.numerator ->Fill(m.pt(),PrescaleWeight);
814  mu2Eta_.numerator->Fill(m1.eta(),PrescaleWeight);
815  mu2Pt_.numerator ->Fill(m1.pt(),PrescaleWeight);
816  break;
817  case 4:
818  if (dimuonCL < minprob) continue;
819  DiMuMass_.numerator ->Fill(DiMuMass);
820  if ((Jpsi_) && (!Upsilon_)) {
821  if (DiMuMass> maxmassJpsi || DiMuMass< minmassJpsi) continue;
822  }
823  if ((!Jpsi_) && (Upsilon_)) {
824  if (DiMuMass> maxmassUpsilon || DiMuMass< minmassUpsilon) continue;
825  }
826  mu1Phi_.numerator->Fill(m.phi(),PrescaleWeight);
827  mu1Eta_.numerator->Fill(m.eta(),PrescaleWeight);
828  mu1Pt_.numerator ->Fill(m.pt(),PrescaleWeight);
829  mu2Phi_.numerator->Fill(m1.phi(),PrescaleWeight);
830  mu2Eta_.numerator->Fill(m1.eta(),PrescaleWeight);
831  mu2Pt_.numerator ->Fill(m1.pt(),PrescaleWeight);
832  DiMuPt_.numerator ->Fill((m1.p4()+m.p4()).Pt() ,PrescaleWeight);
833  DiMuEta_.numerator ->Fill((m1.p4()+m.p4()).Eta() ,PrescaleWeight);
834  DiMuPhi_.numerator ->Fill((m1.p4()+m.p4()).Phi(),PrescaleWeight);
835  DiMudR_.numerator ->Fill(reco::deltaR(m,m1),PrescaleWeight);
836  break;
837  case 5:
838  if (dimuonCL < minprob) continue;
839  if ((Jpsi_) && (!Upsilon_)) {
840  if (DiMuMass> maxmassJpsi || DiMuMass< minmassJpsi) continue;
841  }
842  if ((!Jpsi_) && (Upsilon_)) {
843  if (DiMuMass> maxmassUpsilon || DiMuMass< minmassUpsilon) continue;
844  }
845  mu1Phi_.numerator->Fill(m.phi(),PrescaleWeight);
846  mu1Eta_.numerator->Fill(m.eta(),PrescaleWeight);
847  mu1Pt_.numerator ->Fill(m.pt(),PrescaleWeight);
848  mu2Phi_.numerator->Fill(m1.phi(),PrescaleWeight);
849  mu2Eta_.numerator->Fill(m1.eta(),PrescaleWeight);
850  mu2Pt_.numerator ->Fill(m1.pt(),PrescaleWeight);
851  DiMuPt_.numerator ->Fill((m1.p4()+m.p4()).Pt() ,PrescaleWeight);
852  DiMuEta_.numerator ->Fill((m1.p4()+m.p4()).Eta() ,PrescaleWeight);
853  DiMuPhi_.numerator ->Fill((m1.p4()+m.p4()).Phi(),PrescaleWeight);
854  DiMudR_.numerator ->Fill(reco::deltaR(m,m1),PrescaleWeight);
855  break;
856  case 6:
857  if (dimuonCL < minprob) continue;
858  if ((Jpsi_) && (!Upsilon_)) {
859  if (DiMuMass> maxmassJpsi || DiMuMass< minmassJpsi) continue;
860  }
861  if ((!Jpsi_) && (Upsilon_)) {
862  if (DiMuMass> maxmassUpsilon || DiMuMass< minmassUpsilon) continue;
863  }
864  for (auto const & m2 : *muoHandle) { // triple muon paths
865  if (false && !matchToTrigger(hltpath1,m2, handleTriggerEvent)) continue;
866  if (m2.pt() == m.pt()) continue;
867  mu1Phi_.numerator->Fill(m.phi(),PrescaleWeight);
868  mu1Eta_.numerator->Fill(m.eta(),PrescaleWeight);
869  mu1Pt_.numerator ->Fill(m.pt(),PrescaleWeight);
870  mu2Phi_.numerator->Fill(m1.phi(),PrescaleWeight);
871  mu2Eta_.numerator->Fill(m1.eta(),PrescaleWeight);
872  mu2Pt_.numerator ->Fill(m1.pt(),PrescaleWeight);
873  mu3Phi_.numerator->Fill(m2.phi(),PrescaleWeight);
874  mu3Eta_.numerator->Fill(m2.eta(),PrescaleWeight);
875  mu3Pt_.numerator ->Fill(m2.pt(),PrescaleWeight);
876  }
877  break;
878  case 7: // the hists for photon monitoring will be filled on 515 line
879  tnp_=false;
880  break;
881  case 8: // vtx monitoring, filling probability, DS, DCA, cos of pointing angle to the PV, eta, pT of dimuon
882  if ((Jpsi_) && (!Upsilon_)) {
883  if (DiMuMass> maxmassJpsi || DiMuMass< minmassJpsi) continue;
884  }
885  if ((!Jpsi_) && (Upsilon_)) {
886  if (DiMuMass> maxmassUpsilon || DiMuMass< minmassUpsilon) continue;
887  }
888  DiMuProb_.numerator ->Fill( dimuonCL,PrescaleWeight);
889  if (dimuonCL < minprob) continue;
890  DiMuDS_.numerator ->Fill( displacementFromBeamspotJpsi.perp() / sqrt(jerr.rerr(displacementFromBeamspotJpsi)),PrescaleWeight);
891  DiMuPVcos_.numerator ->Fill(jpsi_cos ,PrescaleWeight);
892  DiMuPt_.numerator ->Fill((m1.p4()+m.p4()).Pt() ,PrescaleWeight);
893  DiMuEta_.numerator ->Fill((m1.p4()+m.p4()).Eta() ,PrescaleWeight);
894  DiMuDCA_.numerator ->Fill( cApp.distance(),PrescaleWeight);
895  break;
896  case 9:
897  if (dimuonCL < minprob) continue;
898  if (fabs(jpsi_cos) < mincos) continue;
899  if ((displacementFromBeamspotJpsi.perp() / sqrt(jerr.rerr(displacementFromBeamspotJpsi))) < minDS) continue;
900  if (trHandle.isValid()) {
901  for (auto const & t : *trHandle) {
902  if (!trSelection_ref(t)) continue;
903  if (false && !matchToTrigger(hltpath1,t, handleTriggerEvent)) continue;
904  const reco::Track& itrk1 = t ;
905  if ((reco::deltaR(t,m1) <= min_dR)) continue; // checking overlapping
906  if ((reco::deltaR(t,m) <= min_dR)) continue;
907  if (! itrk1.quality(reco::TrackBase::highPurity)) continue;
909  double trackMass2 = kaon_mass * kaon_mass;
910  double MuMass2 = mu_mass * mu_mass; // 0.1056583745 *0.1056583745;
911  double e1 = sqrt(m.momentum().Mag2() + MuMass2 );
912  double e2 = sqrt(m1.momentum().Mag2() + MuMass2 );
913  double e3 = sqrt(itrk1.momentum().Mag2() + trackMass2 );
914  p1 = reco::Particle::LorentzVector(m.px() , m.py() , m.pz() , e1 );
915  p2 = reco::Particle::LorentzVector(m1.px() , m1.py() , m1.pz() , e2 );
916  p3 = reco::Particle::LorentzVector(itrk1.px(), itrk1.py(), itrk1.pz(), e3 );
917  pB = p1 + p2 + p3;
918  if ( pB.mass() > maxmassJpsiTk || pB.mass()< minmassJpsiTk) continue;
919  reco::TransientTrack trTT(itrk1, &(*bFieldHandle));
920  std::vector<reco::TransientTrack> t_tks;
921  t_tks.push_back(mu1TT);
922  t_tks.push_back(mu2TT);
923  t_tks.push_back(trTT);
924  KalmanVertexFitter kvf;
925  TransientVertex tv = kvf.vertex(t_tks);
926  reco::Vertex vertex = tv;
927  if (!tv.isValid()) continue;
928  float JpsiTkCL = 0;
929  if ((vertex.chi2() >= 0.0) && (vertex.ndof() > 0) )
930  JpsiTkCL = TMath::Prob(vertex.chi2(), vertex.ndof() );
931  math::XYZVector pperp(m.px() + m1.px() + itrk1.px(),
932  m.py() + m1.py() + itrk1.py(),
933  0.);
934  GlobalPoint secondaryVertex = tv.position();
935  GlobalError err = tv.positionError();
936  GlobalPoint displacementFromBeamspot( -1*((vertexBeamSpot.x0() - secondaryVertex.x()) +
937  (secondaryVertex.z() - vertexBeamSpot.z0()) * vertexBeamSpot.dxdz()),
938  -1*((vertexBeamSpot.y0() - secondaryVertex.y()) +
939  (secondaryVertex.z() - vertexBeamSpot.z0()) * vertexBeamSpot.dydz()),
940  0);
941  reco::Vertex::Point vperp(displacementFromBeamspot.x(),displacementFromBeamspot.y(),0.);
942  float jpsiKcos = vperp.Dot(pperp) / (vperp.R()*pperp.R());
943  if (JpsiTkCL<minprob) continue;
944  if (fabs(jpsiKcos)<mincos) continue;
945  if ((displacementFromBeamspot.perp() / sqrt(err.rerr(displacementFromBeamspot)))<minDS) continue;
946  muPhi_.numerator->Fill(t.phi(),PrescaleWeight);
947  muEta_.numerator->Fill(t.eta(),PrescaleWeight);
948  muPt_.numerator ->Fill(t.pt(),PrescaleWeight);
949  }
950  }
951  break;
952 
953  case 10:
954  if (trHandle.isValid()) {
955  for (auto const & t : *trHandle) {
956  if (!trSelection_ref(t)) continue;
957  if (false && !matchToTrigger(hltpath1,t, handleTriggerEvent)) continue;
958  const reco::Track& itrk1 = t ;
959  if ((reco::deltaR(t,m1) <= min_dR)) continue; // checking overlapping
960  if ((reco::deltaR(t,m) <= min_dR)) continue;
961  if (! itrk1.quality(reco::TrackBase::highPurity)) continue;
963  double trackMass2 = kaon_mass * kaon_mass;
964  double MuMass2 = mu_mass * mu_mass; // 0.1056583745 *0.1056583745;
965  double e2 = sqrt(m1.momentum().Mag2() + MuMass2 );
966  double e3 = sqrt(itrk1.momentum().Mag2() + trackMass2 );
967  p2 = reco::Particle::LorentzVector(m1.px() , m1.py() , m1.pz() , e2 );
968  p3 = reco::Particle::LorentzVector(itrk1.px(), itrk1.py(), itrk1.pz(), e3 );
969  pB = p2 + p3;
970  if ( pB.mass() > maxmassJpsiTk || pB.mass()< minmassJpsiTk) continue;
971  reco::TransientTrack trTT(itrk1, &(*bFieldHandle));
972  std::vector<reco::TransientTrack> t_tks;
973  t_tks.push_back(mu2TT);
974  t_tks.push_back(trTT);
975  if (t_tks.size()!=2) continue;
976  KalmanVertexFitter kvf;
977  TransientVertex tv = kvf.vertex(t_tks);
978  reco::Vertex vertex = tv;
979  if (!tv.isValid()) continue;
980  float JpsiTkCL = 0;
981  if ((vertex.chi2() >= 0.0) && (vertex.ndof() > 0) )
982  JpsiTkCL = TMath::Prob(vertex.chi2(), vertex.ndof() );
983  math::XYZVector pperp(m1.px() + itrk1.px(),
984  m1.py() + itrk1.py(),
985  0.);
986  GlobalPoint secondaryVertex = tv.position();
987  GlobalError err = tv.positionError();
988  GlobalPoint displacementFromBeamspot( -1*((vertexBeamSpot.x0() - secondaryVertex.x()) +
989  (secondaryVertex.z() - vertexBeamSpot.z0()) * vertexBeamSpot.dxdz()),
990  -1*((vertexBeamSpot.y0() - secondaryVertex.y()) +
991  (secondaryVertex.z() - vertexBeamSpot.z0()) * vertexBeamSpot.dydz()),
992  0);
993  reco::Vertex::Point vperp(displacementFromBeamspot.x(),displacementFromBeamspot.y(),0.);
994  if (JpsiTkCL<minprob) continue;
995  muPhi_.numerator->Fill(m1.phi(),PrescaleWeight);
996  muEta_.numerator->Fill(m1.eta(),PrescaleWeight);
997  muPt_.numerator ->Fill(m1.pt(),PrescaleWeight);
998  }
999  }
1000  break;
1001  case 11:
1002  case11_selection(dimuonCL, jpsi_cos, displacementFromBeamspotJpsi, jerr, trHandle, hltpath, handleTriggerEvent, m, m1, bFieldHandle, vertexBeamSpot, mu1Phi_.numerator, mu1Eta_.numerator, mu1Pt_.numerator, mu2Phi_.numerator, mu2Eta_.numerator, mu2Pt_.numerator);
1003  break;
1004  }
1005  }
1006  }
1007  if (enum_ == 7) { // photons
1008  const std::string &hltpath = hltpaths_num[0];
1009  if ( phHandle.isValid() ) {
1010  for (auto const & p : *phHandle) {
1011  if (false && !matchToTrigger(hltpath,p, handleTriggerEvent)) continue;
1012  phPhi_.numerator->Fill(p.phi(),PrescaleWeight);
1013  phEta_.numerator->Fill(p.eta(),PrescaleWeight);
1014  phPt_.numerator ->Fill(p.pt(),PrescaleWeight);
1015  }
1016  }
1017  }
1018  }
1019 }
GlobalError positionError() const
int seagull_
Definition: BPHMonitor.h:180
MonitorElement * numerator
Definition: BPHMonitor.h:60
double z0() const
z coordinate
Definition: BeamSpot.h:68
METME mu2Phi_
Definition: BPHMonitor.h:138
int Upsilon_
Definition: BPHMonitor.h:178
METME DiMuDCA_
Definition: BPHMonitor.h:160
float distance() const override
METME phEta_
Definition: BPHMonitor.h:152
METME phPt_
Definition: BPHMonitor.h:153
StringCutObjectSelector< reco::Candidate::LorentzVector, true > DMSelection_ref
Definition: BPHMonitor.h:204
double maxmassJpsiTk
Definition: BPHMonitor.h:189
double kaon_mass
Definition: BPHMonitor.h:191
trigger::size_type sizeFilters() const
Definition: TriggerEvent.h:135
METME mu2Pt_
Definition: BPHMonitor.h:140
METME muPt_
Definition: BPHMonitor.h:129
METME mu1Eta_
Definition: BPHMonitor.h:134
METME phPhi_
Definition: BPHMonitor.h:151
const FreeTrajectoryState & theState() const
edm::EDGetTokenT< reco::MuonCollection > muoToken_
Definition: BPHMonitor.h:110
edm::InputTag bsInputTag_
Definition: BPHMonitor.h:106
T y() const
Definition: PV3DBase.h:63
METME mu2Eta_
Definition: BPHMonitor.h:139
METME DiMuPhi_
Definition: BPHMonitor.h:154
METME mu3Pt_
Definition: BPHMonitor.h:145
bool matchToTrigger(const std::string &theTriggerName, T t, edm::Handle< trigger::TriggerEvent > handleTriggerEvent)
Definition: BPHMonitor.cc:1138
double px() const
x coordinate of momentum vector
Definition: TrackBase.h:627
const Vector & momentum() const
track momentum vector
Definition: TrackBase.h:675
edm::EDGetTokenT< trigger::TriggerEvent > hltInputTag_
Definition: BPHMonitor.h:199
edm::EDGetTokenT< reco::TrackCollection > trToken_
Definition: BPHMonitor.h:112
double minmass_
Definition: BPHMonitor.h:182
double minprob
Definition: BPHMonitor.h:195
void Fill(long long x)
METME mu1Phi_
Definition: BPHMonitor.h:133
METME DiMuEta_
Definition: BPHMonitor.h:155
double dydz() const
dydz slope
Definition: BeamSpot.h:84
int iEvent
Definition: GenABIO.cc:230
double mincos
Definition: BPHMonitor.h:196
double maxmassJpsi
Definition: BPHMonitor.h:183
std::vector< bool > warningPrinted4token_
Definition: BPHMonitor.h:206
void case11_selection(const float &dimuonCL, const float &jpsi_cos, const GlobalPoint &displacementFromBeamspotJpsi, const GlobalError &jerr, const edm::Handle< reco::TrackCollection > &trHandle, const std::string &hltpath, const edm::Handle< trigger::TriggerEvent > &handleTriggerEvent, const reco::Muon &m, const reco::Muon &m1, const edm::ESHandle< MagneticField > &bFieldHandle, const reco::BeamSpot &vertexBeamSpot, MonitorElement *phi1, MonitorElement *eta1, MonitorElement *pT1, MonitorElement *phi2, MonitorElement *eta2, MonitorElement *pT2)
Definition: BPHMonitor.cc:1166
bool calculate(const TrajectoryStateOnSurface &sta, const TrajectoryStateOnSurface &stb) override
edm::InputTag muoInputTag_
Definition: BPHMonitor.h:105
T sqrt(T t)
Definition: SSEVec.h:18
double p4[4]
Definition: TauolaWrapper.h:92
bool accept(const edm::Event &event, const edm::EventSetup &setup)
To be called from analyze/filter() methods.
GlobalPoint position() const
T z() const
Definition: PV3DBase.h:64
double mu_mass
Definition: BPHMonitor.h:192
GenericTriggerEventFlag * den_genTriggerEventFlag_
Definition: BPHMonitor.h:168
double chi2() const
chi-squares
Definition: Vertex.h:98
MonitorElement * denominator
Definition: BPHMonitor.h:61
CachingVertex< 5 > vertex(const std::vector< reco::TransientTrack > &tracks) const override
METME DiMuDS_
Definition: BPHMonitor.h:159
math::XYZPoint Point
point in the space
Definition: Vertex.h:39
bool isValid() const
Definition: HandleBase.h:74
double p2[4]
Definition: TauolaWrapper.h:90
double maxmass_
Definition: BPHMonitor.h:181
double dxdz() const
dxdz slope
Definition: BeamSpot.h:82
double ndof() const
Definition: Vertex.h:105
std::vector< std::string > hltpaths_den
Definition: BPHMonitor.h:201
StringCutObjectSelector< reco::Muon, true > muoSelection_
Definition: BPHMonitor.h:169
double pz() const
z coordinate of momentum vector
Definition: TrackBase.h:639
METME DiMuProb_
Definition: BPHMonitor.h:158
constexpr auto deltaR(const T1 &t1, const T2 &t2) -> decltype(t1.eta())
Definition: deltaR.h:28
double minmassJpsiTk
Definition: BPHMonitor.h:190
edm::EDGetTokenT< reco::PhotonCollection > phToken_
Definition: BPHMonitor.h:113
edm::EDGetTokenT< reco::BeamSpot > bsToken_
Definition: BPHMonitor.h:111
double minDS
Definition: BPHMonitor.h:197
StringCutObjectSelector< reco::Muon, true > muoSelection_ref
Definition: BPHMonitor.h:170
XYZVectorD XYZVector
spatial vector with cartesian internal representation
Definition: Vector3D.h:30
T rerr(const GlobalPoint &aPoint) const
double minmassUpsilon
Definition: BPHMonitor.h:186
double maxmassUpsilon
Definition: BPHMonitor.h:185
bool quality(const TrackQuality) const
Track quality.
Definition: TrackBase.h:510
std::string const & label() const
Definition: InputTag.h:36
METME muEta_
Definition: BPHMonitor.h:128
double p1[4]
Definition: TauolaWrapper.h:89
edm::InputTag trInputTag_
Definition: BPHMonitor.h:107
METME DiMuMass_
Definition: BPHMonitor.h:161
METME DiMuPt_
Definition: BPHMonitor.h:156
double y0() const
y coordinate
Definition: BeamSpot.h:66
METME mu1Pt_
Definition: BPHMonitor.h:135
METME mu3Phi_
Definition: BPHMonitor.h:143
std::vector< std::string > hltpaths_num
Definition: BPHMonitor.h:200
METME mu3Eta_
Definition: BPHMonitor.h:144
double minmassJpsi
Definition: BPHMonitor.h:184
edm::InputTag phInputTag_
Definition: BPHMonitor.h:108
METME DiMuPVcos_
Definition: BPHMonitor.h:157
METME DiMudR_
Definition: BPHMonitor.h:162
T x() const
Definition: PV3DBase.h:62
GenericTriggerEventFlag * num_genTriggerEventFlag_
Definition: BPHMonitor.h:167
math::XYZTLorentzVector LorentzVector
Lorentz vector.
Definition: Particle.h:21
bool isValid() const
METME muPhi_
Definition: BPHMonitor.h:127
StringCutObjectSelector< reco::Track, true > trSelection_ref
Definition: BPHMonitor.h:203
double py() const
y coordinate of momentum vector
Definition: TrackBase.h:633
double p3[4]
Definition: TauolaWrapper.h:91
double x0() const
x coordinate
Definition: BeamSpot.h:64
double min_dR
Definition: BPHMonitor.h:193
void BPHMonitor::bookHistograms ( DQMStore::IBooker ibooker,
edm::Run const &  iRun,
edm::EventSetup const &  iSetup 
)
overrideprotectedvirtual

Implements DQMEDAnalyzer.

Definition at line 227 of file BPHMonitor.cc.

References bookME(), cos_binning_, d0_binning_, dca_binning_, den_genTriggerEventFlag_, DiMuDCA_, DiMudR_, DiMuDS_, DiMuEta_, DiMuMass_, DiMuPhi_, DiMuProb_, DiMuPt_, DiMuPVcos_, dR_binning_, ds_binning_, enum_, eta_binning_, folderName_, GenericTriggerEventFlag::initRun(), mass_binning_, mu1Eta_, mu1Phi_, mu1Pt_, mu2Eta_, mu2Phi_, mu2Pt_, mu3Eta_, mu3Phi_, mu3Pt_, mud0_, muEta_, muPhi_, muPt_, muz0_, num_genTriggerEventFlag_, GenericTriggerEventFlag::on(), phi_binning_, prob_binning_, pt_binning_, DQMStore::IBooker::setCurrentFolder(), setMETitle(), AlCaHLTBitMon_QueryRunRegistry::string, tnp_, trOrMu_, and z0_binning_.

230 {
231 
232  std::string histname, histtitle, istnp, trMuPh;
233  bool Ph_ = false; if (enum_ == 7) Ph_ = true;
234  if (tnp_) istnp = "Tag_and_Probe/"; else istnp = "";
235  std::string currentFolder = folderName_ + istnp;
236  ibooker.setCurrentFolder(currentFolder);
237  if (trOrMu_) trMuPh = "tr"; else if (Ph_) trMuPh = "ph"; else trMuPh = "mu";
238 
239  if (enum_ == 7 || enum_ == 1 || enum_ == 9 || enum_ == 10) {
240  histname = trMuPh+"Pt"; histtitle = trMuPh+"_P_{t}";
241  bookME(ibooker,muPt_,histname,histtitle, pt_binning_);
242  setMETitle(muPt_,trMuPh+"_Pt[GeV]","events / 1 GeV");
243 
244  histname = trMuPh+"Phi"; histtitle = trMuPh+"Phi";
245  bookME(ibooker,muPhi_,histname,histtitle, phi_binning_);
246  setMETitle(muPhi_,trMuPh+"_#phi","events / 0.1 rad");
247 
248  histname = trMuPh+"Eta"; histtitle = trMuPh+"_Eta";
249  bookME(ibooker,muEta_,histname,histtitle, eta_binning_);
250  setMETitle(muEta_,trMuPh+"_#eta","events / 0.2");
251  }
252  else {
253  histname = trMuPh+"1Pt"; histtitle = trMuPh+"1_P_{t}";
254  bookME(ibooker,mu1Pt_,histname,histtitle, pt_binning_);
255  setMETitle(mu1Pt_,trMuPh+"_Pt[GeV]","events / 1 GeV");
256 
257  histname = trMuPh+"1Phi"; histtitle = trMuPh+"1Phi";
258  bookME(ibooker,mu1Phi_,histname,histtitle, phi_binning_);
259  setMETitle(mu1Phi_,trMuPh+"_#phi","events / 0.1 rad");
260 
261  histname = trMuPh+"1Eta"; histtitle = trMuPh+"1_Eta";
262  bookME(ibooker,mu1Eta_,histname,histtitle, eta_binning_);
263  setMETitle(mu1Eta_,trMuPh+"_#eta","events / 0.2");
264 
265  histname = trMuPh+"2Pt"; histtitle = trMuPh+"2_P_{t}";
266  bookME(ibooker,mu2Pt_,histname,histtitle, pt_binning_);
267  setMETitle(mu2Pt_,trMuPh+"_Pt[GeV]","events / 1 GeV");
268 
269  histname = trMuPh+"2Phi"; histtitle = trMuPh+"2Phi";
270  bookME(ibooker,mu2Phi_,histname,histtitle, phi_binning_);
271  setMETitle(mu2Phi_,trMuPh+"_#phi","events / 0.1 rad");
272 
273  histname = trMuPh+"2Eta"; histtitle = trMuPh+"2_Eta";
274  bookME(ibooker,mu2Eta_,histname,histtitle, eta_binning_);
275  setMETitle(mu2Eta_,trMuPh+"_#eta","events / 0.2");
276 
277  if (enum_ == 6) {
278  histname = trMuPh+"3Eta"; histtitle = trMuPh+"3Eta";
279  bookME(ibooker,mu3Eta_,histname,histtitle, eta_binning_);
280  setMETitle(mu3Eta_,trMuPh+"3#eta","events / 0.2");
281 
282  histname = trMuPh+"3Pt"; histtitle = trMuPh+"3_P_{t}";
283  bookME(ibooker,mu3Pt_,histname,histtitle, pt_binning_);
284  setMETitle(mu3Pt_,trMuPh+"3_Pt[GeV]","events / 1 GeV");
285 
286  histname = trMuPh+"3Phi"; histtitle = trMuPh+"3Phi";
287  bookME(ibooker,mu3Phi_,histname,histtitle, phi_binning_);
288  setMETitle(mu3Phi_,trMuPh+"3_#phi","events / 0.1 rad");
289  }
290  else if (enum_ == 2 || enum_ == 4 || enum_ == 5 || enum_ == 8) {
291  histname = "DiMuEta"; histtitle = "DiMuEta";
292  bookME(ibooker,DiMuEta_,histname,histtitle, eta_binning_);
293  setMETitle(DiMuEta_,"DiMu#eta","events / 0.2");
294 
295  histname = "DiMuPt"; histtitle = "DiMu_P_{t}";
296  bookME(ibooker,DiMuPt_,histname,histtitle, pt_binning_);
297  setMETitle(DiMuPt_,"DiMu_Pt[GeV]","events / 1 GeV");
298 
299  histname = "DiMuPhi"; histtitle = "DiMuPhi";
300  bookME(ibooker,DiMuPhi_,histname,histtitle, phi_binning_);
301  setMETitle(DiMuPhi_,"DiMu_#phi","events / 0.1 rad");
302 
303  if (enum_ == 4 || enum_ == 5) {
304  histname = "DiMudR"; histtitle = "DiMudR";
305  bookME(ibooker,DiMudR_,histname,histtitle, dR_binning_);
306  setMETitle(DiMudR_,"DiMu_#dR","events /");
307  if (enum_ == 4) {
308  histname = "DiMuMass"; histtitle = "DiMuMass";
309  bookME(ibooker,DiMuMass_,histname,histtitle, mass_binning_);
310  setMETitle(DiMuMass_,"DiMu_#mass","events /");
311  }
312  } else if (enum_ == 8) {
313  histname = "DiMuProb"; histtitle = "DiMuProb";
314  bookME(ibooker,DiMuProb_,histname,histtitle, prob_binning_);
315  setMETitle(DiMuProb_,"DiMu_#prob","events /");
316 
317  histname = "DiMuPVcos"; histtitle = "DiMuPVcos";
318  bookME(ibooker,DiMuPVcos_,histname,histtitle, cos_binning_);
319  setMETitle(DiMuPVcos_,"DiMu_#cosPV","events /");
320 
321  histname = "DiMuDS"; histtitle = "DiMuDS";
322  bookME(ibooker,DiMuDS_,histname,histtitle, ds_binning_);
323  setMETitle(DiMuDS_,"DiMu_#ds","events /");
324 
325  histname = "DiMuDCA"; histtitle = "DiMuDCA";
326  bookME(ibooker,DiMuDCA_,histname,histtitle, dca_binning_);
327  setMETitle(DiMuDCA_,"DiMu_#dca","events /");
328  }
329  } // if (enum_ == 2 || enum_ == 4 || enum_ == 5 || enum_ == 8)
330  }
331 
332  if (trOrMu_) {
333  if (false) { // not filled anywhere
334  histname = trMuPh+"_d0"; histtitle = trMuPh+"_d0";
335  bookME(ibooker,mud0_,histname,histtitle, d0_binning_);
336  setMETitle(mud0_,trMuPh+"_d0","events / bin");
337 
338  histname = trMuPh+"_z0"; histtitle = trMuPh+"_z0";
339  bookME(ibooker,muz0_,histname,histtitle, z0_binning_);
340  setMETitle(muz0_,trMuPh+"_z0","events / bin");
341  }
342  }
343 
344  // Initialize the GenericTriggerEventFlag
347 }
MEbinning z0_binning_
Definition: BPHMonitor.h:119
METME mu2Phi_
Definition: BPHMonitor.h:138
METME DiMuDCA_
Definition: BPHMonitor.h:160
METME mu2Pt_
Definition: BPHMonitor.h:140
METME muPt_
Definition: BPHMonitor.h:129
METME mu1Eta_
Definition: BPHMonitor.h:134
void bookME(DQMStore::IBooker &, METME &me, std::string &histname, std::string &histtitle, int &nbins, double &xmin, double &xmax)
Definition: BPHMonitor.cc:179
std::string folderName_
Definition: BPHMonitor.h:102
METME mu2Eta_
Definition: BPHMonitor.h:139
METME DiMuPhi_
Definition: BPHMonitor.h:154
METME mu3Pt_
Definition: BPHMonitor.h:145
MEbinning eta_binning_
Definition: BPHMonitor.h:117
METME mu1Phi_
Definition: BPHMonitor.h:133
METME DiMuEta_
Definition: BPHMonitor.h:155
MEbinning dca_binning_
Definition: BPHMonitor.h:122
void setMETitle(METME &me, std::string titleX, std::string titleY)
Definition: BPHMonitor.cc:170
MEbinning pt_binning_
Definition: BPHMonitor.h:116
MEbinning dR_binning_
Definition: BPHMonitor.h:120
GenericTriggerEventFlag * den_genTriggerEventFlag_
Definition: BPHMonitor.h:168
METME DiMuDS_
Definition: BPHMonitor.h:159
MEbinning phi_binning_
Definition: BPHMonitor.h:115
MEbinning ds_binning_
Definition: BPHMonitor.h:123
MEbinning prob_binning_
Definition: BPHMonitor.h:125
MEbinning cos_binning_
Definition: BPHMonitor.h:124
METME muz0_
Definition: BPHMonitor.h:131
METME DiMuProb_
Definition: BPHMonitor.h:158
MEbinning d0_binning_
Definition: BPHMonitor.h:118
void setCurrentFolder(const std::string &fullpath)
Definition: DQMStore.cc:274
METME muEta_
Definition: BPHMonitor.h:128
METME DiMuMass_
Definition: BPHMonitor.h:161
METME DiMuPt_
Definition: BPHMonitor.h:156
MEbinning mass_binning_
Definition: BPHMonitor.h:121
METME mud0_
Definition: BPHMonitor.h:130
METME mu1Pt_
Definition: BPHMonitor.h:135
METME mu3Phi_
Definition: BPHMonitor.h:143
METME mu3Eta_
Definition: BPHMonitor.h:144
void initRun(const edm::Run &run, const edm::EventSetup &setup)
To be called from beginRun() methods.
METME DiMuPVcos_
Definition: BPHMonitor.h:157
METME DiMudR_
Definition: BPHMonitor.h:162
GenericTriggerEventFlag * num_genTriggerEventFlag_
Definition: BPHMonitor.h:167
METME muPhi_
Definition: BPHMonitor.h:127
void BPHMonitor::bookME ( DQMStore::IBooker ibooker,
METME me,
std::string &  histname,
std::string &  histtitle,
int &  nbins,
double &  xmin,
double &  xmax 
)
protected

Definition at line 179 of file BPHMonitor.cc.

References DQMStore::IBooker::book1D(), METME::denominator, and METME::numerator.

Referenced by bookHistograms(), and bookME().

180 {
181  me.numerator = ibooker.book1D(histname+"_numerator", histtitle+" (numerator)", nbins, min, max);
182  me.denominator = ibooker.book1D(histname+"_denominator", histtitle+" (denominator)", nbins, min, max);
183 }
MonitorElement * numerator
Definition: BPHMonitor.h:60
MonitorElement * book1D(Args &&...args)
Definition: DQMStore.h:118
MonitorElement * denominator
Definition: BPHMonitor.h:61
T min(T a, T b)
Definition: MathUtil.h:58
void BPHMonitor::bookME ( DQMStore::IBooker ibooker,
METME me,
std::string &  histname,
std::string &  histtitle,
std::vector< double >  binningX 
)
protected

Definition at line 184 of file BPHMonitor.cc.

References DQMStore::IBooker::book1D(), METME::denominator, pileupCalc::nbins, and METME::numerator.

185 {
186  int nbins = binning.size()-1;
187  std::vector<float> fbinning(binning.begin(),binning.end());
188  float* arr = &fbinning[0];
189  me.numerator = ibooker.book1D(histname+"_numerator", histtitle+" (numerator)", nbins, arr);
190  me.denominator = ibooker.book1D(histname+"_denominator", histtitle+" (denominator)", nbins, arr);
191 }
MonitorElement * numerator
Definition: BPHMonitor.h:60
MonitorElement * book1D(Args &&...args)
Definition: DQMStore.h:118
MonitorElement * denominator
Definition: BPHMonitor.h:61
void BPHMonitor::bookME ( DQMStore::IBooker ibooker,
METME me,
std::string &  histname,
std::string &  histtitle,
int &  nbinsX,
double &  xmin,
double &  xmax,
double &  ymin,
double &  ymax 
)
protected

Definition at line 192 of file BPHMonitor.cc.

References DQMStore::IBooker::bookProfile(), METME::denominator, and METME::numerator.

193 {
194  me.numerator = ibooker.bookProfile(histname+"_numerator", histtitle+" (numerator)", nbinsX, xmin, xmax, ymin, ymax);
195  me.denominator = ibooker.bookProfile(histname+"_denominator", histtitle+" (denominator)", nbinsX, xmin, xmax, ymin, ymax);
196 }
MonitorElement * numerator
Definition: BPHMonitor.h:60
MonitorElement * bookProfile(Args &&...args)
Definition: DQMStore.h:160
MonitorElement * denominator
Definition: BPHMonitor.h:61
void BPHMonitor::bookME ( DQMStore::IBooker ibooker,
METME me,
std::string &  histname,
std::string &  histtitle,
int &  nbinsX,
double &  xmin,
double &  xmax,
int &  nbinsY,
double &  ymin,
double &  ymax 
)
protected

Definition at line 197 of file BPHMonitor.cc.

References DQMStore::IBooker::book2D(), METME::denominator, and METME::numerator.

198 {
199  me.numerator = ibooker.book2D(histname+"_numerator", histtitle+" (numerator)", nbinsX, xmin, xmax, nbinsY, ymin, ymax);
200  me.denominator = ibooker.book2D(histname+"_denominator", histtitle+" (denominator)", nbinsX, xmin, xmax, nbinsY, ymin, ymax);
201 }
MonitorElement * numerator
Definition: BPHMonitor.h:60
MonitorElement * denominator
Definition: BPHMonitor.h:61
MonitorElement * book2D(Args &&...args)
Definition: DQMStore.h:136
void BPHMonitor::bookME ( DQMStore::IBooker ibooker,
METME me,
std::string &  histname,
std::string &  histtitle,
std::vector< double >  binningX,
std::vector< double >  binningY 
)
protected

Definition at line 202 of file BPHMonitor.cc.

References DQMStore::IBooker::book2D(), METME::denominator, and METME::numerator.

203 {
204  int nbinsX = binningX.size()-1;
205  std::vector<float> fbinningX(binningX.begin(),binningX.end());
206  float* arrX = &fbinningX[0];
207  int nbinsY = binningY.size()-1;
208  std::vector<float> fbinningY(binningY.begin(),binningY.end());
209  float* arrY = &fbinningY[0];
210 
211  me.numerator = ibooker.book2D(histname+"_numerator", histtitle+" (numerator)", nbinsX, arrX, nbinsY, arrY);
212  me.denominator = ibooker.book2D(histname+"_denominator", histtitle+" (denominator)", nbinsX, arrX, nbinsY, arrY);
213 }
MonitorElement * numerator
Definition: BPHMonitor.h:60
MonitorElement * denominator
Definition: BPHMonitor.h:61
MonitorElement * book2D(Args &&...args)
Definition: DQMStore.h:136
void BPHMonitor::bookME ( DQMStore::IBooker ibooker,
METME me,
std::string &  histname,
std::string &  histtitle,
MEbinning binning 
)
protected

Definition at line 215 of file BPHMonitor.cc.

References bookME().

216 {
217  // If the vector in the binning is filled use the bins defined there
218  // otherwise use a linear binning between min and max
219  if (binning.edges.empty()) {
220  this->bookME(ibooker, me, histname, histtitle, binning.nbins, binning.xmin, binning.xmax);
221  } else {
222  this->bookME(ibooker, me, histname, histtitle, binning.edges);
223  }
224 }
void bookME(DQMStore::IBooker &, METME &me, std::string &histname, std::string &histtitle, int &nbins, double &xmin, double &xmax)
Definition: BPHMonitor.cc:179
void BPHMonitor::case11_selection ( const float &  dimuonCL,
const float &  jpsi_cos,
const GlobalPoint displacementFromBeamspotJpsi,
const GlobalError jerr,
const edm::Handle< reco::TrackCollection > &  trHandle,
const std::string &  hltpath,
const edm::Handle< trigger::TriggerEvent > &  handleTriggerEvent,
const reco::Muon m,
const reco::Muon m1,
const edm::ESHandle< MagneticField > &  bFieldHandle,
const reco::BeamSpot vertexBeamSpot,
MonitorElement phi1,
MonitorElement eta1,
MonitorElement pT1,
MonitorElement phi2,
MonitorElement eta2,
MonitorElement pT2 
)

Definition at line 1166 of file BPHMonitor.cc.

References reco::Vertex::chi2(), DEFINE_FWK_MODULE, reco::deltaR(), reco::BeamSpot::dxdz(), reco::BeamSpot::dydz(), SiPixelPhase1TrackClustersV_cfi::e3, vertexPlots::e4, MonitorElement::Fill(), reco::TrackBase::highPurity, edm::HandleBase::isValid(), TransientVertex::isValid(), kaon_mass, matchToTrigger(), maxmassJpsiTk, maxmassTkTk, min_dR, mincos, minDS, minmassJpsiTk, minmassTkTk, minprob, reco::LeafCandidate::momentum(), reco::TrackBase::momentum(), mu_mass, reco::Vertex::ndof(), p1, p2, p3, p4, PV3DBase< T, PVType, FrameType >::perp(), TransientVertex::position(), TransientVertex::positionError(), reco::LeafCandidate::px(), reco::TrackBase::px(), reco::LeafCandidate::py(), reco::TrackBase::py(), reco::LeafCandidate::pz(), reco::TrackBase::pz(), reco::TrackBase::quality(), GlobalErrorBase< T, ErrorWeightType >::rerr(), mathSSE::sqrt(), lumiQTWidget::t, reco::Muon::track(), trSelection_ref, KalmanVertexFitter::vertex(), PV3DBase< T, PVType, FrameType >::x(), reco::BeamSpot::x0(), PV3DBase< T, PVType, FrameType >::y(), reco::BeamSpot::y0(), PV3DBase< T, PVType, FrameType >::z(), and reco::BeamSpot::z0().

Referenced by analyze().

1166  {
1167  //cout <<"\nInside case11_selection" <<endl;
1168  if (dimuonCL < minprob) return;
1169  if (fabs(jpsi_cos) < mincos) return;
1170  if ((displacementFromBeamspotJpsi.perp() / sqrt(jerr.rerr(displacementFromBeamspotJpsi))) < minDS) return;
1171  if (trHandle.isValid()) {
1173  for (auto const & t : *trHandle) {
1174  if (!trSelection_ref(t)) continue;
1175  if (false && !matchToTrigger(hltpath,t, handleTriggerEvent)) continue;
1176  if ((reco::deltaR(t,m) <= min_dR)) continue; // checking overlapping
1177  if ((reco::deltaR(t,m1) <= min_dR)) continue; // checking overlapping
1178  for (auto const & t1 : *trHandle) {
1179  if (&t - &(*trHandle)[0] >= &t1 - &(*trHandle)[0]) continue; // not enough, need the following DeltaR checks
1180  //if (t.pt() == t1.pt()) continue;
1181  if (!trSelection_ref(t1)) continue;
1182  if (false && !matchToTrigger(hltpath,t1, handleTriggerEvent)) continue;
1183  if ((reco::deltaR(t1,m) <= min_dR)) continue; // checking overlapping
1184  if ((reco::deltaR(t1,m1) <= min_dR)) continue; // checking overlapping
1185  if ((reco::deltaR(t,t1) <= min_dR)) continue; // checking overlapping
1186  const reco::Track& itrk1 = t ;
1187  const reco::Track& itrk2 = t1 ;
1188  if (! itrk1.quality(reco::TrackBase::highPurity)) continue;
1189  if (! itrk2.quality(reco::TrackBase::highPurity)) continue;
1190  reco::Particle::LorentzVector pB, pTkTk, p1, p2, p3, p4;
1191  double trackMass2 = kaon_mass * kaon_mass;
1192  double MuMass2 = mu_mass * mu_mass; // 0.1056583745 *0.1056583745;
1193  double e1 = sqrt(m.momentum().Mag2() + MuMass2 );
1194  double e2 = sqrt(m1.momentum().Mag2() + MuMass2 );
1195  double e3 = sqrt(itrk1.momentum().Mag2() + trackMass2 );
1196  double e4 = sqrt(itrk2.momentum().Mag2() + trackMass2 );
1197  p1 = reco::Particle::LorentzVector(m.px() , m.py() , m.pz() , e1 );
1198  p2 = reco::Particle::LorentzVector(m1.px() , m1.py() , m1.pz() , e2 );
1199  p3 = reco::Particle::LorentzVector(itrk1.px(), itrk1.py(), itrk1.pz(), e3 );
1200  p4 = reco::Particle::LorentzVector(itrk2.px(), itrk2.py(), itrk2.pz(), e4 );
1201  pTkTk = p3 + p4;
1202  if (pTkTk.mass() > maxmassTkTk || pTkTk.mass() < minmassTkTk) continue;
1203  pB = p1 + p2 + p3 + p4;
1204  if ( pB.mass() > maxmassJpsiTk || pB.mass()< minmassJpsiTk) continue;
1205  reco::TransientTrack mu1TT(m.track(), &(*bFieldHandle));
1206  reco::TransientTrack mu2TT(m1.track(), &(*bFieldHandle));
1207  reco::TransientTrack trTT(itrk1, &(*bFieldHandle));
1208  reco::TransientTrack tr1TT(itrk2, &(*bFieldHandle));
1209  std::vector<reco::TransientTrack> t_tks;
1210  t_tks.push_back(mu1TT);
1211  t_tks.push_back(mu2TT);
1212  t_tks.push_back(trTT);
1213  t_tks.push_back(tr1TT);
1214  KalmanVertexFitter kvf;
1215  TransientVertex tv = kvf.vertex(t_tks); // this will compare the tracks
1216  reco::Vertex vertex = tv;
1217  if (!tv.isValid()) continue;
1218  float JpsiTkCL = 0;
1219  if ((vertex.chi2() >= 0.0) && (vertex.ndof() > 0) )
1220  JpsiTkCL = TMath::Prob(vertex.chi2(), vertex.ndof() );
1221  math::XYZVector pperp(m.px() + m1.px() + itrk1.px() + itrk2.px(),
1222  m.py() + m1.py() + itrk1.py() + itrk2.py(),
1223  0.);
1224  GlobalPoint secondaryVertex = tv.position();
1225  GlobalError err = tv.positionError();
1226  GlobalPoint displacementFromBeamspot( -1*((vertexBeamSpot.x0() - secondaryVertex.x()) +
1227  (secondaryVertex.z() - vertexBeamSpot.z0()) * vertexBeamSpot.dxdz()),
1228  -1*((vertexBeamSpot.y0() - secondaryVertex.y()) +
1229  (secondaryVertex.z() - vertexBeamSpot.z0()) * vertexBeamSpot.dydz()),
1230  0);
1231  reco::Vertex::Point vperp(displacementFromBeamspot.x(),displacementFromBeamspot.y(),0.);
1232  float jpsiKcos = vperp.Dot(pperp) / (vperp.R()*pperp.R());
1233  if (JpsiTkCL < minprob) continue;
1234  if (fabs(jpsiKcos) < mincos) continue;
1235  if ((displacementFromBeamspot.perp() / sqrt(err.rerr(displacementFromBeamspot))) < minDS) continue;
1236 
1237  phi1->Fill(t.phi());
1238  eta1->Fill(t.eta());
1239  pT1->Fill(t.pt());
1240  phi2->Fill(t1.phi());
1241  eta2->Fill(t1.eta());
1242  pT2->Fill(t1.pt());
1243  } // for (auto const & t1 : *trHandle)
1244  } // for (auto const & t : *trHandle)
1245  } // if (trHandle.isValid())
1246 }
GlobalError positionError() const
double z0() const
z coordinate
Definition: BeamSpot.h:68
TrackRef track() const override
reference to a Track
Definition: Muon.h:49
T perp() const
Definition: PV3DBase.h:72
double maxmassJpsiTk
Definition: BPHMonitor.h:189
double kaon_mass
Definition: BPHMonitor.h:191
double px() const final
x coordinate of momentum vector
T y() const
Definition: PV3DBase.h:63
bool matchToTrigger(const std::string &theTriggerName, T t, edm::Handle< trigger::TriggerEvent > handleTriggerEvent)
Definition: BPHMonitor.cc:1138
double px() const
x coordinate of momentum vector
Definition: TrackBase.h:627
const Vector & momentum() const
track momentum vector
Definition: TrackBase.h:675
double maxmassTkTk
Definition: BPHMonitor.h:187
double minprob
Definition: BPHMonitor.h:195
void Fill(long long x)
double dydz() const
dydz slope
Definition: BeamSpot.h:84
Vector momentum() const final
spatial momentum vector
double mincos
Definition: BPHMonitor.h:196
double pz() const final
z coordinate of momentum vector
T sqrt(T t)
Definition: SSEVec.h:18
double p4[4]
Definition: TauolaWrapper.h:92
GlobalPoint position() const
T z() const
Definition: PV3DBase.h:64
double mu_mass
Definition: BPHMonitor.h:192
double chi2() const
chi-squares
Definition: Vertex.h:98
CachingVertex< 5 > vertex(const std::vector< reco::TransientTrack > &tracks) const override
math::XYZPoint Point
point in the space
Definition: Vertex.h:39
bool isValid() const
Definition: HandleBase.h:74
double p2[4]
Definition: TauolaWrapper.h:90
double dxdz() const
dxdz slope
Definition: BeamSpot.h:82
double ndof() const
Definition: Vertex.h:105
double pz() const
z coordinate of momentum vector
Definition: TrackBase.h:639
constexpr auto deltaR(const T1 &t1, const T2 &t2) -> decltype(t1.eta())
Definition: deltaR.h:28
double minmassJpsiTk
Definition: BPHMonitor.h:190
double minDS
Definition: BPHMonitor.h:197
XYZVectorD XYZVector
spatial vector with cartesian internal representation
Definition: Vector3D.h:30
T rerr(const GlobalPoint &aPoint) const
double py() const final
y coordinate of momentum vector
bool quality(const TrackQuality) const
Track quality.
Definition: TrackBase.h:510
double minmassTkTk
Definition: BPHMonitor.h:188
double p1[4]
Definition: TauolaWrapper.h:89
double y0() const
y coordinate
Definition: BeamSpot.h:66
T x() const
Definition: PV3DBase.h:62
math::XYZTLorentzVector LorentzVector
Lorentz vector.
Definition: Particle.h:21
bool isValid() const
StringCutObjectSelector< reco::Track, true > trSelection_ref
Definition: BPHMonitor.h:203
double py() const
y coordinate of momentum vector
Definition: TrackBase.h:633
double p3[4]
Definition: TauolaWrapper.h:91
double x0() const
x coordinate
Definition: BeamSpot.h:64
double min_dR
Definition: BPHMonitor.h:193
void BPHMonitor::fillDescriptions ( edm::ConfigurationDescriptions descriptions)
static

Definition at line 1037 of file BPHMonitor.cc.

References edm::ConfigurationDescriptions::add(), edm::ParameterSetDescription::add(), funct::false, fillHistoPSetDescription(), and AlCaHLTBitMon_QueryRunRegistry::string.

1038 {
1040  desc.add<std::string> ( "FolderName", "HLT/BPH/" );
1041  desc.add<edm::InputTag>( "tracks", edm::InputTag("generalTracks") );
1042  desc.add<edm::InputTag>( "photons", edm::InputTag("photons") );
1043  desc.add<edm::InputTag>( "offlinePVs", edm::InputTag("offlinePrimaryVertices") );
1044  desc.add<edm::InputTag>( "beamSpot",edm::InputTag("offlineBeamSpot") );
1045  desc.add<edm::InputTag>( "muons", edm::InputTag("muons") );
1046  desc.add<edm::InputTag>( "hltTriggerSummaryAOD", edm::InputTag("hltTriggerSummaryAOD","","HLT") );
1047  desc.add<std::string>("muoSelection", "abs(eta)<1.4 & isPFMuon & isGlobalMuon & innerTrack.hitPattern.trackerLayersWithMeasurement>5 & innerTrack.hitPattern.numberOfValidPixelHits> 0");
1048  desc.add<std::string>("muoSelection_ref", "isPFMuon & isGlobalMuon & innerTrack.hitPattern.trackerLayersWithMeasurement>5 & innerTrack.hitPattern.numberOfValidPixelHits> 0");
1049  desc.add<std::string>("muoSelection_tag", "isGlobalMuon && isPFMuon && isTrackerMuon && abs(eta) < 2.4 && innerTrack.hitPattern.numberOfValidPixelHits > 0 && innerTrack.hitPattern.trackerLayersWithMeasurement > 5 && globalTrack.hitPattern.numberOfValidMuonHits > 0 && globalTrack.normalizedChi2 < 10"); // tight selection for tag muon
1050  desc.add<std::string>("muoSelection_probe", "isPFMuon & isGlobalMuon & innerTrack.hitPattern.trackerLayersWithMeasurement>5 & innerTrack.hitPattern.numberOfValidPixelHits> 0");
1051  desc.add<std::string>("trSelection_ref", "");
1052  desc.add<std::string>("DMSelection_ref", "Pt>4 & abs(eta)");
1053 
1054  desc.add<int>("nmuons", 1);
1055  desc.add<bool>( "tnp", false );
1056  desc.add<int>( "L3", 0 );
1057  desc.add<int>( "trOrMu", 0 ); // if =0, track param monitoring
1058  desc.add<int>( "Jpsi", 0 );
1059  desc.add<int>( "Upsilon", 0 );
1060  desc.add<int>( "enum", 1 ); // 1...9, 9 sets of variables to be filled, depends on the hlt path
1061  desc.add<int>( "seagull", 1 ); // 1...9, 9 sets of variables to be filled, depends on the hlt path
1062  desc.add<double>( "maxmass", 3.596 );
1063  desc.add<double>( "minmass", 2.596 );
1064  desc.add<double>( "maxmassJpsi", 3.2 );
1065  desc.add<double>( "minmassJpsi", 3. );
1066  desc.add<double>( "maxmassUpsilon", 8.1 );
1067  desc.add<double>( "minmassUpsilon", 8. );
1068  desc.add<double>( "maxmassTkTk", 10);
1069  desc.add<double>( "minmassTkTk", 0);
1070  desc.add<double>( "maxmassJpsiTk", 5.46 );
1071  desc.add<double>( "minmassJpsiTk", 5.1 );
1072  desc.add<double>( "kaon_mass", 0.493677 );
1073  desc.add<double>( "mu_mass", 0.1056583745);
1074  desc.add<double>( "min_dR", 0.001);
1075  desc.add<double>( "minprob", 0.005 );
1076  desc.add<double>( "mincos", 0.95 );
1077  desc.add<double>( "minDS", 3. );
1078 
1079  edm::ParameterSetDescription genericTriggerEventPSet;
1080  genericTriggerEventPSet.add<bool>("andOr");
1081  genericTriggerEventPSet.add<edm::InputTag>("dcsInputTag", edm::InputTag("scalersRawToDigi") );
1082  genericTriggerEventPSet.add<edm::InputTag>("hltInputTag", edm::InputTag("TriggerResults::HLT") );
1083  genericTriggerEventPSet.add<std::vector<int> >("dcsPartitions",{});
1084  genericTriggerEventPSet.add<bool>("andOrDcs", false);
1085  genericTriggerEventPSet.add<bool>("errorReplyDcs", true);
1086  genericTriggerEventPSet.add<std::string>("dbLabel","");
1087  genericTriggerEventPSet.add<bool>("andOrHlt", true);
1088  genericTriggerEventPSet.add<bool>("andOrL1", true);
1089  genericTriggerEventPSet.add<std::vector<std::string> >("hltPaths",{});
1090  genericTriggerEventPSet.add<std::vector<std::string> >("l1Algorithms",{});
1091  genericTriggerEventPSet.add<std::string>("hltDBKey","");
1092  genericTriggerEventPSet.add<bool>("errorReplyHlt",false);
1093  genericTriggerEventPSet.add<bool>("errorReplyL1",true);
1094  genericTriggerEventPSet.add<bool>("l1BeforeMask",true);
1095  genericTriggerEventPSet.add<unsigned int>("verbosityLevel",0);
1096  desc.add<edm::ParameterSetDescription>("numGenericTriggerEventPSet", genericTriggerEventPSet);
1097  desc.add<edm::ParameterSetDescription>("denGenericTriggerEventPSet", genericTriggerEventPSet);
1098 
1099  edm::ParameterSetDescription histoPSet;
1111  fillHistoPSetDescription(phiPSet);
1112  fillHistoPSetDescription(ptPSet);
1113  fillHistoPSetDescription(etaPSet);
1114  fillHistoPSetDescription(z0PSet);
1115  fillHistoPSetDescription(d0PSet);
1116  fillHistoPSetDescription(dRPSet);
1117  fillHistoPSetDescription(massPSet);
1118  fillHistoPSetDescription(dcaPSet);
1119  fillHistoPSetDescription(dsPSet);
1120  fillHistoPSetDescription(cosPSet);
1121  fillHistoPSetDescription(probPSet);
1122  histoPSet.add<edm::ParameterSetDescription>("d0PSet", d0PSet);
1123  histoPSet.add<edm::ParameterSetDescription>("etaPSet", etaPSet);
1124  histoPSet.add<edm::ParameterSetDescription>("phiPSet", phiPSet);
1125  histoPSet.add<edm::ParameterSetDescription>("ptPSet", ptPSet);
1126  histoPSet.add<edm::ParameterSetDescription>("z0PSet", z0PSet);
1127  histoPSet.add<edm::ParameterSetDescription>("dRPSet", dRPSet);
1128  histoPSet.add<edm::ParameterSetDescription>("massPSet", massPSet);
1129  histoPSet.add<edm::ParameterSetDescription>("dcaPSet", dcaPSet);
1130  histoPSet.add<edm::ParameterSetDescription>("dsPSet", dsPSet);
1131  histoPSet.add<edm::ParameterSetDescription>("cosPSet", cosPSet);
1132  histoPSet.add<edm::ParameterSetDescription>("probPSet", probPSet);
1133  desc.add<edm::ParameterSetDescription>("histoPSet",histoPSet);
1134 
1135  descriptions.add("bphMonitoring", desc);
1136 }
static void fillHistoPSetDescription(edm::ParameterSetDescription &pset)
Definition: BPHMonitor.cc:1024
ParameterDescriptionBase * add(U const &iLabel, T const &value)
void add(std::string const &label, ParameterSetDescription const &psetDescription)
void BPHMonitor::fillHistoLSPSetDescription ( edm::ParameterSetDescription pset)
static

Definition at line 1032 of file BPHMonitor.cc.

References edm::ParameterSetDescription::add().

1033 {
1034  pset.add<int> ( "nbins", 2500);
1035 }
ParameterDescriptionBase * add(U const &iLabel, T const &value)
void BPHMonitor::fillHistoPSetDescription ( edm::ParameterSetDescription pset)
static

Definition at line 1024 of file BPHMonitor.cc.

References edm::ParameterSetDescription::addNode().

Referenced by fillDescriptions().

1025 {
1026  pset.addNode((edm::ParameterDescription<int>("nbins", true) and
1027  edm::ParameterDescription<double>("xmin", true) and
1028  edm::ParameterDescription<double>("xmax", true)) xor
1029  edm::ParameterDescription<std::vector<double>>("edges", true));
1030 }
ParameterDescriptionNode * addNode(ParameterDescriptionNode const &node)
MEbinning BPHMonitor::getHistoPSet ( edm::ParameterSet  pset)
staticprivate

Definition at line 146 of file BPHMonitor.cc.

References edm::ParameterSet::existsAs(), and edm::ParameterSet::getParameter().

147 {
148  // Due to the setup of the fillDescription only one of the
149  // two cases is possible at this point.
150  if (pset.existsAs<std::vector<double>>("edges")) {
151  return MEbinning{pset.getParameter<std::vector<double>>("edges")};
152  }
153 
154  return MEbinning {
155  pset.getParameter<int32_t>("nbins"),
156  pset.getParameter<double>("xmin"),
157  pset.getParameter<double>("xmax"),
158  };
159 }
T getParameter(std::string const &) const
bool existsAs(std::string const &parameterName, bool trackiness=true) const
checks if a parameter exists as a given type
Definition: ParameterSet.h:186
template<typename T >
bool BPHMonitor::matchToTrigger ( const std::string &  theTriggerName,
T  t,
edm::Handle< trigger::TriggerEvent handleTriggerEvent 
)
protected

Definition at line 1138 of file BPHMonitor.cc.

References gather_cfg::cout, reco::deltaR(), edm::InputTag::encode(), reco::Particle::eta(), trigger::TriggerEvent::filterKeys(), trigger::TriggerEvent::filterTag(), trigger::TriggerEvent::getObjects(), gen::k, dataset::name, AlCaHLTBitMon_ParallelJobs::p, reco::Particle::phi(), trigger::TriggerEvent::sizeFilters(), and AlCaHLTBitMon_QueryRunRegistry::string.

Referenced by analyze(), and case11_selection().

1138  {
1139  //bool BPHMonitor::matchToTrigger(std::string theTriggerName,T t, edm::Handle<trigger::TriggerEventWithRefs> handleTriggerEvent) {
1140 
1141  bool matchedToTrigger = false;
1142  if (handleTriggerEvent->sizeFilters() > 0) {
1143  const trigger::TriggerObjectCollection & toc(handleTriggerEvent->getObjects()); //Handle< trigger::TriggerEvent > handleTriggerEvent;
1144  for ( size_t ia = 0; ia < handleTriggerEvent->sizeFilters(); ++ ia) {
1145  std::string fullname = handleTriggerEvent->filterTag(ia).encode();
1146  std::string name;
1147  size_t p = fullname.find_first_of(':');
1148  if ( p != std::string::npos) {name = fullname.substr(0, p);}
1149  else {name = fullname;}
1150  const trigger::Keys & k = handleTriggerEvent->filterKeys(ia);
1151  for (trigger::Keys::const_iterator ki = k.begin(); ki !=k.end(); ++ki ) {
1152  reco::Particle theTriggerParticle = toc[*ki].particle();
1153  if (name.find(theTriggerName) != string::npos) {
1154  if ((reco::deltaR(t.eta(), t.phi(),theTriggerParticle.eta(),theTriggerParticle.phi()) <= 0.2)) {
1155  matchedToTrigger = true;
1156  }
1157  }
1158  }
1159  }
1160 
1161  return matchedToTrigger;
1162  }
1163  else {cout <<theTriggerName <<"\t\tNo HLT filters" <<endl; return false;}
1164 }
trigger::size_type sizeFilters() const
Definition: TriggerEvent.h:135
const Keys & filterKeys(trigger::size_type index) const
Definition: TriggerEvent.h:111
std::string encode() const
Definition: InputTag.cc:166
double phi() const
momentum azimuthal angle
Definition: Particle.h:106
const TriggerObjectCollection & getObjects() const
Definition: TriggerEvent.h:98
constexpr auto deltaR(const T1 &t1, const T2 &t2) -> decltype(t1.eta())
Definition: deltaR.h:28
int k[5][pyjets_maxn]
std::vector< TriggerObject > TriggerObjectCollection
collection of trigger physics objects (e.g., all isolated muons)
Definition: TriggerObject.h:81
const edm::InputTag filterTag(trigger::size_type index) const
Definition: TriggerEvent.h:103
std::vector< size_type > Keys
double eta() const
momentum pseudorapidity
Definition: Particle.h:110
void BPHMonitor::setMETitle ( METME me,
std::string  titleX,
std::string  titleY 
)
protected

Definition at line 170 of file BPHMonitor.cc.

References METME::denominator, METME::numerator, and MonitorElement::setAxisTitle().

Referenced by bookHistograms().

171 {
172  me.numerator->setAxisTitle(titleX,1);
173  me.numerator->setAxisTitle(titleY,2);
174  me.denominator->setAxisTitle(titleX,1);
175  me.denominator->setAxisTitle(titleY,2);
176 
177 }
MonitorElement * numerator
Definition: BPHMonitor.h:60
MonitorElement * denominator
Definition: BPHMonitor.h:61
void setAxisTitle(const std::string &title, int axis=1)
set x-, y- or z-axis title (axis=1, 2, 3 respectively)

Member Data Documentation

edm::InputTag BPHMonitor::bsInputTag_
private

Definition at line 106 of file BPHMonitor.h.

Referenced by analyze().

edm::EDGetTokenT<reco::BeamSpot> BPHMonitor::bsToken_
private

Definition at line 111 of file BPHMonitor.h.

Referenced by analyze().

MEbinning BPHMonitor::cos_binning_
private

Definition at line 124 of file BPHMonitor.h.

Referenced by bookHistograms().

MEbinning BPHMonitor::d0_binning_
private

Definition at line 118 of file BPHMonitor.h.

Referenced by bookHistograms().

MEbinning BPHMonitor::dca_binning_
private

Definition at line 122 of file BPHMonitor.h.

Referenced by bookHistograms().

GenericTriggerEventFlag* BPHMonitor::den_genTriggerEventFlag_
private

Definition at line 168 of file BPHMonitor.h.

Referenced by analyze(), bookHistograms(), and ~BPHMonitor().

METME BPHMonitor::DiMuDCA_
private

Definition at line 160 of file BPHMonitor.h.

Referenced by analyze(), bookHistograms(), and BPHMonitor().

METME BPHMonitor::DiMudR_
private

Definition at line 162 of file BPHMonitor.h.

Referenced by analyze(), bookHistograms(), and BPHMonitor().

METME BPHMonitor::DiMuDS_
private

Definition at line 159 of file BPHMonitor.h.

Referenced by analyze(), bookHistograms(), and BPHMonitor().

METME BPHMonitor::DiMuEta_
private

Definition at line 155 of file BPHMonitor.h.

Referenced by analyze(), bookHistograms(), and BPHMonitor().

METME BPHMonitor::DiMuMass_
private

Definition at line 161 of file BPHMonitor.h.

Referenced by analyze(), bookHistograms(), and BPHMonitor().

METME BPHMonitor::DiMuPhi_
private

Definition at line 154 of file BPHMonitor.h.

Referenced by analyze(), bookHistograms(), and BPHMonitor().

METME BPHMonitor::DiMuProb_
private

Definition at line 158 of file BPHMonitor.h.

Referenced by analyze(), bookHistograms(), and BPHMonitor().

METME BPHMonitor::DiMuPt_
private

Definition at line 156 of file BPHMonitor.h.

Referenced by analyze(), bookHistograms(), and BPHMonitor().

METME BPHMonitor::DiMuPVcos_
private

Definition at line 157 of file BPHMonitor.h.

Referenced by analyze(), bookHistograms(), and BPHMonitor().

StringCutObjectSelector<reco::Candidate::LorentzVector,true> BPHMonitor::DMSelection_ref
private

Definition at line 204 of file BPHMonitor.h.

Referenced by analyze().

MEbinning BPHMonitor::dR_binning_
private

Definition at line 120 of file BPHMonitor.h.

Referenced by bookHistograms().

MEbinning BPHMonitor::ds_binning_
private

Definition at line 123 of file BPHMonitor.h.

Referenced by bookHistograms().

int BPHMonitor::enum_
private

Definition at line 179 of file BPHMonitor.h.

Referenced by analyze(), and bookHistograms().

MEbinning BPHMonitor::eta_binning_
private

Definition at line 117 of file BPHMonitor.h.

Referenced by bookHistograms().

std::string BPHMonitor::folderName_
private

Definition at line 102 of file BPHMonitor.h.

Referenced by bookHistograms().

std::string BPHMonitor::histoSuffix_
private

Definition at line 103 of file BPHMonitor.h.

edm::EDGetTokenT<trigger::TriggerEvent> BPHMonitor::hltInputTag_
private

Definition at line 199 of file BPHMonitor.h.

Referenced by analyze().

std::vector<std::string> BPHMonitor::hltpaths_den
private

Definition at line 201 of file BPHMonitor.h.

Referenced by analyze().

std::vector<std::string> BPHMonitor::hltpaths_num
private

Definition at line 200 of file BPHMonitor.h.

Referenced by analyze().

edm::EDGetTokenT<edm::TriggerResults> BPHMonitor::hltTrigResTag_
private

Definition at line 198 of file BPHMonitor.h.

int BPHMonitor::Jpsi_
private

Definition at line 177 of file BPHMonitor.h.

Referenced by analyze().

double BPHMonitor::kaon_mass
private

Definition at line 191 of file BPHMonitor.h.

Referenced by analyze(), and case11_selection().

int BPHMonitor::L3_
private

Definition at line 175 of file BPHMonitor.h.

MEbinning BPHMonitor::mass_binning_
private

Definition at line 121 of file BPHMonitor.h.

Referenced by bookHistograms().

double BPHMonitor::maxmass_
private

Definition at line 181 of file BPHMonitor.h.

Referenced by analyze().

double BPHMonitor::maxmassJpsi
private

Definition at line 183 of file BPHMonitor.h.

Referenced by analyze().

double BPHMonitor::maxmassJpsiTk
private

Definition at line 189 of file BPHMonitor.h.

Referenced by analyze(), and case11_selection().

double BPHMonitor::maxmassTkTk
private

Definition at line 187 of file BPHMonitor.h.

Referenced by case11_selection().

double BPHMonitor::maxmassUpsilon
private

Definition at line 185 of file BPHMonitor.h.

Referenced by analyze().

double BPHMonitor::min_dR
private

Definition at line 193 of file BPHMonitor.h.

Referenced by analyze(), and case11_selection().

double BPHMonitor::mincos
private

Definition at line 196 of file BPHMonitor.h.

Referenced by analyze(), and case11_selection().

double BPHMonitor::minDS
private

Definition at line 197 of file BPHMonitor.h.

Referenced by analyze(), and case11_selection().

double BPHMonitor::minmass_
private

Definition at line 182 of file BPHMonitor.h.

Referenced by analyze().

double BPHMonitor::minmassJpsi
private

Definition at line 184 of file BPHMonitor.h.

Referenced by analyze().

double BPHMonitor::minmassJpsiTk
private

Definition at line 190 of file BPHMonitor.h.

Referenced by analyze(), and case11_selection().

double BPHMonitor::minmassTkTk
private

Definition at line 188 of file BPHMonitor.h.

Referenced by case11_selection().

double BPHMonitor::minmassUpsilon
private

Definition at line 186 of file BPHMonitor.h.

Referenced by analyze().

double BPHMonitor::minprob
private

Definition at line 195 of file BPHMonitor.h.

Referenced by analyze(), and case11_selection().

METME BPHMonitor::mu1d0_
private

Definition at line 136 of file BPHMonitor.h.

METME BPHMonitor::mu1Eta_
private

Definition at line 134 of file BPHMonitor.h.

Referenced by analyze(), bookHistograms(), and BPHMonitor().

METME BPHMonitor::mu1Phi_
private

Definition at line 133 of file BPHMonitor.h.

Referenced by analyze(), bookHistograms(), and BPHMonitor().

METME BPHMonitor::mu1Pt_
private

Definition at line 135 of file BPHMonitor.h.

Referenced by analyze(), bookHistograms(), and BPHMonitor().

METME BPHMonitor::mu1z0_
private

Definition at line 137 of file BPHMonitor.h.

METME BPHMonitor::mu2d0_
private

Definition at line 141 of file BPHMonitor.h.

METME BPHMonitor::mu2Eta_
private

Definition at line 139 of file BPHMonitor.h.

Referenced by analyze(), bookHistograms(), and BPHMonitor().

METME BPHMonitor::mu2Phi_
private

Definition at line 138 of file BPHMonitor.h.

Referenced by analyze(), bookHistograms(), and BPHMonitor().

METME BPHMonitor::mu2Pt_
private

Definition at line 140 of file BPHMonitor.h.

Referenced by analyze(), bookHistograms(), and BPHMonitor().

METME BPHMonitor::mu2z0_
private

Definition at line 142 of file BPHMonitor.h.

METME BPHMonitor::mu3d0_
private

Definition at line 146 of file BPHMonitor.h.

METME BPHMonitor::mu3Eta_
private

Definition at line 144 of file BPHMonitor.h.

Referenced by analyze(), bookHistograms(), and BPHMonitor().

METME BPHMonitor::mu3Phi_
private

Definition at line 143 of file BPHMonitor.h.

Referenced by analyze(), bookHistograms(), and BPHMonitor().

METME BPHMonitor::mu3Pt_
private

Definition at line 145 of file BPHMonitor.h.

Referenced by analyze(), bookHistograms(), and BPHMonitor().

METME BPHMonitor::mu3z0_
private

Definition at line 147 of file BPHMonitor.h.

double BPHMonitor::mu_mass
private

Definition at line 192 of file BPHMonitor.h.

Referenced by analyze(), and case11_selection().

METME BPHMonitor::mud0_
private

Definition at line 130 of file BPHMonitor.h.

Referenced by bookHistograms(), and BPHMonitor().

METME BPHMonitor::muEta_
private

Definition at line 128 of file BPHMonitor.h.

Referenced by analyze(), bookHistograms(), and BPHMonitor().

edm::InputTag BPHMonitor::muoInputTag_
private

Definition at line 105 of file BPHMonitor.h.

Referenced by analyze().

StringCutObjectSelector<reco::Muon,true> BPHMonitor::muoSelection_
private

Definition at line 169 of file BPHMonitor.h.

Referenced by analyze().

StringCutObjectSelector<reco::Muon,true> BPHMonitor::muoSelection_probe
private

Definition at line 172 of file BPHMonitor.h.

StringCutObjectSelector<reco::Muon,true> BPHMonitor::muoSelection_ref
private

Definition at line 170 of file BPHMonitor.h.

Referenced by analyze().

StringCutObjectSelector<reco::Muon,true> BPHMonitor::muoSelection_tag
private

Definition at line 171 of file BPHMonitor.h.

edm::EDGetTokenT<reco::MuonCollection> BPHMonitor::muoToken_
private

Definition at line 110 of file BPHMonitor.h.

Referenced by analyze().

METME BPHMonitor::muPhi_
private

Definition at line 127 of file BPHMonitor.h.

Referenced by analyze(), bookHistograms(), and BPHMonitor().

METME BPHMonitor::muPt_
private

Definition at line 129 of file BPHMonitor.h.

Referenced by analyze(), bookHistograms(), and BPHMonitor().

METME BPHMonitor::muz0_
private

Definition at line 131 of file BPHMonitor.h.

Referenced by bookHistograms(), and BPHMonitor().

int BPHMonitor::nmuons_
private

Definition at line 173 of file BPHMonitor.h.

GenericTriggerEventFlag* BPHMonitor::num_genTriggerEventFlag_
private

Definition at line 167 of file BPHMonitor.h.

Referenced by analyze(), bookHistograms(), and ~BPHMonitor().

METME BPHMonitor::phEta_
private

Definition at line 152 of file BPHMonitor.h.

Referenced by analyze(), and BPHMonitor().

MEbinning BPHMonitor::phi_binning_
private

Definition at line 115 of file BPHMonitor.h.

Referenced by bookHistograms().

edm::InputTag BPHMonitor::phInputTag_
private

Definition at line 108 of file BPHMonitor.h.

Referenced by analyze().

METME BPHMonitor::phPhi_
private

Definition at line 151 of file BPHMonitor.h.

Referenced by analyze(), and BPHMonitor().

METME BPHMonitor::phPt_
private

Definition at line 153 of file BPHMonitor.h.

Referenced by analyze(), and BPHMonitor().

edm::EDGetTokenT<reco::PhotonCollection> BPHMonitor::phToken_
private

Definition at line 113 of file BPHMonitor.h.

Referenced by analyze().

MEbinning BPHMonitor::prob_binning_
private

Definition at line 125 of file BPHMonitor.h.

Referenced by bookHistograms().

MEbinning BPHMonitor::pt_binning_
private

Definition at line 116 of file BPHMonitor.h.

Referenced by bookHistograms().

int BPHMonitor::seagull_
private

Definition at line 180 of file BPHMonitor.h.

Referenced by analyze().

bool BPHMonitor::tnp_
private

Definition at line 174 of file BPHMonitor.h.

Referenced by analyze(), and bookHistograms().

edm::InputTag BPHMonitor::trInputTag_
private

Definition at line 107 of file BPHMonitor.h.

Referenced by analyze().

int BPHMonitor::trOrMu_
private

Definition at line 176 of file BPHMonitor.h.

Referenced by bookHistograms().

StringCutObjectSelector<reco::Track,true> BPHMonitor::trSelection_
private

Definition at line 202 of file BPHMonitor.h.

StringCutObjectSelector<reco::Track,true> BPHMonitor::trSelection_ref
private

Definition at line 203 of file BPHMonitor.h.

Referenced by analyze(), and case11_selection().

edm::EDGetTokenT<reco::TrackCollection> BPHMonitor::trToken_
private

Definition at line 112 of file BPHMonitor.h.

Referenced by analyze().

int BPHMonitor::Upsilon_
private

Definition at line 178 of file BPHMonitor.h.

Referenced by analyze().

std::vector<bool> BPHMonitor::warningPrinted4token_
private

Definition at line 206 of file BPHMonitor.h.

Referenced by analyze(), and BPHMonitor().

MEbinning BPHMonitor::z0_binning_
private

Definition at line 119 of file BPHMonitor.h.

Referenced by bookHistograms().