CMS 3D CMS Logo

List of all members | Classes | Public Types | Public Member Functions | Public Attributes
mkfit::SteeringParams Class Reference

#include <SteeringParams.h>

Classes

class  iterator
 

Public Types

enum  IterationType_e { IT_FwdSearch, IT_BkwFit, IT_BkwSearch }
 

Public Member Functions

void append_plan (int layer)
 
void fill_plan (int first, int last)
 
bool has_bksearch_plan () const
 
iterator make_iterator (IterationType_e type) const
 
void reserve_plan (int n)
 
void set_iterator_limits (int fwd_search_pu, int bkw_fit_last, int bkw_search_pu=-1)
 
 SteeringParams ()
 

Public Attributes

int m_bkw_fit_last = 0
 
int m_bkw_search_pickup = -1
 
int m_fwd_search_pickup = 0
 
std::vector< LayerControlm_layer_plan
 
int m_region
 
track_score_func m_track_scorer
 
std::string m_track_scorer_name
 

Detailed Description

Definition at line 36 of file SteeringParams.h.

Member Enumeration Documentation

◆ IterationType_e

Constructor & Destructor Documentation

◆ SteeringParams()

mkfit::SteeringParams::SteeringParams ( )
inline

Definition at line 110 of file SteeringParams.h.

110 {}

Member Function Documentation

◆ append_plan()

void mkfit::SteeringParams::append_plan ( int  layer)
inline

Definition at line 114 of file SteeringParams.h.

References nano_mu_digi_cff::layer, and m_layer_plan.

Referenced by fill_plan().

114 { m_layer_plan.emplace_back(LayerControl(layer)); }
std::vector< LayerControl > m_layer_plan

◆ fill_plan()

void mkfit::SteeringParams::fill_plan ( int  first,
int  last 
)
inline

Definition at line 116 of file SteeringParams.h.

References append_plan(), dqmdumpme::first, mps_fire::i, and dqmdumpme::last.

116  {
117  for (int i = first; i <= last; ++i)
118  append_plan(i);
119  }
void append_plan(int layer)

◆ has_bksearch_plan()

bool mkfit::SteeringParams::has_bksearch_plan ( ) const
inline

Definition at line 127 of file SteeringParams.h.

References m_bkw_search_pickup.

127 { return m_bkw_search_pickup != -1; }

◆ make_iterator()

iterator mkfit::SteeringParams::make_iterator ( IterationType_e  type) const
inline

Definition at line 129 of file SteeringParams.h.

References mkfit::SteeringParams::iterator::is_valid(), IT_BkwFit, IT_BkwSearch, IT_FwdSearch, m_bkw_fit_last, m_bkw_search_pickup, mkfit::SteeringParams::iterator::m_cur_index, mkfit::SteeringParams::iterator::m_end_index, m_fwd_search_pickup, and m_layer_plan.

Referenced by mkfit::MkFinder::bkFitFitTracks(), mkfit::MkBuilder::find_tracks_in_layers(), mkfit::MkBuilder::findTracksBestHit(), and mkfit::MkBuilder::findTracksStandard().

129  {
130  iterator it(*this, type);
131 
132  if (type == IT_FwdSearch) {
133  it.m_cur_index = m_fwd_search_pickup;
134  it.m_end_index = m_layer_plan.size();
135  } else if (type == IT_BkwFit) {
136  it.m_cur_index = m_layer_plan.size() - 1;
137  it.m_end_index = m_bkw_fit_last - 1;
138  } else if (type == IT_BkwSearch) {
139  it.m_cur_index = m_bkw_search_pickup;
140  it.m_end_index = -1;
141  } else
142  throw std::invalid_argument("unknown iteration type");
143 
144  if (!it.is_valid())
145  throw std::runtime_error("invalid iterator constructed");
146 
147  return it;
148  }
std::vector< LayerControl > m_layer_plan

◆ reserve_plan()

void mkfit::SteeringParams::reserve_plan ( int  n)
inline

Definition at line 112 of file SteeringParams.h.

References m_layer_plan, and dqmiodumpmetadata::n.

112 { m_layer_plan.reserve(n); }
std::vector< LayerControl > m_layer_plan

◆ set_iterator_limits()

void mkfit::SteeringParams::set_iterator_limits ( int  fwd_search_pu,
int  bkw_fit_last,
int  bkw_search_pu = -1 
)
inline

Definition at line 121 of file SteeringParams.h.

References m_bkw_fit_last, m_bkw_search_pickup, and m_fwd_search_pickup.

121  {
122  m_fwd_search_pickup = fwd_search_pu;
123  m_bkw_fit_last = bkw_fit_last;
124  m_bkw_search_pickup = bkw_search_pu;
125  }

Member Data Documentation

◆ m_bkw_fit_last

int mkfit::SteeringParams::m_bkw_fit_last = 0

Definition at line 105 of file SteeringParams.h.

Referenced by make_iterator(), and set_iterator_limits().

◆ m_bkw_search_pickup

int mkfit::SteeringParams::m_bkw_search_pickup = -1

◆ m_fwd_search_pickup

int mkfit::SteeringParams::m_fwd_search_pickup = 0

◆ m_layer_plan

std::vector<LayerControl> mkfit::SteeringParams::m_layer_plan

◆ m_region

int mkfit::SteeringParams::m_region

Definition at line 102 of file SteeringParams.h.

Referenced by mkfit::SteeringParams::iterator::region().

◆ m_track_scorer

track_score_func mkfit::SteeringParams::m_track_scorer

◆ m_track_scorer_name

std::string mkfit::SteeringParams::m_track_scorer_name

Definition at line 100 of file SteeringParams.h.