 |
Belle II Software
release-05-01-25
|
11 #include <tracking/modules/spacePointCreator/SPTCmomentumSeedRetrieverModule.h>
12 #include <framework/logging/Logger.h>
13 #include <framework/geometry/BFieldManager.h>
24 setDescription(
"A module for creating momentum seeds for spacepoint track candidates.");
25 setPropertyFlags(c_ParallelProcessingCertified);
27 addParam(
"tcArrayName", m_PARAMtcArrayName,
" sets the name of expected StoreArray with SpacePointTrackCand in it.",
42 B2DEBUG(1,
"SPTCmomentumSeedRetrieverModule:beginRun: B-Field z-component: " <<
m_bFieldZ);
50 B2DEBUG(1,
"\n" <<
"SPTCmomentumSeedRetrieverModule:event: event " <<
m_eventCounter <<
", got " <<
57 B2DEBUG(1,
"\n" <<
"SPTCmomentumSeedRetrieverModule:event: this TC has got " << aTC.size() <<
" hits\n");
69 B2DEBUG(1,
"SPTCmomentumSeedRetrieverModule:endRun: events: " <<
m_eventCounter
70 <<
", nSPTCsPerEvent: " << invEvents *
float(
m_nTCsTotal)
77 TVectorD stateSeed(6);
78 TMatrixDSym covSeed(6);
80 covSeed(0, 0) = 0.01 ; covSeed(1, 1) = 0.01 ; covSeed(2, 2) = 0.04 ;
81 covSeed(3, 3) = 0.01 ; covSeed(4, 4) = 0.01 ; covSeed(5, 5) = 0.04 ;
87 stateSeed(0) = (sortedHits.front()->X());
88 stateSeed(1) = (sortedHits.front()->Y());
89 stateSeed(2) = (sortedHits.front()->Z());
91 auto momentumSeed = *(results.p);
92 stateSeed(3) = momentumSeed.X();
93 stateSeed(4) = momentumSeed.Y();
94 stateSeed(5) = momentumSeed.Z();
104 double chargeSeed = results.curvatureSign ? -1 * (*(results.curvatureSign)) : 0;
107 return (results.p && results.curvatureSign);
void beginRun() override
Prints a header for each new run.
const std::vector< const Belle2::SpacePoint * > getSortedHits() const
get hits (space points) sorted by their respective sorting parameter
Container for complete fit/estimation results.
static void getField(const double *pos, double *field)
return the magnetic field at a given position.
unsigned int m_nTCsTotal
total number of TCs found in SpacePointTrackCand-container.
#define REG_MODULE(moduleName)
Register the given module (without 'Module' suffix) with the framework.
void endRun() override
Prints a footer for each run which ended.
@ c_isActive
bit 11: SPTC is active (i.e.
void setMagneticFieldStrength(double magneticFieldZ=1.5)
Setter for z component of magnetic field.
void setCovSeed(const TMatrixDSym &cov)
set the covariance matrix seed
bool createSPTCmomentumSeed(SpacePointTrackCand &aTC)
Generates momentum seed at the position of innermost hit of given TC.
unsigned int m_eventCounter
knows current event number.
QualityEstimatorRiemannHelixFit m_estimator
the QualityEstimator used to determine momentum seed.
static const double T
[tesla]
void set6DSeed(const TVectorD &state6D)
set the 6D state seed
StoreArray< SpacePointTrackCand > m_spacePointTrackCands
the storeArray for SpacePointTrackCands as member, is faster than recreating link for each event.
Abstract base class for different kinds of events.
void setChargeSeed(double charge)
Setter for assumed charge of tracked particle.
void InitializeCounters()
initialize variables to avoid nondeterministic behavior
void event() override
Applies the circleFit at given sets of TCs.
double m_bFieldZ
Bz component of the magnetic field, will be updated runwise.
A module for creating momentum seeds for spacepoint track candidates.
virtual QualityEstimationResults estimateQualityAndProperties(std::vector< SpacePoint const * > const &measurements)
Quality estimation providing additional quantities Calculates quality indicator in range [0,...
int getEntries() const
Get the number of objects in the array.
Storage for (VXD) SpacePoint-based track candidates.