40 ,
m_particleCreator(
"Trk::TrackParticleCreatorTool/TrackParticleCreatorTool", this)
108 declareInterface<Trk::IFillNtupleTool>(
this);
173 return StatusCode::FAILURE;
177 return StatusCode::SUCCESS;
186 }
else ATH_MSG_WARNING(
"Variable m_file not set or not pointing to open output file.");
187 return StatusCode::SUCCESS;
194 return StatusCode::SUCCESS;
213 constexpr double invalidParameterValue{-999.};
214 m_d0 = invalidParameterValue;
215 m_z0 = invalidParameterValue;
216 m_phi0 = invalidParameterValue;
217 m_theta = invalidParameterValue;
219 m_pt = invalidParameterValue;
220 m_eta = invalidParameterValue;
221 m_xvtx = invalidParameterValue;
222 m_yvtx = invalidParameterValue;
223 m_zvtx = invalidParameterValue;;
225 constexpr int initialiseNHits{0};
236 constexpr double invalidChiSq(-1e12);
237 constexpr int invalidDegreesOfFreedom{-999};
240 m_ndof = invalidDegreesOfFreedom;
243 if (not aMeasPer)
ATH_MSG_ERROR(
"Could not get Trk::MeasuredPerigee");
250 ATH_MSG_DEBUG(itrk <<
". " <<
" Track Parameters (d0, z0, phi0, theta, q/p)");
260 uint8_t iSummaryValue(0);
262 if (not trackPart)
ATH_MSG_ERROR(
"Could not get xAOD::TrackParticle");
302 if (not fitQual)
ATH_MSG_ERROR(
"No fit quality assigned to the track");
320 int nhitsTotal = alignTSOSCollection->
size();
395 for (; atsit != atsit_end; ++atsit) {
434 std::vector<Trk::Residual>::const_iterator ires = atsos->
firstResidual();
460 double etaval = -std::log(std::tan(std::atan(1. / std::abs(
m_hit_cotth[nhits])) / 2.));
469 const std::vector<Amg::VectorX>* derivs = atsos->
derivatives();
471 int npar = derivs->at(0).rows();
474 int naPar = alignPars->
size();
476 if (npar != naPar)
ATH_MSG_WARNING(
"number of derivatives on AlignTSOS doesn't match the one on AlignModule");
479 for (
int i = 0; i < npar; i++) {
480 double derivative = (*derivs)[0][i];
524 for (
int i = 0; i < npar; i++) {
525 double derivative = (*derivs)[1][i];
577 <<
"Some hits will not be stored.");
626 m_tree =
new TTree(
"IDAlign",
"Inner Detector Alignment Ntuple");
#define ATH_CHECK
Evaluate an expression and check for errors.
#define ATH_MSG_WARNING(x)
This is an Identifier helper class for the TRT subdetector.
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T, V, H > &t)
ServiceHandle< StoreGateSvc > & evtStore()
const ServiceHandle< StoreGateSvc > & detStore() const
DataModel_detail::const_iterator< DataVector > const_iterator
Standard const_iterator.
const T * at(size_type n) const
Access an element, as an rvalue.
const_iterator end() const noexcept
Return a const_iterator pointing past the end of the collection.
const_iterator begin() const noexcept
Return a const_iterator pointing at the beginning of the collection.
size_type size() const noexcept
Returns the number of elements in the collection.
TransformParameters
enum to keep track of transformation coordinates
const RIO_OnTrack * rio() const
returns RIO_OnTrack or leading RIO of CompetingRIOsOnTrack (assigned by c'tor)
const TrackParameters * unbiasedTrackPars() const
returns pointer to unbiased track parameters if present
const std::vector< Amg::VectorX > * derivatives() const
returns pointer to vector of derivatives
int nResDim() const
returns number of measurement residual + scatterer residual dimensions
std::vector< Residual >::const_iterator firstResidual() const
returns first Residual iterator
const AlignModule * module() const
accessor method for AlignModule to which tsos belongs
std::string dumpMeasType() const
returns string corresponding to the measurement type
TrackState::MeasurementType measType() const
returns measurement type enum
const AlignTSOSCollection * alignTSOSCollection() const
returns collection of alignTSOS
Class to represent and store fit qualities from track reconstruction in terms of and number of degre...
int numberDoF() const
returns the number of degrees of freedom of the overall track or vertex fit as integer
double chiSquared() const
returns the of the overall track fit
bool contains(ParamDefs par) const
The simple check for the clients whether the parameter is contained.
const LocalParameters & localParameters() const
Interface method to get the LocalParameters.
const Amg::MatrixX & localCovariance() const
Interface method to get the localError.
double eta() const
Access method for pseudorapidity - from momentum.
const Amg::Vector3D & momentum() const
Access method for the momentum.
const Amg::Vector3D & position() const
Access method for the position.
Class to handle RIO On Tracks ROT) for InDet and Muons, it inherits from the common MeasurementBase.
Identifier identify() const
return the identifier -extends MeasurementBase
virtual const Amg::Vector3D & globalPosition() const override=0
Interface method to get the global Position.
const TrackParameters * trackParameters() const
return ptr to trackparameters const overload
bool type(const TrackStateOnSurfaceType type) const
Use this method to find out if the TSoS is of a certain type: i.e.
@ Measurement
This is a measurement, and will at least contain a Trk::MeasurementBase.
const Perigee * perigeeParameters() const
return Perigee.
const FitQuality * fitQuality() const
return a pointer to the fit quality const-overload
uint32_t runNumber() const
The current event's run number.
uint64_t eventNumber() const
The current event's event number.
bool summaryValue(uint8_t &value, const SummaryType &information) const
Accessor for TrackSummary values.
double error(const Amg::MatrixX &mat, int index)
return diagonal error of the matrix caller should ensure the matrix is symmetric and the index is in ...
Eigen::Matrix< double, 3, 1 > Vector3D
ParametersT< TrackParametersDim, Charged, PerigeeSurface > Perigee
DataVector< AlignTSOS > AlignTSOSCollection
ParametersBase< TrackParametersDim, Charged > TrackParameters
EventInfo_v1 EventInfo
Definition of the latest event info version.
TrackParticle_v1 TrackParticle
Reference the current persistent version:
@ numberOfPixelHoles
number of pixel layers on track with absence of hits [unit8_t].
@ numberOfTRTHits
number of TRT hits [unit8_t].
@ numberOfSCTHits
number of hits in SCT [unit8_t].
@ numberOfPixelHits
these are the pixel hits, including the b-layer [unit8_t].
@ numberOfPixelSharedHits
number of Pixel all-layer hits shared by several tracks [unit8_t].
@ numberOfSCTSharedHits
number of SCT hits shared by several tracks [unit8_t].
@ numberOfSCTHoles
number of SCT holes [unit8_t].