List of all members | Classes | Public Types | Public Member Functions | Static Public Member Functions | Protected Types | Protected Attributes | Private Types | Private Member Functions | Private Attributes
ShowerInventorNS::ShowerInventor Class Reference

Generate hypothetical particle distributions in the shower plane. More...

#include <ShowerInventor.h>

Inheritance diagram for ShowerInventorNS::ShowerInventor:
Inheritance graph
[legend]

Classes

struct  DiagnosticHistos
 
struct  ParticleDistInfo
 

Public Types

enum  ResultFlag { eSuccess, eFailure, eBreakLoop, eContinueLoop }
 Flag returned by module methods to the RunController. More...
 
enum  VersionInfoType {
  eFilename = 1, eRevisionNumber = 2, eDate = 3, eTime = 4,
  eLastEditor = 5
}
 Different types of version info that can be retrieved from GetVersionInfo. More...
 

Public Member Functions

fwk::VModule::ResultFlag Finish ()
 Finish: invoked at end of the run (NOT end of the event) More...
 
utl::CoordinateSystemPtr GetExternalCS () const
 
unsigned int GetNumRequestedParticles () const
 
utl::ParticleGetOneParticle ()
 
utl::StopwatchGetStopwatch ()
 
const utl::StopwatchGetStopwatch () const
 
std::string GetVersionInfo (const VersionInfoType v) const
 Retrieve different sorts of module version info. More...
 
fwk::VModule::ResultFlag Init ()
 Initialize: invoked at beginning of run (NOT beginning of event) More...
 
void InitTiming ()
 
fwk::VModule::ResultFlag Run (evt::Event &event)
 Run: invoked once per event. More...
 
ResultFlag RunWithTiming (evt::Event &event)
 
 ShowerInventor ()
 
virtual ~ShowerInventor ()
 

Static Public Member Functions

static std::string GetResultFlagByName (const ResultFlag flag)
 

Protected Types

enum  InfoLevel { eInfoNone = 0, eInfoFinal = 1, eInfoIntermediate = 2, eInfoDebug = 3 }
 

Protected Attributes

int fInfoLevel = 0
 

Private Types

typedef std::vector< double > RandomCacheContainer
 

Private Member Functions

void FillCaches ()
 
utl::VRandomSamplerGetSampler (const utl::Branch &b)
 
 REGISTER_MODULE ("ShowerInventorNEU", ShowerInventor)
 

Private Attributes

double fAzimuth
 
double fCoreAltitude
 
double fCoreEasting
 
utl::PointfCoreLocation
 
double fCoreNorthing
 
unsigned int fCurrentDistIndex
 
evt::EventfCurrentEvent
 
utl::ParticlefCurrentParticle
 
ParticleDistInfo fCurrentPDI
 
double fCurrentZenith
 
unsigned int fCurrentZenithIndex
 
std::map< int, DiagnosticHistosfDiagnosticHistos
 
std::string fDiagnosticsFileName
 
bool fDiagnosticsOn
 
ShowerInventorParticleIteratorfFileIterator
 
utl::PlanefGroundPlane
 
std::vector< ParticleDistInfofParticleDistros
 
unsigned int fRandomCacheMaxSize
 
utl::RandomEngine::RandomEngineTypefRandomEngine
 
utl::CoordinateSystemPtr fShowerCS
 
utl::CoordinateSystemPtr fShowerLocalCS
 
TH2 * fStationPosGroundCS
 
unsigned int fTotalNumRequestedParticles
 
std::vector< double > fZeniths
 

Detailed Description

Generate hypothetical particle distributions in the shower plane.

Author
T. Paul
Date
13 August 2009

Definition at line 46 of file ShowerInventor.h.

Member Typedef Documentation

typedef std::vector<double> ShowerInventorNS::ShowerInventor::RandomCacheContainer
private

Definition at line 88 of file ShowerInventor.h.

Member Enumeration Documentation

enum fwk::VModule::InfoLevel
protectedinherited
Enumerator
eInfoNone 
eInfoFinal 
eInfoIntermediate 
eInfoDebug 

Definition at line 125 of file VModule.h.

enum fwk::VModule::ResultFlag
inherited

Flag returned by module methods to the RunController.

Enumerator
eSuccess 

Report success to RunController.

eFailure 

Report failure to RunController, causing RunController to terminate execution.

eBreakLoop 

Break current loop. It works for nested loops too!

eContinueLoop 

Skip remaining modules in the current loop and continue with next iteration of the loop.

Definition at line 60 of file VModule.h.

Different types of version info that can be retrieved from GetVersionInfo.

Enumerator
eFilename 
eRevisionNumber 
eDate 
eTime 
eLastEditor 

Definition at line 110 of file VModule.h.

Constructor & Destructor Documentation

ShowerInventor::ShowerInventor ( )

Definition at line 54 of file ShowerInventor.cc.

virtual ShowerInventorNS::ShowerInventor::~ShowerInventor ( )
inlinevirtual

Definition at line 50 of file ShowerInventor.h.

Member Function Documentation

void ShowerInventor::FillCaches ( )
private
VModule::ResultFlag ShowerInventor::Finish ( )
virtual

Finish: invoked at end of the run (NOT end of the event)

This method is for things that should be done at the end of the run (for example, closing files or writing out histograms) {You must override this method in your concrete module}

Implements fwk::VModule.

Definition at line 309 of file ShowerInventor.cc.

References fwk::VModule::eSuccess, fCoreLocation, fCurrentParticle, fDiagnosticHistos, fDiagnosticsFileName, fDiagnosticsOn, fGroundPlane, fParticleDistros, fStationPosGroundCS, and INFO.

utl::CoordinateSystemPtr ShowerInventorNS::ShowerInventor::GetExternalCS ( ) const
inline

Definition at line 61 of file ShowerInventor.h.

References fShowerLocalCS.

unsigned int ShowerInventorNS::ShowerInventor::GetNumRequestedParticles ( ) const
inline

Definition at line 58 of file ShowerInventor.h.

References fTotalNumRequestedParticles.

Particle * ShowerInventor::GetOneParticle ( )
std::string fwk::VModule::GetResultFlagByName ( const ResultFlag  flag)
staticinherited
VRandomSampler * ShowerInventor::GetSampler ( const utl::Branch b)
private

Definition at line 427 of file ShowerInventor.cc.

References utl::Branch::GetChild(), utl::Branch::GetData(), and max.

Referenced by Init().

utl::Stopwatch& fwk::VModule::GetStopwatch ( )
inlineinherited

Definition at line 106 of file VModule.h.

References fwk::VModule::fStopwatch.

const utl::Stopwatch& fwk::VModule::GetStopwatch ( ) const
inlineinherited

Definition at line 107 of file VModule.h.

References fwk::VModule::fStopwatch.

std::string fwk::VModule::GetVersionInfo ( const VersionInfoType  v) const
inherited
VModule::ResultFlag ShowerInventor::Init ( )
virtual

Initialize: invoked at beginning of run (NOT beginning of event)

This method is for things that should be done once at the beginning of a run (for example, booking histograms, performing calculations that need to be done only once, initializing parameters) {You must override this method in your concrete module}

Implements fwk::VModule.

Definition at line 68 of file ShowerInventor.cc.

References ShowerInventorNS::ShowerInventor::ParticleDistInfo::azimuthDistro, ShowerInventorNS::ShowerInventor::ParticleDistInfo::azimuthRandomCache, ShowerInventorNS::ShowerInventor::ParticleDistInfo::cachePosition, fwk::VModule::eSuccess, fAzimuth, fCoreAltitude, fCoreEasting, fCoreNorthing, fCurrentZenithIndex, fDiagnosticHistos, fDiagnosticsFileName, fDiagnosticsOn, fParticleDistros, fRandomCacheMaxSize, fStationPosGroundCS, fTotalNumRequestedParticles, fZeniths, utl::Branch::GetChild(), utl::Branch::GetData(), utl::Branch::GetFirstChild(), utl::Branch::GetNextSibling(), GetSampler(), utl::Branch::GetTopBranch(), INFO, utl::kPi, ShowerInventorNS::ShowerInventor::ParticleDistInfo::numGeneratedParticles, ShowerInventorNS::ShowerInventor::ParticleDistInfo::numRequestedParticles, ShowerInventorNS::ShowerInventor::ParticleDistInfo::particleType, ShowerInventorNS::ShowerInventor::ParticleDistInfo::radialDistro, ShowerInventorNS::ShowerInventor::DiagnosticHistos::radialDistro, ShowerInventorNS::ShowerInventor::ParticleDistInfo::radiusRandomCache, ShowerInventorNS::ShowerInventor::ParticleDistInfo::timeDistro, ShowerInventorNS::ShowerInventor::ParticleDistInfo::timeRandomCache, ShowerInventorNS::ShowerInventor::ParticleDistInfo::weightDistro, and ShowerInventorNS::ShowerInventor::ParticleDistInfo::weightRandomCache.

void fwk::VModule::InitTiming ( )
inlineinherited

Definition at line 95 of file VModule.h.

References fwk::VModule::fStopwatch, and utl::Stopwatch::Reset().

ShowerInventorNS::ShowerInventor::REGISTER_MODULE ( "ShowerInventorNEU"  ,
ShowerInventor   
)
private
VModule::ResultFlag ShowerInventor::Run ( evt::Event event)
virtual

Run: invoked once per event.

This method is for things that should be done once per event {You must override this method in your concrete module}

Implements fwk::VModule.

Definition at line 201 of file ShowerInventor.cc.

References sdet::SDetector::AllStationsBegin(), sdet::SDetector::AllStationsEnd(), ShowerInventorNS::ShowerInventor::ParticleDistInfo::cachePosition, fwk::VModule::eBreakLoop, fwk::VModule::eSuccess, fAzimuth, fCoreAltitude, fCoreEasting, fCoreLocation, fCoreNorthing, fCurrentDistIndex, fCurrentEvent, fCurrentPDI, fCurrentZenith, fCurrentZenithIndex, fDiagnosticsOn, fFileIterator, fGroundPlane, fParticleDistros, fRandomEngine, fShowerCS, fShowerLocalCS, fStationPosGroundCS, fZeniths, fwk::CoordinateSystemRegistry::Get(), utl::ReferenceEllipsoid::GetECEF(), evt::ShowerSimData::GetGroundParticles(), evt::ShowerSimData::GetLocalCoordinateSystem(), utl::UTMPoint::GetPoint(), evt::ShowerSimData::GetShowerCoordinateSystem(), evt::Event::GetSimShower(), utl::UTCDateTime::GetTimeStamp(), evt::ShowerSimData::HasGeometry(), evt::ShowerSimData::HasGroundParticles(), evt::Event::HasSimShower(), evt::ShowerSimData::HasTimeStamp(), utl::kilometer, evt::ShowerSimData::MakeGeometry(), evt::ShowerSimData::MakeGroundParticles(), evt::Event::MakeSimShower(), evt::ShowerSimData::MakeTimeStamp(), TelescopeSimulatorKG::RTFunctions::Plane(), utl::ShowerParticleList::SetFileInterface(), evt::ShowerSimData::SetGroundParticleCoordinateSystemAzimuth(), evt::ShowerSimData::SetGroundParticleCoordinateSystemZenith(), and evt::ShowerSimData::SetPrimaryParticle().

ResultFlag fwk::VModule::RunWithTiming ( evt::Event event)
inlineinherited

Member Data Documentation

double ShowerInventorNS::ShowerInventor::fAzimuth
private

Definition at line 72 of file ShowerInventor.h.

Referenced by GetOneParticle(), Init(), and Run().

double ShowerInventorNS::ShowerInventor::fCoreAltitude
private

Definition at line 75 of file ShowerInventor.h.

Referenced by Init(), and Run().

double ShowerInventorNS::ShowerInventor::fCoreEasting
private

Definition at line 74 of file ShowerInventor.h.

Referenced by Init(), and Run().

utl::Point* ShowerInventorNS::ShowerInventor::fCoreLocation
private

Definition at line 86 of file ShowerInventor.h.

Referenced by Finish(), and Run().

double ShowerInventorNS::ShowerInventor::fCoreNorthing
private

Definition at line 73 of file ShowerInventor.h.

Referenced by Init(), and Run().

unsigned int ShowerInventorNS::ShowerInventor::fCurrentDistIndex
private

Definition at line 128 of file ShowerInventor.h.

Referenced by GetOneParticle(), and Run().

evt::Event* ShowerInventorNS::ShowerInventor::fCurrentEvent
private

Definition at line 139 of file ShowerInventor.h.

Referenced by GetOneParticle(), and Run().

utl::Particle* ShowerInventorNS::ShowerInventor::fCurrentParticle
private

Definition at line 80 of file ShowerInventor.h.

Referenced by Finish(), and GetOneParticle().

ParticleDistInfo ShowerInventorNS::ShowerInventor::fCurrentPDI
private

Definition at line 127 of file ShowerInventor.h.

Referenced by FillCaches(), GetOneParticle(), and Run().

double ShowerInventorNS::ShowerInventor::fCurrentZenith
private

Definition at line 124 of file ShowerInventor.h.

Referenced by GetOneParticle(), and Run().

unsigned int ShowerInventorNS::ShowerInventor::fCurrentZenithIndex
private

Definition at line 125 of file ShowerInventor.h.

Referenced by Init(), and Run().

std::map<int, DiagnosticHistos> ShowerInventorNS::ShowerInventor::fDiagnosticHistos
private

Definition at line 150 of file ShowerInventor.h.

Referenced by Finish(), GetOneParticle(), and Init().

std::string ShowerInventorNS::ShowerInventor::fDiagnosticsFileName
private

Definition at line 135 of file ShowerInventor.h.

Referenced by Finish(), and Init().

bool ShowerInventorNS::ShowerInventor::fDiagnosticsOn
private

Definition at line 134 of file ShowerInventor.h.

Referenced by Finish(), GetOneParticle(), Init(), and Run().

ShowerInventorParticleIterator* ShowerInventorNS::ShowerInventor::fFileIterator
private

Definition at line 82 of file ShowerInventor.h.

Referenced by Run().

utl::Plane* ShowerInventorNS::ShowerInventor::fGroundPlane
private

Definition at line 85 of file ShowerInventor.h.

Referenced by Finish(), and Run().

int fwk::VModule::fInfoLevel = 0
protectedinherited
std::vector<ParticleDistInfo> ShowerInventorNS::ShowerInventor::fParticleDistros
private

Definition at line 122 of file ShowerInventor.h.

Referenced by Finish(), GetOneParticle(), Init(), and Run().

unsigned int ShowerInventorNS::ShowerInventor::fRandomCacheMaxSize
private

Definition at line 130 of file ShowerInventor.h.

Referenced by FillCaches(), GetOneParticle(), and Init().

utl::RandomEngine::RandomEngineType* ShowerInventorNS::ShowerInventor::fRandomEngine
private

Definition at line 69 of file ShowerInventor.h.

Referenced by FillCaches(), and Run().

utl::CoordinateSystemPtr ShowerInventorNS::ShowerInventor::fShowerCS
private

Definition at line 77 of file ShowerInventor.h.

Referenced by GetOneParticle(), and Run().

utl::CoordinateSystemPtr ShowerInventorNS::ShowerInventor::fShowerLocalCS
private

Definition at line 78 of file ShowerInventor.h.

Referenced by GetExternalCS(), GetOneParticle(), and Run().

TH2* ShowerInventorNS::ShowerInventor::fStationPosGroundCS
private

Definition at line 137 of file ShowerInventor.h.

Referenced by Finish(), Init(), and Run().

unsigned int ShowerInventorNS::ShowerInventor::fTotalNumRequestedParticles
private

Definition at line 83 of file ShowerInventor.h.

Referenced by GetNumRequestedParticles(), and Init().

std::vector<double> ShowerInventorNS::ShowerInventor::fZeniths
private

Definition at line 71 of file ShowerInventor.h.

Referenced by Init(), and Run().


The documentation for this class was generated from the following files:

, generated on Tue Sep 26 2023.