Analysis Software
Documentation for sPHENIX simulation software
|
#include <coresoftware/blob/master/offline/packages/KFParticle_sPHENIX/KFParticle_eventReconstruction.h>
Public Member Functions | |
KFParticle_eventReconstruction () | |
KFParticle constructor. | |
~KFParticle_eventReconstruction () override=default | |
void | createDecay (PHCompositeNode *topNode, std::vector< KFParticle > &selectedMother, std::vector< KFParticle > &selectedVertex, std::vector< std::vector< KFParticle >> &selectedDaughters, std::vector< std::vector< KFParticle >> &selectedIntermediates, int &nPVs, int &multiplicity) |
void | buildBasicChain (std::vector< KFParticle > &selectedMotherBasic, std::vector< KFParticle > &selectedVertexBasic, std::vector< std::vector< KFParticle >> &selectedDaughtersBasic, const std::vector< KFParticle > &daughterParticlesBasic, const std::vector< int > &goodTrackIndexBasic, const std::vector< KFParticle > &primaryVerticesBasic) |
Used to reconstruct simple decays with no intermediate states. | |
void | buildChain (std::vector< KFParticle > &selectedMotherAdv, std::vector< KFParticle > &selectedVertexAdv, std::vector< std::vector< KFParticle >> &selectedDaughtersAdv, std::vector< std::vector< KFParticle >> &selectedIntermediatesAdv, const std::vector< KFParticle > &daughterParticlesAdv, const std::vector< int > &goodTrackIndexAdv, const std::vector< KFParticle > &primaryVerticesAdv) |
Used to reconstruct more complicated decays with up to four intermediate states. | |
void | getCandidateDecay (std::vector< KFParticle > &selectedMotherCand, std::vector< KFParticle > &selectedVertexCand, std::vector< std::vector< KFParticle >> &selectedDaughtersCand, std::vector< KFParticle > daughterParticlesCand, std::vector< std::vector< int >> goodTracksThatMeetCand, std::vector< KFParticle > primaryVerticesCand, int n_track_start, int n_track_stop, bool isIntermediate, int intermediateNumber, bool constrainMass) |
Basic building block for event reconstruction and selection. | |
int | selectBestCombination (bool PVconstraint, bool isAnInterMother, std::vector< KFParticle > possibleCandidates, std::vector< KFParticle > possibleVertex) |
Method to chose best candidate from a selection of common SV's. | |
KFParticle | createFakePV () |
Public Member Functions inherited from KFParticle_Tools | |
KFParticle_Tools () | |
KFParticle constructor. | |
~KFParticle_Tools () override=default | |
KFParticle | makeVertex (PHCompositeNode *topNode) |
std::vector< KFParticle > | makeAllPrimaryVertices (PHCompositeNode *topNode, const std::string &vertexMapName) |
KFParticle | makeParticle (PHCompositeNode *topNode) |
Return a KFPTrack from track vector and covariance matrix. No mass or vertex constraints. | |
std::vector< KFParticle > | makeAllDaughterParticles (PHCompositeNode *topNode) |
int | getTracksFromVertex (PHCompositeNode *topNode, const KFParticle &vertex, const std::string &vertexMapName) |
bool | isGoodTrack (const KFParticle &particle, const std::vector< KFParticle > &primaryVertices) |
int | calcMinIP (const KFParticle &track, const std::vector< KFParticle > &PVs, float &minimumIP, float &minimumIPchi2) |
std::vector< int > | findAllGoodTracks (std::vector< KFParticle > daughterParticles, const std::vector< KFParticle > &primaryVertices) |
std::vector< std::vector< int > > | findTwoProngs (std::vector< KFParticle > daughterParticles, std::vector< int > goodTrackIndex, int nTracks) |
std::vector< std::vector< int > > | findNProngs (std::vector< KFParticle > daughterParticles, const std::vector< int > &goodTrackIndex, std::vector< std::vector< int >> goodTracksThatMeet, int nRequiredTracks, unsigned int nProngs) |
std::vector< std::vector< int > > | appendTracksToIntermediates (KFParticle intermediateResonances[], std::vector< KFParticle > daughterParticles, const std::vector< int > &goodTrackIndex, int num_remaining_tracks) |
float | eventDIRA (const KFParticle &particle, const KFParticle &vertex) |
Calculates the cosine of the angle betweent the flight direction and momentum. | |
float | flightDistanceChi2 (const KFParticle &particle, const KFParticle &vertex) |
std::tuple< KFParticle, bool > | buildMother (KFParticle vDaughters[], std::string daughterOrder[], bool isIntermediate, int intermediateNumber, int nTracks, bool constrainMass, float required_vertexID) |
void | constrainToVertex (KFParticle &particle, bool &goodCandidate, KFParticle &vertex) |
std::tuple< KFParticle, bool > | getCombination (KFParticle vDaughters[], std::string daughterOrder[], KFParticle vertex, bool constrain_to_vertex, bool isIntermediate, int intermediateNumber, int nTracks, bool constrainMass, float required_vertexID) |
std::vector< std::vector < std::string > > | findUniqueDaughterCombinations (int start, int end) |
double | calculateEllipsoidRadius (int posOrNeg, double sigma_ii, double sigma_jj, double sigma_ij) |
float | calculateEllipsoidVolume (const KFParticle &particle) |
float | calculateJT (const KFParticle &mother, const KFParticle &daughter) |
bool | isInRange (float min, float value, float max) |
bool | findParticle (const std::string &particle) |
int | getParticleID (const std::string &particle) |
float | getParticleMass (const std::string &particle) |
float | getParticleMass (const int PDGID) |
void | identify (const KFParticle &particle) |
Additional Inherited Members | |
Protected Member Functions inherited from KFParticle_MVA | |
KFParticle_MVA ()=default | |
virtual | ~KFParticle_MVA ()=default |
std::tuple< TMVA::Reader *, std::vector< Float_t > > | initMVA () |
Float_t | evaluateMVA (TMVA::Reader *reader, std::vector< Float_t > reader_floats, const KFParticle &particle, const KFPVertex &vertex) |
Definition at line 33 of file KFParticle_eventReconstruction.h.
View newest version in sPHENIX GitHub at line 33 of file KFParticle_eventReconstruction.h
KFParticle_eventReconstruction::KFParticle_eventReconstruction | ( | ) |
KFParticle constructor.
Definition at line 47 of file KFParticle_eventReconstruction.cc.
View newest version in sPHENIX GitHub at line 47 of file KFParticle_eventReconstruction.cc
|
overridedefault |
void KFParticle_eventReconstruction::buildBasicChain | ( | std::vector< KFParticle > & | selectedMotherBasic, |
std::vector< KFParticle > & | selectedVertexBasic, | ||
std::vector< std::vector< KFParticle >> & | selectedDaughtersBasic, | ||
const std::vector< KFParticle > & | daughterParticlesBasic, | ||
const std::vector< int > & | goodTrackIndexBasic, | ||
const std::vector< KFParticle > & | primaryVerticesBasic | ||
) |
Used to reconstruct simple decays with no intermediate states.
Definition at line 89 of file KFParticle_eventReconstruction.cc.
View newest version in sPHENIX GitHub at line 89 of file KFParticle_eventReconstruction.cc
References KFParticle_Tools::findNProngs(), KFParticle_Tools::findTwoProngs(), getCandidateDecay(), KFParticle_Tools::m_num_tracks, and merge_hashes::p.
Referenced by createDecay().
void KFParticle_eventReconstruction::buildChain | ( | std::vector< KFParticle > & | selectedMotherAdv, |
std::vector< KFParticle > & | selectedVertexAdv, | ||
std::vector< std::vector< KFParticle >> & | selectedDaughtersAdv, | ||
std::vector< std::vector< KFParticle >> & | selectedIntermediatesAdv, | ||
const std::vector< KFParticle > & | daughterParticlesAdv, | ||
const std::vector< int > & | goodTrackIndexAdv, | ||
const std::vector< KFParticle > & | primaryVerticesAdv | ||
) |
Used to reconstruct more complicated decays with up to four intermediate states.
Definition at line 109 of file KFParticle_eventReconstruction.cc.
View newest version in sPHENIX GitHub at line 109 of file KFParticle_eventReconstruction.cc
References KFPMath::a, KFParticle_Tools::appendTracksToIntermediates(), assert, KFPMath::b, parse_cmake_options::begin, Acts::PhysicalConstants::c, KFParticle::Chi2(), KFParticle::Create(), distance(), end, KFParticle_Tools::findNProngs(), KFParticle_Tools::findTwoProngs(), KFParticle_Tools::findUniqueDaughterCombinations(), getCandidateDecay(), KFParticle::GetChi2(), KFParticle_Tools::getCombination(), KFParticle::GetNDF(), KFParticle_Tools::getParticleID(), KFParticle_Tools::getParticleMass(), GetQ(), i, Id(), it, j, k, Acts::UnitConstants::m, m_constrain_int_mass, m_constrain_to_vertex, KFParticle_Tools::m_daughter_charge, KFParticle_Tools::m_daughter_name, KFParticle_Tools::m_intermediate_charge, KFParticle_Tools::m_intermediate_name, KFParticle_Tools::m_num_intermediate_states, KFParticle_Tools::m_num_tracks, KFParticle_Tools::m_num_tracks_from_intermediate, n, KFParticle::NDF(), merge_hashes::p, particles, selectBestCombination(), KFParticleBase::SetId(), KFParticleBase::SetPDG(), and ActsExamples::HepMC3Event::vertices().
Referenced by createDecay().
void KFParticle_eventReconstruction::createDecay | ( | PHCompositeNode * | topNode, |
std::vector< KFParticle > & | selectedMother, | ||
std::vector< KFParticle > & | selectedVertex, | ||
std::vector< std::vector< KFParticle >> & | selectedDaughters, | ||
std::vector< std::vector< KFParticle >> & | selectedIntermediates, | ||
int & | nPVs, | ||
int & | multiplicity | ||
) |
Starts the reconstruction chain
selectedMother | Input a vector and it will be filled with any mother candidates |
selectedVertex | Input a vector and it will be filled with the production vertex associated to your mother |
selectedDaughters | Input a vector and it will be filled with any tracks associated to your mother |
selectedIntermediates | Input a vector and it will be filled with any intermediate states associated to your mother |
Definition at line 54 of file KFParticle_eventReconstruction.cc.
View newest version in sPHENIX GitHub at line 54 of file KFParticle_eventReconstruction.cc
References buildBasicChain(), buildChain(), createFakePV(), KFParticle_Tools::findAllGoodTracks(), KFParticle_Tools::m_has_intermediates, m_use_fake_pv, KFParticle_Tools::m_vtx_map_node_name, KFParticle_Tools::makeAllDaughterParticles(), and KFParticle_Tools::makeAllPrimaryVertices().
Referenced by KFParticle_sPHENIX::process_event().
KFParticle KFParticle_eventReconstruction::createFakePV | ( | ) |
Definition at line 455 of file KFParticle_eventReconstruction.cc.
View newest version in sPHENIX GitHub at line 455 of file KFParticle_eventReconstruction.cc
References KFParticle::Chi2(), KFParticle::Create(), KFParticle::NDF(), and KFParticleBase::SetId().
Referenced by createDecay().
void KFParticle_eventReconstruction::getCandidateDecay | ( | std::vector< KFParticle > & | selectedMotherCand, |
std::vector< KFParticle > & | selectedVertexCand, | ||
std::vector< std::vector< KFParticle >> & | selectedDaughtersCand, | ||
std::vector< KFParticle > | daughterParticlesCand, | ||
std::vector< std::vector< int >> | goodTracksThatMeetCand, | ||
std::vector< KFParticle > | primaryVerticesCand, | ||
int | n_track_start, | ||
int | n_track_stop, | ||
bool | isIntermediate, | ||
int | intermediateNumber, | ||
bool | constrainMass | ||
) |
Basic building block for event reconstruction and selection.
Definition at line 327 of file KFParticle_eventReconstruction.cc.
View newest version in sPHENIX GitHub at line 327 of file KFParticle_eventReconstruction.cc
References KFParticle_Tools::calcMinIP(), KFParticle::Chi2(), KFParticle::Create(), KFParticle_Tools::findUniqueDaughterCombinations(), KFParticle::GetChi2(), KFParticle_Tools::getCombination(), KFParticle::GetNDF(), KFParticle_Tools::getParticleID(), KFParticle_Tools::getParticleMass(), GetQ(), i, Id(), KFParticle_Tools::isInRange(), j, m_constrain_to_vertex, KFParticle_Tools::m_daughter_charge, KFParticle_Tools::m_daughter_name, KFParticle_Tools::m_intermediate_max_ip, KFParticle_Tools::m_intermediate_max_ipchi2, KFParticle_Tools::m_intermediate_min_ip, KFParticle_Tools::m_intermediate_min_ipchi2, TauVsDIS_MachineLearning_Differentiation::names, KFParticle::NDF(), particles, selectBestCombination(), KFParticleBase::SetId(), and KFParticleBase::SetPDG().
Referenced by buildBasicChain(), and buildChain().
int KFParticle_eventReconstruction::selectBestCombination | ( | bool | PVconstraint, |
bool | isAnInterMother, | ||
std::vector< KFParticle > | possibleCandidates, | ||
std::vector< KFParticle > | possibleVertex | ||
) |
Method to chose best candidate from a selection of common SV's.
Definition at line 425 of file KFParticle_eventReconstruction.cc.
View newest version in sPHENIX GitHub at line 425 of file KFParticle_eventReconstruction.cc
References KFParticleBase::GetDeviationFromVertex(), GetDeviationFromVertex(), KFParticle::GetErrMass(), and i.
Referenced by buildChain(), and getCandidateDecay().
|
protected |
Definition at line 89 of file KFParticle_eventReconstruction.h.
View newest version in sPHENIX GitHub at line 89 of file KFParticle_eventReconstruction.h
Referenced by buildChain(), and KFParticle_sPHENIX::constrainIntermediateMasses().
|
protected |
Definition at line 88 of file KFParticle_eventReconstruction.h.
View newest version in sPHENIX GitHub at line 88 of file KFParticle_eventReconstruction.h
Referenced by buildChain(), KFParticle_sPHENIX::constrainToPrimaryVertex(), and getCandidateDecay().
|
protected |
Definition at line 90 of file KFParticle_eventReconstruction.h.
View newest version in sPHENIX GitHub at line 90 of file KFParticle_eventReconstruction.h
Referenced by createDecay(), KFParticle_sPHENIX::process_event(), and KFParticle_sPHENIX::useFakePrimaryVertex().