File indexing completed on 2024-04-06 12:19:35
0001 #ifndef L1Trigger_CSCTriggerPrimitives_GEMClusterProcessor_h
0002 #define L1Trigger_CSCTriggerPrimitives_GEMClusterProcessor_h
0003
0004
0005
0006
0007
0008
0009
0010 #include "FWCore/ParameterSet/interface/ParameterSet.h"
0011 #include "DataFormats/GEMDigi/interface/GEMPadDigiClusterCollection.h"
0012 #include "DataFormats/GEMDigi/interface/GEMCoPadDigi.h"
0013 #include "L1Trigger/CSCTriggerPrimitives/interface/GEMInternalCluster.h"
0014 #include "CondFormats/CSCObjects/interface/CSCL1TPLookupTableME11ILT.h"
0015 #include "CondFormats/CSCObjects/interface/CSCL1TPLookupTableME21ILT.h"
0016
0017 #include <vector>
0018
0019 class GEMClusterProcessor {
0020 public:
0021
0022 GEMClusterProcessor(int region, unsigned station, unsigned chamber, const edm::ParameterSet& conf);
0023
0024
0025 void clear();
0026
0027
0028 void run(const GEMPadDigiClusterCollection*,
0029 const CSCL1TPLookupTableME11ILT* lookupTableME11ILT,
0030 const CSCL1TPLookupTableME21ILT* lookupTableME21ILT);
0031
0032
0033
0034
0035
0036 enum ClusterTypes { AllClusters = 1, SingleClusters = 2, CoincidenceClusters = 3 };
0037 std::vector<GEMInternalCluster> getClusters(int bx, ClusterTypes option = AllClusters) const;
0038
0039
0040 std::vector<GEMCoPadDigi> readoutCoPads() const;
0041
0042 bool hasGE21Geometry16Partitions() const { return hasGE21Geometry16Partitions_; }
0043
0044 private:
0045
0046 void addCoincidenceClusters(const GEMPadDigiClusterCollection*);
0047
0048
0049
0050 void addSingleClusters(const GEMPadDigiClusterCollection*);
0051
0052
0053
0054
0055 void doCoordinateConversion(const CSCL1TPLookupTableME11ILT* lookupTableME11ILT,
0056 const CSCL1TPLookupTableME21ILT* lookupTableME21ILT);
0057
0058
0059 const int region_;
0060 const int station_;
0061 const int chamber_;
0062 bool isEven_;
0063
0064 unsigned int tmbL1aWindowSize_;
0065 unsigned int delayGEMinOTMB_;
0066 unsigned int maxDeltaPad_;
0067 unsigned int maxDeltaBX_;
0068 unsigned int maxDeltaRoll_;
0069
0070 bool hasGE21Geometry16Partitions_;
0071
0072
0073 std::vector<GEMInternalCluster> clusters_;
0074 };
0075
0076 #endif