74 : fID(
std::numeric_limits<size_t>::max())
76 , fPosition(Eigen::Vector3f::Zero())
82 , fOverlapFraction(0.)
83 , fChargeAsymmetry(0.)
96 unsigned int statusBits,
97 const Eigen::Vector3f& position,
103 float overlapFraction,
104 float chargeAsymmetry,
108 const std::vector<float>& hitDelTSigVec,
109 const std::vector<geo::WireID>& wireIDs)
126 std::copy(hitVec.begin(), hitVec.end(),
fHitVector.begin());
157 unsigned int statusBits,
158 const Eigen::Vector3f& position,
164 float overlapFraction,
165 float chargeAsymmetry,
169 const std::vector<float>& hitDelTSigVec,
170 const std::vector<geo::WireID>& wireIDs)
198 o <<
"ClusterHit3D has " << c.
getHits().size() <<
" hits associated";
214 , m_avePosition(Eigen::Vector3f::Zero())
215 , m_aveHitDoca(9999.)
222 const Eigen::Vector3f& avePos,
223 const float aveHitDoca)
242 o << std::setiosflags(std::ios::fixed) << std::setprecision(2);
243 o <<
" PCAxis ID run with " << a.
m_numHitsUsed <<
" space points" << std::endl;
244 o <<
" - center position: " << std::setw(6) << a.
m_avePosition(0) <<
", " 248 o <<
" - average doca: " << a.
m_aveHitDoca << std::endl;
249 o <<
" - Principle axis: " << std::setw(7) << std::setprecision(4) << a.
m_eigenVectors(0, 0)
251 o <<
" - second axis: " << std::setw(7) << std::setprecision(4) << a.
m_eigenVectors(1, 0)
253 o <<
" - third axis: " << std::setw(7) << std::setprecision(4) << a.
m_eigenVectors(2, 0)
257 o <<
" Principal Components Axis is not valid" << std::endl;
273 , m_startPosition{0., 0., 0.}
274 , m_endPosition{0., 0., 0.}
281 const float* startPosition,
282 const float* endPosition,
284 : m_statusBits(statusBits)
285 , m_pcaResults(pcaResults)
286 , m_totalCharge(totalCharge)
287 , m_startPosition{startPosition[0], startPosition[1], startPosition[2]}
288 ,
m_endPosition{endPosition[0], endPosition[1], endPosition[2]}
351 o << std::setiosflags(std::ios::fixed) << std::setprecision(2);
396 if (clusterHit->
WireID().
Wire < m_startWire) {
410 m_view = hit->
View();
412 m_hitVector.push_back(clusterHit);
void initialize(size_t id, unsigned int statusBits, const Eigen::Vector3f &position, float totalCharge, float avePeakTime, float deltaPeakTime, float sigmaPeakTime, float hitChiSquare, float overlapFraction, float chargeAsymmetry, float docaToAxis, float arclenToPoca, const ClusterHit2DVec &hitVec, const std::vector< float > &hitDelTSigVec, const std::vector< geo::WireID > &wireIDVec)
ClusterHit3D & operator=(ClusterHit3D const &)
ClusterHit2D & operator=(ClusterHit2D const &)
float fDeltaPeakTime
Largest delta peak time of associated recob::Hits.
void setWireID(const geo::WireID &wid) const
bool m_svdOK
SVD Decomposition was successful.
Cluster3D operator+(Cluster3D)
constexpr auto const & right(const_AssnsIter< L, R, D, Dir > const &a, const_AssnsIter< L, R, D, Dir > const &b)
float fTotalCharge
Sum of charges of all associated recob::Hits.
void flipAxis(size_t axis)
double m_aveHitDoca
Average doca of hits used in PCA.
Declaration of signal hit object.
const geo::WireID & WireID() const
const float * getStartPosition() const
unsigned m_statusBits
Volatile status information of this 3D hit.
size_t fID
"id" of this hit (useful for indexing)
float Integral() const
Integral under the calibrated signal waveform of the hit, in tick x ADC units.
geo::View_t View() const
View for the plane of the hit.
WireID_t Wire
Index of the wire within its plane.
float fSigmaPeakTime
Quad sum of peak time sigmas.
float m_docaToAxis
DOCA of hit at POCA to associated cluster axis.
friend bool operator<(const ClusterHit2D &a, const ClusterHit2D &b)
float fAvePeakTime
Average peak time of all associated recob::Hits.
friend bool operator<(const Cluster3D &a, const Cluster3D &b)
const recob::Hit * getHit() const
std::vector< geo::WireID > fWireIDVector
Wire ID's for the planes making up hit.
std::vector< float > fHitDelTSigVec
Delta t of hit to matching pair / sig.
EigenValues m_eigenValues
Eigen values from SVD decomposition.
const recob::Hit * m_hit
Hit we are augmenting.
IDparameter< geo::WireID > WireID
Member type of validated geo::WireID parameter.
float m_arcLenToPoca
arc length to POCA along cluster axis
float m_totalCharge
Total charge in the cluster.
Eigen::Vector3f EigenValues
unsigned int fStatusBits
Volatile status information of this 3D hit.
float m_timeTicks
The time (in ticks) for this hit.
float fOverlapFraction
Hit overlap fraction start/stop of triplet.
float m_endPosition[3]
"end" position for cluster
Eigen::Vector3f m_avePosition
Average position of hits fed to PCA.
float fHitChiSquare
Hit ChiSquare relative to the average time.
PlaneID_t Plane
Index of the plane within its TPC.
float fDocaToAxis
DOCA to the associated cluster axis.
float PeakTimeMinusRMS(float sigmas=+1.) const
Returns a time sigmas RMS away from the peak time.
Detector simulation of raw signals on wires.
std::vector< const reco::ClusterHit2D * > ClusterHit2DVec
float fChargeAsymmetry
Assymetry of average of two closest to third charge.
ClusterHit2DVec fHitVector
Hits comprising this 3D hit.
float fArclenToPoca
arc length along axis to DOCA point
geo::WireID m_wireID
Keep track this particular hit's wireID.
Eigen::Matrix3f EigenVectors
int m_clusterIdx
ID for this cluster.
float SigmaPeakTime() const
Uncertainty for the signal peak, in tick units.
2D representation of charge deposited in the TDC/wire plane
constexpr PlaneID const & planeID() const
friend bool operator<(const PrincipalComponents &a, const PrincipalComponents &b)
EigenVectors m_eigenVectors
The three principle axes.
float m_xPosition
The x coordinate for this hit.
float PeakTimePlusRMS(float sigmas=+1.) const
Returns a time sigmas RMS away from the peak time.
friend std::ostream & operator<<(std::ostream &o, const ClusterHit2D &c)
Namespace collecting geometry-related classes utilities.
const ClusterHit2DVec & getHits() const
int getClusterIdx() const
void UpdateParameters(const reco::ClusterHit2D *hit)
friend std::ostream & operator<<(std::ostream &o, const Cluster3D &c)
Eigen::Vector3f fPosition
position of this hit combination in world coordinates
friend std::ostream & operator<<(std::ostream &o, const ClusterHit3D &c)
int m_numHitsUsed
Number of hits in the decomposition.
friend std::ostream & operator<<(std::ostream &o, const PrincipalComponents &a)