Module to analyze the performance of muon reconstruction on the example of Z->mumu events. More...
#include "PhysicsTools/PatExamples/plugins/PatZToMuMuAnalyzer.h"
Public Types | |
typedef math::XYZTLorentzVector | LorentzVector |
typedef math::XYZVector | Vector |
typedef's to simplify get functions More... | |
Public Types inherited from edm::EDAnalyzer | |
typedef EDAnalyzer | ModuleType |
Public Types inherited from edm::EDConsumerBase | |
typedef ProductLabels | Labels |
Public Member Functions | |
PatZToMuMuAnalyzer (const edm::ParameterSet &cfg) | |
default constructor More... | |
~PatZToMuMuAnalyzer () | |
default destructor More... | |
Public Member Functions inherited from edm::EDAnalyzer | |
void | callWhenNewProductsRegistered (std::function< void(BranchDescription const &)> const &func) |
EDAnalyzer () | |
ModuleDescription const & | moduleDescription () const |
std::string | workerType () const |
virtual | ~EDAnalyzer () |
Public Member Functions inherited from edm::EDConsumerBase | |
std::vector< ConsumesInfo > | consumesInfo () const |
EDConsumerBase () | |
ProductHolderIndexAndSkipBit | indexFrom (EDGetToken, BranchType, TypeID const &) const |
void | itemsMayGet (BranchType, std::vector< ProductHolderIndexAndSkipBit > &) const |
void | itemsToGet (BranchType, std::vector< ProductHolderIndexAndSkipBit > &) const |
std::vector < ProductHolderIndexAndSkipBit > const & | itemsToGetFromEvent () const |
void | labelsForToken (EDGetToken iToken, Labels &oLabels) const |
void | modulesDependentUpon (const std::string &iProcessName, std::vector< const char * > &oModuleLabels) const |
void | modulesWhoseProductsAreConsumed (std::vector< ModuleDescription const * > &modules, ProductRegistry const &preg, std::map< std::string, ModuleDescription const * > const &labelsToDesc, std::string const &processName) const |
bool | registeredToConsume (ProductHolderIndex, bool, BranchType) const |
bool | registeredToConsumeMany (TypeID const &, BranchType) const |
void | updateLookup (BranchType iBranchType, ProductHolderIndexHelper const &) |
virtual | ~EDConsumerBase () |
Private Member Functions | |
virtual void | analyze (const edm::Event &event, const edm::EventSetup &setup) override |
everything that needs to be done during the event loop More... | |
bool | booked (const std::string histName) const |
check if histogram was booked More... | |
void | fill (const std::string histName, double value) const |
fill histogram if it had been booked before More... | |
void | fill (std::string hists, const reco::TrackRef &t1, const reco::TrackRef &t2) const |
fill a predefined set of histograms from inner outer or global tracks for first and second mu candidate More... | |
double | mass (const math::XYZVector &t1, const math::XYZVector &t2) const |
calculate the mass of the Z boson from the tracker momenta by hand More... | |
Private Attributes | |
std::map< std::string, TH1D * > | hists_ |
management of 1d histograms More... | |
edm::EDGetTokenT< edm::View < pat::Muon > > | muonsToken_ |
input for muons More... | |
double | shift_ |
Additional Inherited Members | |
Static Public Member Functions inherited from edm::EDAnalyzer | |
static const std::string & | baseType () |
static void | fillDescriptions (ConfigurationDescriptions &descriptions) |
static void | prevalidate (ConfigurationDescriptions &) |
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) |
Module to analyze the performance of muon reconstruction on the example of Z->mumu events.
Module to analyze the performance of muon reconstruction on the example of Z->mumu events: transverse momentum and eta of the muon candidates and the mass of the Z boson candidate are plotted from inner, outer and global tracks. The mass is recalculated by an extra finction. The difference of the outer track and the global track are plotted for the transverse momentum, eta and phi of the two muon candi- dates, for global muons as far as available. The only input parameters are:
muons –> indicating the muon collection of choice. shift –> indicating the relative shift of the transverse momentum for the estimate of the effect on the invariant mass.
The shift is applied to all mass calculations.
Definition at line 33 of file PatZToMuMuAnalyzer.cc.
Definition at line 38 of file PatZToMuMuAnalyzer.cc.
typedef's to simplify get functions
Definition at line 37 of file PatZToMuMuAnalyzer.cc.
|
explicit |
default constructor
Definition at line 76 of file PatZToMuMuAnalyzer.cc.
References fileService, hists_, and TFileService::make().
|
inline |
|
overrideprivatevirtual |
everything that needs to be done during the event loop
Implements edm::EDAnalyzer.
Definition at line 128 of file PatZToMuMuAnalyzer.cc.
References fill(), patZpeak::muons, muonsToken_, and AlCaHLTBitMon_QueryRunRegistry::string.
|
inlineprivate |
check if histogram was booked
Definition at line 52 of file PatZToMuMuAnalyzer.cc.
References hists_.
Referenced by fill().
|
inlineprivate |
fill histogram if it had been booked before
Definition at line 54 of file PatZToMuMuAnalyzer.cc.
References booked(), hists_, and edm::second().
Referenced by analyze(), and fill().
|
private |
fill a predefined set of histograms from inner outer or global tracks for first and second mu candidate
Definition at line 108 of file PatZToMuMuAnalyzer.cc.
References python.multivaluedict::append(), fill(), edm::Ref< C, T, F >::isAvailable(), mass(), and AlCaHLTBitMon_QueryRunRegistry::string.
|
inlineprivate |
calculate the mass of the Z boson from the tracker momenta by hand
Definition at line 68 of file PatZToMuMuAnalyzer.cc.
References shift_, and mathSSE::sqrt().
Referenced by Particle.Particle::__str__(), DiObject.DiMuon::__str__(), and fill().
|
private |
management of 1d histograms
Definition at line 64 of file PatZToMuMuAnalyzer.cc.
Referenced by booked(), fill(), and PatZToMuMuAnalyzer().
|
private |
|
private |
shift in transverse momentum to determine a rough uncertainty on the Z mass estimation
Definition at line 62 of file PatZToMuMuAnalyzer.cc.
Referenced by mass().