CMS 3D CMS Logo

RawToDigiConverter.h
Go to the documentation of this file.
1 /****************************************************************************
2 *
3 * This is a part of the TOTEM offline software.
4 * Authors:
5 * Jan Kašpar (jan.kaspar@gmail.com)
6 *
7 ****************************************************************************/
8 
9 #ifndef EventFilter_CTPPSRawToDigi_RawToDigiConverter
10 #define EventFilter_CTPPSRawToDigi_RawToDigiConverter
11 
14 
16 
19 
24 
26 class RawToDigiConverter {
27 public:
29 
31  void run(const VFATFrameCollection &coll,
32  const TotemDAQMapping &mapping,
33  const TotemAnalysisMask &mask,
36 
38  void run(const VFATFrameCollection &coll,
39  const TotemDAQMapping &mapping,
40  const TotemAnalysisMask &mask,
43 
45  void run(const VFATFrameCollection &coll,
46  const TotemDAQMapping &mapping,
47  const TotemAnalysisMask &mask,
50 
52  void printSummaries() const;
53 
54 private:
55  struct Record {
56  const TotemVFATInfo *info;
57  const VFATFrame *frame;
59  };
60 
61  unsigned char verbosity;
62 
63  unsigned int printErrorSummary;
64  unsigned int printUnknownFrameSummary;
65 
66  enum TestFlag { tfNoTest, tfWarn, tfErr };
67 
69  unsigned int testFootprint;
70  unsigned int testCRC;
71  unsigned int testID;
72  unsigned int testECRaw;
73  unsigned int testECDAQ;
74  unsigned int testECMostFrequent;
75  unsigned int testBCMostFrequent;
76 
78  unsigned int EC_min, BC_min;
79 
81  double EC_fraction, BC_fraction;
82 
84  std::map<TotemFramePosition, std::map<TotemVFATStatus, unsigned int> > errorSummary;
85  std::map<TotemFramePosition, unsigned int> unknownSummary;
86 
90  std::map<TotemFramePosition, Record> &records);
91 };
92 
93 #endif
edm::DetSetVector
Definition: DetSetVector.h:61
input
static const std::string input
Definition: EdmProvDump.cc:48
RawToDigiConverter::Record::frame
const VFATFrame * frame
Definition: RawToDigiConverter.h:61
RawToDigiConverter::verbosity
unsigned char verbosity
Definition: RawToDigiConverter.h:65
RawToDigiConverter::testECDAQ
unsigned int testECDAQ
Definition: RawToDigiConverter.h:77
mps_update.status
status
Definition: mps_update.py:68
RawToDigiConverter::testBCMostFrequent
unsigned int testBCMostFrequent
Definition: RawToDigiConverter.h:79
RawToDigiConverter::tfWarn
Definition: RawToDigiConverter.h:70
TotemDAQMapping.h
TotemTimingDigi.h
RawToDigiConverter::printErrorSummary
unsigned int printErrorSummary
Definition: RawToDigiConverter.h:67
RawToDigiConverter::testCRC
unsigned int testCRC
Definition: RawToDigiConverter.h:74
VFATFrameCollection.h
RawToDigiConverter::testECRaw
unsigned int testECRaw
Definition: RawToDigiConverter.h:76
TotemVFATInfo
Contains mappind data related to a VFAT.
Definition: TotemDAQMapping.h:23
RawToDigiConverter::EC_fraction
double EC_fraction
the minimal required (relative) occupancy of the most frequent counter value to be accepted
Definition: RawToDigiConverter.h:85
RawToDigiConverter::testID
unsigned int testID
Definition: RawToDigiConverter.h:75
RawToDigiConverter::Record::status
TotemVFATStatus status
Definition: RawToDigiConverter.h:62
CTPPSDiamondDigi.h
RawToDigiConverter::EC_min
unsigned int EC_min
the minimal required number of frames to determine the most frequent counter value
Definition: RawToDigiConverter.h:82
TotemDAQMapping
The mapping between FramePosition and VFATInfo.
Definition: TotemDAQMapping.h:39
TotemAnalysisMask.h
RawToDigiConverter::run
void run(const VFATFrameCollection &coll, const TotemDAQMapping &mapping, const TotemAnalysisMask &mask, edm::DetSetVector< TotemRPDigi > &digi, edm::DetSetVector< TotemVFATStatus > &status)
Creates RP digi.
Definition: RawToDigiConverter.cc:176
RawToDigiConverter::Record::info
const TotemVFATInfo * info
Definition: RawToDigiConverter.h:60
TotemVFATStatus.h
RawToDigiConverter::tfNoTest
Definition: RawToDigiConverter.h:70
edm::ParameterSet
Definition: ParameterSet.h:47
RawToDigiConverter::BC_min
unsigned int BC_min
Definition: RawToDigiConverter.h:82
TotemAnalysisMask
Channel-mask mapping.
Definition: TotemAnalysisMask.h:38
RawToDigiConverter::runCommon
void runCommon(const VFATFrameCollection &input, const TotemDAQMapping &mapping, std::map< TotemFramePosition, Record > &records)
Common processing for all VFAT based sub-systems.
Definition: RawToDigiConverter.cc:40
DetSetVector.h
TotemVFATStatus
Definition: TotemVFATStatus.h:20
RawToDigiConverter::tfErr
Definition: RawToDigiConverter.h:70
RawToDigiConverter::RawToDigiConverter
RawToDigiConverter(const edm::ParameterSet &conf)
Definition: RawToDigiConverter.cc:23
VFATFrame
Definition: VFATFrame.h:18
RawToDigiConverter::testFootprint
unsigned int testFootprint
flags for which tests to run
Definition: RawToDigiConverter.h:73
Record
RawToDigiConverter::unknownSummary
std::map< TotemFramePosition, unsigned int > unknownSummary
Definition: RawToDigiConverter.h:89
RawToDigiConverter::TestFlag
TestFlag
Definition: RawToDigiConverter.h:70
ParameterSet.h
VFATFrameCollection
Definition: VFATFrameCollection.h:20
TotemRPDigi.h
RawToDigiConverter::testECMostFrequent
unsigned int testECMostFrequent
Definition: RawToDigiConverter.h:78
RawToDigiConverter
Collection of code to convert TOTEM raw data into digi.
Definition: RawToDigiConverter.h:25
RawToDigiConverter::printUnknownFrameSummary
unsigned int printUnknownFrameSummary
Definition: RawToDigiConverter.h:68
taus_updatedMVAIds_cff.mapping
mapping
Definition: taus_updatedMVAIds_cff.py:29
RawToDigiConverter::printSummaries
void printSummaries() const
Print error summaries.
Definition: RawToDigiConverter.cc:382
RawToDigiConverter::BC_fraction
double BC_fraction
Definition: RawToDigiConverter.h:85
RawToDigiConverter::errorSummary
std::map< TotemFramePosition, std::map< TotemVFATStatus, unsigned int > > errorSummary
error summaries
Definition: RawToDigiConverter.h:88