CMS 3D CMS Logo

CachingSeedCleanerBySharedInput.h
Go to the documentation of this file.
1 #ifndef CachingSeedCleanerBySharedInput_H
2 #define CachingSeedCleanerBySharedInput_H
4 #include <map>
5 #include <unordered_map>
6 
9  public:
10 
11  // in this implementation it populate the cache
12  void add(const Trajectory *traj) override ;
13 
15  void init(const std::vector<Trajectory> *vect) override ;
16 
17  void done() override ;
18 
20  bool good(const TrajectorySeed *seed) override ;
21 
23  bool onlyPixelHits=false) :
25 
26  private:
27  std::vector<Trajectory::RecHitContainer> theVault;
28  std::unordered_multimap<unsigned int, unsigned int> theCache;
29 
32 
33  //uint64_t comps_, tracks_, calls_;
34 };
35 
36 #endif
void done() override
Tells the cleaner that the seeds are finished, and so it can clear any cache it has.
bool good(const TrajectorySeed *seed) override
Returns true if the seed is not overlapping with another trajectory.
void add(const Trajectory *traj) override
Informs the cleaner that a new trajectory has been made, in case the cleaner keeps a local collection...
CachingSeedCleanerBySharedInput(unsigned int numHitsForSeedCleaner=4, bool onlyPixelHits=false)
std::unordered_multimap< unsigned int, unsigned int > theCache
std::vector< Trajectory::RecHitContainer > theVault
numHitsForSeedCleaner
these two parameters are relevant only for the CachingSeedCleanerBySharedInput
void init(const std::vector< Trajectory > *vect) override
Provides the cleaner a pointer to the vector where trajectories are stored, in case it does not want ...