List of all members | Public Types | Public Member Functions | Static Public Member Functions | Protected Types | Protected Attributes | Private Member Functions | Private Attributes
CachedXShowerRegeneratorAG::CachedXShowerRegenerator Class Reference

#include <CachedXShowerRegenerator.h>

Inheritance diagram for CachedXShowerRegeneratorAG::CachedXShowerRegenerator:
Inheritance graph
[legend]

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

 CachedXShowerRegenerator ()
 
VModule::ResultFlag Finish ()
 Finish: invoked at end of the run (NOT end of the event) More...
 
utl::StopwatchGetStopwatch ()
 
const utl::StopwatchGetStopwatch () const
 
std::string GetVersionInfo (const VersionInfoType v) const
 Retrieve different sorts of module version info. More...
 
VModule::ResultFlag Init ()
 Initialize: invoked at beginning of run (NOT beginning of event) More...
 
void InitTiming ()
 
VModule::ResultFlag Run (evt::Event &event)
 Run: invoked once per event. More...
 
ResultFlag RunWithTiming (evt::Event &event)
 

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 Member Functions

void InitNewShower (evt::Event &event)
 
bool IsParticleEnergyLow (const int, const double) const
 
void OutputStats (evt::Event &event)
 
boost::tuple< unsigned int,
double > 
ParticleNumberAndWeight (const double &, const int &)
 (Optional) special handling for particles with very large weights. More...
 
 REGISTER_MODULE ("CachedXShowerRegeneratorAG", CachedXShowerRegenerator)
 

Private Attributes

double fAccumulatedWeightLimit
 
double fAmigaRadius
 
double fDeltaPhi
 
double fDeltaROverR
 
double fElectronEnergyCut
 
utl::TabulatedFunctionfEToVem
 
double fHadronEnergyCut
 
double fHorizontalParticleCut
 
double fInjectionStop
 
double fInnerRadiusCut
 
double fLogXGaussSmearingWidth
 
unsigned int fMaxParticles
 
double fMesonEnergyCut
 
double fMuonEnergyCut
 
double fMuonWeightScale
 
utl::TabulatedFunctionfMuToVem
 
unsigned int fNOutOfRangeWeight
 
double fOuterRadiusCut
 
double fPhiGranularity
 
double fPhotonEnergyCut
 
utl::RandomEngine::RandomEngineTypefRandomEngine
 
double fRGranularity
 
utl::ShadowPtr< ShowerDatafShowerData
 
bool fSimulateAmiga
 
double fTimeSlotSize
 
bool fUseInjectionStop
 
bool fUseStationPositionMatrix
 
bool fUseWeightLimiting
 
double fWeightLimit
 
double fWeightThreshold
 
int largeWeightCtr
 
int unityWeightCtr
 

Detailed Description

Definition at line 66 of file CachedXShowerRegenerator.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

CachedXShowerRegenerator::CachedXShowerRegenerator ( )

Definition at line 103 of file CachedXShowerRegenerator.cc.

Member Function Documentation

VModule::ResultFlag CachedXShowerRegenerator::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 728 of file CachedXShowerRegenerator.cc.

References fwk::VModule::eSuccess, fNOutOfRangeWeight, fWeightLimit, and WARNING.

std::string fwk::VModule::GetResultFlagByName ( const ResultFlag  flag)
staticinherited
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 CachedXShowerRegenerator::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 134 of file CachedXShowerRegenerator.cc.

References fwk::VModule::eSuccess, fAccumulatedWeightLimit, fAmigaRadius, fDeltaPhi, fDeltaROverR, fElectronEnergyCut, fHadronEnergyCut, fHorizontalParticleCut, fInnerRadiusCut, fLogXGaussSmearingWidth, fMaxParticles, fMesonEnergyCut, fMuonEnergyCut, fMuonWeightScale, fOuterRadiusCut, fPhiGranularity, fPhotonEnergyCut, fRandomEngine, fRGranularity, fSimulateAmiga, fUseStationPositionMatrix, fUseWeightLimiting, fWeightThreshold, utl::Branch::GetChild(), utl::Branch::GetData(), utl::Branch::GetTopBranch(), INFO, largeWeightCtr, unityWeightCtr, and WARNING.

void CachedXShowerRegenerator::InitNewShower ( evt::Event event)
private
void fwk::VModule::InitTiming ( )
inlineinherited

Definition at line 95 of file VModule.h.

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

bool CachedXShowerRegenerator::IsParticleEnergyLow ( const int  pType,
const double  pEnergy 
) const
private
void CachedXShowerRegenerator::OutputStats ( evt::Event event)
private
boost::tuple< unsigned int, double > CachedXShowerRegenerator::ParticleNumberAndWeight ( const double &  avgN,
const int &  sId 
)
private

(Optional) special handling for particles with very large weights.

EXPLAIN HOW THIS WORKS need for arguments..

Definition at line 750 of file CachedXShowerRegenerator.cc.

References fAccumulatedWeightLimit, fRandomEngine, fShowerData, and fWeightThreshold.

Referenced by Run().

CachedXShowerRegeneratorAG::CachedXShowerRegenerator::REGISTER_MODULE ( "CachedXShowerRegeneratorAG"  ,
CachedXShowerRegenerator   
)
private
VModule::ResultFlag CachedXShowerRegenerator::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 339 of file CachedXShowerRegenerator.cc.

References utl::abs(), sevt::Station::AddParticle(), utl::Particle::eAntiMuon, fwk::VModule::eBreakLoop, fwk::VModule::eFailure, utl::Particle::eMuon, ERROR, utl::Particle::eShowerFromMuonDecay, fwk::VModule::eSuccess, fAmigaRadius, fHorizontalParticleCut, fMaxParticles, fMuonWeightScale, fRandomEngine, fShowerData, fSimulateAmiga, fUseWeightLimiting, CachedXShowerRegeneratorAG::StationInfo::GetDetStation(), utl::Particle::GetDirection(), CachedXShowerRegeneratorAG::StationInfo::GetEvtStation(), sdet::Station::GetHeight(), sdet::Station::GetId(), utl::TimeInterval::GetInterval(), utl::Particle::GetKineticEnergy(), evt::ShowerSimData::GetLocalCoordinateSystem(), sdet::Station::GetLocalCoordinateSystem(), utl::BasicVector< HepVector >::GetPhi(), utl::Particle::GetPosition(), evt::ShowerSimData::GetPosition(), sdet::Station::GetRadius(), CachedXShowerRegeneratorAG::StationInfo::GetResamplingArea(), utl::BasicVector< HepVector >::GetRho(), utl::BasicVector< HepVector >::GetRho2(), evt::ShowerSimData::GetShowerCoordinateSystem(), utl::Particle::GetSource(), sevt::SEvent::GetStation(), sdet::Station::GetThickness(), utl::Particle::GetTime(), utl::Particle::GetType(), utl::Particle::GetWeight(), utl::BasicVector< HepVector >::GetZ(), evt::Event::HasSimShower(), INFO, InitNewShower(), CachedXShowerRegeneratorAG::InsertValue(), CachedXShowerRegeneratorAG::StationInfo::IsIn(), IsParticleEnergyLow(), utl::BasicVector< HepVector >::kCylindrical, utl::kPi, utl::kPiOnTwo, utl::kTwoPi, largeWeightCtr, ns, OutputStats(), ParticleNumberAndWeight(), CachedXShowerRegeneratorAG::PlaneFrontTime(), utl::Particle::SetParent(), utl::Particle::SetPosition(), utl::Particle::SetTime(), utl::Particle::SetWeight(), utl::Sqr(), sqrt(), sdet::SDetector::StationsBegin(), sdet::SDetector::StationsEnd(), and unityWeightCtr.

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

Member Data Documentation

double CachedXShowerRegeneratorAG::CachedXShowerRegenerator::fAccumulatedWeightLimit
private

Definition at line 113 of file CachedXShowerRegenerator.h.

Referenced by Init(), and ParticleNumberAndWeight().

double CachedXShowerRegeneratorAG::CachedXShowerRegenerator::fAmigaRadius
private

Definition at line 124 of file CachedXShowerRegenerator.h.

Referenced by Init(), and Run().

double CachedXShowerRegeneratorAG::CachedXShowerRegenerator::fDeltaPhi
private

Definition at line 98 of file CachedXShowerRegenerator.h.

Referenced by Init(), and InitNewShower().

double CachedXShowerRegeneratorAG::CachedXShowerRegenerator::fDeltaROverR
private

Definition at line 97 of file CachedXShowerRegenerator.h.

Referenced by Init(), and InitNewShower().

double CachedXShowerRegeneratorAG::CachedXShowerRegenerator::fElectronEnergyCut
private

Definition at line 91 of file CachedXShowerRegenerator.h.

Referenced by Init(), and IsParticleEnergyLow().

utl::TabulatedFunction* CachedXShowerRegeneratorAG::CachedXShowerRegenerator::fEToVem
private

Definition at line 108 of file CachedXShowerRegenerator.h.

double CachedXShowerRegeneratorAG::CachedXShowerRegenerator::fHadronEnergyCut
private

Definition at line 94 of file CachedXShowerRegenerator.h.

Referenced by Init(), and IsParticleEnergyLow().

double CachedXShowerRegeneratorAG::CachedXShowerRegenerator::fHorizontalParticleCut
private

Definition at line 99 of file CachedXShowerRegenerator.h.

Referenced by Init(), and Run().

int fwk::VModule::fInfoLevel = 0
protectedinherited
double CachedXShowerRegeneratorAG::CachedXShowerRegenerator::fInjectionStop
private

Definition at line 106 of file CachedXShowerRegenerator.h.

double CachedXShowerRegeneratorAG::CachedXShowerRegenerator::fInnerRadiusCut
private

Definition at line 88 of file CachedXShowerRegenerator.h.

Referenced by Init(), and InitNewShower().

double CachedXShowerRegeneratorAG::CachedXShowerRegenerator::fLogXGaussSmearingWidth
private

Definition at line 103 of file CachedXShowerRegenerator.h.

Referenced by Init(), and InitNewShower().

unsigned int CachedXShowerRegeneratorAG::CachedXShowerRegenerator::fMaxParticles
private

Definition at line 86 of file CachedXShowerRegenerator.h.

Referenced by Init(), and Run().

double CachedXShowerRegeneratorAG::CachedXShowerRegenerator::fMesonEnergyCut
private

Definition at line 95 of file CachedXShowerRegenerator.h.

Referenced by Init(), and IsParticleEnergyLow().

double CachedXShowerRegeneratorAG::CachedXShowerRegenerator::fMuonEnergyCut
private

Definition at line 92 of file CachedXShowerRegenerator.h.

Referenced by Init(), and IsParticleEnergyLow().

double CachedXShowerRegeneratorAG::CachedXShowerRegenerator::fMuonWeightScale
private

Definition at line 114 of file CachedXShowerRegenerator.h.

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

utl::TabulatedFunction* CachedXShowerRegeneratorAG::CachedXShowerRegenerator::fMuToVem
private

Definition at line 107 of file CachedXShowerRegenerator.h.

unsigned int CachedXShowerRegeneratorAG::CachedXShowerRegenerator::fNOutOfRangeWeight
private

Definition at line 120 of file CachedXShowerRegenerator.h.

Referenced by Finish().

double CachedXShowerRegeneratorAG::CachedXShowerRegenerator::fOuterRadiusCut
private

Definition at line 89 of file CachedXShowerRegenerator.h.

Referenced by Init(), and InitNewShower().

double CachedXShowerRegeneratorAG::CachedXShowerRegenerator::fPhiGranularity
private

Definition at line 101 of file CachedXShowerRegenerator.h.

Referenced by Init(), and InitNewShower().

double CachedXShowerRegeneratorAG::CachedXShowerRegenerator::fPhotonEnergyCut
private

Definition at line 93 of file CachedXShowerRegenerator.h.

Referenced by Init(), and IsParticleEnergyLow().

utl::RandomEngine::RandomEngineType* CachedXShowerRegeneratorAG::CachedXShowerRegenerator::fRandomEngine
private

Definition at line 117 of file CachedXShowerRegenerator.h.

Referenced by Init(), InitNewShower(), ParticleNumberAndWeight(), and Run().

double CachedXShowerRegeneratorAG::CachedXShowerRegenerator::fRGranularity
private

Definition at line 102 of file CachedXShowerRegenerator.h.

Referenced by Init(), and InitNewShower().

utl::ShadowPtr<ShowerData> CachedXShowerRegeneratorAG::CachedXShowerRegenerator::fShowerData
private
bool CachedXShowerRegeneratorAG::CachedXShowerRegenerator::fSimulateAmiga
private

Definition at line 123 of file CachedXShowerRegenerator.h.

Referenced by Init(), and Run().

double CachedXShowerRegeneratorAG::CachedXShowerRegenerator::fTimeSlotSize
private

Definition at line 119 of file CachedXShowerRegenerator.h.

bool CachedXShowerRegeneratorAG::CachedXShowerRegenerator::fUseInjectionStop
private

Definition at line 105 of file CachedXShowerRegenerator.h.

bool CachedXShowerRegeneratorAG::CachedXShowerRegenerator::fUseStationPositionMatrix
private

Definition at line 100 of file CachedXShowerRegenerator.h.

Referenced by Init(), and InitNewShower().

bool CachedXShowerRegeneratorAG::CachedXShowerRegenerator::fUseWeightLimiting
private

Definition at line 110 of file CachedXShowerRegenerator.h.

Referenced by Init(), and Run().

double CachedXShowerRegeneratorAG::CachedXShowerRegenerator::fWeightLimit
private

Definition at line 121 of file CachedXShowerRegenerator.h.

Referenced by Finish().

double CachedXShowerRegeneratorAG::CachedXShowerRegenerator::fWeightThreshold
private

Definition at line 112 of file CachedXShowerRegenerator.h.

Referenced by Init(), and ParticleNumberAndWeight().

int CachedXShowerRegeneratorAG::CachedXShowerRegenerator::largeWeightCtr
private

Definition at line 129 of file CachedXShowerRegenerator.h.

Referenced by Init(), and Run().

int CachedXShowerRegeneratorAG::CachedXShowerRegenerator::unityWeightCtr
private

Definition at line 128 of file CachedXShowerRegenerator.h.

Referenced by Init(), and Run().


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

, generated on Tue Sep 26 2023.