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 <boost/unordered_map.hpp>
6 
9  public:
10 
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) :
26 
27  ~CachingSeedCleanerBySharedInput() override { theVault.clear(); theCache.clear(); }
28  private:
29  std::vector<Trajectory::RecHitContainer> theVault;
30  //std::multimap<uint32_t, unsigned int> theCache;
31  boost::unordered_multimap<uint32_t, unsigned int> theCache;
32 
35 
36  //uint64_t comps_, tracks_, calls_;
37 };
38 
39 #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
CachingSeedCleanerBySharedInput(unsigned int numHitsForSeedCleaner=4, bool onlyPixelHits=false)
std::vector< Trajectory::RecHitContainer > theVault
boost::unordered_multimap< uint32_t, unsigned int > theCache
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 ...