10#define SVD_RECODIGIT_H
12#include <vxd/dataobjects/VxdID.h>
13#include <framework/datastore/RelationsObject.h>
72 float fittedAmplitudeError,
float fittedTime,
float fittedTimeError,
73 const T& probabilities,
float chi2):
79 double inputNorm = std::accumulate(probabilities.begin(), probabilities.end(), 0.0);
80 if (inputNorm < 0.1) inputNorm = 1.0;
82 std::transform(probabilities.begin(), probabilities.end(),
84 [normCoef](
typename T::value_type x)->StoredProbType
85 { return static_cast<StoredProbType>(normCoef * x); }
91 0, true, 0, 0.0, 10.0, 0.0, 100.0,
std::vector<double>({1.0}), 100.0
150 double normCoef =
static_cast<double>(1.0 / storeNorm);
151 if (normCoef < 1.0e-15) normCoef = 1.0;
153 std::back_inserter(outputPdf),
155 { return static_cast<OutputProbType>(normCoef * x); }
170 std::ostringstream os;
171 os <<
"VXDID : " <<
m_sensorID <<
" = " << std::string(thisSensorID) <<
" strip: "
175 <<
" probabilities: ";
177 std::ostream_iterator<StoredProbType>(os,
" "));
Defines interface for accessing relations of objects in StoreArray.
ClassDef(RelationsInterface, 0)
defines interface for accessing relations of objects in StoreArray.
SVDRecoDigit()
Default constructor for the ROOT IO.
double OutputProbType
Type for output probability array.
OutputProbArray getProbabilities() const
Get signal time pdf.
StoredProbArray m_probabilities
pdf of the time estimate.
float m_fitChi2Ndf
Standardized chi2 of the fit.
bool m_isU
True if U, false if V.
std::string toString() const
Display main parameters in this object.
float getTime() const
Get time estimate.
VxdID::baseType m_sensorID
Compressed sensor identifier.
float getAmplitude() const
Get amplitude estimate.
SVDRecoDigit(VxdID sensorID, bool isU, short cellID, float fittedAmplitude, float fittedAmplitudeError, float fittedTime, float fittedTimeError, const T &probabilities, float chi2)
Constructor using a stl container of time bin probabilities.
VxdID::baseType getRawSensorID() const
Get raw sensor ID.
uint16_t StoredProbType
Types for internal storage of probability array.
std::vector< StoredProbType > StoredProbArray
vector of StoreProbType objects
float m_fittedAmplitude
Fitted amplitude of the signal ("charge")
float m_fittedTime
Fitted arrival time of the signal.
float getCharge() const
Get amplitude estimate, alternate getter name.
float getChi2Ndf() const
Get waveform fit chi2/ndf.
short m_cellID
Strip coordinate in pitch units.
VxdID getSensorID() const
Get the sensor ID.
static const uint16_t storedProbArrayNorm
some constant
float m_fittedTimeError
Error estimate of time fit.
float getAmplitudeError() const
Get amplitude error.
std::vector< OutputProbType > OutputProbArray
vector of OutProbType objects
short int getCellID() const
Get strip ID.
bool isUStrip() const
Get strip direction.
float getTimeError() const
Get time error.
float m_fittedAmplitudeError
Error estimate of amplitude fit.
Class to uniquely identify a any structure of the PXD and SVD.
unsigned short baseType
The base integer type for VxdID.
Abstract base class for different kinds of events.