CMS 3D CMS Logo

List of all members | Public Types | Public Member Functions | Private Attributes
mkfit::CombCandidate Class Reference

#include <TrackStructures.h>

Public Types

using allocator_type = CcAlloc< TrackCand >
 
enum  SeedState_e { Dormant = 0, Finding, Finished }
 
using trk_cand_vec_type = std::vector< TrackCand, CcAlloc< TrackCand > >
 

Public Member Functions

int addHit (const HitOnTrack &hot, float chi2, int prev_idx)
 
void beginBkwSearch ()
 
void clear ()
 
 CombCandidate (const allocator_type &alloc)
 
 CombCandidate (const CombCandidate &o)
 
 CombCandidate (CombCandidate &&o)
 
void compactifyHitStorageForBestCand (bool remove_seed_hits, int backward_fit_min_hits)
 
trk_cand_vec_type::reference emplace_back (TrackCand &tc)
 
bool empty () const
 
TrackCandfront ()
 
const TrackCandfront () const
 
HitOnTrack hot (int i) const
 
const HoTNodehot_node (int i) const
 
HoTNodehot_node_nc (int i)
 
const HoTNodehotsData () const
 
int hotsSize () const
 
void importSeed (const Track &seed, const track_score_func &score_func, int region)
 
void mergeCandsAndBestShortOne (const IterationParams &params, const track_score_func &score_func, bool update_score, bool sort_cands)
 
CombCandidateoperator= (CombCandidate &&o)
 
TrackCandoperator[] (int i)
 
const TrackCandoperator[] (int i) const
 
int pickupLayer () const
 
const TrackCandrefBestShortCand () const
 
void repackCandPostBkwSearch (int i)
 
void reset (int max_cands_per_seed, int expected_num_hots)
 
void resize (trk_cand_vec_type::size_type count)
 
void setBestShortCand (const TrackCand &tc)
 
void setState (SeedState_e ss)
 
trk_cand_vec_type::size_type size () const
 
SeedState_e state () const
 

Private Attributes

TrackCand m_best_short_cand
 
std::vector< HoTNodem_hots
 
int m_hots_size = 0
 
short int m_lastHitIdx_before_bkwsearch = -1
 
short int m_nInsideMinusOneHits_before_bkwsearch = -1
 
short int m_nTailMinusOneHits_before_bkwsearch = -1
 
int m_pickup_layer: 16
 
SeedState_e m_state: 8
 
trk_cand_vec_type m_trk_cands
 

Detailed Description

Definition at line 276 of file TrackStructures.h.

Member Typedef Documentation

◆ allocator_type

Definition at line 279 of file TrackStructures.h.

◆ trk_cand_vec_type

Definition at line 278 of file TrackStructures.h.

Member Enumeration Documentation

◆ SeedState_e

Enumerator
Dormant 
Finding 
Finished 

Definition at line 281 of file TrackStructures.h.

Constructor & Destructor Documentation

◆ CombCandidate() [1/3]

mkfit::CombCandidate::CombCandidate ( const allocator_type alloc)
inline

◆ CombCandidate() [2/3]

mkfit::CombCandidate::CombCandidate ( const CombCandidate o)
inline

Definition at line 286 of file TrackStructures.h.

287  : m_trk_cands(o.m_trk_cands),
288  m_state(o.m_state),
289  m_pickup_layer(o.m_pickup_layer),
290  m_lastHitIdx_before_bkwsearch(o.m_lastHitIdx_before_bkwsearch),
291  m_nInsideMinusOneHits_before_bkwsearch(o.m_nInsideMinusOneHits_before_bkwsearch),
292  m_nTailMinusOneHits_before_bkwsearch(o.m_nTailMinusOneHits_before_bkwsearch),
293 #ifdef DUMPHITWINDOW
294  m_seed_algo(o.m_seed_algo),
295  m_seed_label(o.m_seed_label),
296 #endif
297  m_hots_size(o.m_hots_size),
298  m_hots(o.m_hots) {
299  }
short int m_nInsideMinusOneHits_before_bkwsearch
short int m_nTailMinusOneHits_before_bkwsearch
short int m_lastHitIdx_before_bkwsearch
trk_cand_vec_type m_trk_cands
std::vector< HoTNode > m_hots

◆ CombCandidate() [3/3]

mkfit::CombCandidate::CombCandidate ( CombCandidate &&  o)
inline

Definition at line 302 of file TrackStructures.h.

303  : m_trk_cands(std::move(o.m_trk_cands)),
304  m_best_short_cand(std::move(o.m_best_short_cand)),
305  m_state(o.m_state),
306  m_pickup_layer(o.m_pickup_layer),
307  m_lastHitIdx_before_bkwsearch(o.m_lastHitIdx_before_bkwsearch),
308  m_nInsideMinusOneHits_before_bkwsearch(o.m_nInsideMinusOneHits_before_bkwsearch),
309  m_nTailMinusOneHits_before_bkwsearch(o.m_nTailMinusOneHits_before_bkwsearch),
310 #ifdef DUMPHITWINDOW
311  m_seed_algo(o.m_seed_algo),
312  m_seed_label(o.m_seed_label),
313 #endif
314  m_hots_size(o.m_hots_size),
315  m_hots(std::move(o.m_hots)) {
316  // This is not needed as we do EOCC::reset() after EOCCS::resize which
317  // calls Reset here and all CombCands get cleared.
318  // However, if at some point we start using this for other purposes this needs
319  // to be called as well.
320  // for (auto &tc : *this) tc.setCombCandidate(this);
321  }
short int m_nInsideMinusOneHits_before_bkwsearch
short int m_nTailMinusOneHits_before_bkwsearch
short int m_lastHitIdx_before_bkwsearch
trk_cand_vec_type m_trk_cands
def move(src, dest)
Definition: eostools.py:511
std::vector< HoTNode > m_hots

Member Function Documentation

◆ addHit()

int mkfit::CombCandidate::addHit ( const HitOnTrack hot,
float  chi2,
int  prev_idx 
)
inline

Definition at line 383 of file TrackStructures.h.

References hltPixelTracks_cff::chi2, hot(), m_hots, and m_hots_size.

Referenced by mkfit::TrackCand::addHitIdx().

383  {
384  m_hots.push_back({hot, chi2, prev_idx});
385  return m_hots_size++;
386  }
HitOnTrack hot(int i) const
std::vector< HoTNode > m_hots

◆ beginBkwSearch()

void mkfit::CombCandidate::beginBkwSearch ( )

Definition at line 209 of file TrackStructures.cc.

References Dormant, mkfit::TrackCand::lastCcIndex(), m_hots, m_lastHitIdx_before_bkwsearch, m_nInsideMinusOneHits_before_bkwsearch, m_nTailMinusOneHits_before_bkwsearch, m_pickup_layer, m_state, m_trk_cands, mkfit::TrackCand::nInsideMinusOneHits(), mkfit::TrackCand::nTailMinusOneHits(), mkfit::TrackCand::setLastCcIndex(), mkfit::TrackCand::setNInsideMinusOneHits(), and mkfit::TrackCand::setNTailMinusOneHits().

209  {
210  // Assumes compactifyHitStorageForBestCand() has already been called.
211  //
212  // This is to be called before backward-search to start with a single
213  // input candidate for backward combinatorial search.
214  //
215  // m_state and m_pickup_layer are also set.
216 
217  TrackCand &tc = m_trk_cands[0];
218 
219  m_state = Dormant;
220  m_pickup_layer = m_hots[0].m_hot.layer;
221  m_lastHitIdx_before_bkwsearch = tc.lastCcIndex();
222  m_nInsideMinusOneHits_before_bkwsearch = tc.nInsideMinusOneHits();
223  m_nTailMinusOneHits_before_bkwsearch = tc.nTailMinusOneHits();
224  tc.setLastCcIndex(0);
225  tc.setNInsideMinusOneHits(0);
226  tc.setNTailMinusOneHits(0);
227  }
short int m_nInsideMinusOneHits_before_bkwsearch
short int m_nTailMinusOneHits_before_bkwsearch
short int m_lastHitIdx_before_bkwsearch
trk_cand_vec_type m_trk_cands
std::vector< HoTNode > m_hots

◆ clear()

void mkfit::CombCandidate::clear ( void  )
inline

Definition at line 357 of file TrackStructures.h.

References m_trk_cands.

Referenced by mkfit::CandCloner::processSeedRange().

357 { m_trk_cands.clear(); }
trk_cand_vec_type m_trk_cands

◆ compactifyHitStorageForBestCand()

void mkfit::CombCandidate::compactifyHitStorageForBestCand ( bool  remove_seed_hits,
int  backward_fit_min_hits 
)

Definition at line 124 of file TrackStructures.cc.

References mkfit::TrackCand::addHitIdx(), cms::cuda::assert(), mkfit::TrackBase::getNSeedHits(), heavyIonCSV_trainingSettings::idx, mkfit::HitOnTrack::index, mkfit::TrackCand::lastCcIndex(), mkfit::HitOnTrack::layer, mkfit::HoTNode::m_chi2, mkfit::HoTNode::m_hot, m_hots, m_hots_size, m_trk_cands, SiStripPI::max, mkfit::TrackCand::nFoundHits(), mkfit::TrackCand::setLastCcIndex(), mkfit::TrackCand::setNFoundHits(), mkfit::TrackCand::setNInsideMinusOneHits(), mkfit::TrackCand::setNMissingHits(), and mkfit::TrackCand::setNTailMinusOneHits().

124  {
125  // The best candidate is assumed to be in position 0 (after mergeCandsAndBestShortOne
126  // mergeCandsAndBestShortOne has been called).
127  // Other cands are dropped, their hits are dropped as well.
128  // Seed hits are dropped if remove_seed_hits is true.
129 
130  /* The following considerations are related to the following implementation:
131  minNrOfHitsForRebuild (checked against "nHits - nseed") has a default at 5, except
132  1 in initialStep
133  4 in tobTec and pixelLess
134  https://github.com/cms-sw/cmssw/blob/master/RecoTracker/CkfPattern/plugins/GroupedCkfTrajectoryBuilder.cc#L1015
135 
136  NOTE: some of those can be matched hits !!!
137 
138  the hit splitting is triggered here: https://github.com/cms-sw/cmssw/blob/master/RecoTracker/CkfPattern/src/CkfTrackCandidateMakerBase.cc#L468
139  after the rebuild has already happened: https://github.com/cms-sw/cmssw/blob/master/RecoTracker/CkfPattern/src/CkfTrackCandidateMakerBase.cc#L313
140  */
141 
142  assert(!m_trk_cands.empty());
143  m_trk_cands.resize(1);
144  TrackCand &tc = m_trk_cands[0];
145 
146  // Do NOT remove any seed hits if fewer than backward_fit_min_hits hits are available.
147  if (remove_seed_hits && tc.nFoundHits() <= backward_fit_min_hits) {
148  remove_seed_hits = false;
149  }
150 
151  // Stash HoTNodes at the end of m_hots.
152  int stash_end = m_hots.size();
153  int stash_pos = stash_end;
154 
155  int idx = tc.lastCcIndex();
156 
157  if (remove_seed_hits) {
158  // Skip invalid hits that would now be at the head of the candidate.
159  // Make sure to subtract / recount number of hits:
160  // as this is rather involved, just call addHitIdx() repeatedly so counts
161  // of holes get updated correctly.
162  // Though one should not care super much ... it's only relevant for relative scores
163  // and here we are trimming everything down to a single candidate.
164 
165  int n_hits_to_pick = std::max(tc.nFoundHits() - tc.getNSeedHits(), backward_fit_min_hits);
166  while (n_hits_to_pick > 0) {
167  m_hots[--stash_pos] = m_hots[idx];
168  if (m_hots[idx].m_hot.index >= 0)
169  --n_hits_to_pick;
170  idx = m_hots[idx].m_prev_idx;
171  }
172 
173  m_hots_size = 0;
174  m_hots.clear();
175  tc.setLastCcIndex(-1);
176  tc.setNFoundHits(0);
177  tc.setNMissingHits(0);
178  tc.setNInsideMinusOneHits(0);
179  tc.setNTailMinusOneHits(0);
180  while (stash_pos != stash_end && m_hots[stash_pos].m_hot.index < 0)
181  ++stash_pos;
182  while (stash_pos != stash_end) {
183  HoTNode &hn = m_hots[stash_pos];
184  tc.addHitIdx(hn.m_hot.index, hn.m_hot.layer, hn.m_chi2);
185  ++stash_pos;
186  }
187  } else {
188  while (idx != -1) {
189  m_hots[--stash_pos] = m_hots[idx];
190  idx = m_hots[idx].m_prev_idx;
191  }
192 
193  // If we are not removing seed_hits, track is good as it is,
194  // just fixup m_hots and t.lastCcIndex.
195  int pos = 0;
196  while (stash_pos != stash_end) {
197  m_hots[pos].m_hot = m_hots[stash_pos].m_hot;
198  m_hots[pos].m_chi2 = m_hots[stash_pos].m_chi2;
199  m_hots[pos].m_prev_idx = pos - 1;
200  ++pos;
201  ++stash_pos;
202  }
203  m_hots.resize(pos);
204  m_hots_size = pos;
205  tc.setLastCcIndex(pos - 1);
206  }
207  }
assert(be >=bs)
trk_cand_vec_type m_trk_cands
std::vector< HoTNode > m_hots

◆ emplace_back()

trk_cand_vec_type::reference mkfit::CombCandidate::emplace_back ( TrackCand tc)
inline

Definition at line 356 of file TrackStructures.h.

References m_trk_cands.

Referenced by mkfit::CandCloner::processSeedRange().

356 { return m_trk_cands.emplace_back(tc); }
trk_cand_vec_type m_trk_cands

◆ empty()

bool mkfit::CombCandidate::empty ( void  ) const
inline

Definition at line 349 of file TrackStructures.h.

References m_trk_cands.

Referenced by mergeCandsAndBestShortOne().

349 { return m_trk_cands.empty(); }
trk_cand_vec_type m_trk_cands

◆ front() [1/2]

TrackCand& mkfit::CombCandidate::front ( )
inline

Definition at line 354 of file TrackStructures.h.

References m_trk_cands.

354 { return m_trk_cands.front(); }
trk_cand_vec_type m_trk_cands

◆ front() [2/2]

const TrackCand& mkfit::CombCandidate::front ( ) const
inline

Definition at line 355 of file TrackStructures.h.

References m_trk_cands.

355 { return m_trk_cands.front(); }
trk_cand_vec_type m_trk_cands

◆ hot()

HitOnTrack mkfit::CombCandidate::hot ( int  i) const
inline

◆ hot_node()

const HoTNode& mkfit::CombCandidate::hot_node ( int  i) const
inline

◆ hot_node_nc()

HoTNode& mkfit::CombCandidate::hot_node_nc ( int  i)
inline

Definition at line 402 of file TrackStructures.h.

References mps_fire::i, and m_hots.

Referenced by mkfit::TrackCand::refLastHoTNode().

402 { return m_hots[i]; }
std::vector< HoTNode > m_hots

◆ hotsData()

const HoTNode* mkfit::CombCandidate::hotsData ( ) const
inline

Definition at line 405 of file TrackStructures.h.

References m_hots.

Referenced by mkfit::MkFinder::bkFitInputTracks().

405 { return m_hots.data(); }
std::vector< HoTNode > m_hots

◆ hotsSize()

int mkfit::CombCandidate::hotsSize ( ) const
inline

Definition at line 400 of file TrackStructures.h.

References m_hots_size.

400 { return m_hots_size; }

◆ importSeed()

void mkfit::CombCandidate::importSeed ( const Track seed,
const track_score_func score_func,
int  region 
)

Definition at line 53 of file TrackStructures.cc.

References Dormant, dprintf, mkfit::getScoreCand(), trackingPlots::hp, m_pickup_layer, m_state, m_trk_cands, HLT_2022v15_cff::region, fileCollector::seed, and HLT_2022v15_cff::TrackCand.

53  {
54  m_trk_cands.emplace_back(TrackCand(seed, this));
55 
57  m_pickup_layer = seed.getLastHitLyr();
58 #ifdef DUMPHITWINDOW
59  m_seed_algo = seed.algoint();
60  m_seed_label = seed.label();
61 #endif
62 
63  TrackCand &cand = m_trk_cands.back();
64  cand.setNSeedHits(seed.nTotalHits());
65  cand.setEtaRegion(region);
66 
67  dprintf("Importing pt=%f eta=%f, lastCcIndex=%d\n", cand.pT(), cand.momEta(), cand.lastCcIndex());
68 
69  for (const HitOnTrack *hp = seed.beginHitsOnTrack(); hp != seed.endHitsOnTrack(); ++hp) {
70  dprintf(" hit idx=%d lyr=%d\n", hp->index, hp->layer);
71  cand.addHitIdx(hp->index, hp->layer, 0.0f);
72  }
73 
74  cand.setScore(getScoreCand(score_func, cand));
75  }
float getScoreCand(const track_score_func &score_func, const Track &cand1, bool penalizeTailMissHits=false, bool inFindCandidates=false)
Definition: Track.h:608
trk_cand_vec_type m_trk_cands
#define dprintf(...)
Definition: Debug.h:98

◆ mergeCandsAndBestShortOne()

void mkfit::CombCandidate::mergeCandsAndBestShortOne ( const IterationParams params,
const track_score_func score_func,
bool  update_score,
bool  sort_cands 
)

Definition at line 77 of file TrackStructures.cc.

References HltBtagPostValidation_cff::c, mkfit::TrackCand::combCandidate(), empty(), mkfit::getScoreCand(), m_best_short_cand, m_trk_cands, submitPVValidationJobs::params, mkfit::TrackCand::resetShortTrack(), mkfit::TrackBase::score(), mkfit::TrackBase::setScore(), jetUpdater_cfi::sort, and mkfit::sortByScoreTrackCand().

80  {
81  TrackCand *best_short = m_best_short_cand.combCandidate() ? &m_best_short_cand : nullptr;
82 
83  if (!empty()) {
84  if (update_score) {
85  for (auto &c : m_trk_cands)
86  c.setScore(getScoreCand(score_func, c));
87  if (best_short)
88  best_short->setScore(getScoreCand(score_func, *best_short));
89  }
90  if (sort_cands) {
92  }
93 
94  if (best_short && best_short->score() > m_trk_cands.back().score()) {
95  auto ci = m_trk_cands.begin();
96  while (ci->score() > best_short->score())
97  ++ci;
98 
99  if ((int)m_trk_cands.size() >= params.maxCandsPerSeed)
100  m_trk_cands.pop_back();
101 
102  // To print out what has been replaced -- remove when done with short track handling.
103 #ifdef DEBUG
104  if (ci == m_trk_cands.begin()) {
105  printf("FindTracksStd -- Replacing best cand (%f) with short one (%f) in final sorting\n",
106  m_trk_cands.front().score(),
107  best_short->score());
108  }
109 #endif
110 
111  m_trk_cands.insert(ci, *best_short);
112  }
113 
114  } else if (best_short) {
115  m_trk_cands.push_back(*best_short);
116  }
117 
118  if (best_short)
119  best_short->resetShortTrack();
120 
121  // assert(capacity() == (size_t)Config::maxCandsPerSeed);
122  }
float getScoreCand(const track_score_func &score_func, const Track &cand1, bool penalizeTailMissHits=false, bool inFindCandidates=false)
Definition: Track.h:608
CombCandidate * combCandidate() const
bool sortByScoreTrackCand(const TrackCand &cand1, const TrackCand &cand2)
trk_cand_vec_type m_trk_cands

◆ operator=()

CombCandidate& mkfit::CombCandidate::operator= ( CombCandidate &&  o)
inline

Definition at line 327 of file TrackStructures.h.

References m_best_short_cand, m_hots, m_hots_size, m_lastHitIdx_before_bkwsearch, m_nInsideMinusOneHits_before_bkwsearch, m_nTailMinusOneHits_before_bkwsearch, m_pickup_layer, m_state, m_trk_cands, eostools::move(), and EcalTangentSkim_cfg::o.

327  {
328  m_trk_cands = (std::move(o.m_trk_cands));
329  m_best_short_cand = std::move(o.m_best_short_cand);
330  m_state = o.m_state;
331  m_pickup_layer = o.m_pickup_layer;
332  m_lastHitIdx_before_bkwsearch = o.m_lastHitIdx_before_bkwsearch;
333  m_nInsideMinusOneHits_before_bkwsearch = o.m_nInsideMinusOneHits_before_bkwsearch;
334  m_nTailMinusOneHits_before_bkwsearch = o.m_nTailMinusOneHits_before_bkwsearch;
335 #ifdef DUMPHITWINDOW
336  m_seed_algo = o.m_seed_algo;
337  m_seed_label = o.m_seed_label;
338 #endif
339  m_hots_size = o.m_hots_size;
340  m_hots = std::move(o.m_hots);
341 
342  for (auto& tc : m_trk_cands)
343  tc.setCombCandidate(this);
344 
345  return *this;
346  }
short int m_nInsideMinusOneHits_before_bkwsearch
short int m_nTailMinusOneHits_before_bkwsearch
short int m_lastHitIdx_before_bkwsearch
trk_cand_vec_type m_trk_cands
def move(src, dest)
Definition: eostools.py:511
std::vector< HoTNode > m_hots

◆ operator[]() [1/2]

TrackCand& mkfit::CombCandidate::operator[] ( int  i)
inline

Definition at line 352 of file TrackStructures.h.

References mps_fire::i, and m_trk_cands.

352 { return m_trk_cands[i]; }
trk_cand_vec_type m_trk_cands

◆ operator[]() [2/2]

const TrackCand& mkfit::CombCandidate::operator[] ( int  i) const
inline

Definition at line 353 of file TrackStructures.h.

References mps_fire::i, and m_trk_cands.

353 { return m_trk_cands[i]; }
trk_cand_vec_type m_trk_cands

◆ pickupLayer()

int mkfit::CombCandidate::pickupLayer ( ) const
inline

Definition at line 413 of file TrackStructures.h.

References m_pickup_layer.

Referenced by mkfit::MkBuilder::find_tracks_unroll_candidates().

413 { return m_pickup_layer; }

◆ refBestShortCand()

const TrackCand& mkfit::CombCandidate::refBestShortCand ( ) const
inline

Definition at line 407 of file TrackStructures.h.

References m_best_short_cand.

Referenced by mkfit::CandCloner::processSeedRange().

407 { return m_best_short_cand; }

◆ repackCandPostBkwSearch()

void mkfit::CombCandidate::repackCandPostBkwSearch ( int  i)

Definition at line 229 of file TrackStructures.cc.

References mps_fire::i, mkfit::TrackCand::lastCcIndex(), m_hots, m_lastHitIdx_before_bkwsearch, m_nInsideMinusOneHits_before_bkwsearch, m_nTailMinusOneHits_before_bkwsearch, m_trk_cands, mkfit::TrackCand::nInsideMinusOneHits(), mkfit::TrackCand::nTailMinusOneHits(), mkfit::TrackCand::setLastCcIndex(), mkfit::TrackCand::setNInsideMinusOneHits(), and mkfit::TrackCand::setNTailMinusOneHits().

229  {
230  // Called during filtering following backward search when a TrackCand's
231  // front hits need to be reindexed.
232  // mergeCandsAndBestShortOne() has already been called (from MkBuilder::FindXxx()).
233  // NOTES:
234  // 1. Should only be called once for each i (flag/bit to allow multiple calls can be added).
235  // 2. Alternatively, CombCand could provide hit iterator/exporter that would handle this correctly.
236 
237  TrackCand &tc = m_trk_cands[i];
238 
239  int curr_idx = tc.lastCcIndex();
240  if (curr_idx != 0) {
241  int last_idx = -1, prev_idx;
242  do {
243  prev_idx = m_hots[curr_idx].m_prev_idx;
244 
245  m_hots[curr_idx].m_prev_idx = last_idx;
246 
247  last_idx = curr_idx;
248  curr_idx = prev_idx;
249  } while (prev_idx != -1);
250  }
251 
252  tc.setLastCcIndex(m_lastHitIdx_before_bkwsearch);
253  tc.setNInsideMinusOneHits(m_nInsideMinusOneHits_before_bkwsearch + tc.nInsideMinusOneHits());
254  tc.setNTailMinusOneHits(m_nTailMinusOneHits_before_bkwsearch + tc.nTailMinusOneHits());
255  }
short int m_nInsideMinusOneHits_before_bkwsearch
short int m_nTailMinusOneHits_before_bkwsearch
short int m_lastHitIdx_before_bkwsearch
trk_cand_vec_type m_trk_cands
std::vector< HoTNode > m_hots

◆ reset()

void mkfit::CombCandidate::reset ( int  max_cands_per_seed,
int  expected_num_hots 
)
inline

Definition at line 359 of file TrackStructures.h.

References mkfit::getScoreWorstPossible(), m_best_short_cand, m_hots, m_hots_size, m_lastHitIdx_before_bkwsearch, m_nInsideMinusOneHits_before_bkwsearch, m_nTailMinusOneHits_before_bkwsearch, m_trk_cands, mkfit::TrackBase::setScore(), and createJobs::tmp.

359  {
360  std::vector<TrackCand, CcAlloc<TrackCand>> tmp(m_trk_cands.get_allocator());
361  m_trk_cands.swap(tmp);
362  m_trk_cands.reserve(max_cands_per_seed); // we *must* never exceed this
363 
365 
366  // state and pickup_layer set in importSeed.
367 
368  // expected_num_hots is different for CloneEngine and Std, especially as long as we
369  // instantiate all candidates before purging them.
370  // ce: N_layer * N_cands ~~ 20 * 6 = 120
371  // std: i don't know, maybe double?
372  m_hots.reserve(expected_num_hots);
373  m_hots_size = 0;
374  m_hots.clear();
375 
379  }
short int m_nInsideMinusOneHits_before_bkwsearch
short int m_nTailMinusOneHits_before_bkwsearch
void setScore(float s)
Definition: Track.h:192
float getScoreWorstPossible()
Definition: Track.h:604
short int m_lastHitIdx_before_bkwsearch
trk_cand_vec_type m_trk_cands
tmp
align.sh
Definition: createJobs.py:716
std::vector< HoTNode > m_hots

◆ resize()

void mkfit::CombCandidate::resize ( trk_cand_vec_type::size_type  count)
inline

◆ setBestShortCand()

void mkfit::CombCandidate::setBestShortCand ( const TrackCand tc)
inline

Definition at line 408 of file TrackStructures.h.

References m_best_short_cand.

Referenced by mkfit::CandCloner::processSeedRange().

408 { m_best_short_cand = tc; }

◆ setState()

void mkfit::CombCandidate::setState ( SeedState_e  ss)
inline

◆ size()

trk_cand_vec_type::size_type mkfit::CombCandidate::size ( void  ) const
inline

◆ state()

SeedState_e mkfit::CombCandidate::state ( ) const
inline

Definition at line 410 of file TrackStructures.h.

References m_state.

Referenced by mkfit::MkBuilder::find_tracks_unroll_candidates(), and mkfit::CandCloner::processSeedRange().

410 { return m_state; }

Member Data Documentation

◆ m_best_short_cand

TrackCand mkfit::CombCandidate::m_best_short_cand
private

◆ m_hots

std::vector<HoTNode> mkfit::CombCandidate::m_hots
private

◆ m_hots_size

int mkfit::CombCandidate::m_hots_size = 0
private

◆ m_lastHitIdx_before_bkwsearch

short int mkfit::CombCandidate::m_lastHitIdx_before_bkwsearch = -1
private

Definition at line 425 of file TrackStructures.h.

Referenced by beginBkwSearch(), operator=(), repackCandPostBkwSearch(), and reset().

◆ m_nInsideMinusOneHits_before_bkwsearch

short int mkfit::CombCandidate::m_nInsideMinusOneHits_before_bkwsearch = -1
private

Definition at line 426 of file TrackStructures.h.

Referenced by beginBkwSearch(), operator=(), repackCandPostBkwSearch(), and reset().

◆ m_nTailMinusOneHits_before_bkwsearch

short int mkfit::CombCandidate::m_nTailMinusOneHits_before_bkwsearch = -1
private

Definition at line 427 of file TrackStructures.h.

Referenced by beginBkwSearch(), operator=(), repackCandPostBkwSearch(), and reset().

◆ m_pickup_layer

int mkfit::CombCandidate::m_pickup_layer
private

Definition at line 424 of file TrackStructures.h.

Referenced by beginBkwSearch(), importSeed(), operator=(), and pickupLayer().

◆ m_state

SeedState_e mkfit::CombCandidate::m_state
private

Definition at line 423 of file TrackStructures.h.

Referenced by beginBkwSearch(), importSeed(), operator=(), setState(), and state().

◆ m_trk_cands

trk_cand_vec_type mkfit::CombCandidate::m_trk_cands
private