59 double ref_x_, ref_y_, ref_z_;
60 std::vector<double> params_;
61 std::vector<double> cov_;
62 TrackStateType ts_type_;
84 void setNhits(
int nhits) { n_hits_ = nhits; }
85 int getNhits()
const {
return n_hits_; }
87 std::optional<TrackState> getTrackState(TrackStateType tstype)
const {
88 for (
auto ts : track_states_)
89 if (ts.ts_type_ == tstype)
return std::optional<TrackState>(ts);
97 void setNoutliers(
int nout) { n_outliers_ = nout; }
98 int getNoutliers()
const {
return n_outliers_; }
100 void setNdf(
int ndf) { ndf_ = ndf; }
101 int getNdf()
const {
return ndf_; };
103 void setNsharedHits(
int nsh) { n_shared_hits_ = nsh; }
104 int getNsharedHits()
const {
return n_shared_hits_; }
106 void setChi2(
double chi2) { chi2_ = chi2; }
107 double getChi2()
const {
return chi2_; }
109 void setTrackID(
int trackid) { track_id_ = trackid; };
110 int getTrackID()
const {
return track_id_; };
112 void setTruthProb(
double truthProb) { truth_prob_ = truthProb; };
113 double getTruthProb()
const {
return truth_prob_; };
115 void setPdgID(
int pdgID) { pdg_id_ = pdgID; };
116 int getPdgID()
const {
return pdg_id_; };
119 int q()
const {
return perigee_pars_[4] > 0 ? 1 : -1; }
126 void addMeasurementIndex(
unsigned int measIdx) {
127 meas_idxs_.push_back(measIdx);
129 std::vector<unsigned int> getMeasurementsIdxs()
const {
return meas_idxs_; }
131 void addOutlierIndex(
unsigned int measIdx) {
132 outlier_idxs_.push_back(measIdx);
134 std::vector<unsigned int> getOutlierIdxs()
const {
return outlier_idxs_; }
136 void addHoleIndex(
unsigned int measIdx) { hole_idxs_.push_back(measIdx); }
137 std::vector<unsigned int> getHoleIdxs()
const {
return hole_idxs_; }
139 void addSharedIndex(
unsigned int measIdx) { shared_idxs_.push_back(measIdx); }
140 std::vector<unsigned int> getSharedIdxs()
const {
return shared_idxs_; }
142 void addDedxMeasurement(
float path_length) {
143 dedx_measurements_.push_back(path_length);
145 std::vector<float> getDedxMeasurements()
const {
return dedx_measurements_; }
164 std::vector<double> getPerigeeParameters()
const {
return perigee_pars_; }
166 void setPerigeeCov(
const std::vector<double>& cov) { perigee_cov_ = cov; }
167 std::vector<double> getPerigeeCov()
const {
return perigee_cov_; }
169 void setPerigeeLocation(
const std::vector<double>& perigee) {
173 void setPerigeeLocation(
const double& x_,
const double& y_,
180 void setMomentum(
const double& px,
const double& py,
const double& pz) {
186 void setPosition(
const double& x_,
const double& y_,
const double& z_) {
192 std::vector<double> getPerigeeLocation()
const {
return perigee_; };
193 double getPerigeeX()
const {
return perigee_[0]; };
194 double getPerigeeY()
const {
return perigee_[1]; };
195 double getPerigeeZ()
const {
return perigee_[2]; };
197 std::vector<double> getMomentum()
const {
return momentum_; };
198 std::vector<double> getPosition()
const {
return position_; };
202 double getD0()
const {
return perigee_pars_[0]; };
203 double getZ0()
const {
return perigee_pars_[1]; };
204 double getPhi()
const {
return perigee_pars_[2]; };
205 double getTheta()
const {
return perigee_pars_[3]; };
206 double getQoP()
const {
return perigee_pars_[4]; };
207 double getT()
const {
return perigee_pars_[5]; };
210 track_states_.push_back(ts);
213 std::vector<TrackState> getTrackStates()
const {
return track_states_; }
219 int n_shared_hits_{0};
233 std::vector<double> perigee_pars_{0., 0., 0., 0., 0., 0.};
242 std::vector<double> perigee_cov_;
245 std::vector<double> perigee_{0., 0., 0.};
248 std::vector<double> momentum_{0., 0., 0.};
251 std::vector<double> position_{0., 0., 0.};
254 std::vector<unsigned int> meas_idxs_{};
257 std::vector<unsigned int> outlier_idxs_{};
260 std::vector<unsigned int> hole_idxs_{};
263 std::vector<unsigned int> shared_idxs_{};
266 std::vector<float> dedx_measurements_{};
272 double truth_prob_{0.};
278 std::vector<TrackState> track_states_;