ATLAS Offline Software
Public Member Functions | Static Public Attributes | Protected Member Functions | Private Types | Private Member Functions | Private Attributes | Static Private Attributes | List of all members
CosmicGenerator Class Reference

Cosmic generator. The output will be stored in the transient event store so it can be passed to the simulation. More...

#include <CosmicGenerator.h>

Inheritance diagram for CosmicGenerator:
Collaboration diagram for CosmicGenerator:

Public Member Functions

 CosmicGenerator (const std::string &name, ISvcLocator *pSvcLocator)
 
virtual ~CosmicGenerator ()=default
 
virtual StatusCode genInitialize ()
 For initializing the generator, if required. More...
 
virtual StatusCode callGenerator ()
 For calling the generator on each iteration of the event loop. More...
 
virtual StatusCode genFinalize ()
 For finalising the generator, if required. More...
 
virtual StatusCode fillEvt (HepMC::GenEvent *evt)
 For filling the HepMC event object. More...
 
CLHEP::HepLorentzVector generateVertex (void)
 
CLHEP::HepLorentzVector generateVertexReweighted (void)
 
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
 

Static Public Attributes

static CLHEP::HepRandomEngine * COSMIC_RANDOM_ENGINE {}
 Static pointer to random number generator for use by. More...
 

Protected Member Functions

void renounceArray (SG::VarHandleKeyArray &handlesArray)
 remove all handles from I/O resolution More...
 
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. More...
 

Private Types

typedef ServiceHandle< StoreGateSvcStoreGateSvc_t
 

Private Member Functions

bool exzCut (const CLHEP::Hep3Vector &pos, const CLHEP::HepLorentzVector &p)
 
double pathLengthInRock (double xgen, double ygen, double zgen, double theta, double phi)
 
bool pointsAtPixels (double xgen, double ygen, double zgen, double theta, double phi)
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
 specialization for handling Gaudi::Property<SG::VarHandleKey> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleKeyArrayType &)
 specialization for handling Gaudi::Property<SG::VarHandleKeyArray> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleType &)
 specialization for handling Gaudi::Property<SG::VarHandleBase> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &t, const SG::NotHandleType &)
 specialization for handling everything that's not a Gaudi::Property<SG::VarHandleKey> or a <SG::VarHandleKeyArray> More...
 

Private Attributes

int m_events {0}
 
int m_rejected {0}
 
int m_accepted {0}
 
std::vector< int > m_pdgCode
 
IntegerProperty m_dsid {this, "Dsid", 999999, "Dataset ID number"}
 
FloatProperty m_emin {this, "emin", 10.*m_GeV}
 
FloatProperty m_emax {this, "emax", 100.*m_GeV}
 
FloatProperty m_ctcut {this, "ctcut", 0.35}
 
FloatProperty m_xlow {this, "xvert_low", 0.*m_mm}
 
FloatProperty m_xhig {this, "xvert_hig", 10.*m_mm}
 
FloatProperty m_zlow {this, "zvert_low", 0.*m_mm}
 
FloatProperty m_zhig {this, "zvert_hig", 10.*m_mm}
 
FloatProperty m_yval {this, "yvert_val", 81.*m_mm}
 
FloatProperty m_IPx {this, "IPx", 0.f}
 
FloatProperty m_IPy {this, "IPy", 0.f}
 
FloatProperty m_IPz {this, "IPz", 0.f}
 
FloatProperty m_radius {this, "Radius", 0.f}
 
FloatProperty m_zpos {this, "Zposition", 14500.f}
 
FloatProperty m_tmin {this, "tmin", 0.f}
 
FloatProperty m_tmax {this, "tmax", 0.f}
 
BooleanProperty m_cavOpt {this, "OptimizeForCavern", false}
 
IntegerProperty m_srOneOpt {this, "OptimizeForSR1", 0}
 
BooleanProperty m_srOnePixECOpt {this, "OptimizeForSR1PixelEndCap", false}
 
BooleanProperty m_swapYZAxis {this, "SwapYZAxis", false}
 
BooleanProperty m_muonECOpt {this, "OptimizeForMuonEndCap", false}
 
IntegerProperty m_printEvent {this, "PrintEvent", 10}
 
IntegerProperty m_printMod {this, "PrintMod", 100}
 
FloatProperty m_thetamin {this, "ThetaMin", 0.f}
 
FloatProperty m_thetamax {this, "ThetaMax", 1.f}
 
FloatProperty m_phimin {this, "PhiMin", -1.*M_PI}
 
FloatProperty m_phimax {this, "PhiMax", M_PI}
 
bool m_readfile {false}
 
StringProperty m_infile {this, "eventfile", "NONE"}
 
std::ifstream m_ffile
 
std::vector< CLHEP::HepLorentzVector > m_fourPos
 
std::vector< CLHEP::HepLorentzVector > m_fourMom
 
CLHEP::Hep3Vector m_center
 
std::vector< HepMC::Polarization > m_polarization
 
BooleanProperty m_exzCut {this, "ExzCut", false}
 
FloatProperty m_rmax {this, "RMax", 10000000.f}
 
BooleanProperty m_doPathlengthCut {this, "doPathLengthCut", false}
 
BooleanProperty m_doAimedAtPixelsCut {this, "doAimedAtPixelsCut", false}
 
BooleanProperty m_doReweighting {this, "doReweighting", false}
 
DoubleProperty m_energyCutThreshold {this, "energyCutThreshold", 1.0}
 
DoubleProperty m_ysurface {this, "ysurface", 81.*m_mm}
 
DoubleProperty m_rvertmax {this, "rvert_max", 300.*m_mm}
 
DoubleProperty m_pixelplanemaxx {this, "pixelplane_maxx", 1150.}
 
DoubleProperty m_pixelplanemaxz {this, "pixelplane_maxz", 1650.}
 
DataObjIDColl m_extendedExtraObjects
 
StoreGateSvc_t m_evtStore
 Pointer to StoreGate (event store by default) More...
 
StoreGateSvc_t m_detStore
 Pointer to StoreGate (detector store by default) More...
 
std::vector< SG::VarHandleKeyArray * > m_vhka
 
bool m_varHandleArraysDeclared
 

Static Private Attributes

static constexpr float m_GeV = 1000.f
 
static constexpr float m_mm = 10.f
 

Utility event-mangling functions

Todo:
Replace with HepMC units when available
ServiceHandle< IPartPropSvc > m_ppSvc {this, "PartPropSvc", "PartPropSvc"}
 Handle on the particle property service. More...
 
SG::ReadHandleKey< McEventCollectionm_mcevents_const { this, "McEventKey", "GEN_EVENT", "StoreGate key of the MC event collection" }
 Const handle to the MC event collection. More...
 
void GeVToMeV (HepMC::GenEvent *evt)
 Scale event energies/momenta by x 1000. More...
 
void MeVToGeV (HepMC::GenEvent *evt)
 Scale event energies/momenta by x 1/1000. More...
 
void cmTomm (HepMC::GenEvent *evt)
 Scale event lengths by x 10. More...
 
void mmTocm (HepMC::GenEvent *evt)
 Scale event lengths by x 1/10. More...
 

Features for derived classes to use internally

ServiceHandle< IAthRNGSvcm_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
 

Detailed Description

Cosmic generator. The output will be stored in the transient event store so it can be passed to the simulation.

Author
W. Seligman: Initial Code 08-Nov-2002, based on work by M. Shapiro and I. Hinchliffe

Modification for increasing efficiency of muon hitting the detector: H. Ma. March 17, 2006 Property: ExzCut:
if true, the method exzCut(...) will be called to apply a energy dependent position cut on the surface. This rejects low energy muons at large distance. Property: RMax Used by exzCut to reject non-projective muons, which are too far out on the surface

Modifications to accomodate Pixel EndCap C Cosmic Test needs Marian Zdrazil June 7, 2006 mzdra.nosp@m.zil@.nosp@m.lbl.g.nosp@m.ov

Modifications to accomodate replacement of Pixel EndCap C by a Pixel EndCap A Marian Zdrazil November 24, 2006 mzdra.nosp@m.zil@.nosp@m.lbl.g.nosp@m.ov

It is easier and actually more useful to leave the EndCap A in the vertical position (the way it is positioned in the ATLAS detector) instead of rotating it clockwise by 90deg which corresponds to the placement during the Pixel EndCap A cosmic test in SR1 in November 2006. This is why we will generate cosmic muons coming from the positive Z-axis direction better than rotating the whole setup in PixelGeoModel.

Modifications July 3rd 2007, Rob McPherson

Optimize selection of events passed to Geant4 for full simulation:

Definition at line 75 of file CosmicGenerator.h.

Member Typedef Documentation

◆ StoreGateSvc_t

typedef ServiceHandle<StoreGateSvc> AthCommonDataStore< AthCommonMsg< Algorithm > >::StoreGateSvc_t
privateinherited

Definition at line 388 of file AthCommonDataStore.h.

Constructor & Destructor Documentation

◆ CosmicGenerator()

CosmicGenerator::CosmicGenerator ( const std::string &  name,
ISvcLocator *  pSvcLocator 
)

Definition at line 80 of file CosmicGenerator.cxx.

82  : GenModule(name,pSvcLocator)
83 //--------------------------------------------------------------------------
84 {
85 }

◆ ~CosmicGenerator()

virtual CosmicGenerator::~CosmicGenerator ( )
virtualdefault

Member Function Documentation

◆ 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.

76  {
77  if (events()->empty())
78  ATH_MSG_ERROR("McEventCollection is empty during first event access");
79  return *(events()->begin());
80  }

◆ ATLAS_NOT_CONST_THREAD_SAFE() [2/2]

McEventCollection* events GenBase::ATLAS_NOT_CONST_THREAD_SAFE ( )
inherited

Access the current event's McEventCollection.

Note
This function will make a new McEventCollection if there is not already a valid one and MakeMcEvent=True.

◆ callGenerator()

StatusCode CosmicGenerator::callGenerator ( )
virtual

For calling the generator on each iteration of the event loop.

Reimplemented from GenModule.

Definition at line 214 of file CosmicGenerator.cxx.

214  {
215 //---------------------------------------------------------------------------
216 
217  ++m_events;
218  ATH_MSG_DEBUG( "Event #" << m_events);
219 
220  assert(COSMIC_RANDOM_ENGINE != 0);
221  //Re-seed the random number stream
222  long seeds[7];
223  const EventContext& ctx = Gaudi::Hive::currentContext();
224  ATHRNG::calculateSeedsMC21(seeds, "COSMICS", ctx.eventID().event_number(), m_dsid, m_randomSeed);
225  COSMIC_RANDOM_ENGINE->setSeeds(seeds, 0); // NOT THREAD-SAFE
226  CLHEP::HepRandomEngine* engine = COSMIC_RANDOM_ENGINE;
227 
228  // clear up the vectors
229  m_fourPos.clear();
230  m_fourMom.clear();
231  m_polarization.clear();
232  m_pdgCode.clear();
233 
234 
235  if(m_readfile)
236  {
237  if(!m_ffile.eof())
238  {
240  m_ffile >> evt;
241 
242  ATH_MSG_VERBOSE( evt );
243 
244  HepMC::Polarization thePolarization(0.0,0.0);
245  m_polarization.push_back(thePolarization);
246 
247  //
248  // units are already converted to MeV's and mm.
249  //
250  m_fourPos.push_back(evt.Vertex());
251  m_fourMom.push_back(evt.Momentum());
252  m_pdgCode.push_back(evt.pdgID());
253 
254  }
255  else
256  {
257  ATH_MSG_FATAL( "End of file reached - stop " );
258  exit(1);
259  return StatusCode::FAILURE;
260  }
261  }
262  else
263  {
264 
265  bool accepted=false;
266  CLHEP::HepLorentzVector pp;
268  CLHEP::HepLorentzVector vert;
269  CLHEP::Hep3Vector vert3;
270  double theta1;
271  double phi1;
272  double mag1;
273 
274  while(!accepted){
275 
276  if (m_doReweighting && m_cavOpt) {
277  // The code here doesn't make sense without the sphere cut in the
278  // cavern optimization that is selected by OptimizeForCavern=True
279  vert = generateVertexReweighted();
280  vert3 = CLHEP::Hep3Vector(vert.x(),vert.y(),vert.z());
281 
282  double vert_radius=sqrt(vert3.x()*vert3.x() + vert3.z()*vert3.z());
283 
284  pp = gun->GenerateEvent();
285 
286  theta1=pp.theta();
287  phi1=pp.phi();
288  mag1=pp.rho();
289 
290  if (vert_radius>m_radius) {
291  phi1=atan2(vert.z(),vert.x())+M_PI;
292  float delta_phi=std::asin(m_radius/vert_radius);
293  phi1=phi1+CLHEP::RandFlat::shoot(engine, -delta_phi, delta_phi);
294  }
295  pp.setX(mag1*sin(theta1)*std::cos(phi1));
296  pp.setY(mag1*sin(theta1)*std::sin(phi1));
297 
298  } else {
299  vert = generateVertex();
300  vert3 = CLHEP::Hep3Vector(vert.x(),vert.y(),vert.z());
301 
302  pp = gun->GenerateEvent();
303 
304  theta1=pp.theta();
305  phi1=pp.phi();
306  mag1=pp.rho();
307  }
308 
309  CLHEP::Hep3Vector pp_corr(mag1*sin(theta1)*std::cos(phi1),
310  -mag1*std::cos(theta1),
311  mag1*std::sin(theta1)*std::sin(phi1));
312  CLHEP::Hep3Vector direction(pp_corr.x(),pp_corr.y(), pp_corr.z());
313 
314  // if optimization activated, check for the direction of the generated muon
315  if(m_cavOpt) {
316 
317  CLHEP::Hep3Vector center_dir=m_center-vert3;
318  double beta=direction.angle(center_dir);
319  double alpha=std::asin(m_radius/center_dir.r());
320 
321  if(std::abs(beta)<alpha) {
322 
323  if(m_exzCut) {
324  // Old optimization code - is it still useful?
325  CLHEP::HepLorentzVector pp2(pp_corr.x(),pp_corr.y(), pp_corr.z(), pp.e());
326  if( exzCut(vert3,pp2) ) {
327  accepted=true;
328  }
329  } else {
330 
331  accepted = true;
332 
333  ATH_MSG_DEBUG( "x0 = " << vert3.x()
334  << ", y0 = " << vert3.y()
335  << ", z0 = " << vert3.z()
336  << ", theta = " << pp.theta()
337  << ", phi = " << pp.phi()
338  << ", energy = " << pp.e()*m_GeV );
339 
340  if (m_doPathlengthCut) {
341  double path = pathLengthInRock(vert3.x(),vert3.y(),vert3.z(),pp.theta(),pp.phi());
342  double energyLoss = 2.33e-3 * 244. * path; //FIXME Hardcoded values!
343  ATH_MSG_DEBUG( "Energy loss is " << energyLoss
344  << " --> " << (energyLoss>pp.e()*m_GeV ? "REJECTED" : "ACCEPTED") << " by pathlength cut");
345  if (energyLoss-m_energyCutThreshold > pp.e()*m_GeV) accepted = false;
346  }
347 
348  if (m_doAimedAtPixelsCut) {
349  bool aimedAtPixels = pointsAtPixels(vert3.x(),vert3.y(),vert3.z(),pp.theta(),pp.phi());
350  ATH_MSG_DEBUG( (aimedAtPixels ? "AIMED AT PIXELS" : "NOT AIMED AT PIXELS") );
351  if (!aimedAtPixels) accepted = false;
352  }
353 
354  // FOR DEBUGGING ONLY
355  if (accepted) {
356  ATH_MSG_VERBOSE("The following event has been accepted for simulation:");
357  ATH_MSG_VERBOSE( "x0 = " << vert3.x() << ", y0 = " << vert3.y() << ", z0 = " << vert3.z()
358  << ", theta = " << pp.theta() << ", phi = " << pp.phi() << ", energy = " << pp.e()*m_GeV );
359 
360  if (m_doPathlengthCut) {
361  double path = pathLengthInRock(vert3.x(),vert3.y(),vert3.z(),pp.theta(),pp.phi());
362  double energyLoss = 2.33e-3 * 244. * path;
363  ATH_MSG_VERBOSE( "Energy loss is " << energyLoss
364  << " --> " << (energyLoss>pp.e()*m_GeV ? "REJECTED" : "ACCEPTED") << " by pathlength cut" );
365  }
366 
367  if (m_doAimedAtPixelsCut) {
368  bool aimedAtPixels = pointsAtPixels(vert3.x(),vert3.y(),vert3.z(),pp.theta(),pp.phi());
369  ATH_MSG_VERBOSE( (aimedAtPixels ? "AIMED AT PIXELS" : "NOT AIMED AT PIXELS") );
370  }
371 
372  }
373 
374  }
375  }
376 
377  if(accepted) {
378  m_accepted++;
379  } else {
380  ATH_MSG_VERBOSE("Rejected muon due to cavern optimization request!");
381  m_rejected++;
382  }
383  }
384  else if(m_srOneOpt == 1) {
385  CLHEP::Hep3Vector srOneVec(direction.x(), direction.y(), direction.z());
386  if(mag1 < 0) // Check if momentum vector is flipped.
387  srOneVec *= -1;
388 
389  if( (srOneVec.phi() >= -2.25) && (srOneVec.phi() <= -1.7) &&
390  (srOneVec.theta() >= 0.85) && (srOneVec.theta() <= 2.25) ) { //FIXME Hardcoded values!
391  accepted = true;
392  m_accepted++;
393  ATH_MSG_DEBUG("Muon accepted by SR1 SCT/TRT optimization!");
394  } else {
395  ATH_MSG_DEBUG("Rejected muon due to SR1 SCT/TRT optimization request!");
396  m_rejected++;
397  }
398  }
399  else if(m_srOneOpt == 2) {
400  CLHEP::Hep3Vector srOneVec(direction.x(), direction.y(), direction.z());
401  if(mag1 < 0) // Check if momentum vector is flipped.
402  srOneVec *= -1;
403 
404  if( (srOneVec.phi() >= -1.68) && (srOneVec.phi() <= -1.08) &&
405  (srOneVec.theta() >= 0.29) && (srOneVec.theta() <= 0.72) ) { //FIXME Hardcoded values!
406  accepted = true;
407  m_accepted++;
408  ATH_MSG_DEBUG("Muon accepted by SR1 SCT/TRT EndCapC optimization!");
409  } else {
410  ATH_MSG_DEBUG("Rejected muon due to SR1 SCT/TRT EndcapC optimization request!");
411  m_rejected++;
412  }
413  }
414 
415  else if(m_srOnePixECOpt) {
416  CLHEP::Hep3Vector srOneVec(direction.x(), direction.y(), direction.z());
417  if(mag1 < 0) // Check if momentum vector is flipped.
418  srOneVec *= -1;
419 
420  if( (srOneVec.phi() >= m_phimin) && (srOneVec.phi() <= m_phimax) &&
421  (srOneVec.theta() >= m_thetamin) && (srOneVec.theta() <= m_thetamax) ) {
422  accepted = true;
423  m_accepted++;
424  ATH_MSG_DEBUG("Muon accepted by SR1 Pixel EndCap optimization!");
425  } else {
426  ATH_MSG_DEBUG("Rejected muon due to SR1 Pixel EndCap optimization request!");
427  m_rejected++;
428  }
429  }
430 
431  else if (m_muonECOpt) {
432  double coor_x, coor_y, coor_z;
433  coor_z = m_zpos; // defined in jobOpt.
434  coor_x = direction.x()*(coor_z - vert.z())/direction.z() +vert.x();
435  coor_y = direction.y()*(coor_z - vert.z())/direction.z() +vert.y();
436  if( ((coor_x)*(coor_x) + (coor_y)*(coor_y)) <= m_radius*m_radius ) {
437  accepted = true;
438  m_accepted++;
439  } else {
440  coor_z = -m_zpos;
441  coor_x = direction.x()*(coor_z - vert.z())/direction.z() +vert.x();
442  coor_y = direction.y()*(coor_z - vert.z())/direction.z() +vert.y();
443  if( ((coor_x)*(coor_x) + (coor_y)*(coor_y)) <= m_radius*m_radius ) {
444  accepted = true;
445  m_accepted++;
446  } else {
447  ATH_MSG_DEBUG("Rejected muon due to Muon EndCap optimization request!");
448  m_rejected++;
449  }
450  }
451  }
452 
453  else accepted=true; // if no opt required accept the first muon
454  }
455 
456  pp.setX(pp.x()*m_GeV);
457  pp.setY(pp.y()*m_GeV);
458  pp.setZ(pp.z()*m_GeV);
459  pp.setT(pp.t()*m_GeV);
460 
461  // Get the mass of the particle to be generated
462  int charge = gun->GetMuonCharge();
463  // m_pdgCode.push_back(charge*13);
464  m_pdgCode.push_back(charge*-13);
465 
466  const HepPDT::ParticleData* particle = particleData(std::abs(m_pdgCode.back()));
467  if (particle==nullptr){
468  ATH_MSG_FATAL( "Particle with PDG ID=" << std::abs(m_pdgCode.back()) << " returned a nullptr" );
469  return StatusCode::FAILURE;
470  }
471 
472  double mass = particle->mass().value();
473 
474  // Compute the kinematic values. First, the vertex 4-vector:
475  double x = vert.x();
476  double y = vert.y();
477  double z = vert.z();
478  double t = vert.t();
479 
480  // Do we need to swap Y- and Z-axis for the PixelEndCap A Cosmic test ?
481  // if not...do nothing...if so, invert position of y- and z- coordinate
482  //
483  // but not only that...change also the direction of the incoming cosmic muon(s),
484  // they must go towards the pixel endcap A, i.e. y -> -y
485  //
486  if(!m_swapYZAxis)
487  m_fourPos.push_back(CLHEP::HepLorentzVector(x,y,z,t));
488  else
489  m_fourPos.push_back(CLHEP::HepLorentzVector(x,z,y,t));
490 
491  // Set the polarization. Realistically, this is going to be zero
492  // for most studies.
493  HepMC::Polarization thePolarization(0.0);
494  m_polarization.push_back(thePolarization);
495 
496 
497  // The method of calculating e, theta, and phi depends on the user's
498  // commands. Let the KinematicManager handle it.
499  double e = pp.e();
500  double theta = pp.theta();
501  double phi = pp.phi();
502 
503  // At this point, we have e, theta, and phi. Put them together to
504  // get the four-momentum.
505 
506  double p2 = e*e - mass*mass;
507  if ( p2 < 0 )
508  {
509  ATH_MSG_ERROR( "Event #" << m_events
510  << " E=" << e << ", mass=" << mass
511  << " -- you have generated a tachyon! Increase energy or change particle ID." );
512  return StatusCode::FAILURE;
513  }
514 
515  double p = std::sqrt(p2);
516  double px = p*std::sin(theta)*std::cos(phi);
517  double pz = p*std::sin(theta)*std::sin(phi);
518  double py = -p*std::cos(theta);
519 
520  // Do we need to swap Y- and Z-axis for the PixelEndCap C Cosmic test ?
521  // if not...do nothing...if so, invert position of y- and z- coordinate
522  //
523  // well and don't forget about the direction of the incoming cosmic muon(s) either
524  // that means: y -> -y
525  //
526  if(!m_swapYZAxis) {
527  // Line below corrupted py sign and forces muons to be upwards, not downwards.
528  // m_fourMom.push_back(CLHEP::HepLorentzVector(px,-py,pz,pp.e()));
529  m_fourMom.push_back(CLHEP::HepLorentzVector(px,py,pz,pp.e()));
530  }
531  else
532  m_fourMom.push_back(CLHEP::HepLorentzVector(px,pz,-py,pp.e()));
533 
535  " (x,y,z,t) = ("
536  << m_fourPos.back().x() << ","
537  << m_fourPos.back().y() << ","
538  << m_fourPos.back().z() << ","
539  << m_fourPos.back().t() << "), (Px,Py,Pz,E) = ("
540  << m_fourMom.back().px() << ","
541  << m_fourMom.back().py() << ","
542  << m_fourMom.back().pz() << ","
543  << m_fourMom.back().e() << ")" );
545  " (theta,phi) = (" << theta << "," << phi << "), "
546  << "polarization(theta,phi) = ("<< m_polarization.back().theta() << ","<< m_polarization.back().phi() << ")" );
547  }
548  return StatusCode::SUCCESS;
549 
550 }

◆ cmTomm()

void GenBase::cmTomm ( HepMC::GenEvent *  evt)
protectedinherited

Scale event lengths by x 10.

Definition at line 78 of file GenBase.cxx.

78  {
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);
85  }
86 }

◆ declareGaudiProperty() [1/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< Algorithm > >::declareGaudiProperty ( Gaudi::Property< T > &  hndl,
const SG::VarHandleKeyArrayType  
)
inlineprivateinherited

specialization for handling Gaudi::Property<SG::VarHandleKeyArray>

Definition at line 170 of file AthCommonDataStore.h.

172  {
173  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
174  hndl.value(),
175  hndl.documentation());
176 
177  }

◆ declareGaudiProperty() [2/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< Algorithm > >::declareGaudiProperty ( Gaudi::Property< T > &  hndl,
const SG::VarHandleKeyType  
)
inlineprivateinherited

specialization for handling Gaudi::Property<SG::VarHandleKey>

Definition at line 156 of file AthCommonDataStore.h.

158  {
159  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
160  hndl.value(),
161  hndl.documentation());
162 
163  }

◆ declareGaudiProperty() [3/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< Algorithm > >::declareGaudiProperty ( Gaudi::Property< T > &  hndl,
const SG::VarHandleType  
)
inlineprivateinherited

specialization for handling Gaudi::Property<SG::VarHandleBase>

Definition at line 184 of file AthCommonDataStore.h.

186  {
187  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
188  hndl.value(),
189  hndl.documentation());
190  }

◆ declareGaudiProperty() [4/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< Algorithm > >::declareGaudiProperty ( Gaudi::Property< T > &  t,
const SG::NotHandleType  
)
inlineprivateinherited

specialization for handling everything that's not a Gaudi::Property<SG::VarHandleKey> or a <SG::VarHandleKeyArray>

Definition at line 199 of file AthCommonDataStore.h.

200  {
201  return PBASE::declareProperty(t);
202  }

◆ declareProperty() [1/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< Algorithm > >::declareProperty ( const std::string &  name,
SG::VarHandleBase hndl,
const std::string &  doc,
const SG::VarHandleType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
hndlObject holding the property value.
docDocumentation 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.

249  {
250  this->declare(hndl.vhKey());
251  hndl.vhKey().setOwner(this);
252 
253  return PBASE::declareProperty(name,hndl,doc);
254  }

◆ declareProperty() [2/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< Algorithm > >::declareProperty ( const std::string &  name,
SG::VarHandleKey hndl,
const std::string &  doc,
const SG::VarHandleKeyType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
hndlObject holding the property value.
docDocumentation 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.

225  {
226  this->declare(hndl);
227  hndl.setOwner(this);
228 
229  return PBASE::declareProperty(name,hndl,doc);
230  }

◆ declareProperty() [3/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< Algorithm > >::declareProperty ( const std::string &  name,
SG::VarHandleKeyArray hndArr,
const std::string &  doc,
const SG::VarHandleKeyArrayType  
)
inlineinherited

Definition at line 259 of file AthCommonDataStore.h.

263  {
264 
265  // std::ostringstream ost;
266  // ost << Algorithm::name() << " VHKA declareProp: " << name
267  // << " size: " << hndArr.keys().size()
268  // << " mode: " << hndArr.mode()
269  // << " vhka size: " << m_vhka.size()
270  // << "\n";
271  // debug() << ost.str() << endmsg;
272 
273  hndArr.setOwner(this);
274  m_vhka.push_back(&hndArr);
275 
276  Gaudi::Details::PropertyBase* p = PBASE::declareProperty(name, hndArr, doc);
277  if (p != 0) {
278  p->declareUpdateHandler(&AthCommonDataStore<PBASE>::updateVHKA, this);
279  } else {
280  ATH_MSG_ERROR("unable to call declareProperty on VarHandleKeyArray "
281  << name);
282  }
283 
284  return p;
285 
286  }

◆ declareProperty() [4/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< Algorithm > >::declareProperty ( const std::string &  name,
T &  property,
const std::string &  doc,
const SG::NotHandleType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
propertyObject holding the property value.
docDocumentation 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.

337  {
338  return PBASE::declareProperty(name, property, doc);
339  }

◆ declareProperty() [5/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< Algorithm > >::declareProperty ( const std::string &  name,
T &  property,
const std::string &  doc = "none" 
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
propertyObject holding the property value.
docDocumentation 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.

355  {
356  typedef typename SG::HandleClassifier<T>::type htype;
357  return declareProperty (name, property, doc, htype());
358  }

◆ declareProperty() [6/6]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< Algorithm > >::declareProperty ( Gaudi::Property< T > &  t)
inlineinherited

Definition at line 145 of file AthCommonDataStore.h.

145  {
146  typedef typename SG::HandleClassifier<T>::type htype;
148  }

◆ detStore()

const ServiceHandle<StoreGateSvc>& AthCommonDataStore< AthCommonMsg< Algorithm > >::detStore ( ) const
inlineinherited

The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 95 of file AthCommonDataStore.h.

95 { return m_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.

83  {
84  if (events_const()->empty())
85  ATH_MSG_ERROR("Const McEventCollection is empty during first event access");
86  return *(events_const()->begin());
87  }

◆ events_const() [1/2]

const McEventCollection* GenBase::events_const ( ) const
inlineinherited

Access the current event's McEventCollection (const)

Definition at line 96 of file GenBase.h.

96  {
97  return events_const( getContext() );
98  }

◆ events_const() [2/2]

const McEventCollection* GenBase::events_const ( const EventContext &  ctx) const
inlineinherited

Definition at line 99 of file GenBase.h.

99  {
101  if (!ret.isValid())
102  ATH_MSG_ERROR("No McEventCollection found in StoreGate with key " << m_mcevents_const.key());
103  return ret.cptr();
104  }

◆ evtStore() [1/2]

ServiceHandle<StoreGateSvc>& AthCommonDataStore< AthCommonMsg< Algorithm > >::evtStore ( )
inlineinherited

The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 85 of file AthCommonDataStore.h.

85 { return m_evtStore; }

◆ evtStore() [2/2]

const ServiceHandle<StoreGateSvc>& AthCommonDataStore< AthCommonMsg< Algorithm > >::evtStore ( ) const
inlineinherited

The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 90 of file AthCommonDataStore.h.

90 { return m_evtStore; }

◆ 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.

70  {
71  // Examples of how to retrieve the random number engine for a given
72  // stream.
73  // NB getRandomEngine should only be called once per event for a
74  // given stream, as it causes the stream to be re-seeded each time
75  // it is called.
76 
77  // Example 1 - seeded based on the current event number (+ slot, run, streamName)
78  //const EventContext& ctx = Gaudi::Hive::currentContext();
79  //CLHEP::HepRandomEngine* rndmEngine = this->getRandomEngine("MyStream", ctx);
80 
81  // Example 2 - seeded based on the m_randomSeed property (+ slot, run, streamName)
82  //const EventContext& ctx = Gaudi::Hive::currentContext();
83  //CLHEP::HepRandomEngine* rndmEngine = this->getRandomEngine("MyStream", m_randomSeed.value(), ctx);
84 
85  // Call the code that generates an event
86  CHECK(this->callGenerator());
87 
88  // Create the MC event and send the GeneratorEvent stored in it to fillEvt
89  HepMC::GenEvent* evt = HepMC::newGenEvent(1,1);
90  CHECK(this->fillEvt(evt));
92 
93  // Add the event to the MC event collection
94  if (events()) {
95  // If this is an "afterburner" generator, replace the last event rather than add a new one
97  if (m_isAfterburner.value() || name() == "Tauola" || name() == "Photos") {
98  events()->pop_back();
99  }
100  // Add the event to the end of the collection
101  events()->push_back(evt);
102  ATH_MSG_DEBUG("MC event added to McEventCollection");
103 
104  // remove the empty event in case of ParticleDecayer
105  if (name() == "ParticleDecayer") {
106  events()->pop_back();
107  }
108  }
109 
110  // Call the incident service to notify that an event has been made
111  m_incidentSvc->fireIncident( Incident(name(), "McEventGenerated") );
112  return StatusCode::SUCCESS;
113 }

◆ extraDeps_update_handler()

void AthCommonDataStore< AthCommonMsg< Algorithm > >::extraDeps_update_handler ( Gaudi::Details::PropertyBase &  ExtraDeps)
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

◆ 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.

51 {
52  // If we didn't find any symlinks to add, just return the collection
53  // from the base class. Otherwise, return the extended collection.
54  if (!m_extendedExtraObjects.empty()) {
56  }
57  return Algorithm::extraOutputDeps();
58 }

◆ exzCut()

bool CosmicGenerator::exzCut ( const CLHEP::Hep3Vector &  pos,
const CLHEP::HepLorentzVector &  p 
)
private

Definition at line 662 of file CosmicGenerator.cxx.

663 {
664 // p is in GeV...
665 
666  double r =0;
667  bool cut = false;
668  if(pos.z()<0){
669  r = std::sqrt((std::pow(pos.x(),2)+std::pow(pos.z()+28000,2))) ; //FIXME Hardcoded values!
670  double e = 0.45238*r+5000 ; //FIXME Hardcoded values!
671  cut = p.e()*m_GeV>e;
672  }
673  else
674  {
675  r = std::sqrt((std::pow(pos.x(),2)+std::pow(pos.z()-20000,2))) ; //FIXME Hardcoded values!
676  if(r<15000) { //FIXME Hardcoded values!
677  cut = true;
678  } else
679  {
680  double e = 0.461538*(r-15000)+10000 ; //FIXME Hardcoded values!
681  cut = p.e()*m_GeV>e;
682  ATH_MSG_VERBOSE("z>0 r , e, p.e = "<<r <<" " <<e <<" " <<p.e()*m_GeV);
683  }
684  }
685 
686  cut = cut && r < m_rmax ;
687 
688  return cut;
689 }

◆ fillEvt()

StatusCode CosmicGenerator::fillEvt ( HepMC::GenEvent *  evt)
virtual

For filling the HepMC event object.

Implements GenModule.

Definition at line 622 of file CosmicGenerator.cxx.

622  {
623 //---------------------------------------------------------------------------
624 
625 
626  // loop over generated vertices
627  if(m_fourMom.size()==m_fourPos.size()&&m_fourMom.size()==m_polarization.size()){
628 
629  for(std::size_t v=0;v<m_fourMom.size();++v){
630 
631  // Note: The vertex and particle are owned by the event, so the
632  // event is responsible for those pointers.
633 
634  // Create the particle, and specify its polarization.
635 
638 
639  // Create the vertex, and add the particle to the vertex.
641  vertex->add_particle_out( particle );
642 
643  // Add the vertex to the event.
644  event->add_vertex( vertex );
645 
646  }
647 
648  event->set_event_number(m_events); // Set the event number
649  if (event->weights().empty()){
650  event->weights().push_back(1.0);
651  }
652  return StatusCode::SUCCESS;
653  } else {
654  ATH_MSG_ERROR("Wrong different number of vertexes/momenta/polaritazions!");
655  return StatusCode::FAILURE;
656  }
657 
658 }

◆ finalize()

StatusCode GenModule::finalize ( )
inlineinherited

Definition at line 55 of file GenModule.h.

55 { return genFinalize(); }

◆ generateVertex()

CLHEP::HepLorentzVector CosmicGenerator::generateVertex ( void  )

Definition at line 132 of file CosmicGenerator.cxx.

132  {
133 
134  // Get the pointer to the engine of the stream named SINGLE. If the
135  // stream does not exist is created automaticaly
136  CLHEP::HepRandomEngine* engine = COSMIC_RANDOM_ENGINE;
137 
138  // Generate a random number according to the distribution.
139 
140  float x_val = CLHEP::RandFlat::shoot(engine, m_xlow, m_xhig);
141  float z_val = CLHEP::RandFlat::shoot(engine, m_zlow, m_zhig);
142 
143  // Generate a random number for time offset
144  float t_val = m_tmin; // Assign defined value
145  if(m_tmin < m_tmax){
146  t_val = CLHEP::RandFlat::shoot(engine, m_tmin, m_tmax);
147  }
148  else if(m_tmin.value() == m_tmax.value()){
149  t_val = m_tmin;
150  }
151  else ATH_MSG_FATAL("You specified m_tmin = " << m_tmin << " and m_tmax " << m_tmax);
152  CLHEP::HepLorentzVector p(x_val,m_yval,z_val, t_val*CLHEP::c_light);
153 
154  return p;
155 
156 }

◆ generateVertexReweighted()

CLHEP::HepLorentzVector CosmicGenerator::generateVertexReweighted ( void  )

Definition at line 158 of file CosmicGenerator.cxx.

158  {
159 
160  // Get the pointer to the engine of the stream named SINGLE. If the
161  // stream does not exist is created automaticaly
162  CLHEP::HepRandomEngine* engine = COSMIC_RANDOM_ENGINE;
163 
164  // Generate non-uniform distribution of vertices to reflect azimuthal
165  // angle subtended by the sphere of radiusm m_radius
166  // Inside m_radius, the density of vertices is proportional to 2 pi r dr
167  // Outside m_radius, the density is proportional to 2r arcsin (m_radius/r)
168  // We approximate the latter by its maximum: m_radius * pi
169  // We generate vertices out to m_rvertmax.
170  // Integrating the approximated distribution gives
171  // pi r**2 for r < m_radius and pi m_radius r for r> m_radius
172  // So with ran in (0,1) we take r=max_r * ran for ran>m_radius/max_r
173  // and r= sqrt(m_radius*max_r*ran) for ran<m_radius/max_r
174  // for r>m_radius we use acceptance/rejection by comparing
175  // m_radius * pi * new_ran with 2r arcsin (m_radius/r)
176  int accept=0;
177  float max_r = m_rvertmax;
178  float r_val = 0.;
179  while(accept==0){
180  float ran_one = CLHEP::RandFlat::shoot(engine,0.,1.);
181  if(ran_one>(m_radius/max_r)){
182  r_val = ran_one*max_r;
183  float ran_two = CLHEP::RandFlat::shoot(engine,0.,1.);
184  if(m_radius*M_PI*ran_two<2*r_val*asin(m_radius/r_val)){
185  accept=1;
186  }
187  }
188  else
189  {
190  r_val = std::sqrt(m_radius*max_r*ran_one);
191  accept=1;
192  }
193  }
194  float ran_three= CLHEP::RandFlat::shoot(engine, 0.,2*M_PI);
195  float x_val = r_val*cos(ran_three);
196  float z_val = r_val*sin(ran_three);
197 
198  // Generate a random number for time offset
199  float t_val = m_tmin; // Assign defined value
200  if(m_tmin < m_tmax){
201  t_val = CLHEP::RandFlat::shoot(engine, m_tmin, m_tmax);
202  }
203  else if(m_tmin.value() == m_tmax.value()){
204  t_val = m_tmin;
205  }
206  else ATH_MSG_FATAL( " You specified m_tmin = " << m_tmin << " and m_tmax " << m_tmax );
207  CLHEP::HepLorentzVector p(x_val,m_yval,z_val, t_val*CLHEP::c_light);
208 
209  return p;
210 }

◆ genFinalize()

StatusCode CosmicGenerator::genFinalize ( )
virtual

For finalising the generator, if required.

Reimplemented from GenModule.

Definition at line 554 of file CosmicGenerator.cxx.

554  {
555 //---------------------------------------------------------------------------
556  // Get the KinematicManager.
557 
558  if(m_cavOpt){
559 
560  ATH_MSG_INFO("********************************************");
561  ATH_MSG_INFO("** you have run CosmicGenerator with some ");
562  ATH_MSG_INFO("** optimizations for cavern simulation");
563  ATH_MSG_INFO("** "<<m_accepted<<" muons were accepted");
564  ATH_MSG_INFO("** "<<m_rejected<<" muons were rejected");
565  ATH_MSG_INFO("********************************************");
566 
567  }
568  if(m_srOneOpt == 1){
569 
570  ATH_MSG_INFO("**********************************************");
571  ATH_MSG_INFO("** you have run CosmicGenerator with some ");
572  ATH_MSG_INFO("** optimizations for SR1 SCT/TRT simulation");
573  ATH_MSG_INFO("** "<<m_accepted<<" muons were accepted");
574  ATH_MSG_INFO("** "<<m_rejected<<" muons were rejected");
575  ATH_MSG_INFO("**********************************************");
576 
577  }
578  if(m_srOneOpt == 2){
579 
580  ATH_MSG_INFO("**********************************************");
581  ATH_MSG_INFO("** you have run CosmicGenerator with some ");
582  ATH_MSG_INFO("** optimizations for SR1 SCT/TRT EndcapC simulation");
583  ATH_MSG_INFO("** "<<m_accepted<<" muons were accepted");
584  ATH_MSG_INFO("** "<<m_rejected<<" muons were rejected");
585  ATH_MSG_INFO("**********************************************");
586 
587  }
588 
589  if(m_srOnePixECOpt){
590 
591  ATH_MSG_INFO("***************************************************");
592  ATH_MSG_INFO("** you have run CosmicGenerator with some ");
593  ATH_MSG_INFO("** optimizations for SR1 Pixel EndCap simulation");
594  ATH_MSG_INFO("** "<<m_accepted<<" muons were accepted");
595  ATH_MSG_INFO("** "<<m_rejected<<" muons were rejected");
596  ATH_MSG_INFO("***************************************************");
597 
598  if(m_swapYZAxis){
599  ATH_MSG_INFO("***************************************************");
600  ATH_MSG_INFO(" You have swapped Y- and Z-axis, i.e. muons are ");
601  ATH_MSG_INFO(" not coming from the top any more !!! ");
602  ATH_MSG_INFO("***************************************************");
603  }
604 
605  }
606 
607  if(m_muonECOpt) {
608 
609  ATH_MSG_INFO("***************************************************");
610  ATH_MSG_INFO("** you have run CosmicGenerator with some " );
611  ATH_MSG_INFO("** filters for cosmic muon simulation" );
612  ATH_MSG_INFO("** "<<m_accepted<<" muons were accepted" );
613  ATH_MSG_INFO("** "<<m_rejected<<" muons were rejected" );
614  ATH_MSG_INFO("***************************************************");
615  }
616 
617  return StatusCode::SUCCESS;
618 }

◆ genInitialize()

StatusCode CosmicGenerator::genInitialize ( )
virtual

For initializing the generator, if required.

Reimplemented from GenModule.

Definition at line 88 of file CosmicGenerator.cxx.

88  {
89 //---------------------------------------------------------------------------
90 
91  // Initialize event count.
92 
93  m_events = 0;
94 
95  m_accepted=0;
96  m_rejected=0;
97 
98  if(m_infile.value()=="NONE") {
101 
103  gun->SetCosCut(m_ctcut);
105  float flux_withCT = gun->InitializeGenerator();
106 
107  ATH_MSG_INFO( "Initialisation cosmic gun done." );
108  ATH_MSG_INFO( "Accepted diff flux after E and cos(theta) cuts = " << flux_withCT << " /cm^2/s" );
109  if (! m_doReweighting) {
110  // The following is only correct w/o reweighting
111  ATH_MSG_INFO( "Accepted total flux after E and cos(theta) cuts = " <<
112  flux_withCT*(m_xhig-m_xlow)/m_mm*(m_zhig-m_zlow)/m_mm << " /s" );
113  }
114 
115  }
116  else {
117  ATH_MSG_INFO( "Cosmics are read from file " << m_infile );
118  m_ffile.open(m_infile.value().c_str());
119  if(!m_ffile) {
120  ATH_MSG_FATAL( "Could not open input file - stop! " );
121  return StatusCode::FAILURE;
122  }
123  m_readfile = true;
124  }
125 
126  m_center=CLHEP::Hep3Vector(m_IPx, m_IPy, m_IPz);
127 
128  return StatusCode::SUCCESS;
129 
130 }

◆ 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

Definition at line 34 of file GenModule.cxx.

36 {
37  ATHRNG::RNGWrapper* rngWrapper = m_rndmSvc->getEngine(this, streamName);
38  std::string rngName = name()+streamName;
39  rngWrapper->setSeed( rngName, ctx );
40  return rngWrapper->getEngine(ctx);
41 }

◆ getRandomEngine() [2/2]

CLHEP::HepRandomEngine * GenModule::getRandomEngine ( const std::string &  streamName,
unsigned long int  randomSeedOffset,
const EventContext &  ctx 
) const
protectedinherited

Definition at line 44 of file GenModule.cxx.

46 {
47  ATHRNG::RNGWrapper* rngWrapper = m_rndmSvc->getEngine(this, streamName);
48  rngWrapper->setSeed( streamName, ctx.slot(), randomSeedOffset, ctx.eventID().run_number() );
49  return rngWrapper->getEngine(ctx);
50 }

◆ 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.

54 {
55  const size_t slot=0;
56  EventContext ctx;
57  ctx.setSlot( slot );
58  ctx.setEventID (EventIDBase (conditionsRun,
59  EventIDBase::UNDEFEVT, // event
60  EventIDBase::UNDEFNUM, // timestamp
61  EventIDBase::UNDEFNUM, // timestamp ns
62  lbn));
64  Atlas::ExtendedEventContext( evtStore()->hiveProxyDict(),
65  conditionsRun) );
66  return getRandomEngine(streamName, randomSeedOffset, ctx);
67 }

◆ 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.

58  {
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());
66  }
67 }

◆ initialize()

StatusCode GenModule::initialize ( )
virtualinherited

Reimplemented from GenBase.

Definition at line 21 of file GenModule.cxx.

21  {
22  // Base class initializations
24  // Get the random number service
25  CHECK(m_rndmSvc.retrieve());
26  // Get the incident service
27  CHECK(m_incidentSvc.retrieve());
30  return StatusCode::SUCCESS;
31 }

◆ inputHandles()

virtual std::vector<Gaudi::DataHandle*> AthCommonDataStore< AthCommonMsg< Algorithm > >::inputHandles ( ) const
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.

◆ MeVToGeV()

void GenBase::MeVToGeV ( HepMC::GenEvent *  evt)
protectedinherited

Scale event energies/momenta by x 1/1000.

Definition at line 68 of file GenBase.cxx.

68  {
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);
76  }
77 }

◆ mmTocm()

void GenBase::mmTocm ( HepMC::GenEvent *  evt)
protectedinherited

Scale event lengths by x 1/10.

Definition at line 87 of file GenBase.cxx.

87  {
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);
94  }
95 }

◆ msg() [1/2]

MsgStream& AthCommonMsg< Algorithm >::msg ( ) const
inlineinherited

Definition at line 24 of file AthCommonMsg.h.

24  {
25  return this->msgStream();
26  }

◆ msg() [2/2]

MsgStream& AthCommonMsg< Algorithm >::msg ( const MSG::Level  lvl) const
inlineinherited

Definition at line 27 of file AthCommonMsg.h.

27  {
28  return this->msgStream(lvl);
29  }

◆ msgLvl()

bool AthCommonMsg< Algorithm >::msgLvl ( const MSG::Level  lvl) const
inlineinherited

Definition at line 30 of file AthCommonMsg.h.

30  {
31  return this->msgLevel(lvl);
32  }

◆ outputHandles()

virtual std::vector<Gaudi::DataHandle*> AthCommonDataStore< AthCommonMsg< Algorithm > >::outputHandles ( ) const
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.

◆ 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.

126  {
127  return pdt().particle(HepPDT::ParticleID(std::abs(pid)));
128  }

◆ particleTable()

const HepPDT::ParticleDataTable& GenBase::particleTable ( ) const
inlineinherited

Get a particle data table.

Definition at line 118 of file GenBase.h.

118  {
119  return *(m_ppSvc->PDT());
120  }

◆ partPropSvc()

const ServiceHandle<IPartPropSvc> GenBase::partPropSvc ( ) const
inlineinherited

Access the particle property service.

Definition at line 113 of file GenBase.h.

113  {
114  return m_ppSvc;
115  }

◆ pathLengthInRock()

double CosmicGenerator::pathLengthInRock ( double  xgen,
double  ygen,
double  zgen,
double  theta,
double  phi 
)
private

Definition at line 694 of file CosmicGenerator.cxx.

694  {
695  // y is vertical direction, z along beam, major shaft has z>0
696 
697  // Definition of shafts and cavern
698  double p14_x = 1700; //FIXME Hardcoded values!
699  double p14_z = 13500; //FIXME Hardcoded values!
700  double p14_radius = 9000.; //FIXME Hardcoded values!
701  double p16_x = 1700; //FIXME Hardcoded values!
702  double p16_z = -20000; //FIXME Hardcoded values!
703  double p16_radius = 6300.; //FIXME Hardcoded values!
704  double y1 = 26400; // ! mm cavern height above IP //FIXME Hardcoded values!
705 
706  // direction of trajectory
707  // x=x0 - t sinth cosphi; y=y0 + t costh; z=z0 - t sinth sinphi
708  double cosphi = std::cos(phi);
709  double sinphi = std::sin(phi);
710  double costh = std::cos(theta);
711  double sinth = std::sin(theta);
712 
713  double y0 = m_ysurface;
714  double t = (ygen-y0)/costh;
715  double x0 = xgen + t*sinth*cosphi; // x position at y=0
716  double z0 = zgen + t*sinth*sinphi; // z position at y=0
717 
718  // full path length ignoring shaft
719  double full_distance = (y0-y1)/costh;
720 
721  // does trajectory intersect p14 cylinder?
722  double z_mid14 = (x0-p14_x)*sinphi-(z0-p14_z)*cosphi;
723  double min_dist14 = std::abs(z_mid14); //minimum distance of line from center
724  double shaft_distance14 = 0.;
725  if (min_dist14<p14_radius) {
726 
727  // z values at intersections
728  double z_plus14 = -cosphi*z_mid14+sinphi*std::sqrt(std::pow(p14_radius,2.)-std::pow(z_mid14,2.)) + p14_z;
729  double z_minus14 = -cosphi*z_mid14-sinphi*std::sqrt(std::pow(p14_radius,2.)-std::pow(z_mid14,2.)) + p14_z;
730 
731  // y values at intersections
732  double y_plus14 = y0-costh*(z_plus14-z0)/sinth/sinphi;
733  double y_minus14 = y0-costh*(z_minus14-z0)/sinth/sinphi;
734  double y_great14 = y_plus14>y_minus14 ? y_plus14 : y_minus14;
735  double y_less14 = y_plus14>y_minus14 ? y_minus14 : y_plus14;
736 
737  // top intersection must occur above bottom of shaft
738  if ( (y_great14>y1) && (y_less14<y0) ) {
739  double y_top14 = y_great14<y0 ? y_great14 : y0;
740  double y_bottom14 = y_less14>y1 ? y_less14 : y1;
741  shaft_distance14 = (y_top14-y_bottom14)/costh;
742  }
743  }
744 
745  // does trajectory intersect p16 cylinder?
746  double z_mid16 = (x0-p16_x)*sinphi-(z0-p16_z)*cosphi;
747  double min_dist16 = std::abs(z_mid16);
748  double shaft_distance16 = 0.;
749  if (min_dist16<p16_radius) {
750 
751  // z values at intersections
752  double z_plus16 = -cosphi*z_mid16+sinphi*std::sqrt(std::pow(p16_radius,2.)-std::pow(z_mid16,2.)) + p16_z;
753  double z_minus16 = -cosphi*z_mid16-sinphi*std::sqrt(std::pow(p16_radius,2.)-std::pow(z_mid16,2.)) + p16_z;
754 
755  // determine y values at intersections
756  double y_plus16 = y0-costh*(z_plus16-z0)/sinth/sinphi;
757  double y_minus16 = y0-costh*(z_minus16-z0)/sinth/sinphi;
758  double y_great16 = y_plus16>y_minus16 ? y_plus16 : y_minus16;
759  double y_less16 = y_plus16>y_minus16 ? y_minus16 : y_plus16;
760 
761  // top intersection must occur above bottom of shaft
762  if ( (y_great16>y1) && (y_less16<y0) ) {
763  double y_top16 = y_great16<y0 ? y_great16 : y0;
764  double y_bottom16 = y_less16>y1 ? y_less16 : y1;
765  shaft_distance16 = (y_top16-y_bottom16)/costh;
766  }
767  }
768 
769  double rock_distance = full_distance - shaft_distance14-shaft_distance16;
770  return rock_distance;
771 }

◆ pdt()

const HepPDT::ParticleDataTable& GenBase::pdt ( ) const
inlineinherited

Shorter alias to get a particle data table.

Definition at line 123 of file GenBase.h.

123 { return particleTable(); }

◆ pointsAtPixels()

bool CosmicGenerator::pointsAtPixels ( double  xgen,
double  ygen,
double  zgen,
double  theta,
double  phi 
)
private

Definition at line 775 of file CosmicGenerator.cxx.

775  {
776  // y is vertical direction, z along beam, major shaft has z<0
777  bool does = false;
778 
779  // direction of trajectory
780  // x=xgen+ t sinth cosphi; y=ygen+t costh; z=zgen+t sinth sinphi
781  double cosphi = std::cos(phi);
782  double sinphi = std::sin(phi);
783  double costh = std::cos(theta);
784  double sinth = std::sin(theta);
785  double t = ygen/costh; //for parameterized trajectory
786  double x_pos = xgen + t*sinth*cosphi; //x position at y=0
787  double z_pos = zgen + t*sinth*sinphi; //z position at y=0
788 
789  ATH_MSG_VERBOSE("x_pos = " << x_pos << ", z_pos = " << z_pos);
790 
791  if((std::abs(x_pos)<m_pixelplanemaxx)&&(std::abs(z_pos)<m_pixelplanemaxz)){
792  does=true;
793  }
794 
795  return does;
796 }

◆ renounce()

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> AthCommonDataStore< AthCommonMsg< Algorithm > >::renounce ( T &  h)
inlineprotectedinherited

Definition at line 380 of file AthCommonDataStore.h.

381  {
382  h.renounce();
383  PBASE::renounce (h);
384  }

◆ renounceArray()

void AthCommonDataStore< AthCommonMsg< Algorithm > >::renounceArray ( SG::VarHandleKeyArray handlesArray)
inlineprotectedinherited

remove all handles from I/O resolution

Definition at line 364 of file AthCommonDataStore.h.

364  {
365  handlesArray.renounce();
366  }

◆ sysInitialize()

StatusCode AthAlgorithm::sysInitialize ( )
overridevirtualinherited

Override sysInitialize.

Override sysInitialize from the base class.

Loop through all output handles, and if they're WriteCondHandles, automatically register them and this Algorithm with the CondSvc

Scan through all outputHandles, and if they're WriteCondHandles, register them with the CondSvc

Reimplemented from AthCommonDataStore< AthCommonMsg< Algorithm > >.

Reimplemented in AthAnalysisAlgorithm, AthFilterAlgorithm, PyAthena::Alg, and AthHistogramAlgorithm.

Definition at line 66 of file AthAlgorithm.cxx.

66  {
68 
69  if (sc.isFailure()) {
70  return sc;
71  }
72  ServiceHandle<ICondSvc> cs("CondSvc",name());
73  for (auto h : outputHandles()) {
74  if (h->isCondition() && h->mode() == Gaudi::DataHandle::Writer) {
75  // do this inside the loop so we don't create the CondSvc until needed
76  if ( cs.retrieve().isFailure() ) {
77  ATH_MSG_WARNING("no CondSvc found: won't autoreg WriteCondHandles");
78  return StatusCode::SUCCESS;
79  }
80  if (cs->regHandle(this,*h).isFailure()) {
81  sc = StatusCode::FAILURE;
82  ATH_MSG_ERROR("unable to register WriteCondHandle " << h->fullKey()
83  << " with CondSvc");
84  }
85  }
86  }
87  return sc;
88 }

◆ sysStart()

virtual StatusCode AthCommonDataStore< AthCommonMsg< Algorithm > >::sysStart ( )
overridevirtualinherited

Handle START transition.

We override this in order to make sure that conditions handle keys can cache a pointer to the conditions container.

◆ updateVHKA()

void AthCommonDataStore< AthCommonMsg< Algorithm > >::updateVHKA ( Gaudi::Details::PropertyBase &  )
inlineinherited

Definition at line 308 of file AthCommonDataStore.h.

308  {
309  // debug() << "updateVHKA for property " << p.name() << " " << p.toString()
310  // << " size: " << m_vhka.size() << endmsg;
311  for (auto &a : m_vhka) {
312  std::vector<SG::VarHandleKey*> keys = a->keys();
313  for (auto k : keys) {
314  k->setOwner(this);
315  }
316  }
317  }

Member Data Documentation

◆ COSMIC_RANDOM_ENGINE

CLHEP::HepRandomEngine * CosmicGenerator::COSMIC_RANDOM_ENGINE {}
static

Static pointer to random number generator for use by.

Definition at line 89 of file CosmicGenerator.h.

◆ m_accepted

int CosmicGenerator::m_accepted {0}
private

Definition at line 103 of file CosmicGenerator.h.

◆ m_cavOpt

BooleanProperty CosmicGenerator::m_cavOpt {this, "OptimizeForCavern", false}
private

Definition at line 122 of file CosmicGenerator.h.

◆ m_center

CLHEP::Hep3Vector CosmicGenerator::m_center
private

Definition at line 142 of file CosmicGenerator.h.

◆ m_ctcut

FloatProperty CosmicGenerator::m_ctcut {this, "ctcut", 0.35}
private

Definition at line 109 of file CosmicGenerator.h.

◆ m_detStore

StoreGateSvc_t AthCommonDataStore< AthCommonMsg< Algorithm > >::m_detStore
privateinherited

Pointer to StoreGate (detector store by default)

Definition at line 393 of file AthCommonDataStore.h.

◆ m_doAimedAtPixelsCut

BooleanProperty CosmicGenerator::m_doAimedAtPixelsCut {this, "doAimedAtPixelsCut", false}
private

Definition at line 160 of file CosmicGenerator.h.

◆ m_doPathlengthCut

BooleanProperty CosmicGenerator::m_doPathlengthCut {this, "doPathLengthCut", false}
private

Definition at line 159 of file CosmicGenerator.h.

◆ m_doReweighting

BooleanProperty CosmicGenerator::m_doReweighting {this, "doReweighting", false}
private

Definition at line 161 of file CosmicGenerator.h.

◆ m_dsid

IntegerProperty CosmicGenerator::m_dsid {this, "Dsid", 999999, "Dataset ID number"}
private

Definition at line 106 of file CosmicGenerator.h.

◆ m_emax

FloatProperty CosmicGenerator::m_emax {this, "emax", 100.*m_GeV}
private

Definition at line 108 of file CosmicGenerator.h.

◆ m_emin

FloatProperty CosmicGenerator::m_emin {this, "emin", 10.*m_GeV}
private

Definition at line 107 of file CosmicGenerator.h.

◆ m_energyCutThreshold

DoubleProperty CosmicGenerator::m_energyCutThreshold {this, "energyCutThreshold", 1.0}
private

Definition at line 162 of file CosmicGenerator.h.

◆ m_events

int CosmicGenerator::m_events {0}
private

Definition at line 101 of file CosmicGenerator.h.

◆ m_evtStore

StoreGateSvc_t AthCommonDataStore< AthCommonMsg< Algorithm > >::m_evtStore
privateinherited

Pointer to StoreGate (event store by default)

Definition at line 390 of file AthCommonDataStore.h.

◆ m_extendedExtraObjects

DataObjIDColl AthAlgorithm::m_extendedExtraObjects
privateinherited

Definition at line 79 of file AthAlgorithm.h.

◆ m_exzCut

BooleanProperty CosmicGenerator::m_exzCut {this, "ExzCut", false}
private

Definition at line 149 of file CosmicGenerator.h.

◆ m_ffile

std::ifstream CosmicGenerator::m_ffile
private

Definition at line 137 of file CosmicGenerator.h.

◆ m_fourMom

std::vector<CLHEP::HepLorentzVector> CosmicGenerator::m_fourMom
private

Definition at line 141 of file CosmicGenerator.h.

◆ m_fourPos

std::vector<CLHEP::HepLorentzVector> CosmicGenerator::m_fourPos
private

Definition at line 140 of file CosmicGenerator.h.

◆ m_GeV

constexpr float CosmicGenerator::m_GeV = 1000.f
staticconstexprprivate

Definition at line 97 of file CosmicGenerator.h.

◆ 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_infile

StringProperty CosmicGenerator::m_infile {this, "eventfile", "NONE"}
private

Definition at line 136 of file CosmicGenerator.h.

◆ m_IPx

FloatProperty CosmicGenerator::m_IPx {this, "IPx", 0.f}
private

Definition at line 115 of file CosmicGenerator.h.

◆ m_IPy

FloatProperty CosmicGenerator::m_IPy {this, "IPy", 0.f}
private

Definition at line 116 of file CosmicGenerator.h.

◆ m_IPz

FloatProperty CosmicGenerator::m_IPz {this, "IPz", 0.f}
private

Definition at line 117 of file CosmicGenerator.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

SG::ReadHandleKey<McEventCollection> GenBase::m_mcevents_const { this, "McEventKey", "GEN_EVENT", "StoreGate key of the MC event collection" }
privateinherited

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_mm

constexpr float CosmicGenerator::m_mm = 10.f
staticconstexprprivate

Definition at line 98 of file CosmicGenerator.h.

◆ m_muonECOpt

BooleanProperty CosmicGenerator::m_muonECOpt {this, "OptimizeForMuonEndCap", false}
private

Definition at line 126 of file CosmicGenerator.h.

◆ m_pdgCode

std::vector<int> CosmicGenerator::m_pdgCode
private

Definition at line 104 of file CosmicGenerator.h.

◆ m_phimax

FloatProperty CosmicGenerator::m_phimax {this, "PhiMax", M_PI}
private

Definition at line 133 of file CosmicGenerator.h.

◆ m_phimin

FloatProperty CosmicGenerator::m_phimin {this, "PhiMin", -1.*M_PI}
private

Definition at line 132 of file CosmicGenerator.h.

◆ m_pixelplanemaxx

DoubleProperty CosmicGenerator::m_pixelplanemaxx {this, "pixelplane_maxx", 1150.}
private

Definition at line 165 of file CosmicGenerator.h.

◆ m_pixelplanemaxz

DoubleProperty CosmicGenerator::m_pixelplanemaxz {this, "pixelplane_maxz", 1650.}
private

Definition at line 166 of file CosmicGenerator.h.

◆ m_polarization

std::vector<HepMC::Polarization> CosmicGenerator::m_polarization
private

Definition at line 143 of file CosmicGenerator.h.

◆ 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_printEvent

IntegerProperty CosmicGenerator::m_printEvent {this, "PrintEvent", 10}
private

Definition at line 127 of file CosmicGenerator.h.

◆ m_printMod

IntegerProperty CosmicGenerator::m_printMod {this, "PrintMod", 100}
private

Definition at line 128 of file CosmicGenerator.h.

◆ m_radius

FloatProperty CosmicGenerator::m_radius {this, "Radius", 0.f}
private

Definition at line 118 of file CosmicGenerator.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_readfile

bool CosmicGenerator::m_readfile {false}
private

Definition at line 135 of file CosmicGenerator.h.

◆ m_rejected

int CosmicGenerator::m_rejected {0}
private

Definition at line 102 of file CosmicGenerator.h.

◆ m_rmax

FloatProperty CosmicGenerator::m_rmax {this, "RMax", 10000000.f}
private

Definition at line 151 of file CosmicGenerator.h.

◆ m_rndmSvc

ServiceHandle<IAthRNGSvc> GenModule::m_rndmSvc {this, "RndmSvc", "AthRNGSvc"}
privateinherited

Data members.

Definition at line 99 of file GenModule.h.

◆ m_rvertmax

DoubleProperty CosmicGenerator::m_rvertmax {this, "rvert_max", 300.*m_mm}
private

Definition at line 164 of file CosmicGenerator.h.

◆ m_srOneOpt

IntegerProperty CosmicGenerator::m_srOneOpt {this, "OptimizeForSR1", 0}
private

Definition at line 123 of file CosmicGenerator.h.

◆ m_srOnePixECOpt

BooleanProperty CosmicGenerator::m_srOnePixECOpt {this, "OptimizeForSR1PixelEndCap", false}
private

Definition at line 124 of file CosmicGenerator.h.

◆ m_swapYZAxis

BooleanProperty CosmicGenerator::m_swapYZAxis {this, "SwapYZAxis", false}
private

Definition at line 125 of file CosmicGenerator.h.

◆ m_thetamax

FloatProperty CosmicGenerator::m_thetamax {this, "ThetaMax", 1.f}
private

Definition at line 131 of file CosmicGenerator.h.

◆ m_thetamin

FloatProperty CosmicGenerator::m_thetamin {this, "ThetaMin", 0.f}
private

Definition at line 130 of file CosmicGenerator.h.

◆ m_tmax

FloatProperty CosmicGenerator::m_tmax {this, "tmax", 0.f}
private

Definition at line 121 of file CosmicGenerator.h.

◆ m_tmin

FloatProperty CosmicGenerator::m_tmin {this, "tmin", 0.f}
private

Definition at line 120 of file CosmicGenerator.h.

◆ m_varHandleArraysDeclared

bool AthCommonDataStore< AthCommonMsg< Algorithm > >::m_varHandleArraysDeclared
privateinherited

Definition at line 399 of file AthCommonDataStore.h.

◆ m_vhka

std::vector<SG::VarHandleKeyArray*> AthCommonDataStore< AthCommonMsg< Algorithm > >::m_vhka
privateinherited

Definition at line 398 of file AthCommonDataStore.h.

◆ m_xhig

FloatProperty CosmicGenerator::m_xhig {this, "xvert_hig", 10.*m_mm}
private

Definition at line 111 of file CosmicGenerator.h.

◆ m_xlow

FloatProperty CosmicGenerator::m_xlow {this, "xvert_low", 0.*m_mm}
private

Definition at line 110 of file CosmicGenerator.h.

◆ m_ysurface

DoubleProperty CosmicGenerator::m_ysurface {this, "ysurface", 81.*m_mm}
private

Definition at line 163 of file CosmicGenerator.h.

◆ m_yval

FloatProperty CosmicGenerator::m_yval {this, "yvert_val", 81.*m_mm}
private

Definition at line 114 of file CosmicGenerator.h.

◆ m_zhig

FloatProperty CosmicGenerator::m_zhig {this, "zvert_hig", 10.*m_mm}
private

Definition at line 113 of file CosmicGenerator.h.

◆ m_zlow

FloatProperty CosmicGenerator::m_zlow {this, "zvert_low", 0.*m_mm}
private

Definition at line 112 of file CosmicGenerator.h.

◆ m_zpos

FloatProperty CosmicGenerator::m_zpos {this, "Zposition", 14500.f}
private

Definition at line 119 of file CosmicGenerator.h.


The documentation for this class was generated from the following files:
HepMC::GenVertexPtr
HepMC::GenVertex * GenVertexPtr
Definition: GenVertex.h:59
AllowedVariables::e
e
Definition: AsgElectronSelectorTool.cxx:37
ATHRNG::RNGWrapper::setSeed
void setSeed(const std::string &algName, const EventContext &ctx)
Set the random seed using a string (e.g.
Definition: RNGWrapper.h:169
beamspotman.r
def r
Definition: beamspotman.py:676
CosmicGenerator::m_zlow
FloatProperty m_zlow
Definition: CosmicGenerator.h:112
CosmicGun
Definition: CosmicGun.h:10
ATH_MSG_FATAL
#define ATH_MSG_FATAL(x)
Definition: AthMsgStreamMacros.h:34
CosmicGenerator::m_events
int m_events
Definition: CosmicGenerator.h:101
Trk::ParticleSwitcher::particle
constexpr ParticleHypothesis particle[PARTICLEHYPOTHESES]
the array of masses
Definition: ParticleHypothesis.h:76
CosmicGenerator::m_tmin
FloatProperty m_tmin
Definition: CosmicGenerator.h:120
test_pyathena.px
px
Definition: test_pyathena.py:18
athena.path
path
python interpreter configuration --------------------------------------—
Definition: athena.py:128
CosmicGenerator::m_xlow
FloatProperty m_xlow
Definition: CosmicGenerator.h:110
phi
Scalar phi() const
phi method
Definition: AmgMatrixBasePlugin.h:67
ATH_MSG_INFO
#define ATH_MSG_INFO(x)
Definition: AthMsgStreamMacros.h:31
SG::ReadHandle::cptr
const_pointer_type cptr()
Dereference the pointer.
Base_Fragment.mass
mass
Definition: Sherpa_i/share/common/Base_Fragment.py:59
CosmicGun::SetCosCut
void SetCosCut(float ctcut)
Definition: CosmicGun.cxx:157
GenModule::fillEvt
virtual StatusCode fillEvt(HepMC::GenEvent *evt)=0
For filling the HepMC event object.
CosmicGenerator::m_accepted
int m_accepted
Definition: CosmicGenerator.h:103
GenModule::callGenerator
virtual StatusCode callGenerator()
For calling the generator on each iteration of the event loop.
Definition: GenModule.h:66
GenBase::events_const
const McEventCollection * events_const() const
Access the current event's McEventCollection (const)
Definition: GenBase.h:96
SG::ReadHandle< McEventCollection >
AthCommonDataStore::declareProperty
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T > &t)
Definition: AthCommonDataStore.h:145
CosmicGenerator::m_pixelplanemaxx
DoubleProperty m_pixelplanemaxx
Definition: CosmicGenerator.h:165
CosmicGenerator::m_doPathlengthCut
BooleanProperty m_doPathlengthCut
Definition: CosmicGenerator.h:159
CosmicGenerator::m_pdgCode
std::vector< int > m_pdgCode
Definition: CosmicGenerator.h:104
CosmicGenerator::m_ysurface
DoubleProperty m_ysurface
Definition: CosmicGenerator.h:163
CutsMETMaker::accept
StatusCode accept(const xAOD::Muon *mu)
Definition: CutsMETMaker.cxx:18
theta
Scalar theta() const
theta method
Definition: AmgMatrixBasePlugin.h:75
HepMC::GenParticlePtr
GenParticle * GenParticlePtr
Definition: GenParticle.h:37
GenModule::m_incidentSvc
ServiceHandle< IIncidentSvc > m_incidentSvc
Handle on the incident service.
Definition: GenModule.h:101
M_PI
#define M_PI
Definition: ActiveFraction.h:11
HepMC::set_polarization
void set_polarization(T &a, const Polarization &b)
Definition: Polarization.h:44
AthCommonDataStore< AthCommonMsg< Algorithm > >::m_evtStore
StoreGateSvc_t m_evtStore
Pointer to StoreGate (event store by default)
Definition: AthCommonDataStore.h:390
AthCommonDataStore< AthCommonMsg< Algorithm > >::m_vhka
std::vector< SG::VarHandleKeyArray * > m_vhka
Definition: AthCommonDataStore.h:398
CosmicGenerator::COSMIC_RANDOM_ENGINE
static CLHEP::HepRandomEngine * COSMIC_RANDOM_ENGINE
Static pointer to random number generator for use by.
Definition: CosmicGenerator.h:89
HepMC::newGenEvent
GenEvent * newGenEvent(const int a, const int b)
Definition: GenEvent.h:624
CosmicGenerator::m_srOnePixECOpt
BooleanProperty m_srOnePixECOpt
Definition: CosmicGenerator.h:124
LArG4FSStartPointFilter.evt
evt
Definition: LArG4FSStartPointFilter.py:42
CosmicGenerator::m_dsid
IntegerProperty m_dsid
Definition: CosmicGenerator.h:106
read_hist_ntuple.t
t
Definition: read_hist_ntuple.py:5
drawFromPickle.cos
cos
Definition: drawFromPickle.py:36
ATH_MSG_VERBOSE
#define ATH_MSG_VERBOSE(x)
Definition: AthMsgStreamMacros.h:28
SG::VarHandleKey::key
const std::string & key() const
Return the StoreGate ID for the referenced object.
Definition: AthToolSupport/AsgDataHandles/Root/VarHandleKey.cxx:141
CosmicGenerator::m_ctcut
FloatProperty m_ctcut
Definition: CosmicGenerator.h:109
x
#define x
CosmicGenerator::pointsAtPixels
bool pointsAtPixels(double xgen, double ygen, double zgen, double theta, double phi)
Definition: CosmicGenerator.cxx:775
HepMC::fillBarcodesAttribute
void fillBarcodesAttribute(GenEvent *)
Definition: GenEvent.h:626
empty
bool empty(TH1 *h)
Definition: computils.cxx:295
python.DataFormatRates.events
events
Definition: DataFormatRates.py:105
CosmicGenerator::m_fourMom
std::vector< CLHEP::HepLorentzVector > m_fourMom
Definition: CosmicGenerator.h:141
CosmicGenerator::m_rejected
int m_rejected
Definition: CosmicGenerator.h:102
GenModule::getRandomEngine
CLHEP::HepRandomEngine * getRandomEngine(const std::string &streamName, const EventContext &ctx) const
Definition: GenModule.cxx:34
makeTRTBarrelCans.y1
tuple y1
Definition: makeTRTBarrelCans.py:15
AthenaPoolTestRead.sc
sc
Definition: AthenaPoolTestRead.py:27
CosmicGenerator::m_xhig
FloatProperty m_xhig
Definition: CosmicGenerator.h:111
SG::VarHandleKeyArray::setOwner
virtual void setOwner(IDataHandleHolder *o)=0
CosmicGun::GenerateEvent
CLHEP::HepLorentzVector GenerateEvent(void)
Definition: CosmicGun.cxx:113
IDTPMcnv.htype
htype
Definition: IDTPMcnv.py:29
CosmicGenerator::m_pixelplanemaxz
DoubleProperty m_pixelplanemaxz
Definition: CosmicGenerator.h:166
SG::makeHandle
SG::ReadCondHandle< T > makeHandle(const SG::ReadCondHandleKey< T > &key, const EventContext &ctx=Gaudi::Hive::currentContext())
Definition: ReadCondHandle.h:270
CosmicGenerator::m_printEvent
IntegerProperty m_printEvent
Definition: CosmicGenerator.h:127
GenModule::genuserInitialize
virtual StatusCode genuserInitialize()
For initialization of user code, if required. Called after genInitialize.
Definition: GenModule.h:64
GenModule::m_rndmSvc
ServiceHandle< IAthRNGSvc > m_rndmSvc
Data members.
Definition: GenModule.h:99
GenBase::m_ppSvc
ServiceHandle< IPartPropSvc > m_ppSvc
Handle on the particle property service.
Definition: GenBase.h:160
AthCommonDataStore< AthCommonMsg< Algorithm > >::evtStore
ServiceHandle< StoreGateSvc > & evtStore()
The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.
Definition: AthCommonDataStore.h:85
TRTCalib_cfilter.p2
p2
Definition: TRTCalib_cfilter.py:131
CosmicGenerator::m_fourPos
std::vector< CLHEP::HepLorentzVector > m_fourPos
Definition: CosmicGenerator.h:140
GenModule::genInitialize
virtual StatusCode genInitialize()
For initializing the generator, if required.
Definition: GenModule.h:62
CosmicGenerator::m_phimin
FloatProperty m_phimin
Definition: CosmicGenerator.h:132
CosmicGenerator::m_swapYZAxis
BooleanProperty m_swapYZAxis
Definition: CosmicGenerator.h:125
python.utils.AtlRunQueryDQUtils.p
p
Definition: AtlRunQueryDQUtils.py:210
AthCommonDataStore
Definition: AthCommonDataStore.h:52
AthAlgorithm::sysInitialize
virtual StatusCode sysInitialize() override
Override sysInitialize.
Definition: AthAlgorithm.cxx:66
ATH_MSG_ERROR
#define ATH_MSG_ERROR(x)
Definition: AthMsgStreamMacros.h:33
CosmicGenerator::m_readfile
bool m_readfile
Definition: CosmicGenerator.h:135
event
POOL::TEvent event(POOL::TEvent::kClassAccess)
AthCommonDataStore< AthCommonMsg< Algorithm > >::outputHandles
virtual std::vector< Gaudi::DataHandle * > outputHandles() const override
Return this algorithm's output handles.
HepMC::newGenVertexPtr
GenVertexPtr newGenVertexPtr(const HepMC::FourVector &pos=HepMC::FourVector(0.0, 0.0, 0.0, 0.0), const int i=0)
Definition: GenVertex.h:64
z
#define z
CosmicGenerator::m_doAimedAtPixelsCut
BooleanProperty m_doAimedAtPixelsCut
Definition: CosmicGenerator.h:160
CosmicGenerator::m_energyCutThreshold
DoubleProperty m_energyCutThreshold
Definition: CosmicGenerator.h:162
Atlas::ExtendedEventContext
Definition: ExtendedEventContext.h:23
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
GenBase::m_mcevents_const
SG::ReadHandleKey< McEventCollection > m_mcevents_const
Const handle to the MC event collection.
Definition: GenBase.h:163
GenModule::m_isAfterburner
BooleanProperty m_isAfterburner
Flag for normal vs. afterburner generators.
Definition: GenModule.h:87
CosmicGenerator::m_cavOpt
BooleanProperty m_cavOpt
Definition: CosmicGenerator.h:122
CosmicGun::GetCosmicGun
static CosmicGun * GetCosmicGun(void)
Definition: CosmicGun.cxx:53
BindingsTest.cut
cut
This script demonstrates how to call a C++ class from Python Also how to use PyROOT is shown.
Definition: BindingsTest.py:13
ParticleGun_EoverP_Config.pid
pid
Definition: ParticleGun_EoverP_Config.py:62
Amg::pz
@ pz
Definition: GeoPrimitives.h:40
jobOptions.ParticleID
ParticleID
Definition: jobOptions.decayer.py:85
CosmicGun::GetMuonCharge
int GetMuonCharge(void)
Definition: CosmicGun.cxx:137
GenModule::genFinalize
virtual StatusCode genFinalize()
For finalising the generator, if required.
Definition: GenModule.h:70
CHECK
#define CHECK(...)
Evaluate an expression and check for errors.
Definition: Control/AthenaKernel/AthenaKernel/errorcheck.h:422
CosmicGenerator::m_center
CLHEP::Hep3Vector m_center
Definition: CosmicGenerator.h:142
CosmicGenerator::m_doReweighting
BooleanProperty m_doReweighting
Definition: CosmicGenerator.h:161
CosmicGenerator::m_phimax
FloatProperty m_phimax
Definition: CosmicGenerator.h:133
CosmicGenerator::m_zpos
FloatProperty m_zpos
Definition: CosmicGenerator.h:119
AthCommonDataStore< AthCommonMsg< Algorithm > >::m_detStore
StoreGateSvc_t m_detStore
Pointer to StoreGate (detector store by default)
Definition: AthCommonDataStore.h:393
TRT::Track::z0
@ z0
Definition: InnerDetector/InDetCalibEvent/TRT_CalibData/TRT_CalibData/TrackInfo.h:63
CosmicGenerator::generateVertex
CLHEP::HepLorentzVector generateVertex(void)
Definition: CosmicGenerator.cxx:132
MuonR4::SegmentFit::ParamDefs::x0
@ x0
CosmicGenerator::m_srOneOpt
IntegerProperty m_srOneOpt
Definition: CosmicGenerator.h:123
calibdata.exit
exit
Definition: calibdata.py:236
CosmicGenerator::m_IPy
FloatProperty m_IPy
Definition: CosmicGenerator.h:116
SG::ReadHandle::isValid
virtual bool isValid() override final
Can the handle be successfully dereferenced?
CosmicGun::InitializeGenerator
float InitializeGenerator()
Definition: CosmicGun.cxx:85
SG::VarHandleKeyArray::renounce
virtual void renounce()=0
GenBase::particleTable
const HepPDT::ParticleDataTable & particleTable() const
Get a particle data table.
Definition: GenBase.h:118
SG::HandleClassifier::type
std::conditional< std::is_base_of< SG::VarHandleKeyArray, T >::value, VarHandleKeyArrayType, type2 >::type type
Definition: HandleClassifier.h:54
CosmicGenerator::m_polarization
std::vector< HepMC::Polarization > m_polarization
Definition: CosmicGenerator.h:143
MuonR4::SegmentFit::ParamDefs::y0
@ y0
GenModule::GenModule
GenModule(const std::string &name, ISvcLocator *pSvcLocator)
Constructor.
Definition: GenModule.cxx:14
Amg::py
@ py
Definition: GeoPrimitives.h:39
CosmicGenerator::m_ffile
std::ifstream m_ffile
Definition: CosmicGenerator.h:137
merge_scale_histograms.doc
string doc
Definition: merge_scale_histograms.py:9
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:228
ATHRNG::RNGWrapper
A wrapper class for event-slot-local random engines.
Definition: RNGWrapper.h:56
CosmicGenerator::m_rmax
FloatProperty m_rmax
Definition: CosmicGenerator.h:151
charge
double charge(const T &p)
Definition: AtlasPID.h:756
CosmicGenerator::generateVertexReweighted
CLHEP::HepLorentzVector generateVertexReweighted(void)
Definition: CosmicGenerator.cxx:158
python.PhysicalConstants.c_light
float c_light
Definition: PhysicalConstants.py:63
CosmicGenerator::m_IPz
FloatProperty m_IPz
Definition: CosmicGenerator.h:117
CosmicGenerator::m_zhig
FloatProperty m_zhig
Definition: CosmicGenerator.h:113
CosmicGun::PrintLevel
void PrintLevel(int printevt, int printmod)
Definition: CosmicGun.cxx:94
CosmicGenerator::m_printMod
IntegerProperty m_printMod
Definition: CosmicGenerator.h:128
ATHRNG::RNGWrapper::getEngine
CLHEP::HepRandomEngine * getEngine(const EventContext &ctx) const
Retrieve the random engine corresponding to the provided EventContext.
Definition: RNGWrapper.h:134
python.LumiBlobConversion.pos
pos
Definition: LumiBlobConversion.py:18
python.PyAthena.v
v
Definition: PyAthena.py:154
AthAlgorithm::m_extendedExtraObjects
DataObjIDColl m_extendedExtraObjects
Definition: AthAlgorithm.h:79
Trk::vertex
@ vertex
Definition: MeasurementType.h:21
AthenaPoolExample_Copy.streamName
string streamName
Definition: AthenaPoolExample_Copy.py:39
CosmicGenerator::m_rvertmax
DoubleProperty m_rvertmax
Definition: CosmicGenerator.h:164
a
TList * a
Definition: liststreamerinfos.cxx:10
HepMC::newGenParticlePtr
GenParticlePtr newGenParticlePtr(const HepMC::FourVector &mom=HepMC::FourVector(0.0, 0.0, 0.0, 0.0), int pid=0, int status=0)
Definition: GenParticle.h:39
y
#define y
h
ATH_MSG_WARNING
#define ATH_MSG_WARNING(x)
Definition: AthMsgStreamMacros.h:32
GenModule::m_randomSeed
IntegerProperty m_randomSeed
Seed for random number engine.
Definition: GenModule.h:84
eFEXNTuple.delta_phi
def delta_phi(phi1, phi2)
Definition: eFEXNTuple.py:15
CosmicGenerator::m_yval
FloatProperty m_yval
Definition: CosmicGenerator.h:114
CosmicGenerator::m_GeV
static constexpr float m_GeV
Definition: CosmicGenerator.h:97
CosmicGun::SetEnergyRange
void SetEnergyRange(float emin, float emax)
Definition: CosmicGun.cxx:141
GenBase::pdt
const HepPDT::ParticleDataTable & pdt() const
Shorter alias to get a particle data table.
Definition: GenBase.h:123
CosmicGenerator::m_emin
FloatProperty m_emin
Definition: CosmicGenerator.h:107
SG::VarHandleBase::vhKey
SG::VarHandleKey & vhKey()
Return a non-const reference to the HandleKey.
Definition: StoreGate/src/VarHandleBase.cxx:623
ATHRNG::calculateSeedsMC21
void calculateSeedsMC21(long *seeds, const std::string &algName, uint64_t ev, uint64_t run, uint64_t offset=0)
Set the random seed using a string (e.g.
Definition: RNGWrapper.cxx:37
CosmicGenerator::exzCut
bool exzCut(const CLHEP::Hep3Vector &pos, const CLHEP::HepLorentzVector &p)
Definition: CosmicGenerator.cxx:662
CosmicGenerator::m_thetamax
FloatProperty m_thetamax
Definition: CosmicGenerator.h:131
CosmicGenerator::m_infile
StringProperty m_infile
Definition: CosmicGenerator.h:136
python.Bindings.keys
keys
Definition: Control/AthenaPython/python/Bindings.py:798
LHEF::Writer
Pythia8::Writer Writer
Definition: Prophecy4fMerger.cxx:12
drawFromPickle.sin
sin
Definition: drawFromPickle.py:36
CosmicGenerator::m_emax
FloatProperty m_emax
Definition: CosmicGenerator.h:108
CosmicGenerator::m_mm
static constexpr float m_mm
Definition: CosmicGenerator.h:98
MuonParameters::beta
@ beta
Definition: MuonParamDefs.h:144
CosmicGenerator::m_muonECOpt
BooleanProperty m_muonECOpt
Definition: CosmicGenerator.h:126
pow
constexpr int pow(int base, int exp) noexcept
Definition: ap_fixedTest.cxx:15
CosmicGenerator::m_IPx
FloatProperty m_IPx
Definition: CosmicGenerator.h:115
GenBase::particleData
const HepPDT::ParticleData * particleData(int pid) const
Access an element in the particle data table.
Definition: GenBase.h:126
CosmicGenerator::m_tmax
FloatProperty m_tmax
Definition: CosmicGenerator.h:121
CosmicGenerator::pathLengthInRock
double pathLengthInRock(double xgen, double ygen, double zgen, double theta, double phi)
Definition: CosmicGenerator.cxx:694
AthCommonDataStore::declareGaudiProperty
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>
Definition: AthCommonDataStore.h:156
Atlas::setExtendedEventContext
void setExtendedEventContext(EventContext &ctx, ExtendedEventContext &&ectx)
Move an extended context into a context object.
Definition: ExtendedEventContext.cxx:50
GenBase::initialize
virtual StatusCode initialize() override
Definition: GenBase.cxx:17
CosmicGenerator::m_thetamin
FloatProperty m_thetamin
Definition: CosmicGenerator.h:130
CosmicGenerator::m_radius
FloatProperty m_radius
Definition: CosmicGenerator.h:118
CosmicGenerator::m_exzCut
BooleanProperty m_exzCut
Definition: CosmicGenerator.h:149
DataVector::begin
const_iterator begin() const noexcept
Return a const_iterator pointing at the beginning of the collection.
fitman.k
k
Definition: fitman.py:528
GenModule::getRandomEngineDuringInitialize
CLHEP::HepRandomEngine * getRandomEngineDuringInitialize(const std::string &streamName, unsigned long int randomSeedOffset, unsigned int conditionsRun=1, unsigned int lbn=1) const
Definition: GenModule.cxx:53
ServiceHandle< ICondSvc >
CosmicEventParser
Definition: CosmicEventParser.h:12