![]() |
ATLAS Offline Software
|
Implementation of the PileupReweighting tool. More...
#include <PileupReweightingTool.h>
Public Member Functions | |
| virtual UInt_t | GetRandomLumiBlockNumber (UInt_t runNumber) |
| Get a random lumiblock number for the given run number. | |
| virtual Double_t | GetIntegratedLumi (UInt_t start, UInt_t end) |
| Get the integrated luminosity (in pb-1) between start and end run (inclusive) | |
| virtual Double_t | GetIntegratedLumi (const TString &trigger) |
| Total lumi (in pb-1) for a given trigger combination .. leave blank for the unprescaled. | |
| virtual Double_t | GetIntegratedLumi (Int_t periodNumber, UInt_t start, UInt_t end) |
| similar to above, but for only the given mcRunNumber/periodNumber | |
| virtual Double_t | GetIntegratedLumiFraction (Int_t periodNumber, UInt_t start, UInt_t end) |
| return fraction of lumi assigned to periodNumber (or mcRunNumber) that is between start and end data run numbers | |
| virtual Double_t | GetIntegratedLumiFraction (Int_t periodNumber, Double_t mu, UInt_t start, UInt_t end) |
| return fraction of lumi assigned to periodNumber (or mcRunNumber) with given mu, that is between start and end data run numbers | |
| virtual Int_t | AddPeriod (Int_t periodNumber, UInt_t start, UInt_t end) |
| use these methods when generating config files | |
| virtual Int_t | SetBinning (Int_t nbinsx, Double_t *xbins, Int_t nbinsy=0, Double_t *ybins=0) |
| virtual Int_t | SetUniformBinning (Int_t nbinsx, Double_t xlow, Double_t xup, Int_t nbinsy=0, Double_t ylow=0, Double_t yup=0) |
| virtual Int_t | SetBinning (TH1 *hist) |
| virtual Double_t | GetSumOfEventWeights (Int_t channel) |
| helpful alternative to using the EventBookkeepers info ... assuming you made your PRW Config file!! | |
| virtual Double_t | GetNumberOfEvents (Int_t channel) |
| PileupReweightingTool (const std::string &name) | |
| Constructor for standalone usage. | |
| virtual StatusCode | initialize () |
| Function initialising the tool. | |
| virtual StatusCode | finalize () |
| Finalize - can call the WriteToFile for us. | |
| virtual StatusCode | apply (const xAOD::EventInfo &eventInfo, bool mu_dependent) |
| Decorates with: MC: PileupWeight (CombinedWeight[*UnrepresentedDataWeight if action=2]), RandomRunNumber, RandomLumiBlockNumber Data: corrected_averageInteractionsPerCrossing mu_dependent says if the mu_dependency should be used for random run numbers or the data weights. | |
| virtual float | getCombinedWeight (const xAOD::EventInfo &eventInfo, bool correctUnrepresented) |
| Return combined pileup weight. | |
| virtual float | getCombinedWeight (const xAOD::EventInfo &eventInfo, Double_t x, Double_t y, bool correctUnrepresented) |
| Same as above, but for a 'custom weight' variable. | |
| virtual float | getCombinedWeight (const xAOD::EventInfo &eventInfo, const TString &trigger, bool mu_dependent, bool correctUnrepresented) |
| get combined weight (i.e. pileup weight) but with a 1./dataWeight factor applied, this if used for 'prescaling' MC | |
| virtual ULong64_t | getPRWHash (const xAOD::EventInfo &eventInfo) |
| return the prw hash used for fast updates of weights at the post-processing level ... see the share/makeWeightTree.C script for usage | |
| virtual float | getCorrectedAverageInteractionsPerCrossing (const xAOD::EventInfo &eventInfo, bool includeDataScaleFactor) |
| Get the mu of a lumiblock ... needed to 'correct' the number in datasets. | |
| virtual float | getCorrectedActualInteractionsPerCrossing (const xAOD::EventInfo &eventInfo, bool includeDataScaleFactor) |
| Get the corrected 'actual' interactions per crossing. | |
| virtual double | getLumiBlockIntegratedLumi (const xAOD::EventInfo &eventInfo) |
| Get the integrated lumi of a lumiblock (in pb-1) | |
| virtual float | getUnrepresentedDataWeight (const xAOD::EventInfo &eventInfo) |
| When using UnrepresentedDataAction=2, you may want to apply this additional weight to ensure sum of weights are preserved. | |
| virtual float | getDataWeight (const xAOD::EventInfo &eventInfo, const TString &trigger, bool mu_dependent) |
| Get the dataWeight used to 'unprescale' data collected from a given trigger combination. mu_dependency is recommended to be true. | |
| virtual float | getPrescaleWeight (const xAOD::EventInfo &eventInfo, const TString &trigger, bool mu_dependent) |
| Get weight used to 'prescale' Monte Carlo for given trigger comibnation. | |
| virtual int | getRandomRunNumber (const xAOD::EventInfo &eventInfo, bool mu_dependent) |
| Get a random run number for this MC event, using mu-dependent randomization by default ... jetetmiss seem to like it muchly. | |
| virtual int | fill (const xAOD::EventInfo &eventInfo) |
| Call this method once per event when in config file generating mode and you want standard mu reweighting. | |
| virtual int | fill (const xAOD::EventInfo &eventInfo, Double_t x, Double_t y) |
| Use this method if you want to do a generic reweighting instead. | |
| virtual CP::TPileupReweighting * | expert () |
| Get pointer to the underlying tool - expert use only. Will require #include "PileupReweighting/TPileupReweighting.h". | |
| bool | isAffectedBySystematic (const CP::SystematicVariation &systematic) const |
| The ISystematicsTool methods. | |
| CP::SystematicSet | affectingSystematics () const |
| the list of all systematics this tool can be affected by | |
| CP::SystematicSet | recommendedSystematics () const |
| the list of all systematics this tool recommends to use | |
| StatusCode | applySystematicVariation (const CP::SystematicSet &systConfig) |
| effects: configure this tool for the given list of systematic variations. | |
| void | updateHandler (Gaudi::Details::PropertyBase &) |
| Int_t | Merge (TCollection *coll) |
| virtual void | print () const |
| Print the state of the tool. | |
| ServiceHandle< StoreGateSvc > & | evtStore () |
The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc. | |
| const ServiceHandle< StoreGateSvc > & | detStore () const |
The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc. | |
| virtual StatusCode | sysInitialize () override |
| Perform system initialization for an algorithm. | |
| virtual StatusCode | sysStart () override |
| Handle START transition. | |
| virtual std::vector< Gaudi::DataHandle * > | inputHandles () const override |
| Return this algorithm's input handles. | |
| virtual std::vector< Gaudi::DataHandle * > | outputHandles () const override |
| Return this algorithm's output handles. | |
| Gaudi::Details::PropertyBase & | declareProperty (Gaudi::Property< T, V, H > &t) |
| void | updateVHKA (Gaudi::Details::PropertyBase &) |
| MsgStream & | msg () const |
| bool | msgLvl (const MSG::Level lvl) const |
| virtual float | getCorrectedMu (const xAOD::EventInfo &eventInfo, bool includedDataScaleFactor=false) |
| Get the corrected average mu of a lumiblock ... (averaging is over all filled BCID in the fill) The additional flag indicates if the returned value should include the data scale factor or not. | |
Additional helper functions, not directly mimicking Athena | |
| template<class T> | |
| const T * | getProperty (const std::string &name) const |
| Get one of the tool's properties. | |
| const std::string & | msg_level_name () const __attribute__((deprecated)) |
| A deprecated function for getting the message level's name. | |
| const std::string & | getName (const void *ptr) const |
| Get the name of an object that is / should be in the event store. | |
| SG::sgkey_t | getKey (const void *ptr) const |
| Get the (hashed) key of an object that is in the event store. | |
Static Public Member Functions | |
| static Version_t | Class_Version () |
Protected Member Functions | |
| virtual bool | runLbnOK (Int_t runNbr, Int_t lbn) |
| virtual bool | passTriggerBeforePrescale (const TString &trigger) const |
| void | renounceArray (SG::VarHandleKeyArray &handlesArray) |
| remove all handles from I/O resolution | |
| std::enable_if_t< std::is_void_v< std::result_of_t< decltype(&T::renounce)(T)> > &&!std::is_base_of_v< SG::VarHandleKeyArray, T > &&std::is_base_of_v< Gaudi::DataHandle, T >, void > | renounce (T &h) |
| void | extraDeps_update_handler (Gaudi::Details::PropertyBase &ExtraDeps) |
| Add StoreName to extra input/output deps as needed. | |
| Int_t | UsePeriodConfig (const TString &configName) |
| use a hardcoded period configuration | |
| void | SetDefaultChannel (Int_t channel, Int_t mcRunNumber=-1) |
| Set which channel should be used as a default when specific mc channel distributions cannot be found. | |
| Int_t | GetDefaultChannel (Int_t mcRunNumber=-1) |
| void | RemapPeriod (Int_t periodNumber1, Int_t periodNumber2) |
| Combine two period numbers. | |
| Double_t | GetLumiBlockIntegratedLumi (Int_t runNumber, UInt_t lb) |
| get integrated lumi for specific run and lumiblock number . | |
| Float_t | GetLumiBlockMu (Int_t runNumber, UInt_t lb) |
| get the lumiblock mu, useful for 'updating' the mu coming from data to account for new lumitags | |
| void | DisableWarnings (Bool_t in) |
| Indicate if warnings should be suppressed. | |
| void | EnableDebugging (Bool_t in) |
| Indicate if additional debugging information should be output. | |
| void | PrintInfo (Bool_t in) |
| disable info | |
| void | SetUnrepresentedDataAction (Int_t action, Double_t tolerance=0.05) |
| Set how to handle configurations where some of your data has no corresponding mc to describe it 0=Default (Throw exception), 1=Subtract lumi from normalizations (i.e. | |
| Double_t | GetUnrepresentedDataFraction (Int_t periodNumber, Int_t channel) |
| return the unrepresented data fraction in a given channel . | |
| Float_t | GetUnrepresentedDataWeight (Int_t periodNumber, Int_t channel) |
| Bool_t | IsUnrepresentedData (Int_t runNumber, Float_t x, Float_t y=0.) |
| void | IgnoreConfigFilePeriods (Bool_t in) |
| Should the tool ignore period assignments encoded in config file. | |
| Int_t | GetFirstFoundPeriodNumber (UInt_t runNumber) |
| Get the first period number with the data run number contained - assume all periods are disconnected for this to be useful. | |
| void | SetDataScaleFactors (Float_t x, Float_t y=1.) |
| Scale the LumiMetaData mu values by this factor. | |
| void | SetMCScaleFactors (Float_t x, Float_t y=1.) |
| Int_t | AddConfigFile (const TString &fileName) |
| Int_t | AddLumiCalcFile (const TString &fileName, const TString &trigger="None") |
| Int_t | AddMetaDataFile (const TString &fileName, const TString &channelBranchName="mc_channel_number") |
| Bool_t | RemoveChannel (int chanNum) |
| Removes a channel from the inputs ... this is for experts only. | |
| Int_t | Initialize () |
| Initialize this class once before the event loop starts If distribution information is provided, it is assumed to be for the standard pileup reweighting. | |
| Float_t | GetCombinedWeight (Int_t periodNumber, Int_t channelNumber, Float_t x, Float_t y=0.) |
| Float_t | GetPeriodWeight (Int_t periodNumber, Int_t channelNumber) |
| Float_t | GetPrimaryWeight (Int_t periodNumber, Int_t channelNumber, Float_t x) |
| Float_t | GetSecondaryWeight (Int_t periodNumber, Int_t channelNumber, Float_t x, Float_t y) |
| Double_t | GetMetaData (const TString &metadataName, Int_t channelNumber) |
| TTree * | GetMetaDataTree () |
| combines loaded metadata with channel sumsofweights and entry counts | |
| Int_t | GenerateMetaDataFile (const TString &fileName, const TString &channelBranchName="mc_channel_number") |
| Int_t | Fill (Int_t runNumber, Int_t channelNumber, Float_t w, Float_t x, Float_t y=0.) |
| Int_t | WriteToFile (const TString &filename="") |
| Int_t | WriteToFile (TFile *outFile) |
| ULong64_t | GetPRWHash (Int_t periodNumber, Int_t channelNumber, Float_t x, Float_t y=0.) |
| Bool_t | MakeWeightTree (TString channelNumbers, TString outFile, TString hashBranch="PRWHash", TString weightBranch="PileupWeight") |
| void | SetRandomSeed (int seed) |
| int | GetRandomSeed () |
| UInt_t | GetRandomRunNumber (Int_t mcRunNumber) |
| Gets a random data run number according to the integrated lumi distribution associated to this mcRunNumber. | |
| UInt_t | GetRandomRunNumber (Int_t mcRunNumber, Double_t mu) |
| Get random run number according to integrated lumi distribution for the given mu value (uses the binning of the mu histogram) | |
| Int_t | GetRandomPeriodNumber (Int_t mcRunNumber) |
| Get random period number from the sub-periods assigned to this run number. | |
| std::vector< int > | GetPeriodNumbers () const |
| TH1 * | GetInputHistogram (Int_t channelNumber, Int_t periodNumber) |
| TH1 * | GetPrimaryDistribution (Int_t channelNumber, Int_t periodNumber) |
| TH1 * | GetPrimaryTriggerDistribution (const TString &trigger, Int_t periodNumber, long triggerBits) |
| Double_t | GetDataWeight (Int_t runNumber, const TString &trigger, Double_t x, bool run_dependent=false) |
| Method for weighting data to account for prescales and mu bias. | |
| Double_t | GetDataWeight (Int_t runNumber, const TString &trigger) |
| Double_t | GetPrescaleWeight (Int_t runNumber, const TString &trigger, Double_t x, bool run_dependent=false) |
| Method for prescaling MC to account for prescales in data. | |
| Double_t | GetPrescaleWeight (Int_t runNumber, const TString &trigger) |
| Bool_t | IsInitialized () |
| Int_t | AddDistribution (TH1 *hist, Int_t runNumber, Int_t channelNumber) |
| void | ResetCountingMode () |
| This method is DEFINITELY EXPERT USE ONLY. | |
| void | SetParentTool (TPileupReweighting *tool) |
| Float_t | GetDataScaleFactor () const |
| void | SetTriggerBit (const TString &trigger, bool in=true) |
| void | ResetTriggerBits () |
| double | GetRunAverageMu (int run) |
| Int_t | GetNearestGoodBin (Int_t thisMCRunNumber, Int_t bin) |
| Int_t | IsBadBin (Int_t thisMCRunNumber, Int_t bin) |
| std::unique_ptr< TH1 > | CloneEmptyHistogram (Int_t runNumber, Int_t channelNumber) |
| void | normalizeHistogram (TH1 *histo) |
| Normalize histograms. | |
| void | AddDistributionTree (TTree *tree, TFile *file) |
| void | CalculatePrescaledLuminosityHistograms (const TString &trigger, int run_dependent=0) |
| std::unique_ptr< CompositeTrigger > | makeTrigger (const TString &s) |
| void | calculateHistograms (CompositeTrigger *trigger, int run_dependent) |
| void | PrintPeriods () |
| std::map< UInt_t, Run > & | GetRunMap () |
| void | CopyProperties (const TPileupReweighting *in) |
Protected Attributes | |
| std::map< TString, bool > | m_triggerPassBits |
| TPileupReweighting * | m_parentTool |
| Bool_t | m_SetWarnings |
| Bool_t | m_debugging |
| Bool_t | m_printInfo |
| Bool_t | m_countingMode |
| Int_t | m_unrepresentedDataAction |
| Bool_t | m_isInitialized |
| Bool_t | m_lumiVectorIsLoaded |
| Float_t | m_dataScaleFactorX |
| Float_t | m_dataScaleFactorY |
| Float_t | m_mcScaleFactorX |
| Float_t | m_mcScaleFactorY |
| Int_t | m_nextPeriodNumber |
| Bool_t | m_ignoreFilePeriods |
| TTree * | m_metadatatree |
| Double_t | m_unrepDataTolerance |
| Bool_t | m_doGlobalDataWeight |
| Bool_t | m_doPrescaleWeight = false |
| Int_t | m_lumicalcRunNumberOffset |
| std::map< TString, std::vector< TString > > | m_lumicalcFiles |
| map storing the lumicalc file locations - used when building DataPileupWeights | |
| std::unique_ptr< TH1 > | m_emptyHistogram |
| the empty histogram used for this weight... effectively holds the configuration of the binning | |
| std::map< TString, std::map< Int_t, Double_t > > | m_metadata |
| channel metadata map | |
| std::map< TString, std::unique_ptr< CompositeTrigger > > | m_triggerObjs |
| std::list< Period > | m_periodList |
| List physically holding (owning) period objects. | |
| std::map< Int_t, Period * > | m_periods |
| std::map< UInt_t, Run > | m_runs |
| std::map< Int_t, Double_t > | unrepDataByChannel |
| std::string | m_prwFilesPathPrefix |
| std::unique_ptr< TRandom3 > | m_random3 |
| Bool_t | m_ignoreBadChannels |
| Bool_t | m_useMultiPeriods = true |
| int | m_autoRunStart = 0 |
| int | m_autoRunEnd = 0 |
Private Types | |
| typedef ServiceHandle< StoreGateSvc > | StoreGateSvc_t |
Private Member Functions | |
| Gaudi::Details::PropertyBase & | declareGaudiProperty (Gaudi::Property< T, V, H > &hndl, const SG::VarHandleKeyType &) |
| specialization for handling Gaudi::Property<SG::VarHandleKey> | |
Implementation of the PileupReweighting tool.
Definition at line 33 of file PileupReweightingTool.h.
|
privateinherited |
Definition at line 388 of file AthCommonDataStore.h.
| CP::PileupReweightingTool::PileupReweightingTool | ( | const std::string & | name | ) |
Constructor for standalone usage.
Definition at line 34 of file PileupReweightingTool.cxx.
|
inherited |
Definition at line 936 of file TPileupReweighting.cxx.
|
inherited |
Definition at line 728 of file TPileupReweighting.cxx.
|
protectedinherited |
Definition at line 648 of file TPileupReweighting.cxx.
|
inherited |
Definition at line 847 of file TPileupReweighting.cxx.
|
inherited |
Definition at line 506 of file TPileupReweighting.cxx.
|
inlinevirtual |
use these methods when generating config files
Implements CP::IPileupReweightingTool.
Definition at line 59 of file PileupReweightingTool.h.
|
virtual |
the list of all systematics this tool can be affected by
Implements CP::IReentrantSystematicsTool.
Definition at line 119 of file PileupReweightingTool.cxx.
|
virtual |
Decorates with: MC: PileupWeight (CombinedWeight[*UnrepresentedDataWeight if action=2]), RandomRunNumber, RandomLumiBlockNumber Data: corrected_averageInteractionsPerCrossing mu_dependent says if the mu_dependency should be used for random run numbers or the data weights.
You will get random run numbers of 0 for events with zero pileup weight
Implements CP::IPileupReweightingTool.
Definition at line 451 of file PileupReweightingTool.cxx.
|
virtual |
effects: configure this tool for the given list of systematic variations.
any requested systematics that are not affecting this tool will be silently ignored (unless they cause other errors). failures: systematic unknown failures: requesting multiple variations on the same systematic (e.g. up & down) failures: requesting an unsupported variation on an otherwise supported systematic (e.g. a 2 sigma variation and the tool only supports 1 sigma variations) failures: unsupported combination of supported systematic failures: other tool specific errors
Implements CP::ISystematicsTool.
Definition at line 130 of file PileupReweightingTool.cxx.
|
protectedinherited |
Definition at line 2109 of file TPileupReweighting.cxx.
|
protectedinherited |
Definition at line 2086 of file TPileupReweighting.cxx.
|
inlinestatic |
Definition at line 177 of file PileupReweightingTool.h.
|
protectedinherited |
Definition at line 435 of file TPileupReweighting.cxx.
|
inlineinherited |
Definition at line 473 of file TPileupReweighting.h.
|
inlineprivateinherited |
specialization for handling Gaudi::Property<SG::VarHandleKey>
Definition at line 156 of file AthCommonDataStore.h.
|
inlineinherited |
Definition at line 145 of file AthCommonDataStore.h.
|
inlineinherited |
The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.
Definition at line 95 of file AthCommonDataStore.h.
|
inlineinherited |
Indicate if warnings should be suppressed.
Definition at line 116 of file TPileupReweighting.h.
|
inlineinherited |
Indicate if additional debugging information should be output.
Definition at line 118 of file TPileupReweighting.h.
|
inlineinherited |
The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.
Definition at line 85 of file AthCommonDataStore.h.
|
inlinevirtual |
Get pointer to the underlying tool - expert use only. Will require #include "PileupReweighting/TPileupReweighting.h".
Implements CP::IPileupReweightingTool.
Definition at line 121 of file PileupReweightingTool.h.
|
protectedinherited |
Add StoreName to extra input/output deps as needed.
use the logic of the VarHandleKey to parse the DataObjID keys supplied via the ExtraInputs and ExtraOuputs Properties to add the StoreName if it's not explicitly given
|
inherited |
Definition at line 1837 of file TPileupReweighting.cxx.
|
virtual |
Call this method once per event when in config file generating mode and you want standard mu reweighting.
Implements CP::IPileupReweightingTool.
Definition at line 425 of file PileupReweightingTool.cxx.
|
virtual |
Use this method if you want to do a generic reweighting instead.
Implements CP::IPileupReweightingTool.
Definition at line 429 of file PileupReweightingTool.cxx.
|
virtual |
Finalize - can call the WriteToFile for us.
Definition at line 299 of file PileupReweightingTool.cxx.
|
inherited |
Definition at line 460 of file TPileupReweighting.cxx.
|
inherited |
Definition at line 1603 of file TPileupReweighting.cxx.
|
virtual |
Return combined pileup weight.
Implements CP::IPileupReweightingTool.
Definition at line 397 of file PileupReweightingTool.cxx.
|
virtual |
get combined weight (i.e. pileup weight) but with a 1./dataWeight factor applied, this if used for 'prescaling' MC
Implements CP::IPileupReweightingTool.
Definition at line 525 of file PileupReweightingTool.cxx.
|
virtual |
Same as above, but for a 'custom weight' variable.
Implements CP::IPileupReweightingTool.
Definition at line 404 of file PileupReweightingTool.cxx.
|
virtual |
Get the corrected 'actual' interactions per crossing.
Implements CP::IPileupReweightingTool.
Definition at line 157 of file PileupReweightingTool.cxx.
|
virtual |
Get the mu of a lumiblock ... needed to 'correct' the number in datasets.
Implements CP::IPileupReweightingTool.
Definition at line 148 of file PileupReweightingTool.cxx.
|
inlinevirtualinherited |
Get the corrected average mu of a lumiblock ... (averaging is over all filled BCID in the fill) The additional flag indicates if the returned value should include the data scale factor or not.
Note: if the lumiblock is not present in the input lumicalc file, then -1.0 will be returned This method will soon be deprecated in favour of the new naming: getCorrectedAverageInteractionsPerCrossing
Definition at line 61 of file IPileupReweightingTool.h.
|
inlineinherited |
Definition at line 298 of file TPileupReweighting.h.
|
inherited |
Definition at line 1722 of file TPileupReweighting.cxx.
|
inherited |
Method for weighting data to account for prescales and mu bias.
Use by giving the tool multiple lumicalc files, one for each trigger
Definition at line 1730 of file TPileupReweighting.cxx.
|
virtual |
Get the dataWeight used to 'unprescale' data collected from a given trigger combination. mu_dependency is recommended to be true.
Implements CP::IPileupReweightingTool.
Definition at line 495 of file PileupReweightingTool.cxx.
|
inherited |
Definition at line 109 of file TPileupReweighting.cxx.
|
inherited |
Get the first period number with the data run number contained - assume all periods are disconnected for this to be useful.
Definition at line 422 of file TPileupReweighting.cxx.
|
inlineinherited |
Definition at line 251 of file TPileupReweighting.h.
|
inlinevirtual |
Total lumi (in pb-1) for a given trigger combination .. leave blank for the unprescaled.
Implements CP::IPileupReweightingTool.
Definition at line 51 of file PileupReweightingTool.h.
|
inlinevirtual |
similar to above, but for only the given mcRunNumber/periodNumber
Implements CP::IPileupReweightingTool.
Definition at line 53 of file PileupReweightingTool.h.
|
inlinevirtual |
Get the integrated luminosity (in pb-1) between start and end run (inclusive)
Implements CP::IPileupReweightingTool.
Definition at line 49 of file PileupReweightingTool.h.
|
inlinevirtual |
return fraction of lumi assigned to periodNumber (or mcRunNumber) with given mu, that is between start and end data run numbers
Implements CP::IPileupReweightingTool.
Definition at line 57 of file PileupReweightingTool.h.
|
inlinevirtual |
return fraction of lumi assigned to periodNumber (or mcRunNumber) that is between start and end data run numbers
Implements CP::IPileupReweightingTool.
Definition at line 55 of file PileupReweightingTool.h.
|
inherited |
Get the (hashed) key of an object that is in the event store.
This is a bit of a special one. StoreGateSvc and xAOD::TEvent both provide ways for getting the SG::sgkey_t key for an object that is in the store, based on a bare pointer. But they provide different interfaces for doing so.
In order to allow tools to efficiently perform this operation, they can use this helper function.
| ptr | The bare pointer to the object that the event store should know about |
Definition at line 119 of file AsgTool.cxx.
|
inherited |
get integrated lumi for specific run and lumiblock number .
. comes from the 'unprescaled lumi', and is in pb
Definition at line 154 of file TPileupReweighting.cxx.
|
virtual |
Get the integrated lumi of a lumiblock (in pb-1)
Implements CP::IPileupReweightingTool.
Definition at line 167 of file PileupReweightingTool.cxx.
|
inherited |
get the lumiblock mu, useful for 'updating' the mu coming from data to account for new lumitags
Definition at line 168 of file TPileupReweighting.cxx.
|
inlineinherited |
Definition at line 188 of file TPileupReweighting.h.
|
inherited |
combines loaded metadata with channel sumsofweights and entry counts
Definition at line 574 of file TPileupReweighting.cxx.
|
inherited |
Get the name of an object that is / should be in the event store.
This is a bit of a special one. StoreGateSvc and xAOD::TEvent both provide ways for getting the std::string name for an object that is in the store, based on a bare pointer. But they provide different interfaces for doing so.
In order to allow tools to efficiently perform this operation, they can use this helper function.
| ptr | The bare pointer to the object that the event store should know about |
Definition at line 106 of file AsgTool.cxx.
|
protectedinherited |
Definition at line 1367 of file TPileupReweighting.cxx.
|
inlinevirtual |
|
inlineinherited |
|
inherited |
Definition at line 1623 of file TPileupReweighting.cxx.
|
inherited |
Definition at line 1817 of file TPileupReweighting.cxx.
|
inherited |
Method for prescaling MC to account for prescales in data.
Definition at line 1825 of file TPileupReweighting.cxx.
|
virtual |
Get weight used to 'prescale' Monte Carlo for given trigger comibnation.
Implements CP::IPileupReweightingTool.
Definition at line 514 of file PileupReweightingTool.cxx.
|
inlineinherited |
Definition at line 259 of file TPileupReweighting.h.
|
inlineinherited |
Definition at line 267 of file TPileupReweighting.h.
|
inherited |
Definition at line 1653 of file TPileupReweighting.cxx.
|
inherited |
Get one of the tool's properties.
|
inherited |
Definition at line 1584 of file TPileupReweighting.cxx.
|
virtual |
return the prw hash used for fast updates of weights at the post-processing level ... see the share/makeWeightTree.C script for usage
Implements CP::IPileupReweightingTool.
Definition at line 392 of file PileupReweightingTool.cxx.
|
inlinevirtual |
Get a random lumiblock number for the given run number.
Implements CP::IPileupReweightingTool.
Definition at line 47 of file PileupReweightingTool.h.
|
inherited |
Get random period number from the sub-periods assigned to this run number.
Definition at line 1492 of file TPileupReweighting.cxx.
|
inherited |
Gets a random data run number according to the integrated lumi distribution associated to this mcRunNumber.
allows use of custom reweighting config files
Definition at line 1412 of file TPileupReweighting.cxx.
|
inherited |
Get random run number according to integrated lumi distribution for the given mu value (uses the binning of the mu histogram)
Definition at line 1438 of file TPileupReweighting.cxx.
|
virtual |
Get a random run number for this MC event, using mu-dependent randomization by default ... jetetmiss seem to like it muchly.
Get a random run number for this MC event, mu_dependency is not recommended for this.
Implements CP::IPileupReweightingTool.
Definition at line 418 of file PileupReweightingTool.cxx.
|
inlineinherited |
Definition at line 223 of file TPileupReweighting.h.
Definition at line 303 of file TPileupReweighting.h.
|
inlineinherited |
Definition at line 447 of file TPileupReweighting.h.
|
inherited |
Definition at line 1701 of file TPileupReweighting.cxx.
|
inlinevirtual |
helpful alternative to using the EventBookkeepers info ... assuming you made your PRW Config file!!
Implements CP::IPileupReweightingTool.
Definition at line 64 of file PileupReweightingTool.h.
|
inherited |
return the unrepresented data fraction in a given channel .
. when using action=2, you will want to scale up all MC events by 1/(1-unrepFraction) to account for missed data
Definition at line 1386 of file TPileupReweighting.cxx.
|
inlineinherited |
Definition at line 134 of file TPileupReweighting.h.
|
virtual |
When using UnrepresentedDataAction=2, you may want to apply this additional weight to ensure sum of weights are preserved.
Implements CP::IPileupReweightingTool.
Definition at line 412 of file PileupReweightingTool.cxx.
|
inlineinherited |
Should the tool ignore period assignments encoded in config file.
Definition at line 146 of file TPileupReweighting.h.
|
inherited |
Initialize this class once before the event loop starts If distribution information is provided, it is assumed to be for the standard pileup reweighting.
Definition at line 1021 of file TPileupReweighting.cxx.
|
virtual |
Function initialising the tool.
Reimplemented from asg::AsgTool.
Definition at line 169 of file PileupReweightingTool.cxx.
|
overridevirtualinherited |
Return this algorithm's input handles.
We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.
|
virtual |
The ISystematicsTool methods.
Implements CP::ISystematicsTool.
Definition at line 115 of file PileupReweightingTool.cxx.
|
protectedinherited |
Definition at line 1351 of file TPileupReweighting.cxx.
|
inlineinherited |
Definition at line 288 of file TPileupReweighting.h.
|
inherited |
Definition at line 1524 of file TPileupReweighting.cxx.
|
protectedinherited |
Definition at line 2278 of file TPileupReweighting.cxx.
|
inherited |
Definition at line 1530 of file TPileupReweighting.cxx.
| Int_t TPileupReweighting::Merge | ( | TCollection * | coll | ) |
Definition at line 238 of file TPileupReweighting.cxx.
|
inlineinherited |
Definition at line 24 of file AthCommonMsg.h.
|
inherited |
A deprecated function for getting the message level's name.
Instead of using this, weirdly named function, user code should get the string name of the current minimum message level (in case they really need it...), with:
This function's name doesn't follow the ATLAS coding rules, and as such will be removed in the not too distant future.
Definition at line 101 of file AsgTool.cxx.
|
inlineinherited |
Definition at line 30 of file AthCommonMsg.h.
|
protectedinherited |
Normalize histograms.
Definition at line 1996 of file TPileupReweighting.cxx.
|
overridevirtualinherited |
Return this algorithm's output handles.
We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.
|
protectedvirtual |
Reimplemented from CP::TPileupReweighting.
Definition at line 106 of file PileupReweightingTool.cxx.
|
virtualinherited |
Print the state of the tool.
Implements asg::IAsgTool.
Reimplemented in AsgHelloTool, HI::HIPileupTool, JetBottomUpSoftDrop, JetConstituentsRetriever, JetDumper, JetFinder, JetFromPseudojet, JetModifiedMassDrop, JetPileupLabelingTool, JetPruner, JetPseudojetRetriever, JetReclusterer, JetReclusteringTool, JetRecTool, JetRecursiveSoftDrop, JetSoftDrop, JetSplitter, JetSubStructureMomentToolsBase, JetToolRunner, JetTrimmer, JetTruthLabelingTool, KtDeltaRTool, and LundVariablesTool.
Definition at line 131 of file AsgTool.cxx.
|
inlineinherited |
|
inlineinherited |
Definition at line 407 of file TPileupReweighting.h.
|
virtual |
the list of all systematics this tool recommends to use
Implements CP::IReentrantSystematicsTool.
Definition at line 126 of file PileupReweightingTool.cxx.
|
inherited |
Combine two period numbers.
Histos are merged and the first number will be redirected to the second (the second is created if it doesn't exist)
Definition at line 63 of file TPileupReweighting.cxx.
|
inherited |
Removes a channel from the inputs ... this is for experts only.
Definition at line 1001 of file TPileupReweighting.cxx.
|
inlineprotectedinherited |
Definition at line 380 of file AthCommonDataStore.h.
|
inlineprotectedinherited |
remove all handles from I/O resolution
Definition at line 364 of file AthCommonDataStore.h.
|
inlineinherited |
This method is DEFINITELY EXPERT USE ONLY.
Used in the checkPRWConfigFile utitlity
Definition at line 293 of file TPileupReweighting.h.
|
inlineinherited |
Definition at line 301 of file TPileupReweighting.h.
|
protectedvirtual |
Reimplemented from CP::TPileupReweighting.
Definition at line 101 of file PileupReweightingTool.cxx.
|
inlinevirtual |
|
inlinevirtual |
|
inlineinherited |
Scale the LumiMetaData mu values by this factor.
Definition at line 156 of file TPileupReweighting.h.
|
inherited |
Set which channel should be used as a default when specific mc channel distributions cannot be found.
default channels can now be assigned for each mc run number .. mcRunNumber=-1 is the global default
Definition at line 72 of file TPileupReweighting.cxx.
|
inlineinherited |
Definition at line 157 of file TPileupReweighting.h.
|
inlineinherited |
Definition at line 296 of file TPileupReweighting.h.
|
inlineinherited |
Definition at line 222 of file TPileupReweighting.h.
|
inlineinherited |
Definition at line 300 of file TPileupReweighting.h.
|
inlinevirtual |
|
inlineinherited |
Set how to handle configurations where some of your data has no corresponding mc to describe it 0=Default (Throw exception), 1=Subtract lumi from normalizations (i.e.
discard data), 2=keep lumi and continue
Definition at line 124 of file TPileupReweighting.h.
|
overridevirtualinherited |
Perform system initialization for an algorithm.
We override this to declare all the elements of handle key arrays at the end of initialization. See comments on updateVHKA.
Reimplemented in asg::AsgMetadataTool, AthCheckedComponent< AthAlgTool >, AthCheckedComponent<::AthAlgTool >, and DerivationFramework::CfAthAlgTool.
|
overridevirtualinherited |
Handle START transition.
We override this in order to make sure that conditions handle keys can cache a pointer to the conditions container.
| void CP::PileupReweightingTool::updateHandler | ( | Gaudi::Details::PropertyBase & | ) |
Definition at line 92 of file PileupReweightingTool.cxx.
|
inlineinherited |
Definition at line 308 of file AthCommonDataStore.h.
|
inherited |
use a hardcoded period configuration
Definition at line 234 of file TPileupReweighting.cxx.
|
inherited |
Definition at line 1888 of file TPileupReweighting.cxx.
|
inherited |
Definition at line 1907 of file TPileupReweighting.cxx.
|
private |
Definition at line 149 of file PileupReweightingTool.h.
|
protectedinherited |
Definition at line 469 of file TPileupReweighting.h.
|
protectedinherited |
Definition at line 468 of file TPileupReweighting.h.
|
private |
Definition at line 140 of file PileupReweightingTool.h.
|
protectedinherited |
Definition at line 335 of file TPileupReweighting.h.
|
private |
Default weight tool in standalone mode.
Definition at line 165 of file PileupReweightingTool.h.
|
protectedinherited |
Definition at line 338 of file TPileupReweighting.h.
|
protectedinherited |
Definition at line 338 of file TPileupReweighting.h.
|
protectedinherited |
Definition at line 333 of file TPileupReweighting.h.
|
private |
Definition at line 156 of file PileupReweightingTool.h.
|
private |
Definition at line 168 of file PileupReweightingTool.h.
|
privateinherited |
Pointer to StoreGate (detector store by default)
Definition at line 393 of file AthCommonDataStore.h.
|
protectedinherited |
Definition at line 344 of file TPileupReweighting.h.
Definition at line 158 of file PileupReweightingTool.h.
|
protectedinherited |
Definition at line 345 of file TPileupReweighting.h.
|
private |
Definition at line 145 of file PileupReweightingTool.h.
|
private |
Definition at line 147 of file PileupReweightingTool.h.
|
protectedinherited |
the empty histogram used for this weight... effectively holds the configuration of the binning
Definition at line 358 of file TPileupReweighting.h.
|
privateinherited |
Pointer to StoreGate (event store by default)
Definition at line 390 of file AthCommonDataStore.h.
|
private |
Definition at line 171 of file PileupReweightingTool.h.
|
protectedinherited |
Definition at line 464 of file TPileupReweighting.h.
|
protectedinherited |
Definition at line 341 of file TPileupReweighting.h.
|
private |
Definition at line 141 of file PileupReweightingTool.h.
|
protectedinherited |
Definition at line 337 of file TPileupReweighting.h.
|
protectedinherited |
map storing the lumicalc file locations - used when building DataPileupWeights
Definition at line 349 of file TPileupReweighting.h.
|
protectedinherited |
Definition at line 346 of file TPileupReweighting.h.
|
protectedinherited |
Definition at line 337 of file TPileupReweighting.h.
|
protectedinherited |
Definition at line 339 of file TPileupReweighting.h.
|
protectedinherited |
Definition at line 339 of file TPileupReweighting.h.
|
protectedinherited |
channel metadata map
Definition at line 363 of file TPileupReweighting.h.
|
protectedinherited |
Definition at line 342 of file TPileupReweighting.h.
|
protectedinherited |
Definition at line 340 of file TPileupReweighting.h.
|
private |
Definition at line 160 of file PileupReweightingTool.h.
|
protectedinherited |
Definition at line 331 of file TPileupReweighting.h.
|
protectedinherited |
List physically holding (owning) period objects.
Definition at line 450 of file TPileupReweighting.h.
|
protectedinherited |
Definition at line 451 of file TPileupReweighting.h.
|
private |
Definition at line 154 of file PileupReweightingTool.h.
|
protectedinherited |
Definition at line 334 of file TPileupReweighting.h.
|
private |
Definition at line 151 of file PileupReweightingTool.h.
|
protectedinherited |
Definition at line 456 of file TPileupReweighting.h.
|
protectedinherited |
Definition at line 462 of file TPileupReweighting.h.
|
protectedinherited |
Definition at line 452 of file TPileupReweighting.h.
|
protectedinherited |
Definition at line 332 of file TPileupReweighting.h.
|
private |
Definition at line 148 of file PileupReweightingTool.h.
|
private |
Definition at line 148 of file PileupReweightingTool.h.
|
private |
Definition at line 172 of file PileupReweightingTool.h.
|
private |
Definition at line 152 of file PileupReweightingTool.h.
|
protectedinherited |
Definition at line 401 of file TPileupReweighting.h.
|
protectedinherited |
Definition at line 315 of file TPileupReweighting.h.
|
protectedinherited |
Definition at line 343 of file TPileupReweighting.h.
|
protectedinherited |
Definition at line 336 of file TPileupReweighting.h.
|
private |
Definition at line 144 of file PileupReweightingTool.h.
|
private |
Definition at line 147 of file PileupReweightingTool.h.
|
protectedinherited |
Definition at line 465 of file TPileupReweighting.h.
|
private |
Definition at line 157 of file PileupReweightingTool.h.
|
private |
Definition at line 163 of file PileupReweightingTool.h.
|
privateinherited |
Definition at line 399 of file AthCommonDataStore.h.
|
private |
Definition at line 162 of file PileupReweightingTool.h.
|
privateinherited |
Definition at line 398 of file AthCommonDataStore.h.
|
private |
Definition at line 170 of file PileupReweightingTool.h.
|
protectedinherited |
Definition at line 454 of file TPileupReweighting.h.