![]() |
ATLAS Offline Software
|
Tool to provide the global NN calibration for jets. More...
#include <GlobalNNCalibration.h>
Public Member Functions | |
| GlobalNNCalibration () | |
| The constructor. | |
| GlobalNNCalibration (const std::string &name) | |
| The constructor. | |
| GlobalNNCalibration (const std::string &name, TEnv *config, TString jetAlgo, const TString &calibAreaTag, bool dev) | |
| The constructor, which is used by the JetCalibrationTool. | |
| virtual | ~GlobalNNCalibration ()=default |
| The destructor. | |
| virtual StatusCode | initialize () override |
| Returns the charged fraction of a jet. | |
| virtual void | setUnitsGeV (bool useGeV) |
| virtual StatusCode | getNominalResolutionData (const xAOD::Jet &, double &) const |
| virtual StatusCode | getNominalResolutionMC (const xAOD::Jet &, double &) const |
| void | setLevel (MSG::Level lvl) |
| Change the current logging level. | |
Functions providing the same interface as AthMessaging | |
| bool | msgLvl (const MSG::Level lvl) const |
| Test the output level of the object. | |
| MsgStream & | msg () const |
| The standard message stream. | |
| MsgStream & | msg (const MSG::Level lvl) const |
| The standard message stream. | |
Protected Member Functions | |
| virtual StatusCode | calibrate (xAOD::Jet &jet, JetEventInfo &) const override |
| virtual StatusCode | setStartP4 (xAOD::Jet &jet) const |
Protected Attributes | |
| double | m_GeV |
| std::string | m_jetStartScale |
| std::string | m_name |
Private Member Functions | |
| double | getJetChargedFraction (const xAOD::Jet &jet_reco, int PVindex) const |
| Returns the charged fraction of a jet. | |
| double | getJetDetEta (const xAOD::Jet &jet_reco) const |
| Returns the detector eta of the jet. | |
| int | getJetNtrk1000 (const xAOD::Jet &jet_reco, int PVindex) const |
| Returns the number of tracks with pT > 1 GeV associated to the jet. | |
| double | getJetWtrk1000 (const xAOD::Jet &jet_reco, int PVindex) const |
| Returns the jet width. | |
| double | getJESPt (const xAOD::Jet &jet_reco) const |
| Returns the jet pT after the MCJES calibration. | |
| std::map< std::string, double > | getJetFeatures (const xAOD::Jet &jet_reco, JetEventInfo &jetEventInfo) const |
| Returns a map of possible inputs to the NN, and their corresponding values for this jet. | |
| double | getSplineSlope (const int ieta, const double minPt) const |
| Gets the slope of the spline histogram for a given eta bin, for extrapolation of the calibration. | |
| void | loadSplineHists (const TString &fileName, const std::string &etajes_name="etaJes") |
| Reads the spline histograms from the file given in the config, and stores them in m_ptCorrFactors. | |
| double | getSplineCorr (const int etaBin, double E) const |
| Returns the correction from spline histogram, which should be applied after the NN correction. | |
| int | getEtaBin (const xAOD::Jet &jet_reco, const std::vector< double > &etaBins) const |
| Returns the eta bin, as determined by a list of bin edges. | |
| void | initMessaging () const |
| Initialize our message level and MessageSvc. | |
Private Attributes | |
| std::vector< std::unique_ptr< lwt::LightweightGraph > > | m_lwnns |
| std::vector< std::unique_ptr< TH1 > > | m_ptCorrFactors |
| std::vector< double > | m_nnEtaBins |
| std::vector< double > | m_closureEtaBins |
| std::vector< TString > | m_NNInputs |
| TEnv * | m_config {} |
| TString | m_jetAlgo |
| std::string | m_calibAreaTag |
| bool | m_dev {} |
| bool | m_doSplineCorr {true} |
| bool | m_doLogPtScaling {} |
| double | m_minNNCorrection {} |
| double | m_maxNNCorrection {} |
| std::vector< double > | m_JPtS_MinPt_Slopes |
| std::vector< double > | m_JPtS_MinPt_Pt |
| std::vector< double > | m_JPtS_MinPt_R |
| std::string | m_nm |
| Message source name. | |
| boost::thread_specific_ptr< MsgStream > | m_msg_tls |
| MsgStream instance (a std::cout like with print-out levels) | |
| std::atomic< IMessageSvc * > | m_imsg { nullptr } |
| MessageSvc pointer. | |
| std::atomic< MSG::Level > | m_lvl { MSG::NIL } |
| Current logging level. | |
| std::atomic_flag m_initialized | ATLAS_THREAD_SAFE = ATOMIC_FLAG_INIT |
| Messaging initialized (initMessaging) | |
Tool to provide the global NN calibration for jets.
Definition at line 35 of file GlobalNNCalibration.h.
| GlobalNNCalibration::GlobalNNCalibration | ( | ) |
The constructor.
Note that this doesn't have all the necessary information, so it will not configure things correctly.
Definition at line 30 of file GlobalNNCalibration.cxx.
| GlobalNNCalibration::GlobalNNCalibration | ( | const std::string & | name | ) |
The constructor.
Note that this doesn't have all the necessary information, so it will not configure things correctly.
| name | The name of the tool being created |
Definition at line 38 of file GlobalNNCalibration.cxx.
| GlobalNNCalibration::GlobalNNCalibration | ( | const std::string & | name, |
| TEnv * | config, | ||
| TString | jetAlgo, | ||
| const TString & | calibAreaTag, | ||
| bool | dev ) |
The constructor, which is used by the JetCalibrationTool.
| name | The name of the tool being created |
| config | The name of the config file for the calibration |
| jetAlgo | The name of the jet collection |
| calibAreaTag | The tag for this calibration |
| dev | A flag for if the calibration is run in development mode |
Definition at line 44 of file GlobalNNCalibration.cxx.
|
virtualdefault |
The destructor.
|
overrideprotectedvirtual |
Implements JetCalibrationStep.
Definition at line 126 of file GlobalNNCalibration.cxx.
|
private |
Returns the eta bin, as determined by a list of bin edges.
| jet_reco | The jet |
| etaBins | A list of bin edges |
Definition at line 303 of file GlobalNNCalibration.cxx.
|
private |
Returns the jet pT after the MCJES calibration.
| jet_reco | The jet |
Definition at line 344 of file GlobalNNCalibration.cxx.
|
private |
Returns the charged fraction of a jet.
| jet_reco | The jet |
| PVindex | The index of the PV in the PrimaryVertices container |
Definition at line 313 of file GlobalNNCalibration.cxx.
|
private |
Returns the detector eta of the jet.
| jet_reco | The jet |
Definition at line 324 of file GlobalNNCalibration.cxx.
|
private |
Returns a map of possible inputs to the NN, and their corresponding values for this jet.
| jet_reco | The jet |
| jetEventInfo | A set of information about the event and jet |
Definition at line 223 of file GlobalNNCalibration.cxx.
|
private |
Returns the number of tracks with pT > 1 GeV associated to the jet.
| jet_reco | The jet |
| PVindex | The index of the PV in the PrimaryVertices container |
Definition at line 329 of file GlobalNNCalibration.cxx.
|
private |
Returns the jet width.
| jet_reco | The jet |
| PVindex | The index of the PV in the PrimaryVertices container |
Definition at line 336 of file GlobalNNCalibration.cxx.
|
virtualinherited |
Reimplemented in JetSmearingCorrection.
Definition at line 33 of file JetCalibrationStep.cxx.
|
virtualinherited |
Reimplemented in JetSmearingCorrection.
Definition at line 38 of file JetCalibrationStep.cxx.
|
private |
Returns the correction from spline histogram, which should be applied after the NN correction.
| etaBin | |
| E |
Definition at line 190 of file GlobalNNCalibration.cxx.
|
private |
Gets the slope of the spline histogram for a given eta bin, for extrapolation of the calibration.
| ieta | The eta bin for the spline histogram |
| minPt | The pT at which the extrapolation starts, and where the slope should be calculated |
Definition at line 208 of file GlobalNNCalibration.cxx.
|
overridevirtual |
Returns the charged fraction of a jet.
| name | The name of the tool being created |
Implements JetCalibrationStep.
Definition at line 52 of file GlobalNNCalibration.cxx.
|
privateinherited |
Initialize our message level and MessageSvc.
This method should only be called once.
Definition at line 39 of file AthMessaging.cxx.
|
private |
Reads the spline histograms from the file given in the config, and stores them in m_ptCorrFactors.
Loads the calib constants from histograms in TFile named fileName.
| fileName | |
| etajes_name |
Definition at line 164 of file GlobalNNCalibration.cxx.
|
inherited |
The standard message stream.
Definition at line 49 of file AsgMessaging.cxx.
|
inherited |
The standard message stream.
| lvl | The message level to set the stream to |
Definition at line 57 of file AsgMessaging.cxx.
|
inherited |
Test the output level of the object.
| lvl | The message level to test against |
true If messages at level "lvl" will be printed Definition at line 41 of file AsgMessaging.cxx.
|
inherited |
Change the current logging level.
Use this rather than msg().setLevel() for proper operation with MT.
Definition at line 28 of file AthMessaging.cxx.
|
protectedvirtualinherited |
Definition at line 21 of file JetCalibrationStep.cxx.
|
inlinevirtualinherited |
Definition at line 30 of file JetCalibrationStep.h.
|
mutableprivateinherited |
Messaging initialized (initMessaging)
Definition at line 141 of file AthMessaging.h.
|
private |
Definition at line 159 of file GlobalNNCalibration.h.
|
private |
Definition at line 153 of file GlobalNNCalibration.h.
|
private |
Definition at line 157 of file GlobalNNCalibration.h.
|
private |
Definition at line 160 of file GlobalNNCalibration.h.
|
private |
Definition at line 162 of file GlobalNNCalibration.h.
|
private |
Definition at line 161 of file GlobalNNCalibration.h.
|
protectedinherited |
Definition at line 40 of file JetCalibrationStep.h.
|
mutableprivateinherited |
|
private |
Definition at line 158 of file GlobalNNCalibration.h.
|
protectedinherited |
Definition at line 41 of file JetCalibrationStep.h.
|
private |
Definition at line 167 of file GlobalNNCalibration.h.
|
private |
Definition at line 168 of file GlobalNNCalibration.h.
|
private |
Definition at line 166 of file GlobalNNCalibration.h.
|
mutableprivateinherited |
|
private |
Definition at line 150 of file GlobalNNCalibration.h.
|
private |
Definition at line 164 of file GlobalNNCalibration.h.
|
private |
Definition at line 163 of file GlobalNNCalibration.h.
|
mutableprivateinherited |
MsgStream instance (a std::cout like with print-out levels)
Definition at line 132 of file AthMessaging.h.
|
protectedinherited |
Definition at line 42 of file JetCalibrationStep.h.
|
privateinherited |
Message source name.
Definition at line 129 of file AthMessaging.h.
|
private |
Definition at line 152 of file GlobalNNCalibration.h.
|
private |
Definition at line 154 of file GlobalNNCalibration.h.
|
private |
Definition at line 151 of file GlobalNNCalibration.h.