Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-04-06 12:26:09

0001 #ifndef DTSegment_DTSegmentCleaner_h
0002 #define DTSegment_DTSegmentCleaner_h
0003 
0004 /** \file
0005  *
0006  *  Conflict solving and ghost suppression for DT segment candidates 
0007  *
0008  *  The candidates found by DTCombinatorialPatternReco are checked for
0009  *  conflicting segments, namely segment which shares hits with conflicting
0010  *  Left/Right ambuguity solution. Then check for ghost, i.e. segments which
0011  *  shares more than a given number of hits. In both cases, a selection is done
0012  *  retaining the segment with higher number of hits and best chi2, while the
0013  *  others are deleted.
0014  *
0015  * \author : Stefano Lacaprara - INFN Legnaro <stefano.lacaprara@pd.infn.it>
0016  */
0017 
0018 /* Base Class Headers */
0019 
0020 /* Collaborating Class Declarations */
0021 #include "FWCore/ParameterSet/interface/ParameterSet.h"
0022 #include "RecoLocalMuon/DTSegment/src/DTSegmentCand.h"
0023 
0024 /* C++ Headers */
0025 #include <vector>
0026 
0027 /* ====================================================================== */
0028 
0029 /* Class DTSegmentCleaner Interface */
0030 
0031 class DTSegmentCleaner {
0032 public:
0033   typedef std::pair<DTHitPairForFit*, DTEnums::DTCellSide> AssPoint;
0034   typedef std::set<AssPoint, DTSegmentCand::AssPointLessZ> AssPointCont;
0035 
0036   /* Constructor */
0037   DTSegmentCleaner(const edm::ParameterSet& pset);
0038 
0039   /* Destructor */
0040   ~DTSegmentCleaner();
0041 
0042   /* Operations */
0043   /// do the cleaning
0044   std::vector<DTSegmentCand*> clean(const std::vector<DTSegmentCand*>& inputCands) const;
0045 
0046 private:
0047   /// solve the conflicts
0048   std::vector<DTSegmentCand*> solveConflict(const std::vector<DTSegmentCand*>& inputCands) const;
0049 
0050   /// ghost  suppression
0051   std::vector<DTSegmentCand*> ghostBuster(const std::vector<DTSegmentCand*>& inputCands) const;
0052 
0053   int nSharedHitsMax;
0054   int nUnSharedHitsMin;
0055   ///treatment of LR ambiguity cases: 1 chooses the best chi2
0056   ///                                 2 chooses the smaller angle
0057   ///                                 3 keeps both candidates
0058   int segmCleanerMode;
0059 };
0060 #endif  // DTSegment_DTSegmentCleaner_h