![]() |
ATLAS Offline Software
|
In-memory cache for pileup events. More...
#include <BkgStreamsCache.h>
Public Member Functions | |
| BkgStreamsCache (const std::string &, const std::string &, const IInterface *) | |
| virtual | ~BkgStreamsCache () |
| virtual StatusCode | initialize () override final |
| virtual StatusCode | finalize () override final |
| virtual StatusCode | setup (int firstXing, unsigned int nXings, unsigned int firstStore, IBeamIntensity *) override final |
| virtual void | newEvent () override final |
| inform cache that we start overlaying a new event | |
| virtual void | resetEvtsPerXingScaleFactor (float sf) override final |
| reset scale factor at new run/lumiblk | |
| virtual StatusCode | addSubEvts (unsigned int iXing, xAOD::EventInfo *overlaidEvent, int t0BinCenter) override final |
| Read input events in bkg stores and link them to overlay store. | |
| virtual StatusCode | addSubEvts (unsigned int iXing, xAOD::EventInfo *overEvent, int t0BinCenter, bool loadEventProxies, unsigned int) override final |
| Read input events in bkg stores and link them to overlay store. | |
| virtual unsigned int | nStores () const override final |
| how many stores in this cache | |
| long | collXing () |
| meant to be used (mainly) via m_f_collDistr | |
| long | collXingPoisson () |
| unsigned int | numberOfBkgForBunchCrossingIgnoringBeamIntensity (unsigned int iXing) const |
| meant to be used via m_f_numberOfBackgroundForBunchCrossing | |
| unsigned int | numberOfBkgForBunchCrossingDefaultImpl (unsigned int iXing) const |
| unsigned int | numberOfCavernBkgForBunchCrossing (unsigned int iXing) const |
Private Types | |
| typedef std::vector< PileUpStream > | StreamVector |
Private Member Functions | |
| const xAOD::EventInfo * | nextEvent (bool isCentralBunchCrossing) |
| get next bkg event from cache | |
| StatusCode | nextEvent_passive (bool isCentralBunchCrossing) |
| as nextEvent except don't actually load anything | |
| PileUpStream * | current () |
| get current (last asked) stream | |
| unsigned int | setNEvtsXing (unsigned int iXing) |
| unsigned int | nEvtsXing (unsigned int iXing) const |
| bool | alreadyInUse (StreamVector::size_type iStream) |
| void | PileUpEventTypeHandler (Gaudi::Details::PropertyBase &) |
Private Attributes | |
| StreamVector::iterator | m_cursor {} |
| StreamVector | m_streams |
| std::vector< bool > | m_usedStreams |
| unsigned int | m_nXings {0} |
| unsigned int | m_nStores {0} |
| std::vector< unsigned int > | m_nEvtsXing |
| ServiceHandle< IEvtSelector > | m_selecName {this, "EventSelector", "FakeEventSelector"} |
| ServiceHandle< IAtRndmGenSvc > | m_atRndmSvc |
| Gaudi::Property< float > | m_collXing |
| Gaudi::Property< float > | m_occupationFraction |
| Gaudi::Property< std::string > | m_collDistrName |
| Gaudi::Property< float > | m_readDownscale |
| Gaudi::Property< std::string > | m_randomStreamName |
| Gaudi::CheckedProperty< unsigned short > | m_pileUpEventTypeProp |
| Gaudi::Property< unsigned short > | m_subtractBC0 |
| Gaudi::Property< bool > | m_ignoreBM |
| Gaudi::Property< bool > | m_ignoreSF |
| Gaudi::Property< bool > | m_forceReadForBC0 |
| xAOD::EventInfo::PileUpType | m_pileUpEventType |
| the type of events in this cache | |
| CLHEP::RandFlat * | m_readEventRand {nullptr} |
| read a new event every downscaleFactor accesses | |
| CLHEP::RandFlat * | m_chooseEventRand {nullptr} |
| pickup an event store at random from the cache | |
| CLHEP::RandPoisson * | m_collXingPoisson {nullptr} |
| set number of collisions per bunch crossing (if Poisson distribution chosen) | |
| std::function< long() > | m_f_collDistr |
| function returning the number of collisions per bunch crossing before bunch structure modulation | |
| std::function< unsigned int(unsigned int) > | m_f_numberOfBackgroundForBunchCrossing |
| function returning the number of bkg events per bunch crossing after bunch structure modulation | |
| float | m_collXingSF {1.0} |
| float scaling number of collisions per bunch crossing | |
| int | m_zeroXing {-1} |
| offset of BC=0 xing | |
| IBeamIntensity * | m_beamInt {nullptr} |
| pointer to the IBeamIntensity distribution tool | |
In-memory cache for pileup events.
Definition at line 35 of file BkgStreamsCache.h.
|
private |
Definition at line 97 of file BkgStreamsCache.h.
| BkgStreamsCache::BkgStreamsCache | ( | const std::string & | type, |
| const std::string & | name, | ||
| const IInterface * | parent ) |
Definition at line 26 of file BkgStreamsCache.cxx.
|
virtual |
Definition at line 34 of file BkgStreamsCache.cxx.
|
finaloverridevirtual |
Read input events in bkg stores and link them to overlay store.
| iXing | offset to first xing number (=0 first Xing, =nXings for last xing) |
| overlaidEvent | reference to resulting overlaid event |
| t0BinCenter | time wrto t0 of current bin center in ns |
| loadEventProxies | should we load the event proxies or not. |
| BCID | bunch-crossing ID of signal bunch crossing |
Definition at line 327 of file BkgStreamsCache.cxx.
|
finaloverridevirtual |
Read input events in bkg stores and link them to overlay store.
| iXing | offset to first xing number (=0 first Xing, =nXings for last xing) |
| overlaidEvent | reference to resulting overlaid event |
| t0BinCenter | time wrto t0 of current bin center in ns |
Definition at line 319 of file BkgStreamsCache.cxx.
|
private |
Definition at line 199 of file BkgStreamsCache.cxx.
|
inline |
| long BkgStreamsCache::collXingPoisson | ( | ) |
Definition at line 121 of file BkgStreamsCache.cxx.
|
private |
get current (last asked) stream
Definition at line 211 of file BkgStreamsCache.cxx.
|
finaloverridevirtual |
Definition at line 386 of file BkgStreamsCache.cxx.
|
finaloverridevirtual |
Definition at line 218 of file BkgStreamsCache.cxx.
|
private |
Definition at line 277 of file BkgStreamsCache.cxx.
|
finaloverridevirtual |
inform cache that we start overlaying a new event
Definition at line 127 of file BkgStreamsCache.cxx.
|
private |
get next bkg event from cache
Definition at line 147 of file BkgStreamsCache.cxx.
|
private |
as nextEvent except don't actually load anything
Definition at line 174 of file BkgStreamsCache.cxx.
|
inlinefinaloverridevirtual |
| unsigned int BkgStreamsCache::numberOfBkgForBunchCrossingDefaultImpl | ( | unsigned int | iXing | ) | const |
Definition at line 286 of file BkgStreamsCache.cxx.
| unsigned int BkgStreamsCache::numberOfBkgForBunchCrossingIgnoringBeamIntensity | ( | unsigned int | iXing | ) | const |
meant to be used via m_f_numberOfBackgroundForBunchCrossing
Definition at line 282 of file BkgStreamsCache.cxx.
| unsigned int BkgStreamsCache::numberOfCavernBkgForBunchCrossing | ( | unsigned int | iXing | ) | const |
Definition at line 290 of file BkgStreamsCache.cxx.
|
private |
Definition at line 42 of file BkgStreamsCache.cxx.
|
finaloverridevirtual |
|
private |
Definition at line 295 of file BkgStreamsCache.cxx.
|
finaloverridevirtual |
| nXings | bunch Xings to be processed |
| firstStore | id of first store in cache |
Definition at line 48 of file BkgStreamsCache.cxx.
|
private |
Definition at line 108 of file BkgStreamsCache.h.
|
private |
pointer to the IBeamIntensity distribution tool
Definition at line 167 of file BkgStreamsCache.h.
|
private |
pickup an event store at random from the cache
Definition at line 153 of file BkgStreamsCache.h.
|
private |
Definition at line 117 of file BkgStreamsCache.h.
|
private |
Definition at line 111 of file BkgStreamsCache.h.
|
private |
set number of collisions per bunch crossing (if Poisson distribution chosen)
Definition at line 155 of file BkgStreamsCache.h.
|
private |
float scaling number of collisions per bunch crossing
Definition at line 163 of file BkgStreamsCache.h.
|
private |
Definition at line 99 of file BkgStreamsCache.h.
|
private |
function returning the number of collisions per bunch crossing before bunch structure modulation
Definition at line 158 of file BkgStreamsCache.h.
|
private |
function returning the number of bkg events per bunch crossing after bunch structure modulation
Definition at line 161 of file BkgStreamsCache.h.
|
private |
Definition at line 145 of file BkgStreamsCache.h.
|
private |
Definition at line 137 of file BkgStreamsCache.h.
|
private |
Definition at line 141 of file BkgStreamsCache.h.
|
private |
Definition at line 104 of file BkgStreamsCache.h.
|
private |
Definition at line 103 of file BkgStreamsCache.h.
|
private |
Definition at line 102 of file BkgStreamsCache.h.
|
private |
Definition at line 114 of file BkgStreamsCache.h.
|
private |
the type of events in this cache
Definition at line 149 of file BkgStreamsCache.h.
|
private |
Definition at line 127 of file BkgStreamsCache.h.
|
private |
Definition at line 124 of file BkgStreamsCache.h.
|
private |
Definition at line 120 of file BkgStreamsCache.h.
|
private |
read a new event every downscaleFactor accesses
Definition at line 151 of file BkgStreamsCache.h.
|
private |
Definition at line 106 of file BkgStreamsCache.h.
|
private |
Definition at line 100 of file BkgStreamsCache.h.
|
private |
Definition at line 133 of file BkgStreamsCache.h.
|
private |
Definition at line 101 of file BkgStreamsCache.h.
|
private |