|
ATLAS Offline Software
|
Track Record Generator. The class takes input simulation track records and uses them as generator records.
More...
#include <TrackRecordGenerator.h>
|
| TrackRecordGenerator (const std::string &name, ISvcLocator *pSvcLocator) |
|
virtual | ~TrackRecordGenerator () |
|
virtual StatusCode | callGenerator () |
| For calling the generator on each iteration of the event loop. More...
|
|
virtual StatusCode | fillEvt (HepMC::GenEvent *evt) |
| For filling the HepMC event object. More...
|
|
virtual StatusCode | sysInitialize () override |
| Override sysInitialize. More...
|
|
virtual const DataObjIDColl & | extraOutputDeps () const override |
| Return the list of extra output dependencies. More...
|
|
ServiceHandle< StoreGateSvc > & | evtStore () |
| The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc . More...
|
|
const ServiceHandle< StoreGateSvc > & | evtStore () const |
| The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc . More...
|
|
const ServiceHandle< StoreGateSvc > & | detStore () const |
| The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc . More...
|
|
virtual StatusCode | sysStart () override |
| Handle START transition. More...
|
|
virtual std::vector< Gaudi::DataHandle * > | inputHandles () const override |
| Return this algorithm's input handles. More...
|
|
virtual std::vector< Gaudi::DataHandle * > | outputHandles () const override |
| Return this algorithm's output handles. More...
|
|
Gaudi::Details::PropertyBase & | declareProperty (Gaudi::Property< T > &t) |
|
Gaudi::Details::PropertyBase * | declareProperty (const std::string &name, SG::VarHandleKey &hndl, const std::string &doc, const SG::VarHandleKeyType &) |
| Declare a new Gaudi property. More...
|
|
Gaudi::Details::PropertyBase * | declareProperty (const std::string &name, SG::VarHandleBase &hndl, const std::string &doc, const SG::VarHandleType &) |
| Declare a new Gaudi property. More...
|
|
Gaudi::Details::PropertyBase * | declareProperty (const std::string &name, SG::VarHandleKeyArray &hndArr, const std::string &doc, const SG::VarHandleKeyArrayType &) |
|
Gaudi::Details::PropertyBase * | declareProperty (const std::string &name, T &property, const std::string &doc, const SG::NotHandleType &) |
| Declare a new Gaudi property. More...
|
|
Gaudi::Details::PropertyBase * | declareProperty (const std::string &name, T &property, const std::string &doc="none") |
| Declare a new Gaudi property. More...
|
|
void | updateVHKA (Gaudi::Details::PropertyBase &) |
|
MsgStream & | msg () const |
|
MsgStream & | msg (const MSG::Level lvl) const |
|
bool | msgLvl (const MSG::Level lvl) const |
|
|
StatusCode | initialize () |
|
StatusCode | execute () |
|
StatusCode | finalize () |
|
|
virtual StatusCode | genuserInitialize () |
| For initialization of user code, if required. Called after genInitialize. More...
|
|
|
StatusCode | initialize () |
|
StatusCode | execute () |
|
StatusCode | finalize () |
|
|
virtual StatusCode | genuserInitialize () |
| For initialization of user code, if required. Called after genInitialize. More...
|
|
|
StatusCode | initialize () |
|
StatusCode | execute () |
|
StatusCode | finalize () |
|
|
virtual StatusCode | genuserInitialize () |
| For initialization of user code, if required. Called after genInitialize. More...
|
|
|
StatusCode | initialize () |
|
StatusCode | execute () |
|
StatusCode | finalize () |
|
|
StatusCode | initialize () |
|
StatusCode | execute () |
|
StatusCode | finalize () |
|
|
virtual StatusCode | genuserInitialize () |
| For initialization of user code, if required. Called after genInitialize. More...
|
|
|
StatusCode | initialize () |
|
StatusCode | execute () |
|
StatusCode | finalize () |
|
|
virtual StatusCode | genuserInitialize () |
| For initialization of user code, if required. Called after genInitialize. More...
|
|
|
StatusCode | initialize () |
|
StatusCode | execute () |
|
StatusCode | finalize () |
|
|
virtual StatusCode | genuserInitialize () |
| For initialization of user code, if required. Called after genInitialize. More...
|
|
|
StatusCode | initialize () |
|
StatusCode | execute () |
|
StatusCode | finalize () |
|
|
virtual StatusCode | genuserInitialize () |
| For initialization of user code, if required. Called after genInitialize. More...
|
|
|
StatusCode | initialize () |
|
StatusCode | execute () |
|
StatusCode | finalize () |
|
|
virtual StatusCode | genuserInitialize () |
| For initialization of user code, if required. Called after genInitialize. More...
|
|
|
StatusCode | initialize () |
|
StatusCode | execute () |
|
StatusCode | finalize () |
|
|
StatusCode | initialize () |
|
StatusCode | execute () |
|
StatusCode | finalize () |
|
|
virtual StatusCode | genuserInitialize () |
| For initialization of user code, if required. Called after genInitialize. More...
|
|
|
StatusCode | initialize () |
|
StatusCode | execute () |
|
StatusCode | finalize () |
|
|
StatusCode | initialize () |
|
StatusCode | execute () |
|
StatusCode | finalize () |
|
|
virtual StatusCode | genuserInitialize () |
| For initialization of user code, if required. Called after genInitialize. More...
|
|
|
StatusCode | initialize () |
|
StatusCode | execute () |
|
StatusCode | finalize () |
|
|
virtual StatusCode | genuserInitialize () |
| For initialization of user code, if required. Called after genInitialize. More...
|
|
|
StatusCode | initialize () |
|
StatusCode | execute () |
|
StatusCode | finalize () |
|
|
virtual StatusCode | genInitialize () |
| For initializing the generator, if required. More...
|
|
virtual StatusCode | genuserInitialize () |
| For initialization of user code, if required. Called after genInitialize. More...
|
|
virtual StatusCode | genFinalize () |
| For finalising the generator, if required. More...
|
|
|
ServiceHandle< IAthRNGSvc > | m_rndmSvc {this, "RndmSvc", "AthRNGSvc"} |
| Data members. More...
|
|
ServiceHandle< IIncidentSvc > | m_incidentSvc {this, "IncidentSvc", "IncidentSvc"} |
| Handle on the incident service. More...
|
|
IntegerProperty | m_randomSeed {this, "RandomSeed", 1234567, "Random seed for the built-in random engine"} |
| Seed for random number engine. More...
|
|
BooleanProperty | m_isAfterburner {this, "IsAfterburner", false, "Set true if generator modifies existing events rather than creating new ones"} |
| Flag for normal vs. afterburner generators. More...
|
|
CLHEP::HepRandomEngine * | getRandomEngine (const std::string &streamName, const EventContext &ctx) const |
|
CLHEP::HepRandomEngine * | getRandomEngine (const std::string &streamName, unsigned long int randomSeedOffset, const EventContext &ctx) const |
|
CLHEP::HepRandomEngine * | getRandomEngineDuringInitialize (const std::string &streamName, unsigned long int randomSeedOffset, unsigned int conditionsRun=1, unsigned int lbn=1) const |
|
Track Record Generator. The class takes input simulation track records and uses them as generator records.
- Author
- Zach Marshall ZLMar.nosp@m.shal.nosp@m.l@lbl.nosp@m..gov
Definition at line 27 of file TrackRecordGenerator.h.
◆ StoreGateSvc_t
◆ TrackRecordGenerator()
TrackRecordGenerator::TrackRecordGenerator |
( |
const std::string & |
name, |
|
|
ISvcLocator * |
pSvcLocator |
|
) |
| |
◆ ~TrackRecordGenerator()
TrackRecordGenerator::~TrackRecordGenerator |
( |
| ) |
|
|
virtual |
◆ ATLAS_NOT_CONST_THREAD_SAFE() [1/2]
HepMC::GenEvent* event GenBase::ATLAS_NOT_CONST_THREAD_SAFE |
( |
| ) |
|
|
inlineinherited |
Access the current signal event (first in the McEventCollection)
- Note
- This function will make a new McEventCollection if there is not already a valid one and MakeMcEvent=True.
Definition at line 76 of file GenBase.h.
78 ATH_MSG_ERROR(
"McEventCollection is empty during first event access");
79 return *(
events()->begin());
◆ ATLAS_NOT_CONST_THREAD_SAFE() [2/2]
◆ callGenerator()
StatusCode TrackRecordGenerator::callGenerator |
( |
| ) |
|
|
virtual |
For calling the generator on each iteration of the event loop.
Reimplemented from GenModule.
Definition at line 46 of file TrackRecordGenerator.cxx.
57 const EventContext& ctx = Gaudi::Hive::currentContext();
65 for (
auto iterTTR : *coll) {
69 double en = std::sqrt(
mass*
mass+iterTTR.GetMomentum().mag2());
72 <<
"\n mom is "<<iterTTR.GetMomentum()
73 <<
"\n pdg is "<<iterTTR.GetPDGCode() );
75 CLHEP::HepLorentzVector particle4Position( iterTTR.GetPosition(), iterTTR.GetTime());
79 ATH_MSG_DEBUG(
"Track record started at " << particle4Position );
82 if ( particle4Position.z() == 22031 || particle4Position.z() == -22031 ){
83 particle4Position.setX( particle4Position.x() + CLHEP::RandFlat::shoot(rndmEngine, -
m_smearTR,
m_smearTR) );
84 particle4Position.setY( particle4Position.y() + CLHEP::RandFlat::shoot(rndmEngine, -
m_smearTR,
m_smearTR) );
86 particle4Position.setZ( particle4Position.z() + CLHEP::RandFlat::shoot(rndmEngine, -
m_smearTR,
m_smearTR) );
87 double R = std::sqrt(
std::pow( particle4Position.x(),2 ) +
std::pow(particle4Position.y(),2 ) );
89 dPhi = CLHEP::RandFlat::shoot( rndmEngine, -
dPhi,
dPhi );
90 double theta = std::atan2( particle4Position.x() , particle4Position.y() );
94 ATH_MSG_DEBUG(
"Shifted track record to " << particle4Position );
96 CLHEP::HepLorentzVector particle4Momentum( iterTTR.GetMomentum(),
en );
98 ATH_MSG_DEBUG(
"Track record momentum was " << particle4Momentum );
102 double dPhi = CLHEP::RandFlat::shoot(rndmEngine, 0, 2*
M_PI);
105 CLHEP::HepLorentzVector perpendicularMomentum( 1 , 0 , 0 , 0);
106 if ( particle4Momentum.x() != 0 ){
107 if (particle4Momentum.y() == 0){
108 perpendicularMomentum.setX( 0 );
109 perpendicularMomentum.setY( 1 );
111 perpendicularMomentum.setX( particle4Momentum.y() );
112 perpendicularMomentum.setY( particle4Momentum.x() );
117 double tempP =
std::pow(particle4Momentum.x(),2)+
std::pow(particle4Momentum.y(),2)+
std::pow(particle4Momentum.z(),2);
120 perpendicularMomentum.setX(0);
121 perpendicularMomentum.setY(0);
122 }
else if (
std::tan(dTheta) == 0 ){
123 ATH_MSG_DEBUG(
"Randomly deciding to keep the vector's direction...");
124 perpendicularMomentum.setX(0);
125 perpendicularMomentum.setY(0);
128 perpendicularMomentum.setX( perpendicularMomentum.x() *
scale );
129 perpendicularMomentum.setY( perpendicularMomentum.y() *
scale );
132 perpendicularMomentum.rotate(
dPhi , particle4Momentum.vect() );
134 particle4Momentum.setX( particle4Momentum.x() + perpendicularMomentum.x() );
135 particle4Momentum.setY( particle4Momentum.y() + perpendicularMomentum.y() );
136 particle4Momentum.setZ( particle4Momentum.z() + perpendicularMomentum.z() );
139 double scale2 = tempP==0? 1 : (
pow(particle4Momentum.x(),2)+
pow(particle4Momentum.y(),2)+
pow(particle4Momentum.z(),2)) / tempP;
140 particle4Momentum.setX( particle4Momentum.x() *
scale2 );
141 particle4Momentum.setY( particle4Momentum.y() *
scale2 );
142 particle4Momentum.setZ( particle4Momentum.z() *
scale2 );
143 ATH_MSG_DEBUG(
"Rotated the vector by " << perpendicularMomentum );
144 ATH_MSG_DEBUG(
"And resulting momentum is " << particle4Momentum );
147 ATH_MSG_DEBUG(
"Will stop the track record where it is and give it mass " <<
mass );
148 particle4Momentum.setX(0);
149 particle4Momentum.setY(0);
150 particle4Momentum.setZ(0);
151 particle4Momentum.setT(
mass);
161 m_fourPos.push_back( particle4Position );
162 m_fourMom.push_back( particle4Momentum );
164 m_pdgCode.push_back(iterTTR.GetPDGCode());
165 HepMC::Polarization thePolarization(0.0,0.0);
174 return StatusCode::SUCCESS;
◆ cmTomm()
void GenBase::cmTomm |
( |
HepMC::GenEvent * |
evt | ) |
|
|
protectedinherited |
Scale event lengths by x 10.
Definition at line 78 of file GenBase.cxx.
79 for (HepMC::GenEvent::vertex_iterator vtx =
evt->vertices_begin(); vtx !=
evt->vertices_end(); ++vtx) {
80 const HepMC::FourVector fv((*vtx)->position().x() * 10,
81 (*vtx)->position().y() * 10,
82 (*vtx)->position().z() * 10,
83 (*vtx)->position().t() * 10);
84 (*vtx)->set_position(fv);
◆ declareGaudiProperty() [1/4]
specialization for handling Gaudi::Property<SG::VarHandleKeyArray>
Definition at line 170 of file AthCommonDataStore.h.
175 hndl.documentation());
◆ declareGaudiProperty() [2/4]
specialization for handling Gaudi::Property<SG::VarHandleKey>
Definition at line 156 of file AthCommonDataStore.h.
161 hndl.documentation());
◆ declareGaudiProperty() [3/4]
specialization for handling Gaudi::Property<SG::VarHandleBase>
Definition at line 184 of file AthCommonDataStore.h.
189 hndl.documentation());
◆ declareGaudiProperty() [4/4]
◆ declareProperty() [1/6]
Declare a new Gaudi property.
- Parameters
-
name | Name of the property. |
hndl | Object holding the property value. |
doc | Documentation string for the property. |
This is the version for types that derive from SG::VarHandleBase
. The property value object is put on the input and output lists as appropriate; then we forward to the base class.
Definition at line 245 of file AthCommonDataStore.h.
250 this->declare(hndl.
vhKey());
251 hndl.
vhKey().setOwner(
this);
253 return PBASE::declareProperty(
name,hndl,
doc);
◆ declareProperty() [2/6]
Declare a new Gaudi property.
- Parameters
-
name | Name of the property. |
hndl | Object holding the property value. |
doc | Documentation string for the property. |
This is the version for types that derive from SG::VarHandleKey
. The property value object is put on the input and output lists as appropriate; then we forward to the base class.
Definition at line 221 of file AthCommonDataStore.h.
229 return PBASE::declareProperty(
name,hndl,
doc);
◆ declareProperty() [3/6]
◆ declareProperty() [4/6]
Declare a new Gaudi property.
- Parameters
-
name | Name of the property. |
property | Object holding the property value. |
doc | Documentation string for the property. |
This is the generic version, for types that do not derive from SG::VarHandleKey
. It just forwards to the base class version of declareProperty
.
Definition at line 333 of file AthCommonDataStore.h.
338 return PBASE::declareProperty(
name, property,
doc);
◆ declareProperty() [5/6]
Declare a new Gaudi property.
- Parameters
-
name | Name of the property. |
property | Object holding the property value. |
doc | Documentation string for the property. |
This dispatches to either the generic declareProperty
or the one for VarHandle/Key/KeyArray.
Definition at line 352 of file AthCommonDataStore.h.
◆ declareProperty() [6/6]
◆ detStore()
◆ event_const()
const HepMC::GenEvent* GenBase::event_const |
( |
| ) |
const |
|
inlineinherited |
Access the current signal event (const)
Definition at line 83 of file GenBase.h.
85 ATH_MSG_ERROR(
"Const McEventCollection is empty during first event access");
◆ events_const() [1/2]
◆ events_const() [2/2]
◆ evtStore() [1/2]
◆ evtStore() [2/2]
◆ execute()
StatusCode GenModule::execute |
( |
| ) |
|
|
virtualinherited |
- Todo:
- Remove hard-coded alg name checking (already incomplete)
Reimplemented from GenBase.
Definition at line 70 of file GenModule.cxx.
105 if (
name() ==
"ParticleDecayer") {
112 return StatusCode::SUCCESS;
◆ extraDeps_update_handler()
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
◆ extraOutputDeps()
const DataObjIDColl & AthAlgorithm::extraOutputDeps |
( |
| ) |
const |
|
overridevirtualinherited |
Return the list of extra output dependencies.
This list is extended to include symlinks implied by inheritance relations.
Definition at line 50 of file AthAlgorithm.cxx.
57 return Algorithm::extraOutputDeps();
◆ fillEvt()
StatusCode TrackRecordGenerator::fillEvt |
( |
HepMC::GenEvent * |
evt | ) |
|
|
virtual |
For filling the HepMC event object.
Implements GenModule.
Definition at line 178 of file TrackRecordGenerator.cxx.
181 ATH_MSG_ERROR(
"Wrong different number of vertexes/momenta/polaritazions!");
182 return StatusCode::FAILURE;
196 event->add_vertex(
vertex );
203 if (
event->weights().empty()){
204 event->weights().push_back(1.0);
206 return StatusCode::SUCCESS;
◆ finalize()
StatusCode GenModule::finalize |
( |
| ) |
|
|
inlineinherited |
◆ genFinalize()
virtual StatusCode GenModule::genFinalize |
( |
| ) |
|
|
inlinevirtualinherited |
For finalising the generator, if required.
Reimplemented in Hijing, Herwig7, CosmicGenerator, Pythia8_i, Hydjet, Starlight_i, Epos, BeamHaloGeneratorAlg, MultiParticleGunPileup, MultiPy8Pileup, Pythia8B_i, and Sherpa_i.
Definition at line 70 of file GenModule.h.
70 {
return StatusCode::SUCCESS; }
◆ genInitialize()
virtual StatusCode GenModule::genInitialize |
( |
| ) |
|
|
inlinevirtualinherited |
For initializing the generator, if required.
Reimplemented in Hijing, Herwig7, CosmicGenerator, Pythia8_i, Hydjet, Starlight_i, ParticleDecayer, Epos, BeamHaloGeneratorAlg, MultiParticleGunPileup, MultiPy8Pileup, Pythia8B_i, and Sherpa_i.
Definition at line 62 of file GenModule.h.
62 {
return StatusCode::SUCCESS; }
◆ genuserInitialize()
virtual StatusCode GenModule::genuserInitialize |
( |
| ) |
|
|
inlinevirtualinherited |
For initialization of user code, if required. Called after genInitialize.
Reimplemented in Pythia8B_i.
Definition at line 64 of file GenModule.h.
64 {
return StatusCode::SUCCESS; }
◆ getRandomEngine() [1/2]
CLHEP::HepRandomEngine * GenModule::getRandomEngine |
( |
const std::string & |
streamName, |
|
|
const EventContext & |
ctx |
|
) |
| const |
|
protectedinherited |
◆ getRandomEngine() [2/2]
CLHEP::HepRandomEngine * GenModule::getRandomEngine |
( |
const std::string & |
streamName, |
|
|
unsigned long int |
randomSeedOffset, |
|
|
const EventContext & |
ctx |
|
) |
| const |
|
protectedinherited |
◆ getRandomEngineDuringInitialize()
CLHEP::HepRandomEngine * GenModule::getRandomEngineDuringInitialize |
( |
const std::string & |
streamName, |
|
|
unsigned long int |
randomSeedOffset, |
|
|
unsigned int |
conditionsRun = 1 , |
|
|
unsigned int |
lbn = 1 |
|
) |
| const |
|
protectedinherited |
Definition at line 53 of file GenModule.cxx.
58 ctx.setEventID (EventIDBase (conditionsRun,
59 EventIDBase::UNDEFEVT,
60 EventIDBase::UNDEFNUM,
61 EventIDBase::UNDEFNUM,
◆ GeVToMeV()
void GenBase::GeVToMeV |
( |
HepMC::GenEvent * |
evt | ) |
|
|
protectedinherited |
Scale event energies/momenta by x 1000.
- Todo:
- Add HepMC units awareness and do it differently when HepMC provides this functionality directly (and reference-based FourVector accessors)
Definition at line 58 of file GenBase.cxx.
59 for (HepMC::GenEvent::particle_iterator
p =
evt->particles_begin();
p !=
evt->particles_end(); ++
p) {
60 const HepMC::FourVector fv((*p)->momentum().px() * 1000,
61 (*p)->momentum().py() * 1000,
62 (*p)->momentum().pz() * 1000,
63 (*p)->momentum().e() * 1000);
64 (*p)->set_momentum(fv);
65 (*p)->set_generated_mass(1000 * (*p)->generated_mass());
◆ initialize()
StatusCode GenModule::initialize |
( |
| ) |
|
|
virtualinherited |
◆ inputHandles()
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.
◆ MeVToGeV()
void GenBase::MeVToGeV |
( |
HepMC::GenEvent * |
evt | ) |
|
|
protectedinherited |
Scale event energies/momenta by x 1/1000.
Definition at line 68 of file GenBase.cxx.
69 for (HepMC::GenEvent::particle_iterator
p =
evt->particles_begin();
p !=
evt->particles_end(); ++
p) {
70 const HepMC::FourVector fv((*p)->momentum().px() / 1000,
71 (*p)->momentum().py() / 1000,
72 (*p)->momentum().pz() / 1000,
73 (*p)->momentum().e() / 1000);
74 (*p)->set_momentum(fv);
75 (*p)->set_generated_mass((*p)->generated_mass() / 1000);
◆ mmTocm()
void GenBase::mmTocm |
( |
HepMC::GenEvent * |
evt | ) |
|
|
protectedinherited |
Scale event lengths by x 1/10.
Definition at line 87 of file GenBase.cxx.
88 for (HepMC::GenEvent::vertex_iterator vtx =
evt->vertices_begin(); vtx !=
evt->vertices_end(); ++vtx) {
89 const HepMC::FourVector fv((*vtx)->position().x() / 10,
90 (*vtx)->position().y() / 10,
91 (*vtx)->position().z() / 10,
92 (*vtx)->position().t() / 10);
93 (*vtx)->set_position(fv);
◆ msg() [1/2]
◆ msg() [2/2]
◆ msgLvl()
◆ outputHandles()
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.
◆ particleData()
const HepPDT::ParticleData* GenBase::particleData |
( |
int |
pid | ) |
const |
|
inlineinherited |
Access an element in the particle data table.
Definition at line 126 of file GenBase.h.
◆ particleTable()
const HepPDT::ParticleDataTable& GenBase::particleTable |
( |
| ) |
const |
|
inlineinherited |
Get a particle data table.
Definition at line 118 of file GenBase.h.
◆ partPropSvc()
Access the particle property service.
Definition at line 113 of file GenBase.h.
◆ pdt()
const HepPDT::ParticleDataTable& GenBase::pdt |
( |
| ) |
const |
|
inlineinherited |
Shorter alias to get a particle data table.
Definition at line 123 of file GenBase.h.
◆ renounce()
◆ renounceArray()
◆ sysInitialize()
StatusCode AthAlgorithm::sysInitialize |
( |
| ) |
|
|
overridevirtualinherited |
◆ sysStart()
Handle START transition.
We override this in order to make sure that conditions handle keys can cache a pointer to the conditions container.
◆ updateVHKA()
◆ m_add_cL
bool TrackRecordGenerator::m_add_cL |
|
private |
◆ m_center
CLHEP::Hep3Vector TrackRecordGenerator::m_center |
|
private |
◆ m_detStore
◆ m_events
int TrackRecordGenerator::m_events |
|
private |
◆ m_evtStore
◆ m_extendedExtraObjects
DataObjIDColl AthAlgorithm::m_extendedExtraObjects |
|
privateinherited |
◆ m_fourMom
std::vector<CLHEP::HepLorentzVector> TrackRecordGenerator::m_fourMom |
|
private |
◆ m_fourPos
std::vector<CLHEP::HepLorentzVector> TrackRecordGenerator::m_fourPos |
|
private |
◆ m_incidentSvc
ServiceHandle<IIncidentSvc> GenModule::m_incidentSvc {this, "IncidentSvc", "IncidentSvc"} |
|
privateinherited |
Handle on the incident service.
Definition at line 101 of file GenModule.h.
◆ m_isAfterburner
BooleanProperty GenModule::m_isAfterburner {this, "IsAfterburner", false, "Set true if generator modifies existing events rather than creating new ones"} |
|
protectedinherited |
Flag for normal vs. afterburner generators.
Definition at line 87 of file GenModule.h.
◆ m_mcEventKey
std::string GenBase::m_mcEventKey {} |
|
protectedinherited |
StoreGate key for the MC event collection (defaults to GEN_EVENT)
Definition at line 137 of file GenBase.h.
◆ m_mcevents_const
Const handle to the MC event collection.
Definition at line 163 of file GenBase.h.
◆ m_mkMcEvent
BooleanProperty GenBase::m_mkMcEvent {this, "MakeMcEvent", false, "Create a new MC event collection if it doesn't exist"} |
|
protectedinherited |
Flag to determine if a new MC event collection should be made if it doesn't exist.
Definition at line 139 of file GenBase.h.
◆ m_pdgCode
std::vector<int> TrackRecordGenerator::m_pdgCode |
|
private |
◆ m_polarization
std::vector<HepMC::Polarization> TrackRecordGenerator::m_polarization |
|
private |
◆ m_ppSvc
ServiceHandle<IPartPropSvc> GenBase::m_ppSvc {this, "PartPropSvc", "PartPropSvc"} |
|
privateinherited |
Handle on the particle property service.
Definition at line 160 of file GenBase.h.
◆ m_randomSeed
IntegerProperty GenModule::m_randomSeed {this, "RandomSeed", 1234567, "Random seed for the built-in random engine"} |
|
protectedinherited |
Seed for random number engine.
Definition at line 84 of file GenModule.h.
◆ m_recordName
std::string TrackRecordGenerator::m_recordName |
|
private |
◆ m_rndmSvc
◆ m_smearTR
double TrackRecordGenerator::m_smearTR |
|
private |
◆ m_smearTRp
double TrackRecordGenerator::m_smearTRp |
|
private |
◆ m_stopParticles
bool TrackRecordGenerator::m_stopParticles |
|
private |
◆ m_stopped_tminus
float TrackRecordGenerator::m_stopped_tminus |
|
private |
◆ m_stopped_tplus
float TrackRecordGenerator::m_stopped_tplus |
|
private |
◆ m_varHandleArraysDeclared
◆ m_vhka
The documentation for this class was generated from the following files:
HepMC::GenVertex * GenVertexPtr
def retrieve(aClass, aKey=None)
void setSeed(const std::string &algName, const EventContext &ctx)
Set the random seed using a string (e.g.
constexpr ParticleHypothesis particle[PARTICLEHYPOTHESES]
the array of masses
const_pointer_type cptr()
Dereference the pointer.
virtual StatusCode fillEvt(HepMC::GenEvent *evt)=0
For filling the HepMC event object.
virtual StatusCode callGenerator()
For calling the generator on each iteration of the event loop.
const McEventCollection * events_const() const
Access the current event's McEventCollection (const)
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T > &t)
double m_smearTR
Amount by which to smear TR position.
Scalar theta() const
theta method
GenParticle * GenParticlePtr
ServiceHandle< IIncidentSvc > m_incidentSvc
Handle on the incident service.
void set_polarization(T &a, const Polarization &b)
StoreGateSvc_t m_evtStore
Pointer to StoreGate (event store by default)
std::vector< SG::VarHandleKeyArray * > m_vhka
std::vector< int > m_pdgCode
GenEvent * newGenEvent(const int a, const int b)
#define ATH_MSG_VERBOSE(x)
const std::string & key() const
Return the StoreGate ID for the referenced object.
std::string m_recordName
TrackRecord collection name.
void fillBarcodesAttribute(GenEvent *)
CLHEP::HepRandomEngine * getRandomEngine(const std::string &streamName, const EventContext &ctx) const
virtual void setOwner(IDataHandleHolder *o)=0
std::vector< CLHEP::HepLorentzVector > m_fourPos
bool m_stopParticles
Stop particles before simulation.
SG::ReadCondHandle< T > makeHandle(const SG::ReadCondHandleKey< T > &key, const EventContext &ctx=Gaudi::Hive::currentContext())
std::vector< HepMC::Polarization > m_polarization
virtual StatusCode genuserInitialize()
For initialization of user code, if required. Called after genInitialize.
ServiceHandle< IAthRNGSvc > m_rndmSvc
Data members.
ServiceHandle< IPartPropSvc > m_ppSvc
Handle on the particle property service.
ServiceHandle< StoreGateSvc > & evtStore()
The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.
virtual StatusCode genInitialize()
For initializing the generator, if required.
virtual StatusCode sysInitialize() override
Override sysInitialize.
POOL::TEvent event(POOL::TEvent::kClassAccess)
virtual std::vector< Gaudi::DataHandle * > outputHandles() const override
Return this algorithm's output handles.
GenVertexPtr newGenVertexPtr(const HepMC::FourVector &pos=HepMC::FourVector(0.0, 0.0, 0.0, 0.0), const int i=0)
::StatusCode StatusCode
StatusCode definition for legacy code.
SG::ReadHandleKey< McEventCollection > m_mcevents_const
Const handle to the MC event collection.
BooleanProperty m_isAfterburner
Flag for normal vs. afterburner generators.
bool dPhi(const xAOD::TauJet &tau, const xAOD::TauTrack &track, double &out)
virtual StatusCode genFinalize()
For finalising the generator, if required.
#define CHECK(...)
Evaluate an expression and check for errors.
double R(const INavigable4Momentum *p1, const double v_eta, const double v_phi)
StoreGateSvc_t m_detStore
Pointer to StoreGate (detector store by default)
std::vector< CLHEP::HepLorentzVector > m_fourMom
virtual bool isValid() override final
Can the handle be successfully dereferenced?
virtual void renounce()=0
const HepPDT::ParticleDataTable & particleTable() const
Get a particle data table.
std::conditional< std::is_base_of< SG::VarHandleKeyArray, T >::value, VarHandleKeyArrayType, type2 >::type type
GenModule(const std::string &name, ISvcLocator *pSvcLocator)
Constructor.
A wrapper class for event-slot-local random engines.
float m_stopped_tplus
Bounds for random time.
CLHEP::HepRandomEngine * getEngine(const EventContext &ctx) const
Retrieve the random engine corresponding to the provided EventContext.
DataObjIDColl m_extendedExtraObjects
GenParticlePtr newGenParticlePtr(const HepMC::FourVector &mom=HepMC::FourVector(0.0, 0.0, 0.0, 0.0), int pid=0, int status=0)
#define ATH_MSG_WARNING(x)
const HepPDT::ParticleDataTable & pdt() const
Shorter alias to get a particle data table.
SG::VarHandleKey & vhKey()
Return a non-const reference to the HandleKey.
constexpr int pow(int base, int exp) noexcept
const HepPDT::ParticleData * particleData(int pid) const
Access an element in the particle data table.
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>
void setExtendedEventContext(EventContext &ctx, ExtendedEventContext &&ectx)
Move an extended context into a context object.
virtual StatusCode initialize() override
double m_smearTRp
Amount by which to smear TR momentum.
bool m_add_cL
For stopped particles, add c*L to the time.
const_iterator begin() const noexcept
Return a const_iterator pointing at the beginning of the collection.