Analysis Software
Documentation for sPHENIX simulation software
|
#include <coresoftware/blob/master/simulation/g4simulation/g4main/ReadEICFiles.h>
Public Member Functions | |
ReadEICFiles (const std::string &name="EICReader") | |
~ReadEICFiles () override | |
int | Init (PHCompositeNode *topNode) override |
int | process_event (PHCompositeNode *topNode) override |
bool | OpenInputFile (const std::string &name) |
void | SetFirstEntry (int e) |
void | SetNodeName (const std::string &s) |
Public Member Functions inherited from SubsysReco | |
~SubsysReco () override | |
virtual int | End (PHCompositeNode *) |
Called at the end of all processing. | |
virtual int | EndRun (const int) |
Called at the end of each run. | |
virtual int | InitRun (PHCompositeNode *) |
virtual int | Reset (PHCompositeNode *) |
Reset. | |
virtual int | ResetEvent (PHCompositeNode *) |
Clean up after each event. | |
void | Print (const std::string &="ALL") const override |
Public Member Functions inherited from Fun4AllBase | |
virtual | ~Fun4AllBase () |
virtual const std::string | Name () const |
Returns the name of this module. | |
virtual void | Name (const std::string &name) |
Sets the name of this module. | |
virtual void | Verbosity (const int ival) |
Sets the verbosity of this module (0 by default=quiet). | |
virtual void | Verbosity (enu_Verbosity ival) |
Sets the verbosity of this module (0 by default=quiet). | |
virtual int | Verbosity () const |
Gets the verbosity of this module. | |
Public Member Functions inherited from PHHepMCGenHelper | |
PHHepMCGenHelper () | |
virtual | ~PHHepMCGenHelper () |
void | set_vertex_distribution_function (VTXFUNC x, VTXFUNC y, VTXFUNC z, VTXFUNC t) |
toss a new vertex according to a Uniform or Gaus distribution | |
void | set_vertex_distribution_mean (const double x, const double y, const double z, const double t) |
set the mean value of the vertex distribution, use PHENIX units of cm, ns | |
void | set_vertex_distribution_width (const double x, const double y, const double z, const double t) |
set the width of the vertex distribution function about the mean, use PHENIX units of cm, ns | |
int | get_embedding_id () const |
void | set_embedding_id (int id) |
void | set_reuse_vertex (int src_embedding_id) |
reuse vertex from another PHHepMCGenEvent with embedding_id = src_embedding_id Additional smearing and shift possible with set_vertex_distribution_*() | |
virtual int | create_node_tree (PHCompositeNode *topNode) |
init interface nodes | |
const PHHepMCGenEvent * | get_PHHepMCGenEvent_template () const |
choice of reference version of the PHHepMCGenEvent | |
PHHepMCGenEvent * | insert_event (HepMC::GenEvent *evt) |
send HepMC::GenEvent to DST tree. This function takes ownership of evt | |
const PHHepMCGenEventMap * | get_geneventmap () const |
PHHepMCGenEventMap * | get_geneventmap () |
gsl_rng * | get_random_generator () |
void | set_geneventmap (PHHepMCGenEventMap *geneventmap) |
void | set_beam_direction_theta_phi (const double beamA_theta, const double beamA_phi, const double beamB_theta, const double beamB_phi) |
void | set_beam_angular_divergence_hv (const double beamA_divergence_h, const double beamA_divergence_v, const double beamB_divergence_h, const double beamB_divergence_v) |
void | set_beam_angular_z_coefficient_hv (const double beamA_h, const double beamA_v, const double beamB_h, const double beamB_v) |
void | use_beam_bunch_sim (bool b) |
simulate bunch interaction instead of applying vertex distributions | |
void | set_beam_bunch_width (const std::vector< double > &beamA, const std::vector< double > &beamB) |
void | CopySettings (PHHepMCGenHelper &helper) |
void | CopySettings (PHHepMCGenHelper *helper_dest) |
copy setting to helper_dest | |
void | CopyHelperSettings (PHHepMCGenHelper *helper_src) |
copy setting from helper_src | |
void | Print (const std::string &what="ALL") const |
void | PHHepMCGenHelper_Verbosity (int v) |
int | PHHepMCGenHelper_Verbosity () |
Private Types | |
enum | EvtGen { Milou = 1, DEMP = 2, Unknown = 100 } |
Private Member Functions | |
void | GetTree () |
int | CreateNodeTree (PHCompositeNode *topNode) |
Private Attributes | |
std::string | filename |
TChain * | Tin |
int | nEntries |
int | entry |
int | m_EvtGenId |
erhic::EventMC * | GenEvent |
std::string | _node_name |
Additional Inherited Members | |
Public Types inherited from Fun4AllBase | |
enum | enu_Verbosity { VERBOSITY_QUIET = 0, VERBOSITY_SOME = 1, VERBOSITY_MORE = 2, VERBOSITY_EVEN_MORE = 3, VERBOSITY_A_LOT = 4, VERBOSITY_MAX = std::numeric_limits<int>::max() - 10 } |
Public Types inherited from PHHepMCGenHelper | |
enum | VTXFUNC { Uniform, Gaus } |
supported function distributions More... | |
Protected Member Functions inherited from SubsysReco | |
SubsysReco (const std::string &name="NONAME") | |
Protected Member Functions inherited from PHHepMCGenHelper | |
void | HepMC2Lab_boost_rotation_translation (PHHepMCGenEvent *genevent) |
Record the translation,boost,rotation for HepMC frame to lab frame according to collision settings. | |
void | move_vertex (PHHepMCGenEvent *genevent) |
move vertex in translation according to vertex settings | |
std::pair< double, double > | generate_vertx_with_bunch_interaction (PHHepMCGenEvent *genevent) |
Definition at line 20 of file ReadEICFiles.h.
View newest version in sPHENIX GitHub at line 20 of file ReadEICFiles.h
|
private |
Definition at line 44 of file ReadEICFiles.h.
View newest version in sPHENIX GitHub at line 44 of file ReadEICFiles.h
ReadEICFiles::ReadEICFiles | ( | const std::string & | name = "EICReader" | ) |
Definition at line 49 of file ReadEICFiles.cc.
View newest version in sPHENIX GitHub at line 49 of file ReadEICFiles.cc
References PHHepMCGenHelper::set_embedding_id().
|
override |
Definition at line 65 of file ReadEICFiles.cc.
View newest version in sPHENIX GitHub at line 65 of file ReadEICFiles.cc
References Tin.
|
private |
Creade node on node tree
Definition at line 369 of file ReadEICFiles.cc.
View newest version in sPHENIX GitHub at line 369 of file ReadEICFiles.cc
References Fun4AllReturnCodes::ABORTRUN, PHCompositeNode::addNode(), PHHepMCGenHelper::create_node_tree(), Fun4AllReturnCodes::EVENT_OK, PHNodeIterator::findFirst(), and PHWHERE.
Referenced by Init().
|
private |
Get tree from input file
Definition at line 83 of file ReadEICFiles.cc.
View newest version in sPHENIX GitHub at line 83 of file ReadEICFiles.cc
References GenEvent, m_EvtGenId, nEntries, Tin, and Fun4AllBase::Verbosity().
Referenced by OpenInputFile().
|
overridevirtual |
Called during initialization. Typically this is where you can book histograms, and e.g. register them to Fun4AllServer (so they can be output to file using Fun4AllServer::dumpHistos() method).
Reimplemented from SubsysReco.
Definition at line 107 of file ReadEICFiles.cc.
View newest version in sPHENIX GitHub at line 107 of file ReadEICFiles.cc
References CreateNodeTree().
bool ReadEICFiles::OpenInputFile | ( | const std::string & | name | ) |
Specify name of input file to open
Definition at line 72 of file ReadEICFiles.cc.
View newest version in sPHENIX GitHub at line 72 of file ReadEICFiles.cc
References filename, GetTree(), perf_headwind::name, and Tin.
Referenced by Fun4All_EICAnalysis_DVCS(), Fun4All_EICAnalysis_Leptoquarks(), Fun4All_G4_EICDetector_LQ(), Fun4All_G4_EICDetector_LQ_reference(), Fun4All_G4_EICDetector_RICH(), Fun4All_Generator_Display(), Fun4All_MCEventGen(), and InputRegister().
|
overridevirtual |
Called for each event. This is where you do the real work.
Reimplemented from SubsysReco.
Definition at line 114 of file ReadEICFiles.cc.
View newest version in sPHENIX GitHub at line 114 of file ReadEICFiles.cc
References Fun4AllReturnCodes::ABORTRUN, entry, filename, gen(), GenEvent, PHHepMCGenHelper::insert_event(), Acts::UnitConstants::m, m_EvtGenId, nEntries, merge_hashes::p, EicEventHeader::set_demp_weight(), EicEventHeader::set_eventgenerator_type(), EicEventHeader::set_milou_trueQ2(), EicEventHeader::set_milou_trueX(), EicEventHeader::set_milou_weight(), Tin, testSigmaEff::v, and Fun4AllBase::Verbosity().
|
inline |
Set first entry from input tree to be used
Definition at line 33 of file ReadEICFiles.h.
View newest version in sPHENIX GitHub at line 33 of file ReadEICFiles.h
References Acts::UnitConstants::e, and entry.
Referenced by Fun4All_G4_EICDetector_RICH().
|
inline |
Set name of output node
Definition at line 35 of file ReadEICFiles.h.
View newest version in sPHENIX GitHub at line 35 of file ReadEICFiles.h
References _node_name, and physmon_simulation::s.
|
private |
Definition at line 72 of file ReadEICFiles.h.
View newest version in sPHENIX GitHub at line 72 of file ReadEICFiles.h
Referenced by SetNodeName().
|
private |
Number of current event being used from input tree
Definition at line 61 of file ReadEICFiles.h.
View newest version in sPHENIX GitHub at line 61 of file ReadEICFiles.h
Referenced by process_event(), and SetFirstEntry().
|
private |
Name of file containing input tree
Definition at line 52 of file ReadEICFiles.h.
View newest version in sPHENIX GitHub at line 52 of file ReadEICFiles.h
Referenced by cpp.ast.Include::__str__(), cpp.ast.AstBuilder::_GetClass(), cpp.ast.AstBuilder::HandleError(), OpenInputFile(), and process_event().
|
private |
Pinter to event record in tree (= branch). Use 'abstract' EventMC class pointer from which all event types (erhic::EventMilou etc) inherit from.
Definition at line 69 of file ReadEICFiles.h.
View newest version in sPHENIX GitHub at line 69 of file ReadEICFiles.h
Referenced by GetTree(), and process_event().
|
private |
Event Generator id
Definition at line 64 of file ReadEICFiles.h.
View newest version in sPHENIX GitHub at line 64 of file ReadEICFiles.h
Referenced by GetTree(), and process_event().
|
private |
Number of events in input tree
Definition at line 58 of file ReadEICFiles.h.
View newest version in sPHENIX GitHub at line 58 of file ReadEICFiles.h
Referenced by GetTree(), and process_event().
|
private |
Input tree created with eic-smear tree builder
Definition at line 55 of file ReadEICFiles.h.
View newest version in sPHENIX GitHub at line 55 of file ReadEICFiles.h
Referenced by GetTree(), OpenInputFile(), process_event(), and ~ReadEICFiles().