Belle II Software  release-08-01-10
SVDRecoHit2D Class Reference

SVDRecoHit - an extended form of SVDHit containing geometry information. More...

#include <SVDRecoHit2D.h>

Inheritance diagram for SVDRecoHit2D:
Collaboration diagram for SVDRecoHit2D:

Public Member Functions

 SVDRecoHit2D ()
 Default constructor for ROOT IO.
 
 SVDRecoHit2D (const SVDTrueHit *hit, const genfit::TrackCandHit *trackCandHit=nullptr, float sigmaU=-1, float sigmaV=-1)
 Construct SVDRecoHit from a SVDTrueHit for Monte Carlo based tracking. More...
 
 SVDRecoHit2D (VxdID::baseType vxdid, const double u, const double v, double sigmaU=-1, double sigmaV=-1)
 Construct SVDRecoHit directly from vxdid and coordinates without using a hit object from the storearray in the constructor. More...
 
 SVDRecoHit2D (const SVDCluster &uHit, const SVDCluster &vHit)
 Construct SVDRecoHit from a u- and v- SVDCluster. More...
 
 SVDRecoHit2D (const SVDRecoHit &uRecoHit, const SVDRecoHit &vRecoHit)
 Construct SVDRecoHit from a u- and v- (1D) SVDRecoHit. More...
 
virtual ~SVDRecoHit2D ()
 Destructor.
 
genfit::AbsMeasurementclone () const override
 Creating a deep copy of this hit. More...
 
VxdID getSensorID () const
 Get the compact ID.
 
const SVDTrueHitgetTrueHit () const
 Get pointer to the TrueHit used when creating this RecoHit, can be nullptr if created from something else.
 
const SVDClustergetUCluster () const
 Get pointer to the u cluster used to create this RecoHit.
 
const SVDClustergetVCluster () const
 Get pointer to the u cluster used to create this RecoHit.
 
float getU () const
 Get u coordinate.
 
float getV () const
 Get v coordinate.
 
float getUVariance () const
 Get u coordinate variance.
 
float getVVariance () const
 Get v coordinate variance.
 
float getUVCov () const
 Get u-v error covariance.
 
float getEnergyDep () const
 Get deposited energy.
 
virtual std::vector< genfit::MeasurementOnPlane * > constructMeasurementsOnPlane (const genfit::StateOnPlane &state) const override
 Get deposited energy error. More...
 
int getPlaneId () const
 
virtual SharedPlanePtr constructPlane (const StateOnPlane &state) const override
 Construct (virtual) detector plane (use state's AbsTrackRep). More...
 
virtual const AbsHMatrix * constructHMatrix (const AbsTrackRep *) const override
 Returns a new AbsHMatrix object. More...
 
virtual void setPlane (const SharedPlanePtr &physicalPlane, int planeId=-1)
 
void setStripV (bool v=true)
 Use if the coordinate for 1D hits measured in V direction. More...
 
TrackPoint * getTrackPoint () const
 
void setTrackPoint (TrackPoint *tp)
 
const TVectorD & getRawHitCoords () const
 
TVectorD & getRawHitCoords ()
 
const TMatrixDSym & getRawHitCov () const
 
TMatrixDSym & getRawHitCov ()
 
int getDetId () const
 
int getHitId () const
 
virtual bool isLeftRightMeasurement () const
 If the AbsMeasurement is a wire hit, the left/right resolution will be used.
 
virtual int getLeftRightResolution () const
 
unsigned int getDim () const
 
void setRawHitCoords (const TVectorD &coords)
 
void setRawHitCov (const TMatrixDSym &cov)
 
void setDetId (int detId)
 
void setHitId (int hitId)
 
virtual void Print (const Option_t *="") const
 

Protected Attributes

SharedPlanePtr physicalPlane_
 
int planeId_
 This is persistent, but '!' makes ROOT shut up.
 
bool stripV_
 
TVectorD rawHitCoords_
 
TMatrixDSym rawHitCov_
 
int detId_
 
int hitId_
 
TrackPoint * trackPoint_
 Pointer to TrackPoint where the measurement belongs to.
 

Private Types

enum  { HIT_DIMENSIONS = 2 }
 

Private Member Functions

void setDetectorPlane ()
 Set up Detector plane information.
 
TVectorD applyPlanarDeformation (TVectorD rawHit, std::vector< double > planarParameters, const genfit::StateOnPlane &state) const
 Apply planar deformation of sensors.
 

Private Attributes

unsigned short m_sensorID
 Unique sensor identifier.
 
const SVDTrueHitm_trueHit
 Pointer to the Truehit used to generate this hit.
 
const SVDClusterm_uCluster
 Pointer to mother uCluster.
 
const SVDClusterm_vCluster
 Pointer to mother vCluster.
 
float m_energyDep
 deposited energy.
 

Detailed Description

SVDRecoHit - an extended form of SVDHit containing geometry information.

To create a list of SVDRecoHits for all SVDTrueHits belonging to one MCParticle do something like:

//Get the MCParticle in question
MCParticle* mcParticle = ...
//Iterate over the relation and create a list of hits
vector<SVDRecoHit*> hits;
RelationIndex<MCParticle,SVDTrueHit> relMCTrueHit;
RelationIndex<MCParticle,SVDTrueHit>::range_from it = relMCTrueHit.getElementsFrom(mcParticle);
for(; it.first!=it.second; ++it.first){
hits.push_back(new SVDRecoHit(it.first->to));
}
boost::iterator_range< iterator_from > range_from
Iterator range [first,second) of the from side.

Definition at line 46 of file SVDRecoHit2D.h.

Member Enumeration Documentation

◆ anonymous enum

anonymous enum
private
Enumerator
HIT_DIMENSIONS 

sensitive Dimensions of the Hit

Definition at line 133 of file SVDRecoHit2D.h.

Constructor & Destructor Documentation

◆ SVDRecoHit2D() [1/4]

SVDRecoHit2D ( const SVDTrueHit hit,
const genfit::TrackCandHit trackCandHit = nullptr,
float  sigmaU = -1,
float  sigmaV = -1 
)
explicit

Construct SVDRecoHit from a SVDTrueHit for Monte Carlo based tracking.

This requires a valid random number generator to be initialized at gRandom. The Hit position will be smeared using a gaussian smearing with sigmaU and sigmaV along u and v respectively

If one of the errors is set <0, a default resolution will be assumed for both values by dividing the pixel size by sqrt(12).

Parameters
hitSVDTrueHit to use as base
trackCandHit
sigmaUError of the Hit along u
sigmaVError of the Hit along v

Definition at line 29 of file SVDRecoHit2D.cc.

◆ SVDRecoHit2D() [2/4]

SVDRecoHit2D ( VxdID::baseType  vxdid,
const double  u,
const double  v,
double  sigmaU = -1,
double  sigmaV = -1 
)

Construct SVDRecoHit directly from vxdid and coordinates without using a hit object from the storearray in the constructor.

Parameters
vxdidthe vxd id so the reco hit knows on which sensor the measurment took place
ucoordinate of the Hit along u
vcoordinate of the Hit along v
sigmaUError of the Hit along u
sigmaVError of the Hit along v

Definition at line 59 of file SVDRecoHit2D.cc.

◆ SVDRecoHit2D() [3/4]

SVDRecoHit2D ( const SVDCluster uHit,
const SVDCluster vHit 
)

Construct SVDRecoHit from a u- and v- SVDCluster.

Parameters
uHitthe u-type SVDCluster
vHitthe v-type SVDCluster

Definition at line 81 of file SVDRecoHit2D.cc.

◆ SVDRecoHit2D() [4/4]

SVDRecoHit2D ( const SVDRecoHit uRecoHit,
const SVDRecoHit vRecoHit 
)

Construct SVDRecoHit from a u- and v- (1D) SVDRecoHit.

Parameters
uRecoHitthe u-type SVDRecoHit
vRecoHitthe v-type SVDRecoHit

Definition at line 118 of file SVDRecoHit2D.cc.

Member Function Documentation

◆ clone()

genfit::AbsMeasurement * clone ( ) const
overridevirtual

Creating a deep copy of this hit.

Overrides the method inherited from GFRecoHit.

Reimplemented from PlanarMeasurement.

Definition at line 226 of file SVDRecoHit2D.cc.

◆ constructHMatrix()

const AbsHMatrix * constructHMatrix ( const AbsTrackRep ) const
overridevirtualinherited

Returns a new AbsHMatrix object.

Caller must take ownership.

Implements AbsMeasurement.

Reimplemented in PlanarMomentumMeasurement, SVDRecoHit, PXDRecoHit, and AlignableBKLMRecoHit.

Definition at line 67 of file PlanarMeasurement.cc.

◆ constructMeasurementsOnPlane()

std::vector< genfit::MeasurementOnPlane * > constructMeasurementsOnPlane ( const genfit::StateOnPlane state) const
overridevirtual

Get deposited energy error.

Methods that actually interface to Genfit.

Reimplemented from PlanarMeasurement.

Definition at line 217 of file SVDRecoHit2D.cc.

◆ constructPlane()

SharedPlanePtr constructPlane ( const StateOnPlane state) const
overridevirtualinherited

Construct (virtual) detector plane (use state's AbsTrackRep).

It's possible to make corrections to the plane here. The state should be defined somewhere near the measurement. For virtual planes, the state will be extrapolated to the POCA to point (SpacepointMeasurement) or line (WireMeasurement), and from this info the plane will be constructed.

Implements AbsMeasurement.

Definition at line 46 of file PlanarMeasurement.cc.

◆ setStripV()

void setStripV ( bool  v = true)
inlineinherited

Use if the coordinate for 1D hits measured in V direction.

Per default for 1D planar hits, the coordinate is measured in U direction. With this function you can set it to be measured in V direction. This affects the outcoe of constructHMatrix().

Definition at line 70 of file PlanarMeasurement.h.


The documentation for this class was generated from the following files: