Belle II Software  release-05-01-25
LayerSVDRelationFilter.dcl.h
1 /**************************************************************************
2  * BASF2 (Belle Analysis Framework 2) *
3  * Copyright(C) 2016 - Belle II Collaboration *
4  * *
5  * Author: The Belle II Collaboration *
6  * Contributors: Nils Braun, Christian Wessel *
7  * *
8  * This software is provided "as is" without any warranty. *
9  **************************************************************************/
10 #pragma once
11 
12 #include <tracking/trackFindingCDC/filters/base/RelationFilter.dcl.h>
13 #include <tracking/ckf/svd/entities/CKFToSVDState.h>
14 
15 namespace Belle2 {
20  template <class AFilter, class APrefilter = AFilter>
22  class LayerSVDRelationFilter : public TrackFindingCDC::RelationFilter<CKFToSVDState> {
24  using Super = TrackFindingCDC::RelationFilter<CKFToSVDState>;
25 
26  public:
27  using Super::operator();
28 
31 
34 
36  std::vector<CKFToSVDState*> getPossibleTos(CKFToSVDState* from,
37  const std::vector<CKFToSVDState*>& states) const final;
38 
40  void exposeParameters(ModuleParamList* moduleParamList, const std::string& prefix) final;
41 
42 
44  TrackFindingCDC::Weight operator()(const CKFToSVDState& from, const CKFToSVDState& to) final;
45 
47  void beginRun() final;
48 
49  private:
51  int m_param_hitJumping = 1;
53  AFilter m_filter;
55  APrefilter m_prefilter;
57  std::map<short, unsigned long> m_maximalLadderCache;
58  };
60 }
Belle2::LayerSVDRelationFilter::beginRun
void beginRun() final
Initialize the maximal ladder cache.
Definition: LayerSVDRelationFilter.icc.h:43
Belle2::LayerSVDRelationFilter::m_prefilter
APrefilter m_prefilter
Loose pre-filter to reject possibleTos.
Definition: LayerSVDRelationFilter.dcl.h:63
Belle2::LayerSVDRelationFilter::exposeParameters
void exposeParameters(ModuleParamList *moduleParamList, const std::string &prefix) final
Expose the parameters of the filter.
Definition: LayerSVDRelationFilter.icc.h:132
Belle2::LayerSVDRelationFilter::getPossibleTos
std::vector< CKFToSVDState * > getPossibleTos(CKFToSVDState *from, const std::vector< CKFToSVDState * > &states) const final
Return all states the given state is possible related to.
Definition: LayerSVDRelationFilter.icc.h:60
Belle2::LayerSVDRelationFilter::m_filter
AFilter m_filter
Filter for rejecting the states.
Definition: LayerSVDRelationFilter.dcl.h:61
Belle2
Abstract base class for different kinds of events.
Definition: MillepedeAlgorithm.h:19
Belle2::LayerSVDRelationFilter::m_maximalLadderCache
std::map< short, unsigned long > m_maximalLadderCache
Cached number of ladders per layer.
Definition: LayerSVDRelationFilter.dcl.h:65
Belle2::LayerSVDRelationFilter::operator()
TrackFindingCDC::Weight operator()(const CKFToSVDState &from, const CKFToSVDState &to) final
Give a final weight to the possibilities by asking the filter.
Definition: LayerSVDRelationFilter.icc.h:142
Belle2::LayerSVDRelationFilter::Super
TrackFindingCDC::RelationFilter< CKFToSVDState > Super
The parent class.
Definition: LayerSVDRelationFilter.dcl.h:32
Belle2::LayerSVDRelationFilter::m_param_hitJumping
int m_param_hitJumping
Parameter: Make it possible to jump over N layers.
Definition: LayerSVDRelationFilter.dcl.h:59
Belle2::ModuleParamList
The Module parameter list class.
Definition: ModuleParamList.h:46
Belle2::CKFToSVDState
Specialized CKF State for extrapolating into the SVD.
Definition: CKFToSVDState.h:29
Belle2::LayerSVDRelationFilter::LayerSVDRelationFilter
LayerSVDRelationFilter()
Add the filter as listener.
Definition: LayerSVDRelationFilter.icc.h:36
Belle2::LayerSVDRelationFilter::~LayerSVDRelationFilter
~LayerSVDRelationFilter()
Default destructor.