CMS 3D CMS Logo

CSCDigiToRaw.cc
Go to the documentation of this file.
1 
13 #include "boost/dynamic_bitset.hpp"
22 #include <algorithm>
23 
24 using namespace edm;
25 using namespace std;
26 
27 namespace cscd2r {
29  CSCDetId chamberID(const CSCDetId& cscDetId) {
30  CSCDetId chamberId = cscDetId.chamberId();
31  if (chamberId.ring() == 4) {
32  chamberId = CSCDetId(chamberId.endcap(), chamberId.station(), 1, chamberId.chamber(), 0);
33  }
34  return chamberId;
35  }
36 
37  template <typename LCTCollection>
38  bool accept(const CSCDetId& cscId, const LCTCollection& lcts, int bxMin, int bxMax, bool me1abCheck = false) {
39  if (bxMin == -999)
40  return true;
41  int nominalBX = 6;
42  CSCDetId chamberId = chamberID(cscId);
43  typename LCTCollection::Range lctRange = lcts.get(chamberId);
44  bool result = false;
45  for (typename LCTCollection::const_iterator lctItr = lctRange.first; lctItr != lctRange.second; ++lctItr) {
46  int bx = lctItr->getBX() - nominalBX;
47  if (bx >= bxMin && bx <= bxMax) {
48  result = true;
49  break;
50  }
51  }
52 
53  bool me1 = cscId.station() == 1 && cscId.ring() == 1;
54  //this is another "creative" recovery of smart ME1A-ME1B TMB logic cases:
55  //wire selective readout requires at least one (A)LCT in the full chamber
56  if (me1 && result == false && me1abCheck) {
57  CSCDetId me1aId = CSCDetId(chamberId.endcap(), chamberId.station(), 4, chamberId.chamber(), 0);
58  lctRange = lcts.get(me1aId);
59  for (typename LCTCollection::const_iterator lctItr = lctRange.first; lctItr != lctRange.second; ++lctItr) {
60  int bx = lctItr->getBX() - nominalBX;
61  if (bx >= bxMin && bx <= bxMax) {
62  result = true;
63  break;
64  }
65  }
66  }
67 
68  return result;
69  }
70 
71  // need to specialize for pretriggers, since they don't have a getBX()
72  template <>
73  bool accept(const CSCDetId& cscId, const CSCCLCTPreTriggerCollection& lcts, int bxMin, int bxMax, bool me1abCheck) {
74  if (bxMin == -999)
75  return true;
76  int nominalBX = 6;
77  CSCDetId chamberId = chamberID(cscId);
78  CSCCLCTPreTriggerCollection::Range lctRange = lcts.get(chamberId);
79  bool result = false;
80  for (CSCCLCTPreTriggerCollection::const_iterator lctItr = lctRange.first; lctItr != lctRange.second; ++lctItr) {
81  int bx = *lctItr - nominalBX;
82  if (bx >= bxMin && bx <= bxMax) {
83  result = true;
84  break;
85  }
86  }
87  bool me1a = cscId.station() == 1 && cscId.ring() == 4;
88  if (me1a && result == false && me1abCheck) {
89  //check pretriggers in me1a as well; relevant for TMB emulator writing to separate detIds
90  lctRange = lcts.get(cscId);
91  for (CSCCLCTPreTriggerCollection::const_iterator lctItr = lctRange.first; lctItr != lctRange.second; ++lctItr) {
92  int bx = *lctItr - nominalBX;
93  if (bx >= bxMin && bx <= bxMax) {
94  result = true;
95  break;
96  }
97  }
98  }
99  return result;
100  }
101 
102 } // namespace cscd2r
103 
105  : alctWindowMin_(pset.getParameter<int>("alctWindowMin")),
106  alctWindowMax_(pset.getParameter<int>("alctWindowMax")),
107  clctWindowMin_(pset.getParameter<int>("clctWindowMin")),
108  clctWindowMax_(pset.getParameter<int>("clctWindowMax")),
109  preTriggerWindowMin_(pset.getParameter<int>("preTriggerWindowMin")),
110  preTriggerWindowMax_(pset.getParameter<int>("preTriggerWindowMax")) {}
111 
113  CSCDetId chamberId = cscd2r::chamberID(cscDetId);
114  // find the entry into the map
115  map<CSCDetId, CSCEventData>::iterator chamberMapItr = info.theChamberDataMap.find(chamberId);
116  if (chamberMapItr == info.theChamberDataMap.end()) {
117  // make an entry, telling it the correct chamberType
118  int chamberType = chamberId.iChamberType();
119  chamberMapItr = info.theChamberDataMap
120  .insert(pair<CSCDetId, CSCEventData>(chamberId, CSCEventData(chamberType, info.formatVersion_)))
121  .first;
122  }
123  CSCEventData& cscData = chamberMapItr->second;
124  cscData.dmbHeader()->setCrateAddress(info.theElectronicsMap->crate(cscDetId), info.theElectronicsMap->dmb(cscDetId));
125 
126  if (info.formatVersion_ == 2013) {
127  // Set DMB version field to distinguish between ME11s and other chambers (ME11 - 2, others - 1)
128  bool me11 = ((chamberId.station() == 1) && (chamberId.ring() == 4)) ||
129  ((chamberId.station() == 1) && (chamberId.ring() == 1));
130  if (me11) {
131  cscData.dmbHeader()->setdmbVersion(2);
132  } else {
133  cscData.dmbHeader()->setdmbVersion(1);
134  }
135  }
136  return cscData;
137 }
138 
140  const CSCCLCTPreTriggerCollection& preTriggers,
141  FindEventDataInfo& fedInfo,
142  bool usePreTriggers,
143  bool packEverything) const { //iterate over chambers with strip digis in them
144  for (CSCStripDigiCollection::DigiRangeIterator j = stripDigis.begin(); j != stripDigis.end(); ++j) {
145  CSCDetId cscDetId = (*j).first;
146  // only digitize if there are pre-triggers
147 
148  bool me1abCheck = fedInfo.formatVersion_ == 2013;
149  /* !!! Testing. Uncomment for production */
150  if (!usePreTriggers || packEverything ||
151  (usePreTriggers &&
152  cscd2r::accept(cscDetId, preTriggers, preTriggerWindowMin_, preTriggerWindowMax_, me1abCheck))) {
153  bool me1a = (cscDetId.station() == 1) && (cscDetId.ring() == 4);
154  bool zplus = (cscDetId.endcap() == 1);
155  bool me1b = (cscDetId.station() == 1) && (cscDetId.ring() == 1);
156 
157  CSCEventData& cscData = findEventData(cscDetId, fedInfo);
158 
159  std::vector<CSCStripDigi>::const_iterator digiItr = (*j).second.first;
160  std::vector<CSCStripDigi>::const_iterator last = (*j).second.second;
161  for (; digiItr != last; ++digiItr) {
162  CSCStripDigi digi = *digiItr;
163  int strip = digi.getStrip();
164  if (fedInfo.formatVersion_ == 2013) {
165  if (me1a && zplus) {
166  digi.setStrip(49 - strip); // 1-48 -> 48-1
167  }
168  if (me1b && !zplus) {
169  digi.setStrip(65 - strip); // 1-64 -> 64-1
170  }
171  if (me1a) {
172  strip = digi.getStrip(); // reset back 1-16 to 65-80 digi
173  digi.setStrip(strip + 64);
174  }
175 
176  } else {
177  if (me1a && zplus) {
178  digi.setStrip(17 - strip); // 1-16 -> 16-1
179  }
180  if (me1b && !zplus) {
181  digi.setStrip(65 - strip); // 1-64 -> 64-1
182  }
183  if (me1a) {
184  strip = digi.getStrip(); // reset back 1-16 to 65-80 digi
185  digi.setStrip(strip + 64);
186  }
187  }
188  cscData.add(digi, cscDetId.layer());
189  }
190  }
191  }
192 }
193 
195  const CSCALCTDigiCollection& alctDigis,
196  FindEventDataInfo& fedInfo,
197  bool packEverything) const {
198  add(alctDigis, fedInfo);
199  for (CSCWireDigiCollection::DigiRangeIterator j = wireDigis.begin(); j != wireDigis.end(); ++j) {
200  CSCDetId cscDetId = (*j).first;
201  bool me1abCheck = fedInfo.formatVersion_ == 2013;
202  if (packEverything || cscd2r::accept(cscDetId, alctDigis, alctWindowMin_, alctWindowMax_, me1abCheck)) {
203  CSCEventData& cscData = findEventData(cscDetId, fedInfo);
204  std::vector<CSCWireDigi>::const_iterator digiItr = (*j).second.first;
205  std::vector<CSCWireDigi>::const_iterator last = (*j).second.second;
206  for (; digiItr != last; ++digiItr) {
207  cscData.add(*digiItr, cscDetId.layer());
208  }
209  }
210  }
211 }
212 
213 void CSCDigiToRaw::add(const CSCComparatorDigiCollection& comparatorDigis,
214  const CSCCLCTDigiCollection& clctDigis,
215  FindEventDataInfo& fedInfo,
216  bool packEverything) const {
217  add(clctDigis, fedInfo);
218  for (auto const& j : comparatorDigis) {
219  CSCDetId cscDetId = j.first;
220  CSCEventData& cscData = findEventData(cscDetId, fedInfo);
221  bool me1abCheck = fedInfo.formatVersion_ == 2013;
222  if (packEverything || cscd2r::accept(cscDetId, clctDigis, clctWindowMin_, clctWindowMax_, me1abCheck)) {
223  bool me1a = (cscDetId.station() == 1) && (cscDetId.ring() == 4);
224 
225  for (auto digi = j.second.first; digi != j.second.second; ++digi) {
226  if (fedInfo.formatVersion_ == 2013) {
227  // Move ME1/A comparators from CFEB=0 to CFEB=4 if this has not
228  // been done already.
229  if (me1a && digi->getStrip() <= 48) {
230  CSCComparatorDigi digi_corr(64 + digi->getStrip(), digi->getComparator(), digi->getTimeBinWord());
231  cscData.add(digi_corr, cscDetId); // This version does ME11 strips swapping
232  // cscData.add(digi_corr, cscDetId.layer()); // This one doesn't
233  } else {
234  cscData.add(*digi, cscDetId); // This version does ME11 strips swapping
235  // cscData.add(digi, cscDetId.layer()); // This one doesn't
236  }
237  } else {
238  // Move ME1/A comparators from CFEB=0 to CFEB=4 if this has not
239  // been done already.
240  if (me1a && digi->getStrip() <= 16) {
241  CSCComparatorDigi digi_corr(64 + digi->getStrip(), digi->getComparator(), digi->getTimeBinWord());
242  cscData.add(digi_corr, cscDetId.layer());
243  } else {
244  cscData.add(*digi, cscDetId.layer());
245  }
246  }
247  }
248  }
249  }
250 }
251 
252 void CSCDigiToRaw::add(const CSCALCTDigiCollection& alctDigis, FindEventDataInfo& fedInfo) const {
253  for (CSCALCTDigiCollection::DigiRangeIterator j = alctDigis.begin(); j != alctDigis.end(); ++j) {
254  CSCDetId cscDetId = (*j).first;
255  CSCEventData& cscData = findEventData(cscDetId, fedInfo);
256 
257  cscData.add(std::vector<CSCALCTDigi>((*j).second.first, (*j).second.second));
258  }
259 }
260 
261 void CSCDigiToRaw::add(const CSCCLCTDigiCollection& clctDigis, FindEventDataInfo& fedInfo) const {
262  for (CSCCLCTDigiCollection::DigiRangeIterator j = clctDigis.begin(); j != clctDigis.end(); ++j) {
263  CSCDetId cscDetId = (*j).first;
264  CSCEventData& cscData = findEventData(cscDetId, fedInfo);
265 
266  bool me11a = cscDetId.station() == 1 && cscDetId.ring() == 4;
267  //CLCTs are packed by chamber not by A/B parts in ME11
268  //me11a appears only in simulation with SLHC algorithm settings
269  //without the shift, it's impossible to distinguish A and B parts
270  if (me11a && fedInfo.formatVersion_ == 2013) {
271  std::vector<CSCCLCTDigi> shiftedDigis((*j).second.first, (*j).second.second);
272  for (std::vector<CSCCLCTDigi>::iterator iC = shiftedDigis.begin(); iC != shiftedDigis.end(); ++iC) {
273  if (iC->getCFEB() < 3) { //sanity check, mostly
274  (*iC) = CSCCLCTDigi(iC->isValid(),
275  iC->getQuality(),
276  iC->getPattern(),
277  iC->getStripType(),
278  iC->getBend(),
279  iC->getStrip(),
280  iC->getCFEB() + 4,
281  iC->getBX(),
282  iC->getTrknmb(),
283  iC->getFullBX());
284  }
285  }
286  cscData.add(shiftedDigis);
287  } else {
288  cscData.add(std::vector<CSCCLCTDigi>((*j).second.first, (*j).second.second));
289  }
290  }
291 }
292 
293 void CSCDigiToRaw::add(const CSCCorrelatedLCTDigiCollection& corrLCTDigis, FindEventDataInfo& fedInfo) const {
294  for (CSCCorrelatedLCTDigiCollection::DigiRangeIterator j = corrLCTDigis.begin(); j != corrLCTDigis.end(); ++j) {
295  CSCDetId cscDetId = (*j).first;
296  CSCEventData& cscData = findEventData(cscDetId, fedInfo);
297 
298  bool me11a = cscDetId.station() == 1 && cscDetId.ring() == 4;
299  //LCTs are packed by chamber not by A/B parts in ME11
300  //me11a appears only in simulation with SLHC algorithm settings
301  //without the shift, it's impossible to distinguish A and B parts
302  if (me11a && fedInfo.formatVersion_ == 2013) {
303  std::vector<CSCCorrelatedLCTDigi> shiftedDigis((*j).second.first, (*j).second.second);
304  for (std::vector<CSCCorrelatedLCTDigi>::iterator iC = shiftedDigis.begin(); iC != shiftedDigis.end(); ++iC) {
305  if (iC->getStrip() < 96) { //sanity check, mostly
306  (*iC) = CSCCorrelatedLCTDigi(iC->getTrknmb(),
307  iC->isValid(),
308  iC->getQuality(),
309  iC->getKeyWG(),
310  iC->getStrip() + 128,
311  iC->getPattern(),
312  iC->getBend(),
313  iC->getBX(),
314  iC->getMPCLink(),
315  iC->getBX0(),
316  iC->getSyncErr(),
317  iC->getCSCID());
318  }
319  }
320  cscData.add(shiftedDigis);
321  } else {
322  cscData.add(std::vector<CSCCorrelatedLCTDigi>((*j).second.first, (*j).second.second));
323  }
324  }
325 }
326 
328  const CSCWireDigiCollection& wireDigis,
329  const CSCComparatorDigiCollection& comparatorDigis,
330  const CSCALCTDigiCollection& alctDigis,
331  const CSCCLCTDigiCollection& clctDigis,
332  const CSCCLCTPreTriggerCollection& preTriggers,
333  const CSCCorrelatedLCTDigiCollection& correlatedLCTDigis,
334  FEDRawDataCollection& fed_buffers,
335  const CSCChamberMap* mapping,
336  Event& e,
337  uint16_t format_version,
338  bool use_pre_triggers,
339  bool packEverything) const {
340  //bits of code from ORCA/Muon/METBFormatter - thanks, Rick:)!
341 
342  //get fed object from fed_buffers
343  // make a map from the index of a chamber to the event data from it
344  FindEventDataInfo fedInfo{mapping, format_version};
345  add(stripDigis, preTriggers, fedInfo, use_pre_triggers, packEverything);
346  add(wireDigis, alctDigis, fedInfo, packEverything);
347  add(comparatorDigis, clctDigis, fedInfo, packEverything);
348  add(correlatedLCTDigis, fedInfo);
349 
350  int l1a = e.id().event(); //need to add increments or get it from lct digis
351  int bx = l1a; //same as above
352  //int startingFED = FEDNumbering::MINCSCFEDID;
353 
354  if (fedInfo.formatVersion_ == 2005)
355  {
356  std::map<int, CSCDCCEventData> dccMap;
357  for (int idcc = FEDNumbering::MINCSCFEDID; idcc <= FEDNumbering::MAXCSCFEDID; ++idcc) {
358  //idcc goes from startingFed to startingFED+7
359  // @@ if ReadoutMapping changes, this'll have to change
360  // DCCs 1,2,4,5 have 5 DDUs. Otherwise, 4
361  //int nDDUs = (idcc < 2) || (idcc ==4) || (idcc ==5)
362  // ? 5 : 4;
363  //@@ WARNING some DCCs only have 4 DDUs, but I'm giving them all 5, for now
364  int nDDUs = 5;
365  dccMap.insert(std::pair<int, CSCDCCEventData>(idcc, CSCDCCEventData(idcc, nDDUs, bx, l1a)));
366  }
367 
368  for (int idcc = FEDNumbering::MINCSCFEDID; idcc <= FEDNumbering::MAXCSCFEDID; ++idcc) {
369  // for every chamber with data, add to a DDU in this DCC Event
370  for (map<CSCDetId, CSCEventData>::iterator chamberItr = fedInfo.theChamberDataMap.begin();
371  chamberItr != fedInfo.theChamberDataMap.end();
372  ++chamberItr) {
373  int indexDCC = mapping->slink(chamberItr->first);
374  if (indexDCC == idcc) {
375  //FIXME (What does this mean? Is something wrong?)
376  std::map<int, CSCDCCEventData>::iterator dccMapItr = dccMap.find(indexDCC);
377  if (dccMapItr == dccMap.end()) {
378  throw cms::Exception("CSCDigiToRaw") << "Bad DCC number:" << indexDCC;
379  }
380  // get id's based on ChamberId from mapping
381 
382  int dduId = mapping->ddu(chamberItr->first);
383  int dduSlot = mapping->dduSlot(chamberItr->first);
384  int dduInput = mapping->dduInput(chamberItr->first);
385  int dmbId = mapping->dmb(chamberItr->first);
386  dccMapItr->second.addChamber(chamberItr->second, dduId, dduSlot, dduInput, dmbId, format_version);
387  }
388  }
389  }
390 
391  // FIXME: FEDRawData size set to 2*64 to add FED header and trailer
392  for (std::map<int, CSCDCCEventData>::iterator dccMapItr = dccMap.begin(); dccMapItr != dccMap.end(); ++dccMapItr) {
393  boost::dynamic_bitset<> dccBits = dccMapItr->second.pack();
394  FEDRawData& fedRawData = fed_buffers.FEDData(dccMapItr->first);
395  fedRawData.resize(dccBits.size());
396  //fill data with dccEvent
398  FEDTrailer cscFEDTrailer(fedRawData.data() + (fedRawData.size() - 8));
399  cscFEDTrailer.set(fedRawData.data() + (fedRawData.size() - 8),
400  fedRawData.size() / 8,
401  evf::compute_crc(fedRawData.data(), fedRawData.size()),
402  0,
403  0);
404  }
405 
406  } else if (format_version == 2013)
407  {
408  std::map<int, CSCDDUEventData> dduMap;
409  unsigned int ddu_fmt_version = 0x7;
410  const unsigned postLS1_map[] = {841, 842, 843, 844, 845, 846, 847, 848, 849, 831, 832, 833,
411  834, 835, 836, 837, 838, 839, 861, 862, 863, 864, 865, 866,
412  867, 868, 869, 851, 852, 853, 854, 855, 856, 857, 858, 859};
413 
415  for (unsigned int i = 0; i < 36; i++) {
416  unsigned int iddu = postLS1_map[i];
417  // make a new one
418  CSCDDUHeader newDDUHeader(bx, l1a, iddu, ddu_fmt_version);
419 
420  dduMap.insert(std::pair<int, CSCDDUEventData>(iddu, CSCDDUEventData(newDDUHeader)));
421  }
422 
424  for (unsigned int i = 0; i < 36; i++) {
425  unsigned int iddu = postLS1_map[i];
426  // for every chamber with data, add to a DDU in this DCC Event
427  for (map<CSCDetId, CSCEventData>::iterator chamberItr = fedInfo.theChamberDataMap.begin();
428  chamberItr != fedInfo.theChamberDataMap.end();
429  ++chamberItr) {
430  unsigned int indexDDU = mapping->slink(chamberItr->first);
431 
433  // Still preLS1 DCC FEDs mapping
434  if ((indexDDU >= FEDNumbering::MINCSCFEDID) && (indexDDU <= FEDNumbering::MAXCSCFEDID)) {
435  int dduID = mapping->ddu(chamberItr->first); // try to switch to DDU ID mapping
436  // DDU ID is in expectedi post-LS1 FED ID range
437  if ((dduID >= FEDNumbering::MINCSCDDUFEDID) && (dduID <= FEDNumbering::MAXCSCDDUFEDID)) {
438  indexDDU = dduID;
439  } else // Messy
440  {
441  // Lets try to change pre-LS1 1-36 ID range to post-LS1 MINCSCDDUFEDID - MAXCSCDDUFEDID range
442  dduID &= 0xFF;
443  // indexDDU = FEDNumbering::MINCSCDDUFEDID + dduID-1;
444  if ((dduID <= 36) && (dduID > 0))
445  indexDDU = postLS1_map[dduID - 1];
446  }
447  }
448 
449  if (indexDDU == iddu) {
450  std::map<int, CSCDDUEventData>::iterator dduMapItr = dduMap.find(indexDDU);
451  if (dduMapItr == dduMap.end()) {
452  throw cms::Exception("CSCDigiToRaw") << "Bad DDU number:" << indexDDU;
453  }
454  // get id's based on ChamberId from mapping
455 
456  int dduInput = mapping->dduInput(chamberItr->first);
457  int dmbId = mapping->dmb(chamberItr->first);
458  // int crateId = mapping->crate(chamberItr->first);
459  dduMapItr->second.add(chamberItr->second, dmbId, dduInput, format_version);
460  }
461  }
462  }
463 
464  // FIXME: FEDRawData size set to 2*64 to add FED header and trailer
465  for (std::map<int, CSCDDUEventData>::iterator dduMapItr = dduMap.begin(); dduMapItr != dduMap.end(); ++dduMapItr) {
466  boost::dynamic_bitset<> dduBits = dduMapItr->second.pack();
467  FEDRawData& fedRawData = fed_buffers.FEDData(dduMapItr->first);
468  fedRawData.resize(dduBits.size() / 8);
469  //fill data with dduEvent
471  FEDTrailer cscFEDTrailer(fedRawData.data() + (fedRawData.size() - 8));
472  cscFEDTrailer.set(fedRawData.data() + (fedRawData.size() - 8),
473  fedRawData.size() / 8,
474  evf::compute_crc(fedRawData.data(), fedRawData.size()),
475  0,
476  0);
477  }
478  }
479 }
CSCDigiToRaw::preTriggerWindowMax_
const int preTriggerWindowMax_
Definition: CSCDigiToRaw.h:79
CSCCLCTPreTriggerCollection
FEDNumbering.h
CSCDMBHeader::setdmbVersion
void setdmbVersion(unsigned int version)
Definition: CSCDMBHeader.h:32
cscd2r
Definition: CSCDigiToRaw.cc:27
mps_fire.i
i
Definition: mps_fire.py:355
CSCEventData
Definition: CSCEventData.h:28
Range
PixelRecoRange< float > Range
Definition: PixelTripletHLTGenerator.cc:31
CSCDDUHeader
Definition: CSCDDUHeader.h:11
FEDRawDataCollection
Definition: FEDRawDataCollection.h:18
edm
HLT enums.
Definition: AlignableModifier.h:19
CSCDetId::ring
int ring() const
Definition: CSCDetId.h:68
digitizers_cfi.strip
strip
Definition: digitizers_cfi.py:19
CSCStripDigiCollection
CSCDCCEventData
01/20/05 A.Tumanov
Definition: CSCDCCEventData.h:13
l1GtPatternGenerator_cfi.bx
bx
Definition: l1GtPatternGenerator_cfi.py:18
CSCStripDigi::getStrip
int getStrip() const
Definition: CSCStripDigi.h:41
FEDNumbering::MAXCSCFEDID
Definition: FEDNumbering.h:52
info
static const TGPicture * info(bool iBackgroundIsBlack)
Definition: FWCollectionSummaryWidget.cc:152
CSCEventData::dmbHeader
const CSCDMBHeader * dmbHeader() const
the DAQ motherboard header. A good place for event and chamber info
Definition: CSCEventData.h:75
CSCDigiToRaw::preTriggerWindowMin_
const int preTriggerWindowMin_
Definition: CSCDigiToRaw.h:78
FEDNumbering::MAXCSCDDUFEDID
Definition: FEDNumbering.h:90
FEDRawData.h
CSCDetId::iChamberType
unsigned short iChamberType() const
Definition: CSCDetId.h:96
CSCCLCTDigi
Definition: CSCCLCTDigi.h:17
CSCDetId.h
MuonDigiCollection::const_iterator
std::vector< DigiType >::const_iterator const_iterator
Definition: MuonDigiCollection.h:94
FEDRawData
Definition: FEDRawData.h:19
l1tstage1emulator_dqm_sourceclient-live_cfg.bxMin
bxMin
Definition: l1tstage1emulator_dqm_sourceclient-live_cfg.py:84
bitset_utilities::bitsetToChar
void bitsetToChar(const boost::dynamic_bitset<> &bs, unsigned char *result)
this method takes bitset obj and returns char * array
Definition: bitset_append.cc:32
dqmdumpme.last
last
Definition: dqmdumpme.py:56
l1t_dqm_sourceclient-live_cfg.fedRawData
fedRawData
Definition: l1t_dqm_sourceclient-live_cfg.py:182
CSCDigiToRaw::CSCDigiToRaw
CSCDigiToRaw(const edm::ParameterSet &pset)
Constructor.
Definition: CSCDigiToRaw.cc:104
CSCDCCEventData.h
cscPacker_cfi.usePreTriggers
usePreTriggers
Definition: cscPacker_cfi.py:27
CSCDetId::layer
int layer() const
Definition: CSCDetId.h:56
CSCDMBHeader::setCrateAddress
void setCrateAddress(int crate, int dmbId)
Definition: CSCDMBHeader.h:30
l1tstage1emulator_dqm_sourceclient-live_cfg.bxMax
bxMax
Definition: l1tstage1emulator_dqm_sourceclient-live_cfg.py:85
CSCComparatorDigi
Definition: CSCComparatorDigi.h:16
CSCDigiToRaw::alctWindowMax_
const int alctWindowMax_
Definition: CSCDigiToRaw.h:75
FEDRawDataCollection::FEDData
const FEDRawData & FEDData(int fedid) const
retrieve data for fed
Definition: FEDRawDataCollection.cc:19
evf::compute_crc
unsigned short compute_crc(unsigned char *buffer, unsigned int bufSize)
Definition: CRC16.h:46
cscPacker_cfi.packEverything
packEverything
Definition: cscPacker_cfi.py:28
edm::ParameterSet
Definition: ParameterSet.h:36
FEDTrailer
Definition: FEDTrailer.h:14
Event.h
CSCChamberMap.h
CSCDetId
Definition: CSCDetId.h:26
CSCChamberMap
Definition: CSCChamberMap.h:11
createfilelist.int
int
Definition: createfilelist.py:10
CSCEventData::add
void add(const CSCStripDigi &, int layer)
routines to add digis to the data
Definition: CSCEventData.cc:467
FEDRawDataCollection.h
CSCALCTDigiCollection
CSCDetId::chamberId
CSCDetId chamberId() const
Definition: CSCDetId.h:47
CSCComparatorDigiCollection
CSCDetId::chamber
int chamber() const
Definition: CSCDetId.h:62
FEDNumbering::MINCSCFEDID
Definition: FEDNumbering.h:51
CSCCorrelatedLCTDigiCollection
hlt_dqm_clientPB-live_cfg.me1
me1
Definition: hlt_dqm_clientPB-live_cfg.py:68
CSCDigiToRaw::FindEventDataInfo
Definition: CSCDigiToRaw.h:44
CSCDigiToRaw::findEventData
CSCEventData & findEventData(const CSCDetId &cscDetId, FindEventDataInfo &) const
pick out the correct data object for this chamber
Definition: CSCDigiToRaw.cc:112
cscd2r::accept
bool accept(const CSCDetId &cscId, const LCTCollection &lcts, int bxMin, int bxMax, bool me1abCheck=false)
Definition: CSCDigiToRaw.cc:38
CSCDigiToRaw::add
void add(const CSCStripDigiCollection &stripDigis, const CSCCLCTPreTriggerCollection &preTriggers, FindEventDataInfo &, bool usePreTriggers, bool packEverything) const
Definition: CSCDigiToRaw.cc:139
CSCDigiToRaw::FindEventDataInfo::formatVersion_
const uint16_t formatVersion_
Definition: CSCDigiToRaw.h:50
CSCStripDigi
Definition: CSCStripDigi.h:17
std
Definition: JetResolutionObject.h:76
CSCDDUEventData
Definition: CSCDDUEventData.h:19
CSCWireDigiCollection
CSCDigiToRaw.h
CSCDigiToRaw::alctWindowMin_
const int alctWindowMin_
Definition: CSCDigiToRaw.h:74
CSCDetId::endcap
int endcap() const
Definition: CSCDetId.h:85
CSCCLCTDigiCollection
Exception
Definition: hltDiff.cc:246
SurfaceOrientation::zplus
Definition: Surface.h:19
bitset_append.h
MuonDigiCollection::Range
std::pair< const_iterator, const_iterator > Range
Definition: MuonDigiCollection.h:95
FEDNumbering::MINCSCDDUFEDID
Definition: FEDNumbering.h:89
Exception.h
mps_fire.result
result
Definition: mps_fire.py:303
ParameterSet.h
CSCDetId::station
int station() const
Definition: CSCDetId.h:79
dqmiolumiharvest.j
j
Definition: dqmiolumiharvest.py:66
cscd2r::chamberID
CSCDetId chamberID(const CSCDetId &cscDetId)
takes layer ID, converts to chamber ID, switching ME1A to ME11
Definition: CSCDigiToRaw.cc:29
CSCStripDigi::setStrip
void setStrip(int istrip)
Definition: CSCStripDigi.h:62
DigiContainerIterator
Definition: MuonDigiCollection.h:30
edm::Event
Definition: Event.h:73
FEDHeader.h
taus_updatedMVAIds_cff.mapping
mapping
Definition: taus_updatedMVAIds_cff.py:28
CSCDigiToRaw::clctWindowMin_
const int clctWindowMin_
Definition: CSCDigiToRaw.h:76
CSCDigiToRaw::createFedBuffers
void createFedBuffers(const CSCStripDigiCollection &stripDigis, const CSCWireDigiCollection &wireDigis, const CSCComparatorDigiCollection &comparatorDigis, const CSCALCTDigiCollection &alctDigis, const CSCCLCTDigiCollection &clctDigis, const CSCCLCTPreTriggerCollection &preTriggers, const CSCCorrelatedLCTDigiCollection &correlatedLCTDigis, FEDRawDataCollection &fed_buffers, const CSCChamberMap *theMapping, edm::Event &e, uint16_t theFormatVersion=2005, bool usePreTriggers=true, bool packEverything=false) const
Take a vector of digis and fill the FEDRawDataCollection.
Definition: CSCDigiToRaw.cc:327
CSCCorrelatedLCTDigi
Definition: CSCCorrelatedLCTDigi.h:19
muonDTDigis_cfi.pset
pset
Definition: muonDTDigis_cfi.py:27
cscd2r::accept
bool accept(const CSCDetId &cscId, const CSCCLCTPreTriggerCollection &lcts, int bxMin, int bxMax, bool me1abCheck)
Definition: CSCDigiToRaw.cc:73
CRC16.h
MillePedeFileConverter_cfg.e
e
Definition: MillePedeFileConverter_cfg.py:37
FEDTrailer.h
CSCDigiToRaw::clctWindowMax_
const int clctWindowMax_
Definition: CSCDigiToRaw.h:77