Belle II Software  release-08-01-10
BestVXDTrackCandidatesSelectorModule.h
1 /**************************************************************************
2  * basf2 (Belle II Analysis Software Framework) *
3  * Author: The Belle II Collaboration *
4  * *
5  * See git log for contributors and copyright holders. *
6  * This file is licensed under LGPL-3.0, see LICENSE.md. *
7  **************************************************************************/
8 #pragma once
9 
10 #include <tracking/spacePointCreation/SpacePointTrackCand.h>
11 #include <framework/datastore/StoreArray.h>
12 #include <framework/core/Module.h>
13 #include <framework/datastore/SelectSubset.h>
14 
15 
16 
17 namespace Belle2 {
35  public:
38 
40  void initialize() override final;
41 
43  void event() override final;
44 
45  protected:
46 
48  void deactivateCandidates();
49 
51  void selectSubset();
52 
54  std::vector<int> getSortedTrackCandIndices(bool increasing);
55 
56  // parameters
57 
59  unsigned short m_subsetSize;
60 
63 
68 
71 
72 
73  // member variables
74 
77 
80 
83  };
85 }
Module that selects a subset with a fixed size x out of all SpacePointTrackCandidates.
void initialize() override final
Requires SpacePointTrackCands.
std::string m_newNameSpacePointTrackCands
Name of optional output StoreArray containing SpacePointTrackCands.
StoreArray< SpacePointTrackCand > m_newSpacePointTrackCands
StoreArray for optional output SpacePointTrackCands.
std::vector< int > getSortedTrackCandIndices(bool increasing)
Return StoreArrayIndices of all candidates sorted by their qualityIndicator.
void event() override final
Application of the cut.
SelectSubset< SpacePointTrackCand > m_bestCandidates
SubsetSelector operating on a custom selection criteria.
void selectSubset()
Copy or delete candidates to achieve a subset creation.
bool m_subsetCreation
If True copy selected SpacePointTrackCands to new StoreArray, If False deactivate remaining SpacePoin...
StoreArray< SpacePointTrackCand > m_spacePointTrackCands
StoreArray for input SpacePointTrackCands.
void deactivateCandidates()
Don't copy/delete candidates but rather deactivate them by setting a SpacePointTrackCandidate flag.
std::string m_nameSpacePointTrackCands
Name of input StoreArray containing SpacePointTrackCands.
Base class for Modules.
Definition: Module.h:72
Class to create a subset of a given StoreArray together with the relations with other StoreArrays.
Definition: SelectSubset.h:193
Abstract base class for different kinds of events.