Analysis Software
Documentation for sPHENIX simulation software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
TemplateCreation Class Reference

#include <analysis/blob/master/TemplateCreation/src/TemplateCreation.h>

+ Inheritance diagram for TemplateCreation:
+ Collaboration diagram for TemplateCreation:

Public Member Functions

 TemplateCreation (const std::string &name="TemplateCreation")
 
 ~TemplateCreation () override
 
int Init (PHCompositeNode *topNode) override
 
int InitRun (PHCompositeNode *topNode) override
 
int process_event (PHCompositeNode *topNode) override
 
int ResetEvent (PHCompositeNode *topNode) override
 Clean up after each event.
 
int EndRun (const int runnumber) override
 Called at the end of each run.
 
int End (PHCompositeNode *topNode) override
 Called at the end of all processing.
 
int Reset (PHCompositeNode *) override
 Reset.
 
void set_outfile (std::string outfilename)
 
void set_nsamples (int samples)
 
void set_packetrange (int lowpacket, int highpacket)
 
- Public Member Functions inherited from SubsysReco
 ~SubsysReco () override
 
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

double rising_shape (double *x, double *par)
 

Private Attributes

std::string s_outfilename
 
TProfile * hp_all_particle_fine
 
TH2D * h2_all_particle_fine
 
int nsamples
 
int m_packet_low
 
int m_packet_high
 
int m_nchannels
 
double target_hm
 
int binscale = 8
 

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")
 

Detailed Description

Definition at line 13 of file TemplateCreation.h.

View newest version in sPHENIX GitHub at line 13 of file TemplateCreation.h

Constructor & Destructor Documentation

TemplateCreation::TemplateCreation ( const std::string &  name = "TemplateCreation")

Definition at line 43 of file TemplateCreation.cc.

View newest version in sPHENIX GitHub at line 43 of file TemplateCreation.cc

TemplateCreation::~TemplateCreation ( )
override

Definition at line 55 of file TemplateCreation.cc.

View newest version in sPHENIX GitHub at line 55 of file TemplateCreation.cc

Member Function Documentation

int TemplateCreation::End ( PHCompositeNode )
overridevirtual

Called at the end of all processing.

Reimplemented from SubsysReco.

Definition at line 203 of file TemplateCreation.cc.

View newest version in sPHENIX GitHub at line 203 of file TemplateCreation.cc

References PHTFileServer::cd(), Fun4AllReturnCodes::EVENT_OK, PHTFileServer::get(), h2_all_particle_fine, hp_all_particle_fine, i, and s_outfilename.

+ Here is the call graph for this function:

int TemplateCreation::EndRun ( const int  )
overridevirtual

Called at the end of each run.

Reimplemented from SubsysReco.

Definition at line 197 of file TemplateCreation.cc.

View newest version in sPHENIX GitHub at line 197 of file TemplateCreation.cc

References Fun4AllReturnCodes::EVENT_OK.

int TemplateCreation::Init ( PHCompositeNode )
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 60 of file TemplateCreation.cc.

View newest version in sPHENIX GitHub at line 60 of file TemplateCreation.cc

References binscale, Fun4AllReturnCodes::EVENT_OK, PHTFileServer::get(), h2_all_particle_fine, hp_all_particle_fine, nsamples, PHTFileServer::open(), and s_outfilename.

+ Here is the call graph for this function:

int TemplateCreation::InitRun ( PHCompositeNode )
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 69 of file TemplateCreation.cc.

View newest version in sPHENIX GitHub at line 69 of file TemplateCreation.cc

References Fun4AllReturnCodes::EVENT_OK.

int TemplateCreation::process_event ( PHCompositeNode )
overridevirtual

Called for each event. This is where you do the real work.

special event where we do not read out the calorimeters

Reimplemented from SubsysReco.

Definition at line 75 of file TemplateCreation.cc.

View newest version in sPHENIX GitHub at line 75 of file TemplateCreation.cc

References binscale, channel(), Fun4AllReturnCodes::DISCARDEVENT, Fun4AllReturnCodes::EVENT_OK, Event::getEvtType(), Event::getPacket(), h2_all_particle_fine, hp_all_particle_fine, i, Packet::iValue(), j, k, m_nchannels, m_packet_high, m_packet_low, nsamples, pedestal(), train_ambiguity_solver::pid, rising_shape(), sum(), and target_hm.

+ Here is the call graph for this function:

int TemplateCreation::Reset ( PHCompositeNode )
overridevirtual

Reset.

Reimplemented from SubsysReco.

Definition at line 229 of file TemplateCreation.cc.

View newest version in sPHENIX GitHub at line 229 of file TemplateCreation.cc

References Fun4AllReturnCodes::EVENT_OK.

int TemplateCreation::ResetEvent ( PHCompositeNode )
overridevirtual

Clean up after each event.

Reimplemented from SubsysReco.

Definition at line 191 of file TemplateCreation.cc.

View newest version in sPHENIX GitHub at line 191 of file TemplateCreation.cc

References Fun4AllReturnCodes::EVENT_OK.

double TemplateCreation::rising_shape ( double x,
double par 
)
private

Definition at line 32 of file TemplateCreation.cc.

View newest version in sPHENIX GitHub at line 32 of file TemplateCreation.cc

References width, and ambiguity_solver_full_chain::x.

Referenced by process_event().

+ Here is the caller graph for this function:

void TemplateCreation::set_nsamples ( int  samples)
inline

Definition at line 34 of file TemplateCreation.h.

View newest version in sPHENIX GitHub at line 34 of file TemplateCreation.h

References nsamples.

void TemplateCreation::set_outfile ( std::string  outfilename)
inline

Definition at line 30 of file TemplateCreation.h.

View newest version in sPHENIX GitHub at line 30 of file TemplateCreation.h

References s_outfilename.

void TemplateCreation::set_packetrange ( int  lowpacket,
int  highpacket 
)
inline

Definition at line 39 of file TemplateCreation.h.

View newest version in sPHENIX GitHub at line 39 of file TemplateCreation.h

References m_packet_high, and m_packet_low.

Member Data Documentation

int TemplateCreation::binscale = 8
private

Definition at line 57 of file TemplateCreation.h.

View newest version in sPHENIX GitHub at line 57 of file TemplateCreation.h

Referenced by Init(), and process_event().

TH2D* TemplateCreation::h2_all_particle_fine
private

Definition at line 51 of file TemplateCreation.h.

View newest version in sPHENIX GitHub at line 51 of file TemplateCreation.h

Referenced by End(), Init(), and process_event().

TProfile* TemplateCreation::hp_all_particle_fine
private

Definition at line 50 of file TemplateCreation.h.

View newest version in sPHENIX GitHub at line 50 of file TemplateCreation.h

Referenced by End(), Init(), and process_event().

int TemplateCreation::m_nchannels
private

Definition at line 55 of file TemplateCreation.h.

View newest version in sPHENIX GitHub at line 55 of file TemplateCreation.h

Referenced by process_event().

int TemplateCreation::m_packet_high
private

Definition at line 54 of file TemplateCreation.h.

View newest version in sPHENIX GitHub at line 54 of file TemplateCreation.h

Referenced by process_event(), and set_packetrange().

int TemplateCreation::m_packet_low
private

Definition at line 53 of file TemplateCreation.h.

View newest version in sPHENIX GitHub at line 53 of file TemplateCreation.h

Referenced by process_event(), and set_packetrange().

int TemplateCreation::nsamples
private

Definition at line 52 of file TemplateCreation.h.

View newest version in sPHENIX GitHub at line 52 of file TemplateCreation.h

Referenced by Init(), process_event(), and set_nsamples().

std::string TemplateCreation::s_outfilename
private

Definition at line 49 of file TemplateCreation.h.

View newest version in sPHENIX GitHub at line 49 of file TemplateCreation.h

Referenced by End(), Init(), and set_outfile().

double TemplateCreation::target_hm
private

Definition at line 56 of file TemplateCreation.h.

View newest version in sPHENIX GitHub at line 56 of file TemplateCreation.h

Referenced by process_event().


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