Analysis Software
Documentation for sPHENIX simulation software
|
JetHepMCLoader loads special jet objects encoded in HepMC records to DST Jet nodes. Example use are loading sHijing HIJFRG jets. More...
#include <coresoftware/blob/master/simulation/g4simulation/g4jets/JetHepMCLoader.h>
Classes | |
struct | hepmc_jet_src |
Public Member Functions | |
JetHepMCLoader (const std::string &jetInputCategory) | |
~JetHepMCLoader () override | |
int | InitRun (PHCompositeNode *topNode) override |
int | process_event (PHCompositeNode *topNode) override |
int | End (PHCompositeNode *topNode) override |
Called at the end of all processing. | |
void | addJet (const std::string &name, int embeddingID, Jet::ALGO algorithm, double parameter, int tagPID, int tagStatus) |
addJet add HepMC entries for a particular type of jets Example of adding sHijing HIJFRG truth jets with R=0.4: | |
void | saveQAPlots (bool b=true) |
Public Member Functions inherited from SubsysReco | |
~SubsysReco () override | |
virtual int | EndRun (const int) |
Called at the end of each run. | |
virtual int | Init (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. | |
Private Member Functions | |
int | CreateNodes (PHCompositeNode *topNode) |
Fun4AllHistoManager * | getHistoManager () |
Private Attributes | |
std::string | m_jetInputCategory |
bool | m_saveQAPlots = false |
std::vector< hepmc_jet_src > | m_jetSrc |
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 } |
Protected Member Functions inherited from SubsysReco | |
SubsysReco (const std::string &name="NONAME") | |
JetHepMCLoader loads special jet objects encoded in HepMC records to DST Jet nodes. Example use are loading sHijing HIJFRG jets.
Example use for readback HIJFRAG truth jets from the sHijing HepMC records:
Definition at line 42 of file JetHepMCLoader.h.
View newest version in sPHENIX GitHub at line 42 of file JetHepMCLoader.h
JetHepMCLoader::JetHepMCLoader | ( | const std::string & | jetInputCategory | ) |
[in] | jetInputCategory | is the DST PHCompositeNode name that list the output jet maps, e.g. sHijing_HIJFRG for sHijing HIJFRG truth jets |
Definition at line 51 of file JetHepMCLoader.cc.
View newest version in sPHENIX GitHub at line 51 of file JetHepMCLoader.cc
|
inlineoverride |
Definition at line 47 of file JetHepMCLoader.h.
View newest version in sPHENIX GitHub at line 47 of file JetHepMCLoader.h
void JetHepMCLoader::addJet | ( | const std::string & | name, |
int | embeddingID, | ||
Jet::ALGO | algorithm, | ||
double | parameter, | ||
int | tagPID, | ||
int | tagStatus | ||
) |
addJet add HepMC entries for a particular type of jets Example of adding sHijing HIJFRG truth jets with R=0.4:
[in] | name | name of the jet category |
[in] | embeddingID | hepmc event's embedding ID |
[in] | algorithm | pick one from Jet::ALGO |
[in] | parameter | jet parameter, e.g. radius |
[in] | tagPID | HepMC entry identifying tag on PID |
[in] | tagStatus | HepMC entry identifying tag on status |
Definition at line 206 of file JetHepMCLoader.cc.
View newest version in sPHENIX GitHub at line 206 of file JetHepMCLoader.cc
References algorithm, Jet::ANTIKT, Jet::CAMBRIDGE, Jet::KT, m_jetSrc, and perf_headwind::name.
|
private |
Definition at line 240 of file JetHepMCLoader.cc.
View newest version in sPHENIX GitHub at line 240 of file JetHepMCLoader.cc
References Fun4AllReturnCodes::ABORTRUN, PHCompositeNode::addNode(), Fun4AllReturnCodes::EVENT_OK, PHNodeIterator::findFirst(), m_jetInputCategory, m_jetSrc, and PHWHERE.
Referenced by InitRun().
|
overridevirtual |
Called at the end of all processing.
Reimplemented from SubsysReco.
Definition at line 192 of file JetHepMCLoader.cc.
View newest version in sPHENIX GitHub at line 192 of file JetHepMCLoader.cc
References assert, Fun4AllHistoManager::dumpHistos(), Fun4AllReturnCodes::EVENT_OK, getHistoManager(), m_saveQAPlots, and Fun4AllBase::Name().
|
private |
Definition at line 283 of file JetHepMCLoader.cc.
View newest version in sPHENIX GitHub at line 283 of file JetHepMCLoader.cc
References assert, Fun4AllServer::getHistoManager(), Fun4AllServer::instance(), Fun4AllBase::Name(), and Fun4AllServer::registerHistoManager().
Referenced by End(), InitRun(), and process_event().
|
overridevirtual |
Called for first event when run number is known. Typically this is where you may want to fetch data from database, because you know the run number.
Reimplemented from SubsysReco.
Definition at line 58 of file JetHepMCLoader.cc.
View newest version in sPHENIX GitHub at line 58 of file JetHepMCLoader.cc
References assert, CreateNodes(), getHistoManager(), h, i, m_jetSrc, m_saveQAPlots, and Fun4AllHistoManager::registerHisto().
|
overridevirtual |
Called for each event. This is where you do the real work.
Reimplemented from SubsysReco.
Definition at line 91 of file JetHepMCLoader.cc.
View newest version in sPHENIX GitHub at line 91 of file JetHepMCLoader.cc
References Fun4AllReturnCodes::ABORTEVENT, JetContainer::add_jet(), assert, Fun4AllReturnCodes::DISCARDEVENT, Fun4AllReturnCodes::EVENT_OK, PHHepMCGenEventMap::get(), PHHepMCGenEvent::get_embedding_id(), Jet::get_et(), Jet::get_eta(), PHHepMCGenEvent::getEvent(), Fun4AllHistoManager::getHisto(), getHistoManager(), Jet::HEPMC_IMPORT, PHHepMCGenEvent::identify(), Jet::insert_comp(), JetContainer::insert_src(), m_jetSrc, m_saveQAPlots, merge_hashes::p, PHWHERE, JetContainer::set_algo(), Jet::set_e(), JetContainer::set_par(), Jet::set_px(), Jet::set_py(), Jet::set_pz(), Fun4AllBase::Verbosity(), and Fun4AllBase::VERBOSITY_A_LOT.
|
inline |
Definition at line 72 of file JetHepMCLoader.h.
View newest version in sPHENIX GitHub at line 72 of file JetHepMCLoader.h
References KFPMath::b, and m_saveQAPlots.
|
private |
Definition at line 78 of file JetHepMCLoader.h.
View newest version in sPHENIX GitHub at line 78 of file JetHepMCLoader.h
Referenced by CreateNodes().
|
private |
Definition at line 105 of file JetHepMCLoader.h.
View newest version in sPHENIX GitHub at line 105 of file JetHepMCLoader.h
Referenced by addJet(), CreateNodes(), InitRun(), and process_event().
|
private |
Definition at line 80 of file JetHepMCLoader.h.
View newest version in sPHENIX GitHub at line 80 of file JetHepMCLoader.h
Referenced by End(), InitRun(), process_event(), and saveQAPlots().