CMS 3D CMS Logo

HcalUnpackerReport.h
Go to the documentation of this file.
1 #ifndef DATAFORMATS_HCALDIGI_HCALUNPACKERREPORT_H
2 #define DATAFORMATS_HCALDIGI_HCALUNPACKERREPORT_H 1
3 
4 #include <vector>
5 #include <map>
9 
15 public:
17  const std::vector<int>& getFedsUnpacked() const { return FEDsUnpacked_; }
18  const std::vector<int>& getFedsError() const { return FEDsError_; }
19  bool errorFree() const;
20  bool anyValidHCAL() const;
21  int unmappedDigis() const { return unmappedDigis_; }
22  int unmappedTPDigis() const { return unmappedTPDigis_; }
23  int spigotFormatErrors() const { return spigotFormatErrors_; }
24  int badQualityDigis() const { return badqualityDigis_; }
25  int totalDigis() const { return totalDigis_; }
26  int totalTPDigis() const { return totalTPDigis_; }
27  int totalHOTPDigis() const { return totalHOTPDigis_; }
28  int emptyEventSpigots() const { return emptyEventSpigots_; }
29  int OFWSpigots() const { return ofwSpigots_; }
30  int busySpigots() const { return busySpigots_; }
31 
32  bool unsuppressedChannels() const { return unsuppressed_; }
33 
34  bool hasFedWithCalib() const { return !fedInfo_.empty(); }
35  HcalCalibrationEventType fedCalibType(uint16_t fed) const;
36 
37  void setFedCalibInfo(uint16_t fed, HcalCalibrationEventType ctype);
38 
39  typedef std::vector<DetId> DetIdVector;
40  typedef std::vector<HcalElectronicsId> ElectronicsIdVector;
41 
42  DetIdVector::const_iterator bad_quality_begin() const { return badqualityIds_.begin(); }
43  DetIdVector::const_iterator bad_quality_end() const { return badqualityIds_.end(); }
44  ElectronicsIdVector::const_iterator unmapped_begin() const { return unmappedIds_.begin(); }
45  ElectronicsIdVector::const_iterator unmapped_end() const { return unmappedIds_.end(); }
46 
47  bool hasReportInfo(const std::string& name) const;
49  std::vector<std::string> getReportKeys() const;
50 
51  // setters
52  void addUnpacked(int fed);
53  void addError(int fed);
54  void countDigi();
55  void countTPDigi(bool ho = false);
56  void countUnmappedDigi();
57  void countUnmappedTPDigi();
59  void countBadQualityDigi();
60  void countEmptyEventSpigot();
61  void countOFWSpigot();
62  void countBusySpigot();
65  void countBadQualityDigi(const DetId& did);
66  void setUnsuppressed(bool isSup);
67  void setReportInfo(const std::string& name, const std::string& value);
68 
69 private:
70  std::vector<int> FEDsUnpacked_;
71  std::vector<int> FEDsError_;
78 
79  std::vector<std::string> reportInfo_;
80  std::vector<uint16_t> fedInfo_; // first is fed, second is type
81 
83 };
84 
85 #endif
HcalUnpackerReport::HcalUnpackerReport
HcalUnpackerReport()
Definition: HcalUnpackerReport.cc:3
HcalUnpackerReport::setReportInfo
void setReportInfo(const std::string &name, const std::string &value)
Definition: HcalUnpackerReport.cc:81
HcalUnpackerReport::unmappedTPDigis_
int unmappedTPDigis_
Definition: HcalUnpackerReport.h:72
HcalUnpackerReport::countEmptyEventSpigot
void countEmptyEventSpigot()
Definition: HcalUnpackerReport.cc:35
HcalCalibrationEventTypes.h
HcalUnpackerReport::addUnpacked
void addUnpacked(int fed)
Definition: HcalUnpackerReport.cc:20
HcalUnpackerReport::anyValidHCAL
bool anyValidHCAL() const
Definition: HcalUnpackerReport.cc:18
HcalUnpackerReport::unsuppressedChannels
bool unsuppressedChannels() const
Definition: HcalUnpackerReport.h:32
HcalUnpackerReport::bad_quality_end
DetIdVector::const_iterator bad_quality_end() const
Definition: HcalUnpackerReport.h:43
HcalUnpackerReport::errorFree
bool errorFree() const
Definition: HcalUnpackerReport.cc:16
HcalUnpackerReport::countTPDigi
void countTPDigi(bool ho=false)
Definition: HcalUnpackerReport.cc:25
HcalUnpackerReport::totalHOTPDigis_
int totalHOTPDigis_
Definition: HcalUnpackerReport.h:74
HcalUnpackerReport::addError
void addError(int fed)
Definition: HcalUnpackerReport.cc:22
HcalUnpackerReport::FEDsError_
std::vector< int > FEDsError_
Definition: HcalUnpackerReport.h:71
HcalUnpackerReport::countUnmappedTPDigi
void countUnmappedTPDigi()
Definition: HcalUnpackerReport.cc:33
HcalUnpackerReport::unmapped_begin
ElectronicsIdVector::const_iterator unmapped_begin() const
Definition: HcalUnpackerReport.h:44
HcalUnpackerReport::getReportInfo
std::string getReportInfo(const std::string &name) const
Definition: HcalUnpackerReport.cc:93
HcalUnpackerReport::getFedsUnpacked
const std::vector< int > & getFedsUnpacked() const
Definition: HcalUnpackerReport.h:17
HcalUnpackerReport::spigotFormatErrors_
int spigotFormatErrors_
Definition: HcalUnpackerReport.h:73
HcalUnpackerReport::badQualityDigis
int badQualityDigis() const
Definition: HcalUnpackerReport.h:24
DetId
Definition: DetId.h:17
HcalUnpackerReport::countUnmappedDigi
void countUnmappedDigi()
Definition: HcalUnpackerReport.cc:32
HcalUnpackerReport::unmapped_end
ElectronicsIdVector::const_iterator unmapped_end() const
Definition: HcalUnpackerReport.h:45
HcalUnpackerReport::setFedCalibInfo
void setFedCalibInfo(uint16_t fed, HcalCalibrationEventType ctype)
Definition: HcalUnpackerReport.cc:64
HcalUnpackerReport::DetIdVector
std::vector< DetId > DetIdVector
Definition: HcalUnpackerReport.h:39
HcalUnpackerReport
Definition: HcalUnpackerReport.h:14
HcalUnpackerReport::badqualityDigis_
int badqualityDigis_
Definition: HcalUnpackerReport.h:73
HcalUnpackerReport::totalDigis
int totalDigis() const
Definition: HcalUnpackerReport.h:25
HcalCalibrationEventType
HcalCalibrationEventType
Definition: HcalCalibrationEventTypes.h:4
HcalElectronicsId
Readout chain identification for Hcal.
Definition: HcalElectronicsId.h:32
HcalUnpackerReport::reportInfo_
std::vector< std::string > reportInfo_
Definition: HcalUnpackerReport.h:79
HcalUnpackerReport::hasFedWithCalib
bool hasFedWithCalib() const
Definition: HcalUnpackerReport.h:34
HcalUnpackerReport::unmappedTPDigis
int unmappedTPDigis() const
Definition: HcalUnpackerReport.h:22
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
HcalUnpackerReport::unmappedDigis
int unmappedDigis() const
Definition: HcalUnpackerReport.h:21
HcalUnpackerReport::spigotFormatErrors
int spigotFormatErrors() const
Definition: HcalUnpackerReport.h:23
HcalUnpackerReport::getFedsError
const std::vector< int > & getFedsError() const
Definition: HcalUnpackerReport.h:18
HcalUnpackerReport::unmappedDigis_
int unmappedDigis_
Definition: HcalUnpackerReport.h:72
HcalUnpackerReport::countDigi
void countDigi()
Definition: HcalUnpackerReport.cc:24
HcalUnpackerReport::setUnsuppressed
void setUnsuppressed(bool isSup)
Definition: HcalUnpackerReport.cc:77
HcalUnpackerReport::hasReportInfo
bool hasReportInfo(const std::string &name) const
Definition: HcalUnpackerReport.cc:85
HcalUnpackerReport::totalHOTPDigis
int totalHOTPDigis() const
Definition: HcalUnpackerReport.h:27
HcalUnpackerReport::fedCalibType
HcalCalibrationEventType fedCalibType(uint16_t fed) const
Definition: HcalUnpackerReport.cc:53
runTauDisplay.eid
eid
Definition: runTauDisplay.py:298
value
Definition: value.py:1
photonIsolationHIProducer_cfi.ho
ho
Definition: photonIsolationHIProducer_cfi.py:10
HcalUnpackerReport::countBusySpigot
void countBusySpigot()
Definition: HcalUnpackerReport.cc:37
HcalElectronicsId.h
HcalUnpackerReport::totalDigis_
int totalDigis_
Definition: HcalUnpackerReport.h:74
HcalUnpackerReport::totalTPDigis_
int totalTPDigis_
Definition: HcalUnpackerReport.h:74
HcalUnpackerReport::emptyEventSpigots
int emptyEventSpigots() const
Definition: HcalUnpackerReport.h:28
HcalUnpackerReport::unmappedIds_
ElectronicsIdVector unmappedIds_
Definition: HcalUnpackerReport.h:76
DetId.h
HcalUnpackerReport::bad_quality_begin
DetIdVector::const_iterator bad_quality_begin() const
Definition: HcalUnpackerReport.h:42
HcalUnpackerReport::totalTPDigis
int totalTPDigis() const
Definition: HcalUnpackerReport.h:26
HcalUnpackerReport::fedInfo_
std::vector< uint16_t > fedInfo_
Definition: HcalUnpackerReport.h:80
Skims_PA_cff.name
name
Definition: Skims_PA_cff.py:17
HcalUnpackerReport::countOFWSpigot
void countOFWSpigot()
Definition: HcalUnpackerReport.cc:36
HcalUnpackerReport::countSpigotFormatError
void countSpigotFormatError()
Definition: HcalUnpackerReport.cc:34
HcalUnpackerReport::countBadQualityDigi
void countBadQualityDigi()
Definition: HcalUnpackerReport.cc:39
HcalUnpackerReport::ofwSpigots_
int ofwSpigots_
Definition: HcalUnpackerReport.h:82
HcalUnpackerReport::busySpigots_
int busySpigots_
Definition: HcalUnpackerReport.h:82
HcalUnpackerReport::FEDsUnpacked_
std::vector< int > FEDsUnpacked_
Definition: HcalUnpackerReport.h:70
HcalUnpackerReport::getReportKeys
std::vector< std::string > getReportKeys() const
Definition: HcalUnpackerReport.cc:106
HcalUnpackerReport::busySpigots
int busySpigots() const
Definition: HcalUnpackerReport.h:30
HcalUnpackerReport::OFWSpigots
int OFWSpigots() const
Definition: HcalUnpackerReport.h:29
HcalUnpackerReport::unsuppressed_
bool unsuppressed_
Definition: HcalUnpackerReport.h:77
HcalUnpackerReport::emptyEventSpigots_
int emptyEventSpigots_
Definition: HcalUnpackerReport.h:82
HcalUnpackerReport::badqualityIds_
DetIdVector badqualityIds_
Definition: HcalUnpackerReport.h:75
HcalUnpackerReport::ElectronicsIdVector
std::vector< HcalElectronicsId > ElectronicsIdVector
Definition: HcalUnpackerReport.h:40