ECCE @ EIC Software
Reference for
ECCE @ EIC
simulation and reconstruction software on GitHub
|
#include <coresoftware/blob/master/offline/packages/trackreco/PHSimpleVertexFinder.h>
Public Member Functions | |
PHSimpleVertexFinder (const std::string &name="PHSimpleVertexFinder") | |
Tracking includes. | |
~PHSimpleVertexFinder () 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 | setBeamLineCut (const double cut) |
void | setDcaCut (const double cut) |
void | setTrackQualityCut (double cut) |
void | setRequireMVTX (bool set) |
void | setNmvtxRequired (unsigned int n) |
void | setOutlierPairCut (const double cut) |
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 Types | |
using | matrix_t = Eigen::Matrix< double, 3, 3 > |
Private Member Functions | |
int | GetNodes (PHCompositeNode *topNode) |
int | CreateNodes (PHCompositeNode *topNode) |
void | checkDCAs () |
void | findDcaTwoTracks (SvtxTrack *tr1, SvtxTrack *tr2) |
double | dcaTwoLines (const Eigen::Vector3d &p1, const Eigen::Vector3d &v1, const Eigen::Vector3d &p2, const Eigen::Vector3d &v2, Eigen::Vector3d &PCA1, Eigen::Vector3d &PCA2) |
std::vector< std::set < unsigned int > > | findConnectedTracks () |
void | removeOutlierTrackPairs () |
double | getMedian (std::vector< double > &v) |
double | getAverage (std::vector< double > &v) |
Private Attributes | |
SvtxTrackMap * | _track_map {nullptr} |
SvtxTrack * | _track {nullptr} |
SvtxVertexMap * | _svtx_vertex_map {nullptr} |
double | _dcacut = 0.0080 |
double | _beamline_xy_cut = 0.2 |
double | _qual_cut = 5.0 |
bool | _require_mvtx = true |
unsigned int | _nmvtx_required = 3 |
double | _track_pt_cut = 0.0 |
double | _outlier_cut = 0.015 |
std::multimap< unsigned int, unsigned int > | _vertex_track_map |
std::multimap< unsigned int, std::pair< unsigned int, double > > | _track_pair_map |
std::multimap< unsigned int, std::pair< unsigned int, std::pair< Eigen::Vector3d, Eigen::Vector3d > > > | _track_pair_pca_map |
std::map< unsigned int, Eigen::Vector3d > | _vertex_position_map |
std::map< unsigned int, matrix_t > | _vertex_covariance_map |
std::set< unsigned int > | _vertex_set |
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 = INT_MAX - 10 } |
Protected Member Functions inherited from SubsysReco | |
SubsysReco (const std::string &name="NONAME") | |
Definition at line 29 of file PHSimpleVertexFinder.h.
View newest version in sPHENIX GitHub at line 29 of file PHSimpleVertexFinder.h
|
private |
Definition at line 77 of file PHSimpleVertexFinder.h.
View newest version in sPHENIX GitHub at line 77 of file PHSimpleVertexFinder.h
PHSimpleVertexFinder::PHSimpleVertexFinder | ( | const std::string & | name = "PHSimpleVertexFinder" | ) |
Tracking includes.
Definition at line 40 of file PHSimpleVertexFinder.cc.
View newest version in sPHENIX GitHub at line 40 of file PHSimpleVertexFinder.cc
|
override |
Definition at line 47 of file PHSimpleVertexFinder.cc.
View newest version in sPHENIX GitHub at line 47 of file PHSimpleVertexFinder.cc
|
private |
Definition at line 275 of file PHSimpleVertexFinder.cc.
View newest version in sPHENIX GitHub at line 275 of file PHSimpleVertexFinder.cc
References _nmvtx_required, _qual_cut, _require_mvtx, _track_map, SvtxTrackMap::begin(), SvtxTrackMap::end(), findDcaTwoTracks(), TrkrDefs::getTrkrId(), TrkrDefs::mvtxId, and Fun4AllBase::Verbosity().
Referenced by process_event().
|
private |
Check that it is there
Get the tracking subnode
Definition at line 224 of file PHSimpleVertexFinder.cc.
View newest version in sPHENIX GitHub at line 224 of file PHSimpleVertexFinder.cc
References _svtx_vertex_map, PHCompositeNode::addNode(), Fun4AllReturnCodes::EVENT_OK, and PHNodeIterator::findFirst().
Referenced by InitRun().
|
private |
Definition at line 370 of file PHSimpleVertexFinder.cc.
View newest version in sPHENIX GitHub at line 370 of file PHSimpleVertexFinder.cc
References c, d, F, G, X, and Y.
Referenced by findDcaTwoTracks().
|
overridevirtual |
Called at the end of all processing.
Reimplemented from SubsysReco.
Definition at line 219 of file PHSimpleVertexFinder.cc.
View newest version in sPHENIX GitHub at line 219 of file PHSimpleVertexFinder.cc
References Fun4AllReturnCodes::EVENT_OK.
|
private |
Definition at line 428 of file PHSimpleVertexFinder.cc.
View newest version in sPHENIX GitHub at line 428 of file PHSimpleVertexFinder.cc
References _track_pair_map, it, and Fun4AllBase::Verbosity().
Referenced by process_event().
Definition at line 330 of file PHSimpleVertexFinder.cc.
View newest version in sPHENIX GitHub at line 330 of file PHSimpleVertexFinder.cc
References _beamline_xy_cut, _dcacut, _track_pair_map, _track_pair_pca_map, _track_pt_cut, dcaTwoLines(), SvtxTrack::get_id(), SvtxTrack::get_p(), SvtxTrack::get_pt(), SvtxTrack::get_px(), SvtxTrack::get_py(), SvtxTrack::get_pz(), SvtxTrack::get_x(), SvtxTrack::get_y(), SvtxTrack::get_z(), and Fun4AllBase::Verbosity().
Referenced by checkDCAs().
|
private |
Definition at line 646 of file PHSimpleVertexFinder.cc.
View newest version in sPHENIX GitHub at line 646 of file PHSimpleVertexFinder.cc
References it, and Fun4AllBase::Verbosity().
Referenced by removeOutlierTrackPairs().
|
private |
Definition at line 613 of file PHSimpleVertexFinder.cc.
View newest version in sPHENIX GitHub at line 613 of file PHSimpleVertexFinder.cc
References m, m2, and Fun4AllBase::Verbosity().
Referenced by removeOutlierTrackPairs().
|
private |
Definition at line 260 of file PHSimpleVertexFinder.cc.
View newest version in sPHENIX GitHub at line 260 of file PHSimpleVertexFinder.cc
References _track_map, Fun4AllReturnCodes::ABORTEVENT, Fun4AllReturnCodes::EVENT_OK, and PHWHERE.
Referenced by InitRun().
|
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 53 of file PHSimpleVertexFinder.cc.
View newest version in sPHENIX GitHub at line 53 of file PHSimpleVertexFinder.cc
References CreateNodes(), Fun4AllReturnCodes::EVENT_OK, and GetNodes().
|
overridevirtual |
Called for each event. This is where you do the real work.
If we didn't find any matches, try again with a slightly larger DCA cut
Iterate through the tracks and assign the closest vtx id to the track position for propagating back to the vtx. Catches any tracks that were missed or were not compatible with any of the identified vertices
If there is a vertex already assigned, keep going
Reimplemented from SubsysReco.
Definition at line 63 of file PHSimpleVertexFinder.cc.
View newest version in sPHENIX GitHub at line 63 of file PHSimpleVertexFinder.cc
References _dcacut, _svtx_vertex_map, _track_map, _track_pair_map, _track_pair_pca_map, _vertex_covariance_map, _vertex_position_map, _vertex_set, _vertex_track_map, checkDCAs(), SvtxVertexMap::clear(), dz, Fun4AllReturnCodes::EVENT_OK, findConnectedTracks(), SvtxVertexMap::get(), SvtxTrackMap::get(), SvtxVertexMap::insert(), it, max, PHWHERE, pos(), removeOutlierTrackPairs(), SvtxTrack::set_vertex_id(), SvtxTrackMap::size(), track, and Fun4AllBase::Verbosity().
|
private |
Definition at line 488 of file PHSimpleVertexFinder.cc.
View newest version in sPHENIX GitHub at line 488 of file PHSimpleVertexFinder.cc
References _outlier_cut, _track_pair_pca_map, _vertex_position_map, _vertex_set, _vertex_track_map, getAverage(), getMedian(), it, and Fun4AllBase::Verbosity().
Referenced by process_event().
|
inline |
Definition at line 40 of file PHSimpleVertexFinder.h.
View newest version in sPHENIX GitHub at line 40 of file PHSimpleVertexFinder.h
References _beamline_xy_cut.
|
inline |
Definition at line 41 of file PHSimpleVertexFinder.h.
View newest version in sPHENIX GitHub at line 41 of file PHSimpleVertexFinder.h
References _dcacut.
Definition at line 44 of file PHSimpleVertexFinder.h.
View newest version in sPHENIX GitHub at line 44 of file PHSimpleVertexFinder.h
References _nmvtx_required, and n.
|
inline |
Definition at line 46 of file PHSimpleVertexFinder.h.
View newest version in sPHENIX GitHub at line 46 of file PHSimpleVertexFinder.h
References _outlier_cut.
|
inline |
Definition at line 43 of file PHSimpleVertexFinder.h.
View newest version in sPHENIX GitHub at line 43 of file PHSimpleVertexFinder.h
References _require_mvtx.
|
inline |
Definition at line 42 of file PHSimpleVertexFinder.h.
View newest version in sPHENIX GitHub at line 42 of file PHSimpleVertexFinder.h
References _qual_cut.
|
private |
Definition at line 69 of file PHSimpleVertexFinder.h.
View newest version in sPHENIX GitHub at line 69 of file PHSimpleVertexFinder.h
Referenced by findDcaTwoTracks(), and setBeamLineCut().
|
private |
Definition at line 68 of file PHSimpleVertexFinder.h.
View newest version in sPHENIX GitHub at line 68 of file PHSimpleVertexFinder.h
Referenced by findDcaTwoTracks(), process_event(), and setDcaCut().
|
private |
Definition at line 72 of file PHSimpleVertexFinder.h.
View newest version in sPHENIX GitHub at line 72 of file PHSimpleVertexFinder.h
Referenced by checkDCAs(), and setNmvtxRequired().
|
private |
Definition at line 74 of file PHSimpleVertexFinder.h.
View newest version in sPHENIX GitHub at line 74 of file PHSimpleVertexFinder.h
Referenced by removeOutlierTrackPairs(), and setOutlierPairCut().
|
private |
Definition at line 70 of file PHSimpleVertexFinder.h.
View newest version in sPHENIX GitHub at line 70 of file PHSimpleVertexFinder.h
Referenced by checkDCAs(), and setTrackQualityCut().
|
private |
Definition at line 71 of file PHSimpleVertexFinder.h.
View newest version in sPHENIX GitHub at line 71 of file PHSimpleVertexFinder.h
Referenced by checkDCAs(), and setRequireMVTX().
|
private |
Definition at line 66 of file PHSimpleVertexFinder.h.
View newest version in sPHENIX GitHub at line 66 of file PHSimpleVertexFinder.h
Referenced by CreateNodes(), and process_event().
|
private |
Definition at line 65 of file PHSimpleVertexFinder.h.
View newest version in sPHENIX GitHub at line 65 of file PHSimpleVertexFinder.h
|
private |
Definition at line 64 of file PHSimpleVertexFinder.h.
View newest version in sPHENIX GitHub at line 64 of file PHSimpleVertexFinder.h
Referenced by checkDCAs(), GetNodes(), and process_event().
|
private |
Definition at line 78 of file PHSimpleVertexFinder.h.
View newest version in sPHENIX GitHub at line 78 of file PHSimpleVertexFinder.h
Referenced by findConnectedTracks(), findDcaTwoTracks(), and process_event().
|
private |
Definition at line 81 of file PHSimpleVertexFinder.h.
View newest version in sPHENIX GitHub at line 81 of file PHSimpleVertexFinder.h
Referenced by findDcaTwoTracks(), process_event(), and removeOutlierTrackPairs().
|
private |
Definition at line 73 of file PHSimpleVertexFinder.h.
View newest version in sPHENIX GitHub at line 73 of file PHSimpleVertexFinder.h
Referenced by findDcaTwoTracks().
Definition at line 83 of file PHSimpleVertexFinder.h.
View newest version in sPHENIX GitHub at line 83 of file PHSimpleVertexFinder.h
Referenced by process_event().
|
private |
Definition at line 82 of file PHSimpleVertexFinder.h.
View newest version in sPHENIX GitHub at line 82 of file PHSimpleVertexFinder.h
Referenced by process_event(), and removeOutlierTrackPairs().
|
private |
Definition at line 84 of file PHSimpleVertexFinder.h.
View newest version in sPHENIX GitHub at line 84 of file PHSimpleVertexFinder.h
Referenced by process_event(), and removeOutlierTrackPairs().
Definition at line 76 of file PHSimpleVertexFinder.h.
View newest version in sPHENIX GitHub at line 76 of file PHSimpleVertexFinder.h
Referenced by process_event(), and removeOutlierTrackPairs().