Belle II Software development
|
simple Hit class used for sectorMap-training. More...
#include <SecMapTrainerHit.h>
Public Member Functions | |
SecMapTrainerHit (const FullSecID &fullSecID, const SpacePoint &sp) | |
Constructor of class SecMapTrainerHit. | |
SecMapTrainerHit (const FullSecID &fullSecID, const B2Vector3D &position) | |
constructor needed for the Virtual IP | |
SecMapTrainerHit (double x, double y, double z) | |
another constructor needed for the Virtual IP... eccpp | |
std::string | getSectorIDString () const |
returns global hit position of current hit. | |
FullSecID | getSectorID () const |
returns secID of sector containing this hit. | |
bool | operator== (const SpacePoint &b) const |
Compare, if two SpacePoints are the same one. | |
bool | operator!= (const SpacePoint &b) const |
Comparison for inequality with another SpacePoint. | |
std::string | getName () const override |
Print out some info for this SpacePoint. | |
double | X () const |
return the x-value of the global position of the SpacePoint | |
double | Y () const |
return the y-value of the global position of the SpacePoint | |
double | Z () const |
return the z-value of the global position of the SpacePoint | |
double | TimeU () const |
return the time in ns of the cluster on the U side | |
double | TimeV () const |
return the time in ns of the cluster on the V side | |
const B2Vector3D & | getPosition () const |
return the position vector in global coordinates | |
const B2Vector3D & | getPositionError () const |
return the hitErrors in sigma of the global position | |
Belle2::VXD::SensorInfoBase::SensorType | getType () const |
Return SensorType (PXD, SVD, ...) on which the SpacePoint lives. | |
VxdID | getVxdID () const |
Return the VxdID of the sensor on which the the cluster of the SpacePoint lives. | |
double | getNormalizedLocalU () const |
Return normalized local coordinates of the cluster in u (0 <= posU <= 1). | |
double | getNormalizedLocalV () const |
Return normalized local coordinates of the cluster in v (0 <= posV <= 1). | |
std::pair< bool, bool > | getIfClustersAssigned () const |
Returns, if u(v)-coordinate is based on cluster information. | |
unsigned short | getNClustersAssigned () const |
Returns the number of Clusters assigned to this SpacePoint. | |
void | setAssignmentState (bool isAssigned) const |
Setter for association with a track. | |
bool | isUOnly () const |
Returns true if the SP is single clustered and the cluster is a u cluster. | |
bool | isVOnly () const |
Returns true if the SP is single clustered and the cluster is a v cluster. | |
bool | isUAndV () const |
Returns true if the SP is not single clustered. | |
bool | getAssignmentState () const |
Getter for status of assignment to a track. | |
void | setQualityEstimation (float qualityIndicator) |
Setter for the quality of this SpacePoint. | |
float | getQualityEstimation () const |
Getter for the quality of this SpacePoint. | |
void | setQualityEstimationError (double qualityIndicatorError) |
Setter for the spacePoint quality index error. | |
float | getQualityEstimationError () const |
Getter for the spacePoint quality index error. | |
virtual std::vector< genfit::PlanarMeasurement > | getGenfitCompatible () const |
returns a vector of genfit::PlanarMeasurement, which is needed for genfit::track. | |
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 | 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 | |
static B2Vector3D | getGlobalCoordinates (const std::pair< double, double > &hitLocal, VxdID vxdID, const VXD::SensorInfoBase *aSensorInfo=nullptr) |
converts a local hit on a given sensor into global coordinates. | |
static std::pair< double, double > | convertLocalToNormalizedCoordinates (const std::pair< double, double > &hitLocal, VxdID vxdID, const VXD::SensorInfoBase *aSensorInfo=nullptr) |
converts a local hit into sensor-independent relative coordinates. | |
static std::pair< double, double > | convertNormalizedToLocalCoordinates (const std::pair< double, double > &hitNormalized, Belle2::VxdID vxdID, const Belle2::VXD::SensorInfoBase *aSensorInfo=nullptr) |
converts a hit in sensor-independent relative coordinates into local coordinate of given sensor. | |
static double | getUWedged (const std::pair< double, double > &hitLocalUnwedged, VxdID vxdID, const VXD::SensorInfoBase *aSensorInfo=nullptr) |
takes a general uCoordinate, and transforms it to corrected uCoordinate for wedged sensors. | |
static double | getUUnwedged (const std::pair< double, double > &hitLocalWedged, VxdID::baseType vxdID, const VXD::SensorInfoBase *aSensorInfo=nullptr) |
takes a wedged uCoordinate, and transforms it to general uCoordinate. | |
static void | boundaryEnforce (double &value, const double &otherValue, double lower=0, double higher=1, unsigned int side=0, VxdID vxdID=VxdID()) |
Enforce 'value' in the range ['lower', 'higher']. | |
Protected Member Functions | |
void | setPositionError (double uSigma, double vSigma, const VXD::SensorInfoBase *aSensorInfo) |
Setter for global position error from on-sensor sigmas. | |
TClonesArray * | getArrayPointer () const |
Returns the pointer to the raw DataStore array holding this object (protected since these arrays are easy to misuse). | |
Protected Attributes | |
FullSecID | m_secID |
ID of sector containing this hit. | |
B2Vector3D | m_position |
Global position vector. | |
B2Vector3D | m_positionError |
Global position error vector in sigma. | |
std::pair< double, double > | m_normalizedLocal |
Local position vector normalized to sensor size (0 <= x <= 1). | |
double | m_UClusterTime |
Time of the cluster on the U side in ns. | |
double | m_VClusterTime |
Time of the cluster on the V side in ns. | |
std::pair< bool, bool > | m_clustersAssigned {false, false} |
The bool value is true, when correct information of the coordinate exists. | |
VxdID::baseType | m_vxdID |
Stores the VxdID. | |
VXD::SensorInfoBase::SensorType | m_sensorType |
Stores the SensorType using the scheme of SensorInfoBase. | |
float | m_qualityIndicator {0.5} |
Stores a quality indicator. | |
float | m_qualityIndicatorError {0.5} |
Stores the error on the quality indicator. | |
bool | m_isAssigned {false} |
Stores whether this SpacePoint is connected to a track. | |
Private Member Functions | |
ClassDef (RelationsInterface, 0) | |
defines interface for accessing relations of objects in StoreArray. | |
Private Attributes | |
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. | |
simple Hit class used for sectorMap-training.
Definition at line 25 of file SecMapTrainerHit.h.
|
inline |
Constructor of class SecMapTrainerHit.
Definition at line 28 of file SecMapTrainerHit.h.
|
inline |
constructor needed for the Virtual IP
Definition at line 33 of file SecMapTrainerHit.h.
|
inline |
another constructor needed for the Virtual IP... eccpp
Definition at line 41 of file SecMapTrainerHit.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.
|
inlinestaticinherited |
Enforce 'value' in the range ['lower', 'higher'].
param = min(max(param,lower),higher)
value | is the coordinate that must be constrained in the range |
otherValue | is for debugging and logging purposes |
lower | is the lower limit of the prescribed range |
higher | is the upper limit of the prescribed range |
side | is for debugging purposes: 0 for U side 1 for V side |
vxdID | is for debugging purposes |
Definition at line 296 of file SpacePoint.h.
|
staticinherited |
converts a local hit into sensor-independent relative coordinates.
first parameter is the local hit (as provided by SpacePoint::getUWedged(...) and Cluster::getV!) stored as a pair of doubles. second parameter is the coded vxdID, which carries the sensorID. third parameter, a sensorInfo can be passed for testing purposes. If no sensorInfo is passed, the member gets its own pointer to it.
ATTENTION: this function assumes, that for wedged sensors, the uCoordinate is already adapted to the vCoordinate! The normalized coordinates are independent of wedged-sensor-issues
Definition at line 149 of file SpacePoint.cc.
|
staticinherited |
converts a hit in sensor-independent relative coordinates into local coordinate of given sensor.
first parameter is the hit in sensor-independent normalized ! coordinates stored as a pair of floats. second parameter is the coded vxdID, which carries the sensorID. third parameter, a sensorInfo can be passed for testing purposes. If no sensorInfo is passed, the member gets its own pointer to it.
Definition at line 178 of file SpacePoint.cc.
|
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.
|
inlineinherited |
Getter for status of assignment to a track.
Definition at line 185 of file SpacePoint.h.
|
virtualinherited |
returns a vector of genfit::PlanarMeasurement, which is needed for genfit::track.
This member ensures compatibility with genfit2. The return type is detector independent, but each entry will be of the same detector type, since a spacePoint can not contain clusters of different sensors and therefore of different detector types.
Definition at line 117 of file SpacePoint.cc.
|
staticinherited |
converts a local hit on a given sensor into global coordinates.
so this practically does what sensorInfo::pointToGlobal is doing, the difference is, that you do not need to have the sensorInfo beforehand (it will be retrieved using the VxdID) first parameter is the local hit (as provided by getU and getV!) stored as a pair of doubles. second parameter is the coded vxdID, which carries the sensorID. third parameter, a sensorInfo can be passed for testing purposes. If no sensorInfo is passed, the member gets its own pointer to it.
ATTENTION: this function assumes, that for wedged sensors, the uCoordinate is already adapted to the vCoordinate!
Definition at line 204 of file SpacePoint.cc.
|
inlineinherited |
Returns, if u(v)-coordinate is based on cluster information.
.first is true, if u-cluster information is present
.second is true, if v-cluster information is present.
Definition at line 162 of file SpacePoint.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.
|
inlineoverridevirtualinherited |
Print out some info for this SpacePoint.
Reimplemented from RelationsInterface< BASE >.
Definition at line 115 of file SpacePoint.h.
|
inlineinherited |
Returns the number of Clusters assigned to this SpacePoint.
Definition at line 165 of file SpacePoint.h.
|
inlineinherited |
Return normalized local coordinates of the cluster in u (0 <= posU <= 1).
Definition at line 151 of file SpacePoint.h.
|
inlineinherited |
Return normalized local coordinates of the cluster in v (0 <= posV <= 1).
Definition at line 154 of file SpacePoint.h.
|
inlineinherited |
return the position vector in global coordinates
Definition at line 138 of file SpacePoint.h.
|
inlineinherited |
return the hitErrors in sigma of the global position
Definition at line 141 of file SpacePoint.h.
|
inlineinherited |
Getter for the quality of this SpacePoint.
Definition at line 191 of file SpacePoint.h.
|
inlineinherited |
Getter for the spacePoint quality index error.
Definition at line 197 of file SpacePoint.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 |
|
inline |
returns global hit position of current hit.
returns global x-position. returns global y-position. returns global z-position. returns secID of sector containing this hit.
Definition at line 62 of file SecMapTrainerHit.h.
|
inlineinherited |
Return SensorType (PXD, SVD, ...) on which the SpacePoint lives.
Definition at line 145 of file SpacePoint.h.
|
inlinestaticinherited |
takes a wedged uCoordinate, and transforms it to general uCoordinate.
Use this if you want to "unwedge" your u-coordinate. The returned value shall be like the value delivered by a uCluster without information of v (== aCluster.getPosition() ). This is only relevant for wedged/slanted sensors because of their trapezoidal shape, for rectangular shapes, the value does not change
Definition at line 278 of file SpacePoint.h.
|
inlinestaticinherited |
takes a general uCoordinate, and transforms it to corrected uCoordinate for wedged sensors.
Use this if you want to add the information of the vCluster to the local uPosition. The returned value is now dependent of vCluster and valid only for this cluster! This is only relevant for wedged/slanted sensors because of their trapezoidal shape, for rectangular shapes, the value does not change
function kept only for backward compatibility with VXDTF1
Definition at line 263 of file SpacePoint.h.
|
inlineinherited |
Return the VxdID of the sensor on which the the cluster of the SpacePoint lives.
Definition at line 148 of file SpacePoint.h.
|
inlineinherited |
|
inlineinherited |
Returns true if the SP is single clustered and the cluster is a u cluster.
Definition at line 178 of file SpacePoint.h.
|
inlineinherited |
Returns true if the SP is single clustered and the cluster is a v cluster.
Definition at line 180 of file SpacePoint.h.
|
inlineinherited |
Comparison for inequality with another SpacePoint.
Definition at line 109 of file SpacePoint.h.
|
inlineinherited |
Compare, if two SpacePoints are the same one.
As SpacePoints should live in the DataStore and comparing positions doesn't guarantee, that different underlying clusters are used, we compare here only the indices of the SpacePoint within their StoreArray --> SpacePoints are equal, if the share the index.
Definition at line 103 of file SpacePoint.h.
|
inlineinherited |
Setter for association with a track.
Definition at line 175 of file SpacePoint.h.
|
inlineprotectedinherited |
Setter for global position error from on-sensor sigmas.
Definition at line 322 of file SpacePoint.h.
|
inlineinherited |
Setter for the quality of this SpacePoint.
Definition at line 188 of file SpacePoint.h.
|
inlineinherited |
Setter for the spacePoint quality index error.
Definition at line 194 of file SpacePoint.h.
|
inlineinherited |
return the time in ns of the cluster on the U side
Definition at line 132 of file SpacePoint.h.
|
inlineinherited |
return the time in ns of the cluster on the V side
Definition at line 135 of file SpacePoint.h.
|
inlineinherited |
return the x-value of the global position of the SpacePoint
Definition at line 123 of file SpacePoint.h.
|
inlineinherited |
return the y-value of the global position of the SpacePoint
Definition at line 126 of file SpacePoint.h.
|
inlineinherited |
return the z-value of the global position of the SpacePoint
Definition at line 129 of file SpacePoint.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.
|
protectedinherited |
The bool value is true, when correct information of the coordinate exists.
.first is true, if this SpacePoint has a UCluster (only relevant for SVD, PXD always true), .second is true, if this SpacePoint has a VCluster (only relevant for SVD, PXD always true),
Definition at line 365 of file SpacePoint.h.
|
mutableprotectedinherited |
Stores whether this SpacePoint is connected to a track.
We assume, that const for SpacePoint means, things like position et cetera remain constant. The assignment status is therefore a mutable on purpose and SpacePoints can be const during tracking.
Definition at line 396 of file SpacePoint.h.
|
protectedinherited |
Local position vector normalized to sensor size (0 <= x <= 1).
.first: u, .second: v
Definition at line 349 of file SpacePoint.h.
|
protectedinherited |
|
protectedinherited |
Global position error vector in sigma.
[0]: x-uncertainty, [1] : y-uncertainty, [2] : z-uncertainty
Definition at line 342 of file SpacePoint.h.
|
protectedinherited |
Stores a quality indicator.
The value shall be between 0. and 1., where 1. means "good" and 0. means "bad".
Definition at line 381 of file SpacePoint.h.
|
protectedinherited |
Stores the error on the quality indicator.
The value comes from the binning error on the pdfs from which the QI is derived.
Definition at line 388 of file SpacePoint.h.
|
protected |
ID of sector containing this hit.
Definition at line 68 of file SecMapTrainerHit.h.
|
protectedinherited |
Stores the SensorType using the scheme of SensorInfoBase.
Currently there are the following types possible:
PXD, SVD, TEL, VXD
Definition at line 375 of file SpacePoint.h.
|
protectedinherited |
Time of the cluster on the U side in ns.
Definition at line 353 of file SpacePoint.h.
|
protectedinherited |
Time of the cluster on the V side in ns.
Definition at line 357 of file SpacePoint.h.
|
protectedinherited |
Stores the VxdID.
Definition at line 368 of file SpacePoint.h.