#include <GENIEHelper.h>
Public Member Functions | |
GENIEHelper (fhicl::ParameterSet const &pset, TGeoManager *rootGeom, std::string const &rootFile, double const &detectorMass) | |
~GENIEHelper () | |
void | Initialize () |
bool | Stop () |
bool | Sample (simb::MCTruth &truth, simb::MCFlux &flux, simb::GTruth >ruth) |
double | TotalHistFlux () |
double | TotalExposure () const |
double | SpillExposure () const |
std::string | FluxType () const |
std::string | DetectorLocation () const |
std::vector< TH1D * > | FluxHistograms () const |
double | TotalMass () const |
genie::EventRecord * | GetGenieEventRecord () |
TRandom3 * | GetHelperRandom () |
genie::GFluxI * | GetFluxDriver (bool base=true) |
std::string | GetTuneName () const |
std::string | GetEventGeneratorList () const |
Private Member Functions | |
void | RegularizeFluxType () |
void | SqueezeFilePatterns () |
void | AtmoFluxCheck () |
void | HistogramFluxCheck () |
void | InitializeGeometry () |
void | InitializeFiducialSelection () |
void | InitializeRockBoxSelection () |
void | InitializeFluxDriver () |
void | ConfigGeomScan () |
void | SetMaxPathOutInfo () |
void | PackNuMIFlux (simb::MCFlux &flux) |
void | PackSimpleFlux (simb::MCFlux &flux) |
void | PackMCTruth (genie::EventRecord *record, simb::MCTruth &truth) |
void | PackGTruth (genie::EventRecord *record, simb::GTruth &truth) |
void | BuildFluxRotation () |
void | ExpandFluxPaths () |
void | ExpandFluxFilePatternsDirect () |
void | ExpandFluxFilePatternsIFDH () |
bool | StringToBool (std::string v) |
void | SetGXMLPATH () |
void | SetGMSGLAYOUT () |
void | StartGENIEMessenger (std::string prodmode) |
void | ReadXSecTable () |
Private Attributes | |
TGeoManager * | fGeoManager |
pointer to ROOT TGeoManager More... | |
std::string | fGeoFile |
name of file containing the Geometry description More... | |
genie::EventRecord * | fGenieEventRecord |
last generated event More... | |
genie::GeomAnalyzerI * | fGeomD |
genie::GFluxI * | fFluxD |
real flux driver More... | |
genie::GFluxI * | fFluxD2GMCJD |
flux driver passed to genie GMCJDriver, might be GFluxBlender More... | |
genie::GMCJDriver * | fDriver |
ifdh_ns::ifdh * | fIFDH |
(optional) flux file handling More... | |
TRandom3 * | fHelperRandom |
random # generator for GENIEHelper More... | |
bool | fUseHelperRndGen4GENIE |
use fHelperRandom for gRandom during Sample() More... | |
evgb::EvtTimeShiftI * | fTimeShifter |
generator for time offset within a spill More... | |
std::string | fFluxType |
std::string | fFluxSearchPaths |
colon separated set of path stems More... | |
std::vector< std::string > | fFluxFilePatterns |
wildcard patterns files containing histograms or ntuples, or txt More... | |
std::vector< std::string > | fSelectedFluxFiles |
flux files selected after wildcard expansion and subset selection More... | |
int | fMaxFluxFileMB |
maximum size of flux files (MB) More... | |
int | fMaxFluxFileNumber |
maximum # of flux files More... | |
std::string | fFluxCopyMethod |
"DIRECT" = old direct access method, otherwise = ifdh approach schema ("" okay) More... | |
std::string | fFluxCleanup |
"ALWAYS", "/var/tmp", "NEVER" More... | |
std::string | fBeamName |
name of the beam we are simulating More... | |
std::string | fFluxRotCfg |
how to interpret fFluxRotValues More... | |
std::vector< double > | fFluxRotValues |
parameters for rotation More... | |
TRotation * | fFluxRotation |
rotation for atmos / astro flux coord systems More... | |
std::string | fTopVolume |
top volume in the ROOT geometry in which to generate events More... | |
std::string | fWorldVolume |
name of the world volume in the ROOT geometry More... | |
std::string | fDetLocation |
name of flux window location More... | |
std::vector< TH1D * > | fFluxHistograms |
histograms for each nu species More... | |
double | fFluxUpstreamZ |
z where flux starts from (if non-default, simple/ntuple only) More... | |
double | fEventsPerSpill |
double | fPOTPerSpill |
number of pot per spill More... | |
double | fHistEventsPerSpill |
number of events per spill for histogram fluxes - changes each spill More... | |
int | fSpillEvents |
total events for this spill More... | |
double | fSpillExposure |
total exposure (i.e. pot) for this spill More... | |
double | fTotalExposure |
pot used from flux ntuple More... | |
double | fMonoEnergy |
energy of monoenergetic neutrinos More... | |
std::string | fFunctionalFlux |
int | fFunctionalBinning |
double | fEmin |
double | fEmax |
double | fXSecMassPOT |
product of cross section, mass and POT/spill for histogram fluxes More... | |
double | fTotalHistFlux |
total flux of neutrinos from flux histograms for used flavors More... | |
TVector3 | fBeamDirection |
direction of the beam for histogram fluxes More... | |
TVector3 | fBeamCenter |
center of beam for histogram fluxes - must be in meters More... | |
double | fBeamRadius |
radius of cylindar for histogram fluxes - must be in meters More... | |
double | fDetectorMass |
mass of the detector in kg More... | |
double | fSurroundingMass |
double | fGlobalTimeOffset |
overall time shift (ns) added to every particle time More... | |
double | fRandomTimeOffset |
additional random time shift (ns) added to every particle time More... | |
std::string | fSpillTimeConfig |
alternative to flat spill distribution More... | |
std::vector< int > | fGenFlavors |
pdg codes for flavors to generate More... | |
double | fAtmoEmin |
atmo: Minimum energy of neutrinos in GeV More... | |
double | fAtmoEmax |
atmo: Maximum energy of neutrinos in GeV More... | |
double | fAtmoRl |
atmo: radius of the sphere on where the neutrinos are generated More... | |
double | fAtmoRt |
std::vector< std::string > | fEnvironment |
environmental variables and settings used by genie More... | |
std::string | fXSecTable |
cross section file (was $GSPLOAD) More... | |
std::string | fTuneName |
GENIE R-3 Tune name (defines model configuration) More... | |
std::string | fEventGeneratorList |
control over event topologies, was $GEVGL [Default] More... | |
std::string | fGXMLPATH |
locations for GENIE XML files More... | |
std::string | fGMSGLAYOUT |
format for GENIE log message [BASIC]|SIMPLE (SIMPLE=no timestamps) More... | |
std::string | fGENIEMsgThresholds |
additional XML file setting Messager level thresholds (":" separated) More... | |
int | fGHepPrintLevel |
GHepRecord::SetPrintLevel(), -1=no-print. More... | |
std::string | fMixerConfig |
configuration string for genie GFlavorMixerI More... | |
double | fMixerBaseline |
baseline distance if genie flux can't calculate it More... | |
std::string | fFiducialCut |
configuration for geometry selector More... | |
std::string | fGeomScan |
configuration for geometry scan to determine max pathlengths More... | |
std::string | fMaxPathOutInfo |
output info if writing PathLengthList from GeomScan More... | |
unsigned int | fDebugFlags |
set bits to enable debug info More... | |
Definition at line 57 of file GENIEHelper.h.
|
explicit |
Determine which flux files to use Do this after random number seed initialization for stability
For atmos_ / astro_ fluxes we might need to set a coordinate system rotation
Set the GENIE environment if using entries in the fEnvironment vector
Definition at line 217 of file GENIEHelper.cxx.
evgb::GENIEHelper::~GENIEHelper | ( | ) |
Definition at line 472 of file GENIEHelper.cxx.
|
private |
Speical pre-checks for atmo_ fluxes
Definition at line 748 of file GENIEHelper.cxx.
|
private |
Definition at line 2230 of file GENIEHelper.cxx.
|
private |
Definition at line 1404 of file GENIEHelper.cxx.
|
inline |
Definition at line 80 of file GENIEHelper.h.
|
private |
Definition at line 2365 of file GENIEHelper.cxx.
|
private |
Definition at line 2521 of file GENIEHelper.cxx.
|
private |
Definition at line 2346 of file GENIEHelper.cxx.
|
inline |
Definition at line 84 of file GENIEHelper.h.
|
inline |
Definition at line 79 of file GENIEHelper.h.
|
inline |
Definition at line 99 of file GENIEHelper.h.
|
inline |
Definition at line 94 of file GENIEHelper.h.
|
inline |
Definition at line 87 of file GENIEHelper.h.
|
inline |
Definition at line 90 of file GENIEHelper.h.
|
inline |
Definition at line 98 of file GENIEHelper.h.
|
private |
Definition at line 812 of file GENIEHelper.cxx.
void evgb::GENIEHelper::Initialize | ( | void | ) |
Definition at line 590 of file GENIEHelper.cxx.
|
private |
User defined fiducial volume cut [0][M]<SHAPE>:val1,val2,... "0" means reverse the cut (i.e. exclude the volume) "M" means the coordinates are given in the ROOT geometry "master" system and need to be transformed to "top vol" system <SHAPE> can be any of "zcyl" "box" "zpoly" "sphere" [each takes different # of args] This must be followed by a ":" and a list of values separated by punctuation (allowed separators: commas , parentheses () braces {} or brackets [] ) Value mapping: zcly:x0,y0,radius,zmin,zmax - cylinder along z at (x0,y0) capped at z's box:xmin,ymin,zmin,xmax,ymax,zmax - box w/ upper & lower extremes zpoly:nfaces,x0,y0,r_in,phi,zmin,zmax - nfaces sided polygon in x-y plane
Examples: 1) 0mbox:0,0,0.25,1,1,8.75 exclude (i.e. reverse) a box in master coordinates w/ corners (0,0,0.25) (1,1,8.75) 2) mzpoly:6,(2,-1),1.75,0,{0.25,8.75} six sided polygon in x-y plane, centered at x,y=(2,-1) w/ inscribed radius 1.75 no rotation (so first face is in y-z plane +r from center, i.e. hex sits on point) limited to the z range of {0.25,8.75} in the master ROOT geom coordinates 3) zcly:(3,4),5.5,-2,10 a cylinder oriented parallel to the z axis in the "top vol" coordinates at x,y=(3,4) with radius 5.5 and z range of {-2,10}
Definition at line 896 of file GENIEHelper.cxx.
|
private |
Definition at line 1146 of file GENIEHelper.cxx.
|
private |
Definition at line 860 of file GENIEHelper.cxx.
|
private |
Definition at line 1051 of file GENIEHelper.cxx.
|
private |
Definition at line 1983 of file GENIEHelper.cxx.
|
private |
Definition at line 1824 of file GENIEHelper.cxx.
|
private |
Definition at line 1737 of file GENIEHelper.cxx.
|
private |
Definition at line 2079 of file GENIEHelper.cxx.
|
private |
determine which cross section table to use fully expand the path
Definition at line 2865 of file GENIEHelper.cxx.
|
private |
Definition at line 687 of file GENIEHelper.cxx.
bool evgb::GENIEHelper::Sample | ( | simb::MCTruth & | truth, |
simb::MCFlux & | flux, | ||
simb::GTruth & | gtruth | ||
) |
Definition at line 1579 of file GENIEHelper.cxx.
|
private |
GMSGLAYOUT ([BASIC}|SIMPLE) control GENIE's layout of log4cpp message SIMPLE lacks the timestamp; this must be set in the environment at the time the log4cpp Messenger singleton is created
Definition at line 2771 of file GENIEHelper.cxx.
|
private |
GXMLPATH is where GENIE will look for alternative XML configurations (including message service threshold files)
Definition at line 2712 of file GENIEHelper.cxx.
|
private |
Definition at line 1501 of file GENIEHelper.cxx.
|
inline |
Definition at line 78 of file GENIEHelper.h.
|
private |
Definition at line 730 of file GENIEHelper.cxx.
|
private |
start with fGENIEMsgThresholds from pset "GENIEMsgThresholds" value allow fEnvironment $GMSGCONF and $GPRODMODE to expand it function arg might also trigger addition of Messenger_production.xml (pre-R-2_9_0) or Messenger_whisper.xml
$GPRODMODE used to trigger Messenger_production.xml with R-2_8_0 one must add it explicitly to $GMSGCONF
Definition at line 2795 of file GENIEHelper.cxx.
bool evgb::GENIEHelper::Stop | ( | ) |
Definition at line 1529 of file GENIEHelper.cxx.
|
private |
Definition at line 2958 of file GENIEHelper.cxx.
|
inline |
Definition at line 74 of file GENIEHelper.h.
double evgb::GENIEHelper::TotalHistFlux | ( | ) |
Definition at line 575 of file GENIEHelper.cxx.
|
inline |
Definition at line 85 of file GENIEHelper.h.
|
private |
atmo: Maximum energy of neutrinos in GeV
Definition at line 193 of file GENIEHelper.h.
|
private |
atmo: Minimum energy of neutrinos in GeV
Definition at line 192 of file GENIEHelper.h.
|
private |
atmo: radius of the sphere on where the neutrinos are generated
Definition at line 194 of file GENIEHelper.h.
|
private |
atmo: radius of the transvere (perpendicular) area on the sphere where the neutrinos are generated
Definition at line 195 of file GENIEHelper.h.
|
private |
center of beam for histogram fluxes - must be in meters
Definition at line 183 of file GENIEHelper.h.
|
private |
direction of the beam for histogram fluxes
Definition at line 182 of file GENIEHelper.h.
|
private |
name of the beam we are simulating
Definition at line 157 of file GENIEHelper.h.
|
private |
radius of cylindar for histogram fluxes - must be in meters
Definition at line 184 of file GENIEHelper.h.
|
private |
set bits to enable debug info
Definition at line 210 of file GENIEHelper.h.
|
private |
mass of the detector in kg
Definition at line 185 of file GENIEHelper.h.
|
private |
name of flux window location
Definition at line 164 of file GENIEHelper.h.
|
private |
Definition at line 138 of file GENIEHelper.h.
|
private |
Definition at line 179 of file GENIEHelper.h.
|
private |
Definition at line 178 of file GENIEHelper.h.
|
private |
environmental variables and settings used by genie
Definition at line 197 of file GENIEHelper.h.
|
private |
control over event topologies, was $GEVGL [Default]
Definition at line 200 of file GENIEHelper.h.
|
private |
number of events to generate in each spill if not using POT/spill. If using Atmo, set to 1
Definition at line 168 of file GENIEHelper.h.
|
private |
configuration for geometry selector
Definition at line 207 of file GENIEHelper.h.
|
private |
"ALWAYS", "/var/tmp", "NEVER"
Definition at line 156 of file GENIEHelper.h.
|
private |
"DIRECT" = old direct access method, otherwise = ifdh approach schema ("" okay)
Definition at line 155 of file GENIEHelper.h.
|
private |
real flux driver
Definition at line 136 of file GENIEHelper.h.
|
private |
flux driver passed to genie GMCJDriver, might be GFluxBlender
Definition at line 137 of file GENIEHelper.h.
|
private |
wildcard patterns files containing histograms or ntuples, or txt
Definition at line 151 of file GENIEHelper.h.
|
private |
histograms for each nu species
Definition at line 165 of file GENIEHelper.h.
|
private |
rotation for atmos / astro flux coord systems
Definition at line 160 of file GENIEHelper.h.
|
private |
how to interpret fFluxRotValues
Definition at line 158 of file GENIEHelper.h.
|
private |
parameters for rotation
Definition at line 159 of file GENIEHelper.h.
|
private |
colon separated set of path stems
Definition at line 150 of file GENIEHelper.h.
|
private |
histogram, gsimple, dk2nu, ntuple/gnumi, atmos_XXXX atmo_{FLUKA|BARTOL/BGLRS|HONDA/HAKKM}
Definition at line 147 of file GENIEHelper.h.
|
private |
z where flux starts from (if non-default, simple/ntuple only)
Definition at line 167 of file GENIEHelper.h.
|
private |
Definition at line 177 of file GENIEHelper.h.
|
private |
Definition at line 176 of file GENIEHelper.h.
|
private |
pdg codes for flavors to generate
Definition at line 191 of file GENIEHelper.h.
|
private |
last generated event
Definition at line 134 of file GENIEHelper.h.
|
private |
additional XML file setting Messager level thresholds (":" separated)
Definition at line 203 of file GENIEHelper.h.
|
private |
name of file containing the Geometry description
Definition at line 132 of file GENIEHelper.h.
|
private |
pointer to ROOT TGeoManager
Definition at line 131 of file GENIEHelper.h.
|
private |
Definition at line 135 of file GENIEHelper.h.
|
private |
configuration for geometry scan to determine max pathlengths
Definition at line 208 of file GENIEHelper.h.
|
private |
GHepRecord::SetPrintLevel(), -1=no-print.
Definition at line 204 of file GENIEHelper.h.
|
private |
overall time shift (ns) added to every particle time
Definition at line 188 of file GENIEHelper.h.
|
private |
format for GENIE log message [BASIC]|SIMPLE (SIMPLE=no timestamps)
Definition at line 202 of file GENIEHelper.h.
|
private |
locations for GENIE XML files
Definition at line 201 of file GENIEHelper.h.
|
private |
random # generator for GENIEHelper
Definition at line 143 of file GENIEHelper.h.
|
private |
number of events per spill for histogram fluxes - changes each spill
Definition at line 171 of file GENIEHelper.h.
|
private |
(optional) flux file handling
Definition at line 141 of file GENIEHelper.h.
|
private |
maximum size of flux files (MB)
Definition at line 153 of file GENIEHelper.h.
|
private |
maximum # of flux files
Definition at line 154 of file GENIEHelper.h.
|
private |
output info if writing PathLengthList from GeomScan
Definition at line 209 of file GENIEHelper.h.
|
private |
baseline distance if genie flux can't calculate it
Definition at line 206 of file GENIEHelper.h.
|
private |
configuration string for genie GFlavorMixerI
Definition at line 205 of file GENIEHelper.h.
|
private |
energy of monoenergetic neutrinos
Definition at line 175 of file GENIEHelper.h.
|
private |
number of pot per spill
Definition at line 170 of file GENIEHelper.h.
|
private |
additional random time shift (ns) added to every particle time
Definition at line 189 of file GENIEHelper.h.
|
private |
flux files selected after wildcard expansion and subset selection
Definition at line 152 of file GENIEHelper.h.
|
private |
total events for this spill
Definition at line 172 of file GENIEHelper.h.
|
private |
total exposure (i.e. pot) for this spill
Definition at line 173 of file GENIEHelper.h.
|
private |
alternative to flat spill distribution
Definition at line 190 of file GENIEHelper.h.
|
private |
mass of material surrounding the detector that is intercepted by the cylinder for the histogram flux in kg
Definition at line 186 of file GENIEHelper.h.
|
private |
generator for time offset within a spill
Definition at line 145 of file GENIEHelper.h.
|
private |
top volume in the ROOT geometry in which to generate events
Definition at line 162 of file GENIEHelper.h.
|
private |
pot used from flux ntuple
Definition at line 174 of file GENIEHelper.h.
|
private |
total flux of neutrinos from flux histograms for used flavors
Definition at line 181 of file GENIEHelper.h.
|
private |
GENIE R-3 Tune name (defines model configuration)
Definition at line 199 of file GENIEHelper.h.
|
private |
use fHelperRandom for gRandom during Sample()
Definition at line 144 of file GENIEHelper.h.
|
private |
name of the world volume in the ROOT geometry
Definition at line 163 of file GENIEHelper.h.
|
private |
product of cross section, mass and POT/spill for histogram fluxes
Definition at line 180 of file GENIEHelper.h.
|
private |
cross section file (was $GSPLOAD)
Definition at line 198 of file GENIEHelper.h.