Belle II Software development
|
The SVD ShaperDigit class. More...
#include <SVDShaperDigit.h>
Public Types | |
typedef uint8_t | APVRawSampleType |
Types for array of samples received from DAQ. | |
typedef std::array< APVRawSampleType, c_nAPVSamples > | APVRawSamples |
array of APVRawSamplesType objects | |
typedef float | APVFloatSampleType |
Types for array of samples for processing. | |
typedef std::array< APVFloatSampleType, c_nAPVSamples > | APVFloatSamples |
array of APVFloatSampleType objects | |
enum | EAppendStatus { c_DontAppend = 0 , c_Append = 1 } |
Enum for return state of addBGDigit function. More... | |
Public Member Functions | |
template<typename T > | |
SVDShaperDigit (VxdID sensorID, bool isU, short cellID, T samples[c_nAPVSamples], int8_t FADCTime=0) | |
Constructor using c-array of samples. | |
template<typename T > | |
SVDShaperDigit (VxdID sensorID, bool isU, short cellID, T samples, int8_t FADCTime=0) | |
Constructor using a stl container of samples. | |
SVDShaperDigit () | |
Default constructor for the ROOT IO. | |
VxdID | getSensorID () const |
Get the sensor ID. | |
VxdID::baseType | getRawSensorID () const |
Get raw sensor ID. | |
bool | isUStrip () const |
Get strip direction. | |
short int | getCellID () const |
Get strip ID. | |
APVFloatSamples | getSamples () const |
Get array of samples. | |
int | getMaxTimeBin () const |
Get the max bin. | |
int | getMaxADCCounts () const |
Get the ADC counts corresponding to the higher sample amplitude. | |
float | getFADCTime () const |
Get digit FADCTime estimate. | |
std::string | toString () const |
Display main parameters in this object. | |
unsigned int | getUniqueChannelID () const override |
Implementation of base class function. | |
DigitBase::EAppendStatus | addBGDigit (const DigitBase *bg) override |
Implementation of base class function. | |
void | adjustAppendedBGDigit () override |
Modify already appended BG digit if aquisition mode is 3 sample. | |
bool | operator< (const SVDShaperDigit &x) const |
bool | passesZS (int nSamples, float cutMinSignal) const |
does the strip pass the ZS cut? | |
void | addRelationTo (const RelationsInterface< BASE > *object, float weight=1.0, const std::string &namedRelation="") const |
Add a relation from this object to another object (with caching). | |
void | addRelationTo (const TObject *object, float weight=1.0, const std::string &namedRelation="") const |
Add a relation from this object to another object (no caching, can be quite slow). | |
void | copyRelations (const RelationsInterface< BASE > *sourceObj) |
Copies all relations of sourceObj (pointing from or to sourceObj) to this object (including weights). | |
template<class TO > | |
RelationVector< TO > | getRelationsTo (const std::string &name="", const std::string &namedRelation="") const |
Get the relations that point from this object to another store array. | |
template<class FROM > | |
RelationVector< FROM > | getRelationsFrom (const std::string &name="", const std::string &namedRelation="") const |
Get the relations that point from another store array to this object. | |
template<class T > | |
RelationVector< T > | getRelationsWith (const std::string &name="", const std::string &namedRelation="") const |
Get the relations between this object and another store array. | |
template<class TO > | |
TO * | getRelatedTo (const std::string &name="", const std::string &namedRelation="") const |
Get the object to which this object has a relation. | |
template<class FROM > | |
FROM * | getRelatedFrom (const std::string &name="", const std::string &namedRelation="") const |
Get the object from which this object has a relation. | |
template<class T > | |
T * | getRelated (const std::string &name="", const std::string &namedRelation="") const |
Get the object to or from which this object has a relation. | |
template<class TO > | |
std::pair< TO *, float > | getRelatedToWithWeight (const std::string &name="", const std::string &namedRelation="") const |
Get first related object & weight of relation pointing to an array. | |
template<class FROM > | |
std::pair< FROM *, float > | getRelatedFromWithWeight (const std::string &name="", const std::string &namedRelation="") const |
Get first related object & weight of relation pointing from an array. | |
template<class T > | |
std::pair< T *, float > | getRelatedWithWeight (const std::string &name="", const std::string &namedRelation="") const |
Get first related object & weight of relation pointing from/to an array. | |
virtual std::string | getName () const |
Return a short name that describes this object, e.g. | |
virtual std::string | getInfoHTML () const |
Return a short summary of this object's contents in HTML format. | |
std::string | getInfo () const |
Return a short summary of this object's contents in raw text format. | |
std::string | getArrayName () const |
Get name of array this object is stored in, or "" if not found. | |
int | getArrayIndex () const |
Returns this object's array index (in StoreArray), or -1 if not found. | |
Static Public Member Functions | |
template<typename T > | |
static SVDShaperDigit::APVRawSampleType | trimToSampleRange (T x) |
Convert a value to sample range. | |
static void | setAPVMode (size_t mode, size_t firstSample) |
set APV mode for the event | |
Static Public Attributes | |
static const std::size_t | c_nAPVSamples = 6 |
Number of APV samples stored. | |
Protected Member Functions | |
TClonesArray * | getArrayPointer () const |
Returns the pointer to the raw DataStore array holding this object (protected since these arrays are easy to misuse). | |
Private Member Functions | |
ClassDef (DigitBase, 2) | |
ClassDef. | |
Private Attributes | |
VxdID::baseType | m_sensorID = 0 |
Compressed sensor identifier. | |
bool | m_isU = false |
True if U, false if V. | |
short | m_cellID = 0 |
Strip coordinate in pitch units. | |
APVRawSamples | m_samples |
6 APV signals from the strip. | |
int8_t | m_FADCTime = 0 |
digit time estimate from the FADC, in ns | |
DataStore::StoreEntry * | m_cacheDataStoreEntry |
Cache of the data store entry to which this object belongs. | |
int | m_cacheArrayIndex |
Cache of the index in the TClonesArray to which this object belongs. | |
Static Private Attributes | |
static size_t | s_APVSampleMode = 6 |
APV acquisition mode (3 or 6) | |
static size_t | s_APVSampleBegin = 0 |
first sample number for 3 sample acquisition mode (0 - 3) | |
The SVD ShaperDigit class.
The SVDShaperDigit holds a set of 6 raw APV25 signal samples, zero-padded in 3-sample mode) taken on a strip.
Definition at line 32 of file SVDShaperDigit.h.
typedef std::array<APVFloatSampleType, c_nAPVSamples> APVFloatSamples |
array of APVFloatSampleType objects
Definition at line 49 of file SVDShaperDigit.h.
typedef float APVFloatSampleType |
Types for array of samples for processing.
Definition at line 48 of file SVDShaperDigit.h.
typedef std::array<APVRawSampleType, c_nAPVSamples> APVRawSamples |
array of APVRawSamplesType objects
Definition at line 44 of file SVDShaperDigit.h.
typedef uint8_t APVRawSampleType |
Types for array of samples received from DAQ.
An integer type is sufficient for storage, but getters will return array of doubles suitable for computing.
Definition at line 43 of file SVDShaperDigit.h.
|
inherited |
Enum for return state of addBGDigit function.
Enumerator | |
---|---|
c_DontAppend | do not append BG digit to digits |
c_Append | append BG digit to digits |
Definition at line 32 of file DigitBase.h.
|
inline |
Constructor using c-array of samples.
sensorID | Sensor VXD ID. |
isU | True if u strip, false if v. |
cellID | Strip ID. |
samples | std::array of 6 APV raw samples. |
FADCTime | Time estimate from FADC mode. |
Definition at line 60 of file SVDShaperDigit.h.
|
inline |
Constructor using a stl container of samples.
sensorID | Sensor VXD ID. |
isU | True if u strip, false if v. |
cellID | Strip ID. |
samples | std::array of 6 APV raw samples. |
FADCTime | Time estimate from FADC mode. |
Definition at line 79 of file SVDShaperDigit.h.
|
inline |
Default constructor for the ROOT IO.
Definition at line 90 of file SVDShaperDigit.h.
|
inlineoverridevirtual |
Implementation of base class function.
Addition is always possible, so we always return successful merge. Pile-up method.
bg | beam background digit |
Implements DigitBase.
Definition at line 204 of file SVDShaperDigit.h.
|
inlineinherited |
Add a relation from this object to another object (with caching).
object | The object to which the relation should point. |
weight | The weight of the relation. |
namedRelation | Additional name for the relation, or "" for the default naming |
Definition at line 142 of file RelationsObject.h.
|
inlineinherited |
Add a relation from this object to another object (no caching, can be quite slow).
object | The object to which the relation should point. |
weight | The weight of the relation. |
namedRelation | Additional name for the relation, or "" for the default naming |
Definition at line 155 of file RelationsObject.h.
|
inlineoverridevirtual |
Modify already appended BG digit if aquisition mode is 3 sample.
Reimplemented from DigitBase.
Definition at line 233 of file SVDShaperDigit.h.
|
inlineinherited |
Copies all relations of sourceObj (pointing from or to sourceObj) to this object (including weights).
Useful if you want to make a complete copy of a StoreArray object to make modifications to it, but retain all information on linked objects.
Note: this only works if sourceObj inherits from the same base (e.g. RelationsObject), and only for related objects that also inherit from the same base.
Definition at line 170 of file RelationsObject.h.
|
inlineinherited |
Returns this object's array index (in StoreArray), or -1 if not found.
Definition at line 385 of file RelationsObject.h.
|
inlineinherited |
Get name of array this object is stored in, or "" if not found.
Definition at line 377 of file RelationsObject.h.
|
inlineprotectedinherited |
Returns the pointer to the raw DataStore array holding this object (protected since these arrays are easy to misuse).
Definition at line 418 of file RelationsObject.h.
|
inline |
|
inline |
Get digit FADCTime estimate.
Definition at line 155 of file SVDShaperDigit.h.
|
inlineinherited |
Return a short summary of this object's contents in raw text format.
Returns the contents of getInfoHTML() while translating line-breaks etc.
Definition at line 370 of file RelationsObject.h.
|
inlinevirtualinherited |
Return a short summary of this object's contents in HTML format.
Reimplement this in your own class to provide useful output for display or debugging purposes. For example, you might do something like:
Reimplemented in Particle, Cluster, MCParticle, PIDLikelihood, SoftwareTriggerResult, Track, TrackFitResult, TRGSummary, and RecoTrack.
Definition at line 362 of file RelationsObject.h.
|
inline |
Get the ADC counts corresponding to the higher sample amplitude.
Definition at line 144 of file SVDShaperDigit.h.
|
inline |
Get the max bin.
Definition at line 132 of file SVDShaperDigit.h.
|
inlinevirtualinherited |
Return a short name that describes this object, e.g.
pi+ for an MCParticle.
Reimplemented in Particle, MCParticle, and SpacePoint.
Definition at line 344 of file RelationsObject.h.
|
inline |
Get raw sensor ID.
For use in Python
Definition at line 104 of file SVDShaperDigit.h.
|
inlineinherited |
Get the object to or from which this object has a relation.
T | The class of objects to or from which the relation points. |
name | The name of the store array to or from which the relation points. If empty the default store array name for class T will be used. If the special name "ALL" is given all store arrays containing objects of type T are considered. |
namedRelation | Additional name for the relation, or "" for the default naming |
Definition at line 278 of file RelationsObject.h.
|
inlineinherited |
Get the object from which this object has a relation.
FROM | The class of objects from which the relation points. |
name | The name of the store array from which the relation points. If empty the default store array name for class FROM will be used. If the special name "ALL" is given all store arrays containing objects of type FROM are considered. |
namedRelation | Additional name for the relation, or "" for the default naming |
Definition at line 263 of file RelationsObject.h.
|
inlineinherited |
Get first related object & weight of relation pointing from an array.
FROM | The class of objects from which the relation points. |
name | The name of the store array from which the relation points. If empty the default store array name for class FROM will be used. If the special name "ALL" is given all store arrays containing objects of type FROM are considered. |
namedRelation | Additional name for the relation, or "" for the default naming |
Definition at line 314 of file RelationsObject.h.
|
inlineinherited |
Get the object to which this object has a relation.
TO | The class of objects to which the relation points. |
name | The name of the store array to which the relation points. If empty the default store array name for class TO will be used. If the special name "ALL" is given all store arrays containing objects of type TO are considered. |
namedRelation | Additional name for the relation, or "" for the default naming |
Definition at line 248 of file RelationsObject.h.
|
inlineinherited |
Get first related object & weight of relation pointing to an array.
TO | The class of objects to which the relation points. |
name | The name of the store array to which the relation points. If empty the default store array name for class TO will be used. If the special name "ALL" is given all store arrays containing objects of type TO are considered. |
namedRelation | Additional name for the relation, or "" for the default naming |
Definition at line 297 of file RelationsObject.h.
|
inlineinherited |
Get first related object & weight of relation pointing from/to an array.
T | The class of objects to or from which the relation points. |
name | The name of the store array to or from which the relation points. If empty the default store array name for class T will be used. If the special name "ALL" is given all store arrays containing objects of type T are considered. |
namedRelation | Additional name for the relation, or "" for the default naming |
Definition at line 331 of file RelationsObject.h.
|
inlineinherited |
Get the relations that point from another store array to this object.
FROM | The class of objects from which the relations point. |
name | The name of the store array from which the relations point. If empty the default store array name for class FROM will be used. If the special name "ALL" is given all store arrays containing objects of type FROM are considered. |
namedRelation | Additional name for the relation, or "" for the default naming |
Definition at line 212 of file RelationsObject.h.
|
inlineinherited |
Get the relations that point from this object to another store array.
TO | The class of objects to which the relations point. |
name | The name of the store array to which the relations point. If empty the default store array name for class TO will be used. If the special name "ALL" is given all store arrays containing objects of type TO are considered. |
namedRelation | Additional name for the relation, or "" for the default naming |
Definition at line 197 of file RelationsObject.h.
|
inlineinherited |
Get the relations between this object and another store array.
Relations in both directions are returned.
T | The class of objects to or from which the relations point. |
name | The name of the store array to or from which the relations point. If empty the default store array name for class T will be used. If the special name "ALL" is given all store arrays containing objects of type T are considered. |
namedRelation | Additional name for the relation, or "" for the default naming |
Definition at line 230 of file RelationsObject.h.
|
inline |
Get array of samples.
Definition at line 119 of file SVDShaperDigit.h.
|
inline |
|
inlineoverridevirtual |
Implementation of base class function.
Enables BG overlay module to identify uniquely the physical channel of this Digit.
Implements DigitBase.
Definition at line 194 of file SVDShaperDigit.h.
|
inline |
|
inline |
x | input shaper digit |
Definition at line 246 of file SVDShaperDigit.h.
|
inline |
does the strip pass the ZS cut?
nSamples | min number of samples above threshold |
cutMinSignal | SN threshold |
Definition at line 262 of file SVDShaperDigit.h.
|
inlinestatic |
set APV mode for the event
mode | = 3, 6 depending on the number of acquired samples |
firstSample | = first sample (of the 6) to be stored if mode = 3 |
Definition at line 281 of file SVDShaperDigit.h.
|
inline |
Display main parameters in this object.
Definition at line 174 of file SVDShaperDigit.h.
|
inlinestatic |
Convert a value to sample range.
x | value to be converted |
Definition at line 163 of file SVDShaperDigit.h.
|
static |
Number of APV samples stored.
Definition at line 37 of file SVDShaperDigit.h.
|
mutableprivateinherited |
Cache of the index in the TClonesArray to which this object belongs.
Definition at line 432 of file RelationsObject.h.
|
mutableprivateinherited |
Cache of the data store entry to which this object belongs.
Definition at line 429 of file RelationsObject.h.
|
private |
Strip coordinate in pitch units.
Definition at line 292 of file SVDShaperDigit.h.
|
private |
digit time estimate from the FADC, in ns
Definition at line 294 of file SVDShaperDigit.h.
|
private |
True if U, false if V.
Definition at line 291 of file SVDShaperDigit.h.
|
private |
6 APV signals from the strip.
Definition at line 293 of file SVDShaperDigit.h.
|
private |
Compressed sensor identifier.
Definition at line 290 of file SVDShaperDigit.h.