From e7d395bd9933f2e6be57eb256d968e8351c23c83 Mon Sep 17 00:00:00 2001 From: "se.gorbunov" <se.gorbunov@gsi.de> Date: Sat, 1 Oct 2022 22:12:19 +0000 Subject: [PATCH] L1: minor --- reco/L1/CbmL1.cxx | 12 +++++------- reco/L1/CbmL1Performance.cxx | 7 +++++-- reco/L1/L1Algo/L1Extrapolation.cxx | 2 +- reco/L1/L1Algo/L1Extrapolation.h | 2 +- reco/L1/L1Algo/L1TrackPar.h | 4 +++- 5 files changed, 15 insertions(+), 12 deletions(-) diff --git a/reco/L1/CbmL1.cxx b/reco/L1/CbmL1.cxx index 7f6c60d73e..6e43059353 100644 --- a/reco/L1/CbmL1.cxx +++ b/reco/L1/CbmL1.cxx @@ -188,6 +188,8 @@ InitStatus CbmL1::Init() fpAlgo->Init(fUseHitErrors, fTrackingMode, fMissingHits); fHistoDir = gROOT->mkdir("L1"); + fHistoDir->mkdir("Input"); + fHistoDir->mkdir("Fit"); // turn on reconstruction in sub-detectors @@ -215,7 +217,7 @@ InitStatus CbmL1::Init() if (L1Algo::TrackingMode::kGlobal == fTrackingMode) { - //SGtrd2D!! + //at the moment trd2d tracking only fUseMVD = 0; fUseSTS = 0; fUseMUCH = 0; @@ -1022,15 +1024,11 @@ void CbmL1::Reconstruct(CbmEvent* event) L1FieldValue b = fpAlgo->GetParameters()->GetVertexFieldValue(); if ((fabs(b.x[0]) < 0.0000001) && (fabs(b.y[0]) < 0.0000001) && (fabs(b.z[0]) < 0.0000001)) { + // no field fpAlgo->KFTrackFitter_simple(); } else { - if (L1Algo::TrackingMode::kGlobal == fTrackingMode || L1Algo::TrackingMode::kMcbm == fTrackingMode) { - fpAlgo->L1KFTrackFitterMuch(); - } - else { - fpAlgo->L1KFTrackFitter(); - } + fpAlgo->L1KFTrackFitter(); } } diff --git a/reco/L1/CbmL1Performance.cxx b/reco/L1/CbmL1Performance.cxx index 904a756bd3..559285ec3e 100644 --- a/reco/L1/CbmL1Performance.cxx +++ b/reco/L1/CbmL1Performance.cxx @@ -1107,7 +1107,6 @@ void CbmL1::TrackFitPerformance() TDirectory* currentDir = gDirectory; gDirectory = fHistoDir; - gDirectory->mkdir("Fit"); gDirectory->cd("Fit"); { PRes2D = new TH2F("PRes2D", "Resolution P vs P [100%]", 100, 0., 20., 100, -.15, .15); @@ -1184,6 +1183,11 @@ void CbmL1::TrackFitPerformance() {"t", "Residual T [ns]", 100, -10., 10.}, {"pt", "Pull T [residual/estimated_error]", 100, -6., 6.}}; + if (L1Algo::kGlobal == fpAlgo->fTrackingMode) { + TableVertex[4].l = -1.; + TableVertex[4].r = 1.; + } + for (int i = 0; i < Nh_fit; i++) { char n[225], t[255]; sprintf(n, "fst_%s", Table[i].name); @@ -1826,7 +1830,6 @@ void CbmL1::InputPerformance() TDirectory* currentDir = gDirectory; gDirectory = fHistoDir; - gDirectory->mkdir("Input"); gDirectory->cd("Input"); gDirectory->mkdir("STS"); gDirectory->cd("STS"); diff --git a/reco/L1/L1Algo/L1Extrapolation.cxx b/reco/L1/L1Algo/L1Extrapolation.cxx index 73174f8d40..cbb081f569 100644 --- a/reco/L1/L1Algo/L1Extrapolation.cxx +++ b/reco/L1/L1Algo/L1Extrapolation.cxx @@ -19,7 +19,7 @@ void L1Extrapolate // extrapolates track parameters and returns jacobian for ex (L1TrackPar& T, // input track parameters (x,y,tx,ty,Q/p) and cov.matrix fvec z_out, // extrapolate to this z position fvec qp0, // use Q/p linearisation at this value - const L1FieldRegion& F, fvec* w) + const L1FieldRegion& F, const fvec* w) { L1ExtrapolateRungeKutta(T, z_out, qp0, F, w); //L1ExtrapolateAnalytic(T, z_out, qp0, F, w); diff --git a/reco/L1/L1Algo/L1Extrapolation.h b/reco/L1/L1Algo/L1Extrapolation.h index 4887f7769f..f4ec3a4b5c 100644 --- a/reco/L1/L1Algo/L1Extrapolation.h +++ b/reco/L1/L1Algo/L1Extrapolation.h @@ -13,7 +13,7 @@ void L1Extrapolate // extrapolates track parameters and returns jacobian for ex (L1TrackPar& T, // input track parameters (x,y,tx,ty,Q/p) and cov.matrix fvec z_out, // extrapolate to this z position fvec qp0, // use Q/p linearisation at this value - const L1FieldRegion& F, fvec* w = nullptr); + const L1FieldRegion& F, const fvec* w = nullptr); void L1Extrapolate0(L1TrackPar& T, // input track parameters (x,y,tx,ty,Q/p) and cov.matrix fvec z_out, // extrapolate to this z position diff --git a/reco/L1/L1Algo/L1TrackPar.h b/reco/L1/L1Algo/L1TrackPar.h index a6e838a490..75b1d4ec2b 100644 --- a/reco/L1/L1Algo/L1TrackPar.h +++ b/reco/L1/L1Algo/L1TrackPar.h @@ -112,7 +112,8 @@ public: inline void L1TrackPar::Print(int i) const { - // std::cout.setf(std::ios::scientific, std::ios::floatfield); + std::ios_base::fmtflags coutFlags(std::cout.flags()); + std::cout.setf(std::ios::scientific, std::ios::floatfield); if (i == -1) { std::cout << "T = " << std::endl; std::cout << " x " << x << std::endl; @@ -148,6 +149,7 @@ inline void L1TrackPar::Print(int i) const std::cout << " c55 " << C55[i] << std::endl; } PrintCorrelations(i); + std::cout.flags( coutFlags ); } inline void L1TrackPar::PrintCorrelations(int i) const -- GitLab