Analysis Software
Documentation for sPHENIX simulation software
|
#include <analysis/blob/master/PhotonConversion/truthconversion/TruthConversionEval.h>
Public Member Functions | |
TruthConversionEval (const std::string &name, unsigned int runnumber, int particleEmbed, int pythiaEmbed, bool makeTTree, std::string TMVAName, std::string TMVAPath) | |
~TruthConversionEval () | |
int | InitRun (PHCompositeNode *) |
int | process_event (PHCompositeNode *) |
int | End (PHCompositeNode *) |
Called at the end of all processing. | |
const RawClusterContainer * | getClusters () const |
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 | |
TLorentzVector | tracktoTLV (SvtxTrack *track) |
TLorentzVector | particletoTLV (PHG4Particle *particle) |
bool | doNodePointers (PHCompositeNode *topNode) |
SvtxVertex * | get_primary_vertex (PHCompositeNode *topNode) const |
void | numUnique (std::map< int, Conversion > *map, SvtxTrackEval *trackEval, RawClusterContainer *mainClusterContainer, std::vector< std::pair< SvtxTrack *, SvtxTrack * >> *tightBackground) |
void | processTrackBackground (std::vector< SvtxTrack * > *v, SvtxTrackEval *) |
fills the member fields for all the background trees | |
void | recordConversion (Conversion *conversion, TLorentzVector *tlv_photon, TLorentzVector *tlv_electron, TLorentzVector *tlv_positron) |
int | get_embed (PHG4Particle *particle, PHG4TruthInfoContainer *truthinfo) const |
float | vtoR (PHG4VtxPoint *vtx) const |
Static Private Attributes | |
static const int | s_kMAXParticles =200 |
increase this number if arrays go out of bounds | |
static const int | s_kTPCRADIUS =21 |
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") | |
Definition at line 38 of file TruthConversionEval.h.
View newest version in sPHENIX GitHub at line 38 of file TruthConversionEval.h
TruthConversionEval::TruthConversionEval | ( | const std::string & | name, |
unsigned int | runnumber, | ||
int | particleEmbed, | ||
int | pythiaEmbed, | ||
bool | makeTTree, | ||
std::string | TMVAName, | ||
std::string | TMVAPath | ||
) |
name | name of the output file |
runnumber | printed in TTree for condor jobs |
particleEmbed | the embedID of particles embeded by Fun4All |
pythiaEmbed | the embedID for an embeded pythia event |
makeTTree | true-writes the TTree false-won't make TTree will still find clusters |
Definition at line 53 of file TruthConversionEval.C.
View newest version in sPHENIX GitHub at line 53 of file TruthConversionEval.C
References _foutname, _regressor, and perf_headwind::name.
TruthConversionEval::~TruthConversionEval | ( | ) |
Definition at line 61 of file TruthConversionEval.C.
View newest version in sPHENIX GitHub at line 61 of file TruthConversionEval.C
References _f, _regressor, and _vertexer.
|
private |
Definition at line 179 of file TruthConversionEval.C.
View newest version in sPHENIX GitHub at line 179 of file TruthConversionEval.C
References _allTracks, _clusterMap, _mainClusterContainer, _truthinfo, and Fun4AllBase::Name().
Referenced by process_event().
|
virtual |
Called at the end of all processing.
Reimplemented from SubsysReco.
Definition at line 824 of file TruthConversionEval.C.
View newest version in sPHENIX GitHub at line 824 of file TruthConversionEval.C
References _f, and _kMakeTTree.
|
private |
Definition at line 816 of file TruthConversionEval.C.
View newest version in sPHENIX GitHub at line 816 of file TruthConversionEval.C
References PHG4Particle::get_track_id(), and PHG4TruthInfoContainer::isEmbeded().
Referenced by process_event().
|
private |
Definition at line 207 of file TruthConversionEval.C.
View newest version in sPHENIX GitHub at line 207 of file TruthConversionEval.C
References SvtxVertexMap::get().
const RawClusterContainer * TruthConversionEval::getClusters | ( | ) | const |
get the clusters associated with converions
Definition at line 814 of file TruthConversionEval.C.
View newest version in sPHENIX GitHub at line 814 of file TruthConversionEval.C
References _conversionClusters.
|
virtual |
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 68 of file TruthConversionEval.C.
View newest version in sPHENIX GitHub at line 68 of file TruthConversionEval.C
References _b_allphoton_pT, _b_alltrack_pT, _b_approach, _b_cluster_deta, _b_cluster_dphi, _b_cluster_prob, _b_nMatched, _b_nUnmatched, _b_photon_m, _b_photon_pT, _b_reco_pT, _b_tphoton_m, _b_tphoton_pT, _b_track1_eta, _b_track1_phi, _b_track1_pt, _b_track2_eta, _b_track2_phi, _b_track2_pt, _b_track_dca, _b_track_deta, _b_track_dlayer, _b_track_dphi, _b_track_layer, _b_track_pT, _b_truth_pT, _b_tvtx_eta, _b_tvtx_phi, _b_tvtx_radius, _b_tvtx_x, _b_tvtx_y, _b_tvtx_z, _b_vtx_chi2, _b_vtx_eta, _b_vtx_phi, _b_vtx_radius, _b_vtx_x, _b_vtx_y, _b_vtx_z, _bb_approach, _bb_cluster_deta, _bb_cluster_dphi, _bb_cluster_prob, _bb_parent_pid, _bb_photon_m, _bb_photon_pT, _bb_track1_pid, _bb_track2_pid, _bb_track_dca, _bb_track_deta, _bb_track_dlayer, _bb_track_dphi, _bb_track_layer, _bb_track_pT, _bb_vtx_radius, _f, _foutname, _kMakeTTree, _kRunNumber, _observTree, _pairBackTree, _runNumber, _signalCutTree, _trackBackTree, _vertexer, _vtxBackTree, _vtxingTree, and SVReco::InitRun().
|
private |
helper function for process_event fills the member fields with information from the conversions finds the clusters associated with the truth conversions
Definition at line 341 of file TruthConversionEval.C.
View newest version in sPHENIX GitHub at line 341 of file TruthConversionEval.C
References _kRAPIDITYACCEPT, PHG4Particle::get_e(), PHG4Particle::get_pid(), PHG4Particle::get_px(), PHG4Particle::get_py(), PHG4Particle::get_pz(), PHG4Particle::get_track_id(), i, Fun4AllBase::Name(), recordConversion(), and Fun4AllBase::Verbosity().
Referenced by process_event().
|
inlineprivate |
Definition at line 71 of file TruthConversionEval.h.
View newest version in sPHENIX GitHub at line 71 of file TruthConversionEval.h
References PHG4Particle::get_e(), PHG4Particle::get_px(), PHG4Particle::get_py(), and PHG4Particle::get_pz().
Referenced by process_event().
|
virtual |
Find the conversions pass them to numUnique. Fill the TTree
Reimplemented from SubsysReco.
Definition at line 212 of file TruthConversionEval.C.
View newest version in sPHENIX GitHub at line 212 of file TruthConversionEval.C
References _allTracks, _b_allphoton_pT, _b_alltrack_pT, _b_nMatched, _b_nUnmatched, _b_reco_pT, _b_truth_pT, _conversionClusters, _kMakeTTree, _kTightDetaMax, _kTightPtMin, _mainClusterContainer, _observTree, _truthinfo, _vertexer, Fun4AllReturnCodes::ABORTEVENT, SvtxTrackMap::begin(), SvtxTrackEval::best_track_from(), doNodePointers(), SvtxTrackMap::end(), get_embed(), PHG4VtxPoint::get_id(), SvtxTrack::get_id(), PHG4Particle::get_parent_id(), PHG4Particle::get_pid(), PHG4Particle::get_primary_id(), SvtxTrack::get_pt(), PHG4Particle::get_px(), PHG4Particle::get_py(), SvtxEvalStack::get_track_eval(), PHG4Particle::get_track_id(), PHG4Particle::get_vtx_id(), PHG4VtxPoint::get_x(), PHG4VtxPoint::get_y(), PHG4TruthInfoContainer::GetParticle(), PHG4TruthInfoContainer::GetParticleRange(), PHG4TruthInfoContainer::GetVtx(), grand, PHG4Particle::identify(), SVReco::InitEvent(), Fun4AllBase::Name(), next, numUnique(), particletoTLV(), processTrackBackground(), RawClusterContainer::Reset(), s_kTPCRADIUS, setSourceId(), tracktoTLV(), and Fun4AllBase::Verbosity().
|
private |
fills the member fields for all the background trees
Definition at line 419 of file TruthConversionEval.C.
View newest version in sPHENIX GitHub at line 419 of file TruthConversionEval.C
References _bb_approach, _bb_cluster_deta, _bb_cluster_dphi, _bb_cluster_prob, _bb_nCluster, _bb_photon_m, _bb_photon_pT, _bb_track_dca, _bb_track_deta, _bb_track_dlayer, _bb_track_dphi, _bb_track_layer, _bb_track_pT, _bb_vtx_chi2, _bb_vtx_radius, _bb_vtxTrackRPhi_dist, _bb_vtxTrackRZ_dist, _clusterMap, _kTightDetaMax, _kTightPtMin, _mainClusterContainer, _pairBackTree, _regressor, _trackBackTree, _vertexer, _vtxBackTree, Conversion::approachDistance(), SvtxTrack::begin_cluster_keys(), Conversion::correctSecondaryVertex(), SvtxTrack::end_cluster_keys(), TrkrClusterContainer::findCluster(), SVReco::findSecondaryVertex(), SvtxTrack::get_cal_cluster_id(), SvtxTrack::get_dca(), SvtxTrack::get_eta(), SvtxTrack::get_pt(), genfit::GFRaveVertex::getChi2(), RawClusterContainer::getCluster(), TrkrDefs::getLayer(), genfit::GFRaveVertex::getPos(), Conversion::getRecoPhoton(), next, Conversion::trackDEta(), Conversion::trackDLayer(), Conversion::trackDPhi(), Conversion::vtxTrackRPhi(), and Conversion::vtxTrackRZ().
Referenced by process_event().
|
private |
Definition at line 545 of file TruthConversionEval.C.
View newest version in sPHENIX GitHub at line 545 of file TruthConversionEval.C
References _b_approach, _b_cluster_deta, _b_cluster_dphi, _b_cluster_prob, _b_nCluster, _b_photon_m, _b_photon_pT, _b_tphoton_m, _b_tphoton_pT, _b_track1_eta, _b_track1_phi, _b_track1_pt, _b_track2_eta, _b_track2_phi, _b_track2_pt, _b_track_dca, _b_track_deta, _b_track_dlayer, _b_track_dphi, _b_track_layer, _b_track_pT, _b_ttrack_pT, _b_tvtx_eta, _b_tvtx_phi, _b_tvtx_radius, _b_tvtx_x, _b_tvtx_y, _b_tvtx_z, _b_vtx_chi2, _b_vtx_eta, _b_vtx_phi, _b_vtx_radius, _b_vtx_x, _b_vtx_y, _b_vtx_z, _b_vtxTrackRPhi_dist, _b_vtxTrackRZ_dist, _clusterMap, _kMakeTTree, _mainClusterContainer, _regressor, _signalCutTree, _vertexer, _vtxingTree, Conversion::approachDistance(), RawCluster::CloneMe(), Conversion::correctSecondaryVertex(), Conversion::firstLayer(), Conversion::get_cluster_ids(), RawCluster::get_phi(), RawCluster::get_prob(), PHG4VtxPoint::get_x(), RawCluster::get_x(), PHG4VtxPoint::get_y(), RawCluster::get_y(), PHG4VtxPoint::get_z(), RawCluster::get_z(), genfit::GFRaveVertex::getChi2(), RawClusterContainer::getCluster(), genfit::GFRaveVertex::getPos(), Conversion::getRecoPhoton(), Conversion::getRefitRecoPhoton(), Conversion::getSecondaryVertex(), Conversion::getTrackEtas(), Conversion::getTrackPhis(), Conversion::getTrackpTs(), Conversion::getVtx(), Conversion::minDca(), Conversion::minTrackpT(), Conversion::PrintPhotonRecoInfo(), Conversion::recoCount(), Conversion::trackDEta(), Conversion::trackDLayer(), Conversion::trackDPhi(), Conversion::vtxTrackRPhi(), and Conversion::vtxTrackRZ().
Referenced by numUnique().
|
inlineprivate |
Definition at line 65 of file TruthConversionEval.h.
View newest version in sPHENIX GitHub at line 65 of file TruthConversionEval.h
References SvtxTrack::get_eta(), SvtxTrack::get_phi(), SvtxTrack::get_pt(), and physmon_track_finding_ttbar::r.
Referenced by process_event().
|
private |
Definition at line 820 of file TruthConversionEval.C.
View newest version in sPHENIX GitHub at line 820 of file TruthConversionEval.C
References PHG4VtxPoint::get_x(), and PHG4VtxPoint::get_y().
|
private |
Definition at line 103 of file TruthConversionEval.h.
View newest version in sPHENIX GitHub at line 103 of file TruthConversionEval.h
Referenced by doNodePointers(), and process_event().
|
private |
Definition at line 102 of file TruthConversionEval.h.
View newest version in sPHENIX GitHub at line 102 of file TruthConversionEval.h
Referenced by doNodePointers(), processTrackBackground(), and recordConversion().
|
private |
RawClusters associated with truth conversions processed by other modules currently empty
Definition at line 185 of file TruthConversionEval.h.
View newest version in sPHENIX GitHub at line 185 of file TruthConversionEval.h
Referenced by getClusters(), and process_event().
|
private |
output file
Definition at line 93 of file TruthConversionEval.h.
View newest version in sPHENIX GitHub at line 93 of file TruthConversionEval.h
Referenced by End(), InitRun(), and ~TruthConversionEval().
|
private |
name of the output file
Definition at line 105 of file TruthConversionEval.h.
View newest version in sPHENIX GitHub at line 105 of file TruthConversionEval.h
Referenced by InitRun(), and TruthConversionEval().
|
private |
Definition at line 104 of file TruthConversionEval.h.
View newest version in sPHENIX GitHub at line 104 of file TruthConversionEval.h
|
private |
Definition at line 91 of file TruthConversionEval.h.
View newest version in sPHENIX GitHub at line 91 of file TruthConversionEval.h
Referenced by End(), InitRun(), process_event(), and recordConversion().
|
private |
primary embedID
Definition at line 89 of file TruthConversionEval.h.
View newest version in sPHENIX GitHub at line 89 of file TruthConversionEval.h
|
private |
background event embedID i.e. pythia or AA
Definition at line 90 of file TruthConversionEval.h.
View newest version in sPHENIX GitHub at line 90 of file TruthConversionEval.h
|
private |
<TPC radius currently hardcoded
Definition at line 189 of file TruthConversionEval.h.
View newest version in sPHENIX GitHub at line 189 of file TruthConversionEval.h
Referenced by numUnique().
|
private |
Definition at line 88 of file TruthConversionEval.h.
View newest version in sPHENIX GitHub at line 88 of file TruthConversionEval.h
Referenced by InitRun().
|
private |
Definition at line 191 of file TruthConversionEval.h.
View newest version in sPHENIX GitHub at line 191 of file TruthConversionEval.h
Referenced by process_event(), and processTrackBackground().
|
private |
Definition at line 190 of file TruthConversionEval.h.
View newest version in sPHENIX GitHub at line 190 of file TruthConversionEval.h
Referenced by process_event(), and processTrackBackground().
|
private |
Definition at line 100 of file TruthConversionEval.h.
View newest version in sPHENIX GitHub at line 100 of file TruthConversionEval.h
Referenced by doNodePointers(), process_event(), processTrackBackground(), and recordConversion().
|
private |
per event observables
Definition at line 99 of file TruthConversionEval.h.
View newest version in sPHENIX GitHub at line 99 of file TruthConversionEval.h
Referenced by InitRun(), and process_event().
|
private |
background for all possible track pairs
Definition at line 96 of file TruthConversionEval.h.
View newest version in sPHENIX GitHub at line 96 of file TruthConversionEval.h
Referenced by InitRun(), and processTrackBackground().
|
private |
for reco vertex correction with TMVA
Definition at line 107 of file TruthConversionEval.h.
View newest version in sPHENIX GitHub at line 107 of file TruthConversionEval.h
Referenced by processTrackBackground(), recordConversion(), TruthConversionEval(), and ~TruthConversionEval().
|
private |
for the TTree do not change
Definition at line 92 of file TruthConversionEval.h.
View newest version in sPHENIX GitHub at line 92 of file TruthConversionEval.h
Referenced by InitRun().
|
private |
signal data for making track pair cuts
Definition at line 94 of file TruthConversionEval.h.
View newest version in sPHENIX GitHub at line 94 of file TruthConversionEval.h
Referenced by InitRun(), and recordConversion().
|
private |
background for all possible single tracks
Definition at line 95 of file TruthConversionEval.h.
View newest version in sPHENIX GitHub at line 95 of file TruthConversionEval.h
Referenced by InitRun(), and processTrackBackground().
|
private |
Definition at line 101 of file TruthConversionEval.h.
View newest version in sPHENIX GitHub at line 101 of file TruthConversionEval.h
Referenced by doNodePointers(), and process_event().
|
private |
for reco vertex finding
Definition at line 106 of file TruthConversionEval.h.
View newest version in sPHENIX GitHub at line 106 of file TruthConversionEval.h
Referenced by InitRun(), process_event(), processTrackBackground(), recordConversion(), and ~TruthConversionEval().
|
private |
background that passes existing track pair cuts
Definition at line 97 of file TruthConversionEval.h.
View newest version in sPHENIX GitHub at line 97 of file TruthConversionEval.h
Referenced by InitRun(), and processTrackBackground().
|
private |
data for training vtxing
Definition at line 98 of file TruthConversionEval.h.
View newest version in sPHENIX GitHub at line 98 of file TruthConversionEval.h
Referenced by InitRun(), and recordConversion().
|
staticprivate |
increase this number if arrays go out of bounds
Definition at line 87 of file TruthConversionEval.h.
View newest version in sPHENIX GitHub at line 87 of file TruthConversionEval.h
|
staticprivate |
Definition at line 187 of file TruthConversionEval.h.
View newest version in sPHENIX GitHub at line 187 of file TruthConversionEval.h
Referenced by process_event().