BmnRoot 26.10.0-233-gb9bbe585
Software framework of the BM@N experiment
Loading...
Searching...
No Matches
BmnAligner Class Reference

#include <BmnAligner.h>

Inheritance diagram for BmnAligner:
Collaboration diagram for BmnAligner:

Classes

struct  LooHit_t
struct  AlphaData_t

Public Types

typedef std::deque< BmnAlignResult > Results_t

Public Member Functions

 BmnAligner (const BmnMeasureModel *measureModel, BmnDetectorModel *modelDetector, const char *filesListPath, const char *constraintsPath=nullptr, const char *presigmaPath=nullptr, Int_t nThreads=1, Bool_t withProgressBar=kTRUE)
 ~BmnAligner ()
Bool_t Align (Double_t zeroRand=0.0, Int_t maxRounds=3)
Bool_t PrepareData (const char *dumpPath=nullptr, Bool_t fitTargetZ=kTRUE)
Bool_t SaveSolution (const char *jsonPath, Bool_t withAlpha=kFALSE)
Bool_t LoadSolution (const char *jsonPath)
void RandomizeSolution (BmnAlignResult &solution, TVectorD *pStdDevLeaf, TVectorD *pStdDevComp)
void AddBlankSolution ()
void DropLastResult ()
void LinregAlphaMSE ()
Int_t SelectVertexHits ()
Bool_t FitTargetZ (Double_t &z0, Double_t &z0Err)
Bool_t Initialized () const noexcept
Int_t TotalTracks () const noexcept
Int_t TotalHits () const noexcept
Results_t & Results () noexcept
const Results_t & Results () const noexcept
const BmnAlignHierarchy & Hierarchy () const noexcept
const BmnParamLayout & Layout () const noexcept
const BmnDetectorModel * DetectorModel () const noexcept
const BmnMeasureModel * MeasureModel () const noexcept
BmnRootIterator * RootIterator () noexcept
BmnRamIterator * RamIterator () const noexcept
const BmnAlignPriors & Priors () const noexcept
const char * ConstraintsPath () const noexcept
Double_t TotalCpuTime () const noexcept
Double_t TotalRealTime () const noexcept
Double_t MaxZvalue () const noexcept
Int_t TracksUsable () const noexcept
Int_t Elements () const noexcept
const VecBool_t * TrackUsable () const noexcept
BmnSimpleProgressBar * ProgressBar () const noexcept
const BmnAlignResult & ResultLast () const
BmnAlignResult & ResultLast ()
const BmnAlignResult & ResultZero () const
BmnAlignResult & ResultZero ()

Protected Types

typedef std::vector< LooHit_t > VecLooHits_t
typedef std::vector< AlphaData_t > VecAlphaRecs_t
typedef std::vector< BmnHitRecord > VecHitRecs_t

Protected Member Functions

Bool_t IterateAlignment ()
Double_t CalculateMSE (const TVectorD &solution)
Double_t CalculateMSE (Bool_t withResiduals)
Bool_t SolveGlobal (const TMatrixD &mCL, const TVectorD &vBL, Bool_t optimStep=kFALSE)
Int_t SelectOutliers ()
void LeaveOneOut (BmnRamIterator *pItr, VecLooHits_t &hits) const
void InitIterators ()
void MarkTime (TStopwatch &timer)
void DoneInTime (TStopwatch &timer, const char *stage)
Bool_t CheckInit (const char *stage)
void CheckResults () const

Protected Attributes

const BmnMeasureModel * fpMeasureModel
BmnDetectorModel * fpDetModel
BmnAlignHierarchy fHierarchy
BmnAlignPriors fPriors
const char * fpConstraintsPath {nullptr}
const char * fpPresigmaPath {nullptr}
BmnSimpleProgressBar * fpProgressBar {nullptr}
Bool_t fInitialized {kFALSE}
Bool_t fMSEclcSlow {kFALSE}
Bool_t fForceRegular {kFALSE}
Bool_t fAlphaReady {kFALSE}
UInt_t fMSEclcCounter {0u}
UInt_t fMSEclcTick {1u}
Double_t fTotalCpuTime {0.0}
Double_t fTotalRealTime {0.0}
Int_t fIteration {-1}
Int_t fRegularIters {0}
VecBool_t * fpTrackUsable {nullptr}
Int_t fTracksUsableCnt {0}
Int_t fTotalTracks {0}
Int_t fTotalHits {0}
VecInt_t fHitsPerDetector
VecDouble_t fLeafZsum
VecDouble_t fLeafZmin
VecDouble_t fLeafZmax
RM::BrentMinimizer1D fBrent
BmnRootIterator * fpRootIterator {nullptr}
BmnRamIterator * fpRamIterator {nullptr}
VecAlphaRecs_t fAlphaRecs
VecHitRecs_t fHits
 indexed by hit, the same way as fHits
VecInt_t fFirstHits
 hits of all tracks, stored track by track
BmnAlignResult * fpResultPrev {nullptr}
BmnAlignResult * fpResultLast {nullptr}
Results_t fIterationResults
Double_t fMaxZvalue {0.0}

Private Member Functions

void SelectIterator (Int_t threadNum, Int_t &trackIdx, BmnRamIterator *&pItr)
template<typename Method, typename... Args>
void RunThreads (Method method, Args... args)
void ProcessTracks (TVectorD *pvB_dash, TMatrixD *pmC_dash, Int_t threadNum)
void CalculateLocals (TVectorD *pvDA, Int_t threadNum)
void CalculateMSEpart (Bool_t withResiduals, Int_t threadNum)
void LinRegressionAlphaPart (Int_t threadNum)
void HitPullsPart (VecDouble_t *pPx, VecDouble_t *pPy, Int_t threadNum)
void VertexResidualsPart (VecDouble_t *pRx, VecDouble_t *pRy, Int_t threadNum)

Private Attributes

std::vector< BmnRamIterator * > fpIterators
VecInt_t fFirstTracksIdx
std::mutex fMutexGlobal
Int_t fThreadsCnt {1}

Detailed Description

Definition at line 35 of file BmnAligner.h.

Member Typedef Documentation

◆ Results_t

Definition at line 65 of file BmnAligner.h.

◆ VecAlphaRecs_t

typedef std::vector<AlphaData_t> BmnAligner::VecAlphaRecs_t
protected

Definition at line 151 of file BmnAligner.h.

◆ VecHitRecs_t

typedef std::vector<BmnHitRecord> BmnAligner::VecHitRecs_t
protected

Definition at line 152 of file BmnAligner.h.

◆ VecLooHits_t

typedef std::vector<LooHit_t> BmnAligner::VecLooHits_t
protected

Definition at line 99 of file BmnAligner.h.

Constructor & Destructor Documentation

◆ BmnAligner()

BmnAligner::BmnAligner ( const BmnMeasureModel * measureModel,
BmnDetectorModel * modelDetector,
const char * filesListPath,
const char * constraintsPath = nullptr,
const char * presigmaPath = nullptr,
Int_t nThreads = 1,
Bool_t withProgressBar = kTRUE )

◆ ~BmnAligner()

BmnAligner::~BmnAligner ( )

Member Function Documentation

◆ AddBlankSolution()

void BmnAligner::AddBlankSolution ( )
inline

Definition at line 226 of file BmnAligner.h.

References BMN_GLOBAL_PARAMS_PD, fHierarchy, fIterationResults, fMaxZvalue, fpDetModel, fpResultLast, fpResultPrev, and fTotalTracks.

Referenced by Align(), FitTargetZ(), IterateAlignment(), LoadSolution(), and BmnAlignTestTask::Make().

Here is the caller graph for this function:

◆ Align()

Bool_t BmnAligner::Align ( Double_t zeroRand = 0.0,
Int_t maxRounds = 3 )

Definition at line 617 of file BmnAligner.cxx.

References TMath::Abs(), AddBlankSolution(), BMN_GLOBAL_PARAMS_PD, CalculateMSE(), CheckInit(), DoneInTime(), fForceRegular, fHierarchy, fIterationResults, fMSEclcSlow, fMSEclcTick, fpDetModel, fpResultLast, fpResultPrev, fRegularIters, fTotalTracks, fTracksUsableCnt, TVectorT< class Element >::GetMatrixArray(), TVectorT< class Element >::GetNrows(), TVectorT< class Element >::GetSub(), i, IterateAlignment(), LinregAlphaMSE(), RandomizeSolution(), TStopwatch::RealTime(), TStopwatch::Reset(), SelectOutliers(), SelectVertexHits(), TStopwatch::Start(), and TStopwatch::Stop().

Referenced by align().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ CalculateLocals()

void BmnAligner::CalculateLocals ( TVectorD * pvDA,
Int_t threadNum )
private

Definition at line 1184 of file BmnAligner.cxx.

References BMN_GLOBAL_PARAMS_PD, BmnDataIterator::EndOfTracks(), fAlphaRecs, fFirstHits, fpResultLast, fpResultPrev, fpTrackUsable, TVectorT< class Element >::GetMatrixArray(), BmnAligner::AlphaData_t::mGGammaInv, BmnRamIterator::NextTrack(), BmnAligner::AlphaData_t::paramIdx, BmnRamIterator::ResetAll(), SelectIterator(), and ROOT::Math::Transpose().

Referenced by SolveGlobal().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ CalculateMSE() [1/2]

Double_t BmnAligner::CalculateMSE ( Bool_t withResiduals)
protected

Definition at line 1416 of file BmnAligner.cxx.

References CalculateMSEpart(), fMSEclcCounter, fMSEclcSlow, fMSEclcTick, fpProgressBar, fpResultLast, and RunThreads().

Here is the call graph for this function:

◆ CalculateMSE() [2/2]

Double_t BmnAligner::CalculateMSE ( const TVectorD & solution)
protected

Definition at line 1403 of file BmnAligner.cxx.

References BmnAlignResult::A(), CalculateMSE(), and fpResultLast.

Referenced by Align(), CalculateMSE(), IterateAlignment(), LinregAlphaMSE(), and SolveGlobal().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ CalculateMSEpart()

void BmnAligner::CalculateMSEpart ( Bool_t withResiduals,
Int_t threadNum )
private

Definition at line 1436 of file BmnAligner.cxx.

References delta, BmnDataIterator::EndOfHits(), BmnDataIterator::EndOfTracks(), TH1::Fill(), TH2::Fill(), fMutexGlobal, fpDetModel, fpMeasureModel, fpResultLast, fpTrackUsable, TH1::GetNbinsX(), TH1::GetNbinsY(), TH1::GetXaxis(), TAxis::GetXmax(), TAxis::GetXmin(), TH1::GetYaxis(), BmnRamIterator::HitDetectorID(), BmnRamIterator::HitWx(), BmnRamIterator::HitWy(), BmnRamIterator::HitX(), BmnRamIterator::HitY(), BmnRamIterator::HitZ(), BmnRamIterator::NextHit(), BmnRamIterator::NextTrack(), BmnRamIterator::ResetAll(), SelectIterator(), and z.

Referenced by CalculateMSE().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ CheckInit()

Bool_t BmnAligner::CheckInit ( const char * stage)
inlineprotected

Definition at line 200 of file BmnAligner.h.

References fInitialized.

Referenced by Align(), LoadSolution(), PrepareData(), and SaveSolution().

Here is the caller graph for this function:

◆ CheckResults()

void BmnAligner::CheckResults ( ) const
inlineprotected

Definition at line 260 of file BmnAligner.h.

References fIterationResults.

Referenced by ResultLast(), ResultLast(), ResultZero(), and ResultZero().

Here is the caller graph for this function:

◆ ConstraintsPath()

const char * BmnAligner::ConstraintsPath ( ) const
inlinenoexcept

Definition at line 78 of file BmnAligner.h.

Referenced by BmnAlignReport::ModesBelow().

Here is the caller graph for this function:

◆ DetectorModel()

const BmnDetectorModel * BmnAligner::DetectorModel ( ) const
inlinenoexcept

Definition at line 73 of file BmnAligner.h.

Referenced by BmnAlignTestTask::Make(), and BmnAlignReport::ModesBelow().

Here is the caller graph for this function:

◆ DoneInTime()

void BmnAligner::DoneInTime ( TStopwatch & timer,
const char * stage )
inlineprotected

Definition at line 252 of file BmnAligner.h.

References TStopwatch::CpuTime(), MarkTime(), and TStopwatch::RealTime().

Referenced by BmnAligner(), Align(), LoadSolution(), and PrepareData().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ DropLastResult()

void BmnAligner::DropLastResult ( )
inline

Definition at line 236 of file BmnAligner.h.

References fIterationResults, fpResultLast, and fpResultPrev.

Referenced by FitTargetZ(), and BmnAlignTestTask::Make().

Here is the caller graph for this function:

◆ Elements()

Int_t BmnAligner::Elements ( ) const
inlinenoexcept

Definition at line 83 of file BmnAligner.h.

Referenced by PrepareData(), and RandomizeSolution().

Here is the caller graph for this function:

◆ FitTargetZ()

◆ Hierarchy()

const BmnAlignHierarchy & BmnAligner::Hierarchy ( ) const
inlinenoexcept

Definition at line 71 of file BmnAligner.h.

Referenced by BmnAlignReport::Correlations(), BmnAlignTestTask::Make(), BmnAlignReport::ModesBelow(), and BmnAlignReport::Results().

Here is the caller graph for this function:

◆ HitPullsPart()

void BmnAligner::HitPullsPart ( VecDouble_t * pPx,
VecDouble_t * pPy,
Int_t threadNum )
private

Definition at line 1855 of file BmnAligner.cxx.

References BmnDataIterator::EndOfTracks(), fFirstHits, fpDetModel, LeaveOneOut(), BmnRamIterator::NextTrack(), BmnRamIterator::ResetAll(), and SelectIterator().

Referenced by SelectOutliers().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Initialized()

Bool_t BmnAligner::Initialized ( ) const
inlinenoexcept

Definition at line 66 of file BmnAligner.h.

Referenced by align(), BmnAlignReport::Draw(), BmnAlignTestTask::Make(), and makett().

Here is the caller graph for this function:

◆ InitIterators()

void BmnAligner::InitIterators ( )
protected

Definition at line 1875 of file BmnAligner.cxx.

References fFirstTracksIdx, fpIterators, fpRamIterator, fThreadsCnt, fTotalTracks, and i.

Referenced by BmnAligner().

Here is the caller graph for this function:

◆ IterateAlignment()

Bool_t BmnAligner::IterateAlignment ( )
protected

Definition at line 804 of file BmnAligner.cxx.

References AddBlankSolution(), CalculateMSE(), TStopwatch::CpuTime(), fAlphaReady, fForceRegular, fHierarchy, fIteration, fMSEclcCounter, fpProgressBar, fpResultLast, fpResultPrev, fPriors, fRegularIters, fThreadsCnt, i, TMatrixT< Double_t >::kTransposed, ROOT::Math::BrentMinimizer1D::Minimize(), ProcessTracks(), TStopwatch::RealTime(), TMatrixT< class Element >::ResizeTo(), TVectorT< class Element >::ResizeTo(), RunThreads(), ROOT::Math::BrentMinimizer1D::SetFunction(), ROOT::Math::BrentMinimizer1D::SetNpx(), TMatrixT< class Element >::SetSub(), SolveGlobal(), and ROOT::Math::BrentMinimizer1D::XMinimum().

Referenced by Align(), and BmnAlignerTest::IterateAlignment().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Layout()

const BmnParamLayout & BmnAligner::Layout ( ) const
inlinenoexcept

Definition at line 72 of file BmnAligner.h.

Referenced by BmnAlignReport::Correlations(), BmnAlignReport::ModesBelow(), and BmnAlignReport::Results().

Here is the caller graph for this function:

◆ LeaveOneOut()

void BmnAligner::LeaveOneOut ( BmnRamIterator * pItr,
VecLooHits_t & hits ) const
protected

Definition at line 1767 of file BmnAligner.cxx.

References BmnWeightedLine::Add(), BmnWeightedLine::At0(), BmnWeightedLine::Det(), BmnAligner::LooHit_t::detID, BmnDataIterator::EndOfHits(), fpDetModel, fpMeasureModel, fpResultLast, BmnRamIterator::HitDetectorID(), BmnRamIterator::HitWx(), BmnRamIterator::HitWy(), BmnRamIterator::HitX(), BmnRamIterator::HitY(), BmnRamIterator::HitZ(), iX, iY, iZ, BmnRamIterator::NextHit(), BmnAligner::LooHit_t::px, BmnAligner::LooHit_t::py, TMath::QuietNaN(), BmnWeightedLine::Remove(), BmnRamIterator::ResetHits(), BmnAligner::LooHit_t::rx, BmnAligner::LooHit_t::ry, BmnWeightedLine::Slope(), BmnWeightedLine::Var(), and z.

Referenced by HitPullsPart(), and VertexResidualsPart().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ LinregAlphaMSE()

void BmnAligner::LinregAlphaMSE ( )
inline

Definition at line 209 of file BmnAligner.h.

References CalculateMSE(), LinRegressionAlphaPart(), and RunThreads().

Referenced by Align(), LoadSolution(), SelectOutliers(), and SelectVertexHits().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ LinRegressionAlphaPart()

void BmnAligner::LinRegressionAlphaPart ( Int_t threadNum)
private

Definition at line 537 of file BmnAligner.cxx.

References BmnWeightedLine::Add(), BmnWeightedLine::At0(), BmnDataIterator::EndOfHits(), BmnDataIterator::EndOfTracks(), fpDetModel, fpMeasureModel, fpResultLast, BmnRamIterator::HitDetectorID(), BmnRamIterator::HitWx(), BmnRamIterator::HitWy(), BmnRamIterator::HitX(), BmnRamIterator::HitY(), BmnRamIterator::HitZ(), iX, iY, iZ, BmnRamIterator::NextHit(), BmnRamIterator::NextTrack(), BmnRamIterator::ResetAll(), SelectIterator(), and BmnWeightedLine::Slope().

Referenced by LinregAlphaMSE().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ LoadSolution()

Bool_t BmnAligner::LoadSolution ( const char * jsonPath)

Definition at line 480 of file BmnAligner.cxx.

References AddBlankSolution(), CheckInit(), BmnAlignConfig::Solution::composites, DoneInTime(), fHierarchy, fpRamIterator, fpResultLast, BmnAlignConfig::Solution::leaves, LinregAlphaMSE(), BmnAlignConfig::NodeValues::node, BmnAlignConfig::ReadSolution(), TVectorT< class Element >::SetSub(), BmnAlignConfig::NodeValues::values, and BmnAlignConfig::Solution::zeroComposites.

Referenced by align(), and makett().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ MarkTime()

void BmnAligner::MarkTime ( TStopwatch & timer)
inlineprotected

Definition at line 245 of file BmnAligner.h.

References TStopwatch::CpuTime(), fTotalCpuTime, fTotalRealTime, TStopwatch::RealTime(), and TStopwatch::Stop().

Referenced by DoneInTime().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ MaxZvalue()

Double_t BmnAligner::MaxZvalue ( ) const
inlinenoexcept

Definition at line 81 of file BmnAligner.h.

Referenced by BmnAlignReport::Draw().

Here is the caller graph for this function:

◆ MeasureModel()

const BmnMeasureModel * BmnAligner::MeasureModel ( ) const
inlinenoexcept

Definition at line 74 of file BmnAligner.h.

Referenced by BmnAlignTestTask::Make().

Here is the caller graph for this function:

◆ PrepareData()

◆ Priors()

const BmnAlignPriors & BmnAligner::Priors ( ) const
inlinenoexcept

Definition at line 77 of file BmnAligner.h.

Referenced by BmnAlignTestTask::Make(), BmnAlignReport::ModesBelow(), and BmnAlignReport::Results().

Here is the caller graph for this function:

◆ ProcessTracks()

void BmnAligner::ProcessTracks ( TVectorD * pvB_dash,
TMatrixD * pmC_dash,
Int_t threadNum )
private

Definition at line 1236 of file BmnAligner.cxx.

References ROOT::Math::SMatrix< class T, unsigned int D1, unsigned int D2, class R >::Array(), BMN_GLOBAL_PARAMS_PD, BMN_LOCAL_PARAMS_PT, BmnDataIterator::EndOfHits(), BmnDataIterator::EndOfTracks(), fAlphaRecs, fFirstHits, fHierarchy, fMutexGlobal, fpDetModel, fpMeasureModel, fpResultLast, fpResultPrev, fpTrackUsable, BmnRamIterator::GetHit(), BmnRamIterator::HitDetectorID(), BmnRamIterator::HitWx(), BmnRamIterator::HitWy(), BmnRamIterator::HitX(), BmnRamIterator::HitY(), BmnRamIterator::HitZ(), i, ROOT::Math::SMatrix< class T, unsigned int D1, unsigned int D2, class R >::InvertChol(), BmnHitRecord::IsEnabled(), ROOT::Math::SMatrix< Double_t, BMN_LOCAL_PARAMS_PT, BMN_LOCAL_PARAMS_PT, RM::MatRepSym< Double_t, BMN_LOCAL_PARAMS_PT > >::kSize, ROOT::Math::SVector< Double_t, BMN_LOCAL_PARAMS_PT >::kSize, m, BmnAligner::AlphaData_t::mGGammaInv, BmnRamIterator::NextHit(), BmnRamIterator::NextTrack(), BmnAligner::AlphaData_t::paramIdx, BmnRamIterator::ResetAll(), BmnRamIterator::ResetHits(), SelectIterator(), ROOT::Math::SMatrix< class T, unsigned int D1, unsigned int D2, class R >::SetElements(), ROOT::Math::SVector< class T, unsigned int D >::SetElements(), ROOT::Math::TensorProd(), ROOT::Math::Transpose(), TMatrixT< class Element >::Use(), v, and z.

Referenced by IterateAlignment().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ProgressBar()

BmnSimpleProgressBar * BmnAligner::ProgressBar ( ) const
inlinenoexcept

Definition at line 85 of file BmnAligner.h.

Referenced by BmnAlignReport::Draw(), and BmnAlignTestTask::Make().

Here is the caller graph for this function:

◆ RamIterator()

BmnRamIterator * BmnAligner::RamIterator ( ) const
inlinenoexcept

Definition at line 76 of file BmnAligner.h.

Referenced by BmnAlignReport::Draw(), and BmnAlignTestTask::Make().

Here is the caller graph for this function:

◆ RandomizeSolution()

void BmnAligner::RandomizeSolution ( BmnAlignResult & solution,
TVectorD * pStdDevLeaf,
TVectorD * pStdDevComp )

Definition at line 569 of file BmnAligner.cxx.

References BmnAlignResult::A(), BmnAlignResult::ConcatenateA(), Elements(), fHierarchy, TVectorT< class Element >::GetSub(), i, TVectorT< class Element >::NonZeros(), BmnAlignResult::SeparateA(), and TVectorT< class Element >::SetSub().

Referenced by Align().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ResultLast() [1/2]

BmnAlignResult & BmnAligner::ResultLast ( )
inline

Definition at line 266 of file BmnAligner.h.

References CheckResults(), and fIterationResults.

Here is the call graph for this function:

◆ ResultLast() [2/2]

const BmnAlignResult & BmnAligner::ResultLast ( ) const
inline

Definition at line 272 of file BmnAligner.h.

References CheckResults(), and fIterationResults.

Referenced by BmnAlignReport::Correlations(), BmnAlignReport::Draw(), BmnAlignTestTask::Make(), BmnAlignReport::ModesBelow(), BmnAlignReport::Results(), and SaveSolution().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Results() [1/2]

const Results_t & BmnAligner::Results ( ) const
inlinenoexcept

Definition at line 70 of file BmnAligner.h.

◆ Results() [2/2]

Results_t & BmnAligner::Results ( )
inlinenoexcept

Definition at line 69 of file BmnAligner.h.

Referenced by BmnAlignReport::Correlations(), BmnAlignReport::Draw(), BmnAlignReport::DrawResiduals(), BmnAlignTestTask::Make(), BmnAlignReport::ModesBelow(), and BmnAlignReport::Results().

Here is the caller graph for this function:

◆ ResultZero() [1/2]

BmnAlignResult & BmnAligner::ResultZero ( )
inline

Definition at line 278 of file BmnAligner.h.

References CheckResults(), and fIterationResults.

Here is the call graph for this function:

◆ ResultZero() [2/2]

const BmnAlignResult & BmnAligner::ResultZero ( ) const
inline

Definition at line 284 of file BmnAligner.h.

References CheckResults(), and fIterationResults.

Referenced by BmnAlignReport::Results().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ RootIterator()

BmnRootIterator * BmnAligner::RootIterator ( )
inlinenoexcept

Definition at line 75 of file BmnAligner.h.

Referenced by BmnAlignTestTask::Make().

Here is the caller graph for this function:

◆ RunThreads()

template<typename Method, typename... Args>
void BmnAligner::RunThreads ( Method method,
Args... args )
inlineprivate

Definition at line 180 of file BmnAligner.h.

Referenced by CalculateMSE(), IterateAlignment(), LinregAlphaMSE(), SelectOutliers(), SelectVertexHits(), and SolveGlobal().

Here is the caller graph for this function:

◆ SaveSolution()

Bool_t BmnAligner::SaveSolution ( const char * jsonPath,
Bool_t withAlpha = kFALSE )

Definition at line 528 of file BmnAligner.cxx.

References CheckInit(), fHierarchy, fTotalTracks, ResultLast(), and BmnAlignConfig::WriteSolution().

Referenced by align(), and BmnAlignTestTask::Make().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ SelectIterator()

void BmnAligner::SelectIterator ( Int_t threadNum,
Int_t & trackIdx,
BmnRamIterator *& pItr )
inlineprivate

Definition at line 215 of file BmnAligner.h.

References fFirstTracksIdx, fpIterators, and fpRamIterator.

Referenced by CalculateLocals(), CalculateMSEpart(), HitPullsPart(), LinRegressionAlphaPart(), ProcessTracks(), and VertexResidualsPart().

Here is the caller graph for this function:

◆ SelectOutliers()

Int_t BmnAligner::SelectOutliers ( )
protected

Definition at line 1819 of file BmnAligner.cxx.

References fFirstHits, fpProgressBar, fpTrackUsable, fTotalHits, fTotalTracks, fTracksUsableCnt, HitPullsPart(), LinregAlphaMSE(), TMath::QuietNaN(), and RunThreads().

Referenced by Align().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ SelectVertexHits()

Int_t BmnAligner::SelectVertexHits ( )

Definition at line 1518 of file BmnAligner.cxx.

References fFirstHits, fHits, fpProgressBar, fTotalTracks, BmnHitRecord::IsEnabled(), LinregAlphaMSE(), TMath::QuietNaN(), RunThreads(), BmnHitRecord::SetEnabled(), and VertexResidualsPart().

Referenced by Align(), and FitTargetZ().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ SolveGlobal()

Bool_t BmnAligner::SolveGlobal ( const TMatrixD & mCL,
const TVectorD & vBL,
Bool_t optimStep = kFALSE )
protected

Definition at line 1007 of file BmnAligner.cxx.

References CalculateLocals(), CalculateMSE(), TDecompLU::Decompose(), TDecompSVD::Decompose(), fAlphaReady, fBrent, fHierarchy, fpResultLast, fpResultPrev, fPriors, TVectorT< class Element >::GetNrows(), TDecompSVD::GetSig(), TMatrixT< class Element >::GetSub(), TVectorT< class Element >::GetSub(), TDecompSVD::GetV(), TMath::Infinity(), TDecompLU::Invert(), TVectorT< class Element >::ResizeTo(), RunThreads(), TVectorT< class Element >::SetSub(), and TDecompSVD::Solve().

Referenced by IterateAlignment().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ TotalCpuTime()

Double_t BmnAligner::TotalCpuTime ( ) const
inlinenoexcept

Definition at line 79 of file BmnAligner.h.

Referenced by BmnAlignReport::Results().

Here is the caller graph for this function:

◆ TotalHits()

Int_t BmnAligner::TotalHits ( ) const
inlinenoexcept

Definition at line 68 of file BmnAligner.h.

◆ TotalRealTime()

Double_t BmnAligner::TotalRealTime ( ) const
inlinenoexcept

Definition at line 80 of file BmnAligner.h.

Referenced by BmnAlignReport::Results().

Here is the caller graph for this function:

◆ TotalTracks()

Int_t BmnAligner::TotalTracks ( ) const
inlinenoexcept

Definition at line 67 of file BmnAligner.h.

Referenced by BmnAlignTestTask::Make().

Here is the caller graph for this function:

◆ TracksUsable()

Int_t BmnAligner::TracksUsable ( ) const
inlinenoexcept

Definition at line 82 of file BmnAligner.h.

Referenced by BmnAlignReport::Draw().

Here is the caller graph for this function:

◆ TrackUsable()

const VecBool_t * BmnAligner::TrackUsable ( ) const
inlinenoexcept

Definition at line 84 of file BmnAligner.h.

Referenced by BmnAlignReport::Draw().

Here is the caller graph for this function:

◆ VertexResidualsPart()

void BmnAligner::VertexResidualsPart ( VecDouble_t * pRx,
VecDouble_t * pRy,
Int_t threadNum )
private

Definition at line 1558 of file BmnAligner.cxx.

References BmnDataIterator::EndOfHits(), BmnDataIterator::EndOfTracks(), fpDetModel, fpTrackUsable, BmnRamIterator::HitDetectorID(), LeaveOneOut(), BmnRamIterator::NextTrack(), BmnRamIterator::ResetAll(), and SelectIterator().

Referenced by SelectVertexHits().

Here is the call graph for this function:
Here is the caller graph for this function:

Member Data Documentation

◆ fAlphaReady

Bool_t BmnAligner::fAlphaReady {kFALSE}
protected

Definition at line 127 of file BmnAligner.h.

Referenced by IterateAlignment(), and SolveGlobal().

◆ fAlphaRecs

VecAlphaRecs_t BmnAligner::fAlphaRecs
protected

Definition at line 158 of file BmnAligner.h.

Referenced by BmnAligner(), CalculateLocals(), and ProcessTracks().

◆ fBrent

RM::BrentMinimizer1D BmnAligner::fBrent
protected

Definition at line 143 of file BmnAligner.h.

Referenced by BmnAligner(), and SolveGlobal().

◆ fFirstHits

VecInt_t BmnAligner::fFirstHits
protected

◆ fFirstTracksIdx

VecInt_t BmnAligner::fFirstTracksIdx
private

Definition at line 175 of file BmnAligner.h.

Referenced by InitIterators(), and SelectIterator().

◆ fForceRegular

Bool_t BmnAligner::fForceRegular {kFALSE}
protected

Definition at line 126 of file BmnAligner.h.

Referenced by Align(), and IterateAlignment().

◆ fHierarchy

◆ fHits

VecHitRecs_t BmnAligner::fHits
protected

Definition at line 159 of file BmnAligner.h.

Referenced by BmnAligner(), PrepareData(), and SelectVertexHits().

◆ fHitsPerDetector

VecInt_t BmnAligner::fHitsPerDetector
protected

Definition at line 138 of file BmnAligner.h.

Referenced by PrepareData().

◆ fInitialized

Bool_t BmnAligner::fInitialized {kFALSE}
protected

Definition at line 125 of file BmnAligner.h.

Referenced by BmnAligner(), and CheckInit().

◆ fIteration

Int_t BmnAligner::fIteration {-1}
protected

Definition at line 131 of file BmnAligner.h.

Referenced by IterateAlignment().

◆ fIterationResults

Results_t BmnAligner::fIterationResults
protected

◆ fLeafZmax

VecDouble_t BmnAligner::fLeafZmax
protected

Definition at line 142 of file BmnAligner.h.

Referenced by PrepareData().

◆ fLeafZmin

VecDouble_t BmnAligner::fLeafZmin
protected

Definition at line 142 of file BmnAligner.h.

Referenced by PrepareData().

◆ fLeafZsum

VecDouble_t BmnAligner::fLeafZsum
protected

Definition at line 142 of file BmnAligner.h.

Referenced by PrepareData().

◆ fMaxZvalue

Double_t BmnAligner::fMaxZvalue {0.0}
protected

Definition at line 170 of file BmnAligner.h.

Referenced by AddBlankSolution(), and PrepareData().

◆ fMSEclcCounter

UInt_t BmnAligner::fMSEclcCounter {0u}
protected

Definition at line 128 of file BmnAligner.h.

Referenced by CalculateMSE(), and IterateAlignment().

◆ fMSEclcSlow

Bool_t BmnAligner::fMSEclcSlow {kFALSE}
protected

Definition at line 125 of file BmnAligner.h.

Referenced by Align(), and CalculateMSE().

◆ fMSEclcTick

UInt_t BmnAligner::fMSEclcTick {1u}
protected

Definition at line 129 of file BmnAligner.h.

Referenced by Align(), and CalculateMSE().

◆ fMutexGlobal

std::mutex BmnAligner::fMutexGlobal
private

Definition at line 176 of file BmnAligner.h.

Referenced by CalculateMSEpart(), and ProcessTracks().

◆ fpConstraintsPath

const char* BmnAligner::fpConstraintsPath {nullptr}
protected

Definition at line 120 of file BmnAligner.h.

Referenced by BmnAligner(), and PrepareData().

◆ fpDetModel

◆ fpIterators

std::vector<BmnRamIterator*> BmnAligner::fpIterators
private

Definition at line 174 of file BmnAligner.h.

Referenced by ~BmnAligner(), InitIterators(), and SelectIterator().

◆ fpMeasureModel

const BmnMeasureModel* BmnAligner::fpMeasureModel
protected

◆ fpPresigmaPath

const char* BmnAligner::fpPresigmaPath {nullptr}
protected

Definition at line 121 of file BmnAligner.h.

Referenced by BmnAligner(), and PrepareData().

◆ fpProgressBar

BmnSimpleProgressBar* BmnAligner::fpProgressBar {nullptr}
protected

◆ fpRamIterator

BmnRamIterator* BmnAligner::fpRamIterator {nullptr}
protected

◆ fpResultLast

◆ fpResultPrev

BmnAlignResult* BmnAligner::fpResultPrev {nullptr}
protected

◆ fPriors

BmnAlignPriors BmnAligner::fPriors
protected

Definition at line 119 of file BmnAligner.h.

Referenced by IterateAlignment(), PrepareData(), and SolveGlobal().

◆ fpRootIterator

BmnRootIterator* BmnAligner::fpRootIterator {nullptr}
protected

Definition at line 153 of file BmnAligner.h.

Referenced by BmnAligner(), ~BmnAligner(), and PrepareData().

◆ fpTrackUsable

VecBool_t* BmnAligner::fpTrackUsable {nullptr}
protected

◆ fRegularIters

Int_t BmnAligner::fRegularIters {0}
protected

Definition at line 132 of file BmnAligner.h.

Referenced by Align(), and IterateAlignment().

◆ fThreadsCnt

Int_t BmnAligner::fThreadsCnt {1}
private

Definition at line 177 of file BmnAligner.h.

Referenced by BmnAligner(), ~BmnAligner(), InitIterators(), and IterateAlignment().

◆ fTotalCpuTime

Double_t BmnAligner::fTotalCpuTime {0.0}
protected

Definition at line 130 of file BmnAligner.h.

Referenced by MarkTime().

◆ fTotalHits

Int_t BmnAligner::fTotalHits {0}
protected

Definition at line 137 of file BmnAligner.h.

Referenced by BmnAligner(), and SelectOutliers().

◆ fTotalRealTime

Double_t BmnAligner::fTotalRealTime {0.0}
protected

Definition at line 130 of file BmnAligner.h.

Referenced by MarkTime().

◆ fTotalTracks

Int_t BmnAligner::fTotalTracks {0}
protected

◆ fTracksUsableCnt

Int_t BmnAligner::fTracksUsableCnt {0}
protected

Definition at line 135 of file BmnAligner.h.

Referenced by BmnAligner(), Align(), and SelectOutliers().


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