From 46d58c58445d5f1d30e0e93b3e2a0ce7dd51cb90 Mon Sep 17 00:00:00 2001 From: Mario Masciovecchio Date: Mon, 4 Oct 2021 05:42:17 -0700 Subject: [PATCH 1/2] Changes during review of PR 35492 --- .../plugins/MkFitIterationConfigESProducer.cc | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/RecoTracker/MkFit/plugins/MkFitIterationConfigESProducer.cc b/RecoTracker/MkFit/plugins/MkFitIterationConfigESProducer.cc index b77089d24e8ef..8eaa6e2902259 100644 --- a/RecoTracker/MkFit/plugins/MkFitIterationConfigESProducer.cc +++ b/RecoTracker/MkFit/plugins/MkFitIterationConfigESProducer.cc @@ -21,9 +21,9 @@ namespace { IterationSeedPartition &part) { // Seeds are placed into eta regions and sorted on region + eta. - const int size = in_seeds.size(); + const size_t size = in_seeds.size(); - for (int i = 0; i < size; ++i) { + for (size_t i = 0; i < size; ++i) { const Track &S = in_seeds[i]; const bool z_dir_pos = S.pz() > 0; @@ -31,12 +31,15 @@ namespace { HitOnTrack hot = S.getLastHitOnTrack(); // MIMI ACHTUNG -- here we assume seed hits have already been remapped. // This was true at that time :) - float eta = eoh[hot.layer].GetHit(hot.index).eta(); + const float eta = eoh[hot.layer].GetHit(hot.index).eta(); // float eta = S.momEta(); // Region to be defined by propagation / intersection tests TrackerInfo::EtaRegion reg; + // Max eta used for region sorting + constexpr float maxEta_regSort = 5.0; + // Hardcoded for cms ... needs some lists of layers (hit/miss) for brl / ecp tests. // MM: Check lambda functions/std::function const LayerInfo &outer_brl = trk_info.outer_barrel_layer(); @@ -56,7 +59,7 @@ namespace { // There are a lot of tracks that go through that crack. // XXXX trying a fix for low pT tracks that are in barrel after half circle - float maxR = S.maxReachRadius(); + const float maxR = S.maxReachRadius(); float z_at_maxr; bool can_reach_outer_brl = S.canReachRadius(outer_brl.m_rout); @@ -97,7 +100,10 @@ namespace { } part.m_region[i] = reg; - part.m_sort_score[i] = 5.0f * (reg - 2) + eta; + + // TrackerInfo::EtaRegion is enum from 0 to 5 (Reg_Endcap_Neg,Reg_Transition_Neg,Reg_Barrel,Reg_Transition_Pos,Reg_Endcap_Pos) + // Symmetrization around TrackerInfo::Reg_Barrel for sorting is required + part.m_sort_score[i] = maxEta_regSort * (reg - TrackerInfo::Reg_Barrel) + eta; } } } // namespace From ab20cf5149c2ad632575d04fad6f71cebbceac83 Mon Sep 17 00:00:00 2001 From: Mario Masciovecchio Date: Mon, 4 Oct 2021 10:15:51 -0700 Subject: [PATCH 2/2] Increase maxEta_regSort (used in mkFit region sorting), for safety --- RecoTracker/MkFit/plugins/MkFitIterationConfigESProducer.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/RecoTracker/MkFit/plugins/MkFitIterationConfigESProducer.cc b/RecoTracker/MkFit/plugins/MkFitIterationConfigESProducer.cc index 8eaa6e2902259..30c158f78901c 100644 --- a/RecoTracker/MkFit/plugins/MkFitIterationConfigESProducer.cc +++ b/RecoTracker/MkFit/plugins/MkFitIterationConfigESProducer.cc @@ -38,7 +38,7 @@ namespace { TrackerInfo::EtaRegion reg; // Max eta used for region sorting - constexpr float maxEta_regSort = 5.0; + constexpr float maxEta_regSort = 7.0; // Hardcoded for cms ... needs some lists of layers (hit/miss) for brl / ecp tests. // MM: Check lambda functions/std::function