1 #include "../interface/TrigPrimTask.h"
29 bxBinEdges_{1, 271, 541, 892, 1162, 1432, 1783, 2053, 2323, 2674, 2944, 3214, 3446, 3490, 3491, 3565},
81 for(EcalTPGTowerStatusMap::const_iterator ttItr(towerMap.begin()); ttItr != towerMap.end(); ++ttItr){
83 if ((*ttItr).second > 0)
87 meTTMaskMap.fill(ttid,1);
91 for(EcalTPGStripStatusMap::const_iterator stItr(stripMap.begin()); stItr != stripMap.end(); ++stItr){
93 if ((*stItr).second > 0)
97 meTTMaskMap.fill(stid,1);
157 template<
typename DigiCollection>
161 for(
typename DigiCollection::const_iterator digiItr(_digis.begin()); digiItr != _digis.end(); ++digiItr){
172 MESet& meEtRealMap(
MEs_.at(
"EtRealMap"));
173 MESet& meEtSummary(
MEs_.at(
"EtSummary"));
174 MESet& meLowIntMap(
MEs_.at(
"LowIntMap"));
175 MESet& meMedIntMap(
MEs_.at(
"MedIntMap"));
176 MESet& meHighIntMap(
MEs_.at(
"HighIntMap"));
178 MESet& meTTFMismatch(
MEs_.at(
"TTFMismatch"));
183 double nTP[] = {0., 0., 0.};
187 float et(tpItr->compressedEt());
192 else if(ttid.zside() < 0)
196 meEtVsBx.fill(ttid,
bxBin_, et);
199 meEtReal.fill(ttid, et);
200 meEtRealMap.fill(ttid, et);
201 meEtSummary.fill(ttid, et);
203 int interest(tpItr->ttFlag() & 0x3);
207 meLowIntMap.fill(ttid);
210 meMedIntMap.fill(ttid);
213 meHighIntMap.fill(ttid);
219 meTTFlags.fill(ttid,
float(tpItr->ttFlag()));
222 meTTFMismatch.fill(ttid);
233 MESet& meEtMaxEmul(
MEs_.at(
"EtMaxEmul"));
234 MESet& meEmulMaxIndex(
MEs_.at(
"EmulMaxIndex"));
235 MESet& meMatchedIndex(
MEs_.at(
"MatchedIndex"));
236 MESet& meEtEmulError(
MEs_.at(
"EtEmulError"));
237 MESet& meFGEmulError(
MEs_.at(
"FGEmulError"));
242 int et(tpItr->compressedEt());
246 for(
int iDigi(0); iDigi < 5; iDigi++){
247 float sampleEt((*tpItr)[iDigi].compressedEt());
249 if(sampleEt > maxEt){
255 meEtMaxEmul.fill(ttid, maxEt);
257 meEmulMaxIndex.fill(ttid, iMax);
265 int realEt(realItr->compressedEt());
269 int interest(realItr->ttFlag() & 0x3);
272 if(et != realEt) match =
false;
273 if(tpItr->fineGrain() != realItr->fineGrain()) matchFG =
false;
275 std::vector<int> matchedIndex(0);
276 for(
int iDigi(0); iDigi < 5; iDigi++){
277 if((*tpItr)[iDigi].compressedEt() == realEt)
278 matchedIndex.push_back(iDigi + 1);
281 if(!matchedIndex.size()) matchedIndex.push_back(0);
282 for(std::vector<int>::iterator matchItr(matchedIndex.begin()); matchItr != matchedIndex.end(); ++matchItr){
283 meMatchedIndex.fill(ttid, *matchItr + 0.5);
298 if(!match) meEtEmulError.fill(ttid);
299 if(!matchFG) meFGEmulError.fill(ttid);
T getUntrackedParameter(std::string const &, T const &) const
std::map< uint32_t, uint16_t > EcalTPGTowerStatusMap
#define DEFINE_ECALDQM_WORKER(TYPE)
void beginEvent(edm::Event const &, edm::EventSetup const &) override
void setParams(edm::ParameterSet const &) override
Ecal readout channel identification [32:20] Unused (so far) [19:13] DCC id [12:6] tower [5:3] strip [...
std::vector< EcalTriggerPrimitiveDigi >::const_iterator const_iterator
int bunchCrossing() const
std::map< uint32_t, unsigned > towerReadouts_
const std::map< uint32_t, uint16_t > & getMap() const
uint32_t rawId() const
get the raw id
void addDependencies(DependencySet &) override
EcalTrigTowerConstituentsMap const * getTrigTowerMap()
void runOnEmulTPs(EcalTrigPrimDigiCollection const &)
std::vector< DetId > constituentsOf(const EcalTrigTowerDetId &id) const
Get the constituent detids for this tower id.
EcalSubdetector subdet() const
get the subdet
void runOnDigis(DigiCollection const &)
const_iterator end() const
EcalTrigPrimDigiCollection const * realTps_
int bxBinEdges_[nBXBins+1]
void runOnRealTPs(EcalTrigPrimDigiCollection const &)
const std::map< uint32_t, uint16_t > & getMap() const
EcalSubdetector subDet() const
get the subDetector associated to the Trigger Tower
iterator find(key_type k)
std::pair< typename Association::data_type::first_type, double > match(Reference key, Association association, bool bestMatchByMaxValue)
Generic matching function.
volatile std::atomic< bool > shutdown_flag false
std::map< uint32_t, uint16_t > EcalTPGStripStatusMap
void push_back(Dependency const &_d)
const_iterator begin() const