100 std::pair<std::vector<CSCWireDigi>,std::vector<CSCWireDigi> > >
101 matchingDetWireCollection;
103 std::pair<std::vector<CSCStripDigi>,std::vector<CSCStripDigi> > >
104 matchingDetStripCollection;
106 std::pair<std::vector<CSCComparatorDigi>,std::vector<CSCComparatorDigi> > >
107 matchingDetComparatorCollection;
109 std::pair<std::vector<CSCCLCTDigi>,std::vector<CSCCLCTDigi> > >
110 matchingDetCLCTCollection;
112 std::pair<std::vector<CSCALCTDigi>,std::vector<CSCALCTDigi> > >
113 matchingDetALCTCollection;
115 std::pair<std::vector<CSCCorrelatedLCTDigi>,std::vector<CSCCorrelatedLCTDigi> > >
116 matchingDetLCTCollection;
167 wi = _wi->begin(), swi= _swi->begin();
169 st = _st->begin(), sst = _sst->begin();
171 cmp = _cmp->begin(), scmp = _scmp->begin();
173 clct = _clct->begin(), sclct = _sclct->begin();
175 alct = _alct->begin(), salct = _salct->begin();
177 lct = _lct->begin(), slct = _slct->begin();
178 L1CSCTrackCollection::const_iterator
179 trk = _trk->begin(), strk = _strk->begin();
180 std::vector<csctf::TrackStub>::const_iterator
181 dt = _dt->get().begin(), sdt = _sdt->get().begin();
184 matchingDetWireCollection wires;
185 matchingDetStripCollection
strips;
186 matchingDetComparatorCollection comps;
187 matchingDetCLCTCollection clcts;
188 matchingDetALCTCollection alcts;
189 matchingDetLCTCollection lcts,trackstubs;
193 for(;wi != _wi->end();++wi)
196 b=(*wi).second.first,e=(*wi).second.second;
197 std::vector<CSCWireDigi>::iterator
198 beg=wires[(*wi).first].first.end();
199 wires[(*wi).first].first.insert(beg,b,e);
201 for(;swi != _swi->end();++swi)
204 b=(*swi).second.first,e=(*swi).second.second;
207 if((*swi).first.ring() == 4)
208 _id =
CSCDetId((*swi).first.endcap(),(*swi).first.station(),
209 1, (*swi).first.chamber(),(*swi).first.layer());
211 std::vector<CSCWireDigi>::iterator
212 beg=wires[_id].second.end();
214 wires[_id].second.insert(beg,b,e);
217 wires[_id].second.end());
221 for(;st != _st->end();++st)
224 b=(*st).second.first,e=(*st).second.second;
225 std::vector<CSCStripDigi>::iterator
226 beg=
strips[(*st).first].first.end();
231 strips[(*st).first].first.insert(beg,zs.begin(),zs.end());
233 for(;sst != _sst->end();++sst)
236 b=(*sst).second.first,e=(*sst).second.second;
243 std::vector<CSCStripDigi>::iterator
244 beg=
strips[_id].second.end();
246 std::vector<CSCStripDigi> relab =
relabelStripDigis(theMapping,(*sst).first,b,e);
248 strips[_id].second.insert(beg,relab.begin(),relab.end());
253 for(;cmp != _cmp->end();++cmp)
256 b=(*cmp).second.first,e=(*cmp).second.second;
257 std::vector<CSCComparatorDigi>::iterator
258 beg=comps[(*cmp).first].first.end();
260 comps[(*cmp).first].first.insert(beg,b,e);
262 for(;scmp != _scmp->end();++scmp)
265 b=(*scmp).second.first,e=(*scmp).second.second;
268 if((*scmp).first.ring() == 4)
269 _id =
CSCDetId((*scmp).first.endcap(),(*scmp).first.station(),
270 1, (*scmp).first.chamber(),(*scmp).first.layer());
272 std::vector<CSCComparatorDigi>::iterator
273 beg=comps[_id].second.begin();
275 if((*scmp).first.ring()==4)
276 beg=comps[_id].
second.end();
278 std::vector<CSCComparatorDigi> zs =
281 std::vector<CSCComparatorDigi> relab =
286 comps[_id].second.insert(beg,relab.begin(),relab.end());
290 for(;clct != _clct->end();++clct)
293 b=(*clct).second.first,e=(*clct).second.second;
294 std::vector<CSCCLCTDigi>::iterator
295 beg=clcts[(*clct).first].first.end();
297 clcts[(*clct).first].first.insert(beg,b,e);
299 for(;sclct != _sclct->end();++sclct)
302 b=(*sclct).second.first,e=(*sclct).second.second;
305 if((*sclct).first.ring() == 4)
306 _id =
CSCDetId((*sclct).first.endcap(),(*sclct).first.station(),
307 1, (*sclct).first.chamber(),(*sclct).first.layer());
309 std::vector<CSCCLCTDigi>::iterator
310 beg=clcts[_id].second.begin();
312 if((*sclct).first.ring()==4)
313 beg=clcts[_id].
second.end();
315 clcts[_id].second.insert(beg,b,e);
319 for(;alct != _alct->end();++alct)
322 b=(*alct).second.first,e=(*alct).second.second;
323 std::vector<CSCALCTDigi>::iterator
324 beg=alcts[(*alct).first].first.end();
326 alcts[(*alct).first].first.insert(beg,b,e);
328 for(;salct != _salct->end();++salct)
331 b=(*salct).second.first,e=(*salct).second.second;
334 if((*salct).first.ring() == 4)
335 _id =
CSCDetId((*salct).first.endcap(),(*salct).first.station(),
336 1, (*salct).first.chamber(),(*salct).first.layer());
338 std::vector<CSCALCTDigi>::iterator
339 beg=alcts[_id].second.begin();
341 if((*salct).first.ring()==4)
342 beg=alcts[_id].
second.end();
344 alcts[_id].second.insert(beg,b,e);
348 for(;lct != _lct->end();++lct)
351 b=(*lct).second.first,e=(*lct).second.second;
352 std::vector<CSCCorrelatedLCTDigi>::iterator
353 beg=lcts[(*lct).first].first.end();
355 lcts[(*lct).first].first.insert(beg,b,e);
357 for(;slct != _slct->end();++slct)
360 b=(*slct).second.first,e=(*slct).second.second;
363 if((*slct).first.ring() == 4)
364 _id =
CSCDetId((*slct).first.endcap(),(*slct).first.station(),
365 1, (*slct).first.chamber(),(*slct).first.layer());
367 std::vector<CSCCorrelatedLCTDigi>::iterator
368 beg=lcts[_id].second.begin();
370 if((*slct).first.ring()==4)
371 beg=lcts[_id].
second.end();
373 lcts[_id].second.insert(beg,b,e);
376 for(; trk != _trk->end(); ++trk)
378 tracks.push_back(trk->first);
381 for(;strk != _strk->end(); ++strk)
383 simtracks.push_back(strk->first);
387 matchingDetWireCollection::const_iterator w;
388 matchingDetStripCollection::const_iterator
s;
389 matchingDetComparatorCollection::const_iterator
c;
390 matchingDetCLCTCollection::const_iterator cl;
391 matchingDetALCTCollection::const_iterator al;
392 matchingDetLCTCollection::const_iterator lc;
394 for(w = wires.begin(); w != wires.end(); ++w)
396 if(w->second.first.size() != w->second.second.size())
398 std::cout <<
"Major error! # of wire digis in detID: " << w->first
399 <<
" is not equal between sim and unpacked!" << std::endl;
402 std::vector<CSCWireDigi>
a = w->second.second;
403 std::vector<CSCWireDigi> b = w->second.first;
405 for(std::vector<CSCWireDigi>::const_iterator
i = a.begin();
i != a.end(); ++
i)
407 std::cout <<
"UNPACKER OUTPUT:" << std::endl;
408 for(std::vector<CSCWireDigi>::const_iterator
i = b.begin();
i != b.end(); ++
i)
412 int max =
std::min(w->second.first.size(),w->second.second.size());
413 std::vector<CSCWireDigi> cv = w->second.first;
414 std::vector<CSCWireDigi> sv = w->second.second;
415 for(
int i = 0;
i <
max; ++
i)
417 if(sv[
i].getWireGroup() != cv[
i].getWireGroup())
419 std::cout <<
"In detId: " << w->first << std::endl;
420 std::cout <<
"Wire Groups do not match: " << sv[
i].getWireGroup()
421 <<
" != " << cv[
i].getWireGroup() << std::endl;
423 if(sv[
i].getTimeBin() != cv[
i].getTimeBin())
425 std::cout <<
"In detId: " << w->first << std::endl;
426 std::cout <<
"First Time Bins do not match: " << sv[
i].getTimeBin()
427 <<
" != " << cv[
i].getTimeBin() << std::endl;
429 if(sv[
i].getTimeBinWord() != cv[
i].getTimeBinWord())
431 std::cout <<
"In detId: " << w->first << std::endl;
432 std::cout <<
"Time Bin Words do not match: " << sv[
i].getTimeBinWord()
433 <<
" != " << cv[
i].getTimeBinWord() << std::endl;
439 if(
s->second.first.size() !=
s->second.second.size())
441 std::cout <<
"Major error! # of strip digis in detID: " <<
s->first
442 <<
" is not equal between sim and unpacked!" << std::endl;
445 std::vector<CSCStripDigi> a =
s->second.second;
446 std::vector<CSCStripDigi> b =
s->second.first;
448 for(std::vector<CSCStripDigi>::const_iterator
i = a.begin();
i != a.end(); ++
i)
450 std::cout <<
"UNPACKER OUTPUT:" << std::endl;
451 for(std::vector<CSCStripDigi>::const_iterator
i = b.begin();
i != b.end(); ++
i)
454 int max =
std::min(
s->second.first.size(),
s->second.second.size());
455 std::vector<CSCStripDigi> cv =
s->second.first;
456 std::vector<CSCStripDigi> sv =
s->second.second;
457 for(
int i = 0;
i <
max; ++
i)
459 bool me1a =
s->first.station()==1 &&
s->first.ring()==4;
460 bool me1b =
s->first.station()==1 &&
s->first.ring()==1;
461 bool zplus =
s->first.endcap()==1;
464 if(me1a && zplus) k=max-
i-1;
465 if(me1b && !zplus) k=max-i-1;
467 if(sv[k].getStrip() != cv[i].getStrip())
469 std::cout <<
"In detId: " <<
s->first << std::endl;
470 std::cout <<
"Strips do not match: " << sv[
k].getStrip()
471 <<
" != " << cv[
i].getStrip() << std::endl;
473 if(sv[k].getADCCounts().
size() != cv[i].getADCCounts().
size())
475 std::cout <<
"In detId: " <<
s->first << std::endl;
476 std::cout <<
"ADC Readouts not of equal size!" << std::endl;
477 std::cout << sv[
k].getADCCounts().size() <<
' '
478 << cv[
i].getADCCounts().size() << std::endl;
482 std::vector<int> sADC = sv[
k].getADCCounts();
483 std::vector<int> uADC = cv[
i].getADCCounts();
485 for(
unsigned iadc = 0; iadc < sADC.size(); ++iadc)
486 if(sADC[iadc] != uADC[iadc])
488 std::cout <<
"In detId: " <<
s->first << std::endl;
489 std::cout <<
"ADC counts not equal at index: " << iadc << std::endl
490 << std::hex <<sADC[iadc] <<
" != " << uADC[iadc] << std::dec
494 if(sv[k].getADCOverflow().size() != cv[
i].getADCOverflow().size())
496 std::cout <<
"In detId: " <<
s->first << std::endl;
497 std::cout <<
"ADC Overflows not of equal size!" << std::endl;
498 std::cout << sv[
k].getADCOverflow().size() <<
' '
499 << cv[
i].getADCOverflow().size() << std::endl;
503 std::vector<uint16_t> sADC = sv[
k].getADCOverflow();
504 std::vector<uint16_t> uADC = cv[
i].getADCOverflow();
506 for(
unsigned iadc = 0; iadc < sADC.size(); ++iadc)
507 if(sADC[iadc] != uADC[iadc])
509 std::cout <<
"In detId: " <<
s->first << std::endl;
510 std::cout <<
"ADC overflows not equal at index: " << iadc << std::endl
511 << std::hex <<sADC[iadc] <<
" != " << uADC[iadc] << std::dec
515 if(sv[k].getOverlappedSample().size() != cv[
i].getOverlappedSample().size())
517 std::cout <<
"In detId: " <<
s->first << std::endl;
518 std::cout <<
"Overlapped Samples not of equal size!" << std::endl;
519 std::cout << sv[
k].getOverlappedSample().size() <<
' '
520 << cv[
i].getOverlappedSample().size() << std::endl;
524 std::vector<uint16_t> sADC = sv[
k].getOverlappedSample();
525 std::vector<uint16_t> uADC = cv[
i].getOverlappedSample();
527 for(
unsigned iadc = 0; iadc < sADC.size(); ++iadc)
528 if(sADC[iadc] != uADC[iadc])
530 std::cout <<
"In detId: " <<
s->first << std::endl;
531 std::cout <<
"Overlapped Samples not equal at index: " << iadc << std::endl
532 << std::hex <<sADC[iadc] <<
" != " << uADC[iadc] << std::dec
536 if(sv[k].getErrorstat().size() != cv[
i].getErrorstat().size())
538 std::cout <<
"In detId: " <<
s->first << std::endl;
539 std::cout <<
"Errorstat not of equal size!" << std::endl;
540 std::cout << sv[
k].getErrorstat().size() <<
' '
541 << cv[
i].getErrorstat().size() << std::endl;
545 std::vector<uint16_t> sADC = sv[
k].getErrorstat();
546 std::vector<uint16_t> uADC = cv[
i].getErrorstat();
548 for(
unsigned iadc = 0; iadc < sADC.size(); ++iadc)
549 if(sADC[iadc] != uADC[iadc])
551 std::cout <<
"In detId: " <<
s->first << std::endl;
552 std::cout <<
"Errorstat not equal at index: " << iadc << std::endl
553 << std::hex <<sADC[iadc] <<
" != " << uADC[iadc] << std::dec
557 if(sv[k].pedestal() != cv[
i].pedestal())
559 std::cout <<
"In detId: " <<
s->first << std::endl;
560 std::cout <<
"Pedestals not equal: " << sv[
k].pedestal() <<
" != "
561 << cv[
i].pedestal() << std::endl;
563 if(sv[k].amplitude() != cv[i].amplitude())
565 std::cout <<
"In detId: " <<
s->first << std::endl;
566 std::cout <<
"Amplitudes not equal: " << sv[
k].amplitude() <<
" != "
567 << cv[
i].amplitude() << std::endl;
571 for(
c = comps.begin();
c != comps.end(); ++
c)
573 if(
c->second.first.size() !=
c->second.second.size())
575 std::cout <<
"Major error! # of comparator digis in detID: " <<
c->first
576 <<
" is not equal between sim and unpacked!" << std::endl;
579 std::vector<CSCComparatorDigi> a =
c->second.second;
580 std::vector<CSCComparatorDigi> b =
c->second.first;
582 for(std::vector<CSCComparatorDigi>::const_iterator i = a.begin(); i != a.end(); ++
i)
584 std::cout <<
"UNPACKER OUTPUT:" << std::endl;
585 for(std::vector<CSCComparatorDigi>::const_iterator i = b.begin(); i != b.end(); ++
i)
588 int max =
std::min(
c->second.first.size(),
c->second.second.size());
589 std::vector<CSCComparatorDigi> cv =
c->second.first;
590 std::vector<CSCComparatorDigi> sv =
c->second.second;
591 for(
int i = 0; i <
max; ++
i)
593 if(sv[i].getStrip() != cv[
i].getStrip())
595 std::cout <<
"In detId: " <<
s->first << std::endl;
596 std::cout <<
"Comparator strips do not match: " << sv[
i].getStrip()
597 <<
" != " << cv[
i].getStrip() << std::endl;
599 if(sv[i].getComparator() != cv[i].getComparator())
601 std::cout <<
"In detId: " <<
c->first << std::endl;
602 std::cout <<
"Comparators do not match: " << sv[
i].getComparator()
603 <<
" != " << cv[
i].getComparator() << std::endl;
605 if(sv[i].getTimeBinWord() != cv[i].getTimeBinWord())
607 std::cout <<
"In detId: " <<
c->first << std::endl;
608 std::cout <<
"Comparator time bins words do not match: " << sv[
i].getTimeBinWord()
609 <<
" != " << cv[
i].getTimeBinWord() << std::endl;
613 for(cl = clcts.begin(); cl != clcts.end(); ++cl)
615 if(cl->second.first.size() != cl->second.second.size())
617 std::cout <<
"Major error! # of CLCT digis in detID: " << cl->first
618 <<
" is not equal between sim and unpacked!" << std::endl;
621 std::vector<CSCCLCTDigi> a = cl->second.second;
622 std::vector<CSCCLCTDigi> b = cl->second.first;
624 for(std::vector<CSCCLCTDigi>::const_iterator i = a.begin(); i != a.end(); ++
i)
626 std::cout <<
"UNPACKER OUTPUT:" << std::endl;
627 for(std::vector<CSCCLCTDigi>::const_iterator i = b.begin(); i != b.end(); ++
i)
630 int max =
std::min(cl->second.first.size(),cl->second.second.size());
631 std::vector<CSCCLCTDigi> cv = cl->second.first;
632 std::vector<CSCCLCTDigi> sv = cl->second.second;
633 for(
int i = 0; i <
max; ++
i)
635 if(cv[i].getKeyStrip() != sv[
i].getKeyStrip())
637 std::cout <<
"In detId: " << cl->first << std::endl;
638 std::cout <<
"CLCT key strips do not match: " << sv[
i].getKeyStrip()
639 <<
" != " << cv[
i].getKeyStrip() << std::endl;
641 if(cv[i].getStrip() != sv[i].getStrip())
643 std::cout <<
"In detId: " << cl->first << std::endl;
644 std::cout <<
"CLCT strips do not match: " << sv[
i].getStrip()
645 <<
" != " << cv[
i].getStrip() << std::endl;
647 if(cv[i].isValid() != sv[i].isValid())
649 std::cout <<
"In detId: " << cl->first << std::endl;
650 std::cout <<
"CLCT Valid bits do not match: " << sv[
i].isValid()
651 <<
" != " << cv[
i].isValid() << std::endl;
653 if(cv[i].getQuality() != sv[i].getQuality())
655 std::cout <<
"In detId: " << cl->first << std::endl;
656 std::cout <<
"CLCT qualities do not match: " << sv[
i].getQuality()
657 <<
" != " << cv[
i].getQuality() << std::endl;
659 if(cv[i].getPattern() != sv[i].getPattern())
661 std::cout <<
"In detId: " << cl->first << std::endl;
662 std::cout <<
"CLCT patterns do not match: " << sv[
i].getPattern()
663 <<
" != " << cv[
i].getPattern() << std::endl;
665 if(cv[i].getStripType() != sv[i].getStripType())
667 std::cout <<
"In detId: " << cl->first << std::endl;
668 std::cout <<
"CLCT strip types do not match: " << sv[
i].getStripType()
669 <<
" != " << cv[
i].getStripType() << std::endl;
671 if(cv[i].getBend() != sv[i].getBend())
673 std::cout <<
"In detId: " << cl->first << std::endl;
674 std::cout <<
"CLCT bends do not match: " << sv[
i].getBend()
675 <<
" != " << cv[
i].getBend() << std::endl;
677 if(cv[i].getCFEB() != sv[i].getCFEB())
679 std::cout <<
"In detId: " << cl->first << std::endl;
680 std::cout <<
"CLCT CFEBs do not match: " << sv[
i].getCFEB()
681 <<
" != " << cv[
i].getCFEB() << std::endl;
683 if(((
short)cv[i].getBX()) != ((
short)sv[i].getBX()) - 4)
685 std::cout <<
"In detId: " << cl->first << std::endl;
686 std::cout <<
"CLCT BX do not match: " << sv[
i].getBX() - 4
687 <<
" != " << cv[
i].getBX() << std::endl;
689 if(cv[i].getFullBX() != sv[i].getFullBX())
691 std::cout <<
"In detId: " << cl->first << std::endl;
692 std::cout <<
"CLCT Full BX do not match: " << sv[
i].getFullBX()
693 <<
" != " << cv[
i].getFullBX() << std::endl;
695 if(cv[i].getTrknmb() != sv[i].getTrknmb())
697 std::cout <<
"In detId: " << cl->first << std::endl;
698 std::cout <<
"CLCT Track numbers do not match: " << sv[
i].getTrknmb()
699 <<
" != " << cv[
i].getTrknmb() << std::endl;
703 for(al = alcts.begin(); al != alcts.end(); ++al)
705 if(al->second.first.size() != al->second.second.size())
707 std::cout <<
"Major error! # of ALCT digis in detID: " << al->first
708 <<
" is not equal between sim and unpacked!" << std::endl;
711 std::vector<CSCALCTDigi> a = al->second.second;
712 std::vector<CSCALCTDigi> b = al->second.first;
714 for(std::vector<CSCALCTDigi>::const_iterator i = a.begin(); i != a.end(); ++
i)
716 std::cout <<
"UNPACKER OUTPUT:" << std::endl;
717 for(std::vector<CSCALCTDigi>::const_iterator i = b.begin(); i != b.end(); ++
i)
720 int max =
std::min(al->second.first.size(),al->second.second.size());
721 std::vector<CSCALCTDigi> cv = al->second.first;
722 std::vector<CSCALCTDigi> sv = al->second.second;
723 for(
int i = 0; i <
max; ++
i)
725 if(cv[i].getKeyWG() != sv[
i].getKeyWG())
727 std::cout <<
"In detId: " << al->first << std::endl;
728 std::cout <<
"ALCT key wire groups do not match: " << sv[
i].getKeyWG()
729 <<
" != " << cv[
i].getKeyWG() << std::endl;
731 if(cv[i].isValid() != sv[i].isValid())
733 std::cout <<
"In detId: " << al->first << std::endl;
734 std::cout <<
"ALCT Valid bits do not match: " << sv[
i].isValid()
735 <<
" != " << cv[
i].isValid() << std::endl;
737 if(cv[i].getQuality() != sv[i].getQuality())
739 std::cout <<
"In detId: " << al->first << std::endl;
740 std::cout <<
"ALCT qualities do not match: " << sv[
i].getQuality()
741 <<
" != " << cv[
i].getQuality() << std::endl;
743 if(cv[i].getAccelerator() != sv[i].getAccelerator())
745 std::cout <<
"In detId: " << al->first << std::endl;
746 std::cout <<
"ALCT accelerator bits do not match: " << sv[
i].getAccelerator()
747 <<
" != " << cv[
i].getAccelerator() << std::endl;
749 if(cv[i].getCollisionB() != sv[i].getCollisionB())
751 std::cout <<
"In detId: " << al->first << std::endl;
752 std::cout <<
"ALCT CollisionB flags do not match: " << sv[
i].getCollisionB()
753 <<
" != " << cv[
i].getCollisionB() << std::endl;
755 if((cv[i].getBX()) != (sv[i].getBX()))
757 std::cout <<
"In detId: " << al->first << std::endl;
758 std::cout <<
"ALCT BX do not match: " << sv[
i].getBX()
759 <<
" != " << cv[
i].getBX() << std::endl;
761 if(cv[i].getFullBX() != sv[i].getFullBX())
763 std::cout <<
"In detId: " << cl->first << std::endl;
764 std::cout <<
"ALCT Full BX do not match: " << sv[
i].getFullBX()
765 <<
" != " << cv[
i].getFullBX() << std::endl;
769 for(lc = lcts.begin(); lc != lcts.end(); ++lc)
771 if(lc->second.first.size() != lc->second.second.size())
773 std::cout <<
"Major error! # of Correlated LCT digis in detID: " << lc->first
774 <<
" is not equal between sim and unpacked!" << std::endl;
777 std::vector<CSCCorrelatedLCTDigi> a = lc->second.second;
778 std::vector<CSCCorrelatedLCTDigi> b = lc->second.first;
780 for(std::vector<CSCCorrelatedLCTDigi>::const_iterator i = a.begin(); i != a.end(); ++
i)
782 std::cout <<
"UNPACKER OUTPUT:" << std::endl;
783 for(std::vector<CSCCorrelatedLCTDigi>::const_iterator i = b.begin(); i != b.end(); ++
i)
786 int max =
std::min(lc->second.first.size(),lc->second.second.size());
787 std::vector<CSCCorrelatedLCTDigi> cv = lc->second.first;
788 std::vector<CSCCorrelatedLCTDigi> sv = lc->second.second;
789 for(
int i = 0; i <
max; ++
i)
791 if(cv[i].getStrip() != sv[
i].getStrip())
793 std::cout <<
"In detId: " << lc->first << std::endl;
794 std::cout <<
"Correlated LCT strips do not match: " << sv[
i].getStrip()
795 <<
" != " << cv[
i].getStrip() << std::endl;
797 if(cv[i].getKeyWG() != sv[i].getKeyWG())
799 std::cout <<
"In detId: " << lc->first << std::endl;
800 std::cout <<
"Correlated LCT key wire groups do not match: " << sv[
i].getKeyWG()
801 <<
" != " << cv[
i].getKeyWG() << std::endl;
803 if(cv[i].isValid() != sv[i].isValid())
805 std::cout <<
"In detId: " << lc->first << std::endl;
806 std::cout <<
"Correlated LCT Valid bits do not match: " << sv[
i].isValid()
807 <<
" != " << cv[
i].isValid() << std::endl;
809 if(cv[i].getQuality() != sv[i].getQuality())
811 std::cout <<
"In detId: " << lc->first << std::endl;
812 std::cout <<
"Correlated LCT qualities do not match: " << sv[
i].getQuality()
813 <<
" != " << cv[
i].getQuality() << std::endl;
815 if(cv[i].getPattern() != sv[i].getPattern())
817 std::cout <<
"In detId: " << lc->first << std::endl;
818 std::cout <<
"Correlated LCT ALCT patterns do not match: " << sv[
i].getPattern()
819 <<
" != " << cv[
i].getPattern() << std::endl;
821 if(cv[i].getCLCTPattern() != sv[i].getCLCTPattern())
823 std::cout <<
"In detId: " << lc->first << std::endl;
824 std::cout <<
"Correlated LCT CLCT patterns do not match: " << sv[
i].getCLCTPattern()
825 <<
" != " << cv[
i].getCLCTPattern() << std::endl;
827 if(cv[i].getStripType() != sv[i].getStripType())
829 std::cout <<
"In detId: " << lc->first << std::endl;
830 std::cout <<
"Correlated LCT strip types do not match: " << sv[
i].getStripType()
831 <<
" != " << cv[
i].getStripType() << std::endl;
833 if(cv[i].getBend() != sv[i].getBend())
835 std::cout <<
"In detId: " << lc->first << std::endl;
836 std::cout <<
"Correlated LCT bends do not match: " << sv[
i].getBend()
837 <<
" != " << cv[
i].getBend() << std::endl;
839 if(cv[i].getMPCLink() != sv[i].getMPCLink())
841 std::cout <<
"In detId: " << lc->first << std::endl;
842 std::cout <<
"Correlated LCT MPC Links do not match: " << sv[
i].getMPCLink()
843 <<
" != " << cv[
i].getMPCLink() << std::endl;
845 if((cv[i].getBX()) != (sv[i].getBX()-6))
847 std::cout <<
"In detId: " << lc->first << std::endl;
848 std::cout <<
"Correlated LCT BX do not match: " << sv[
i].getBX()-6
849 <<
" != " << cv[
i].getBX() << std::endl;
851 if(cv[i].getCSCID() != sv[i].getCSCID())
853 std::cout <<
"In detId: " << lc->first << std::endl;
854 std::cout <<
"Correlated LCT CSCIDs do not match: " << sv[
i].getCSCID()
855 <<
" != " << cv[
i].getCSCID() << std::endl;
857 if(cv[i].getBX0() != sv[i].getBX0())
859 std::cout <<
"In detId: " << lc->first << std::endl;
860 std::cout <<
"Correlated LCT BX0s do not match: " << sv[
i].getBX0()
861 <<
" != " << cv[
i].getBX0() << std::endl;
863 if(cv[i].getSyncErr() != sv[i].getSyncErr())
865 std::cout <<
"In detId: " << lc->first << std::endl;
866 std::cout <<
"Correlated LCT SyncErrs do not match: " << sv[
i].getSyncErr()
867 <<
" != " << cv[
i].getSyncErr() << std::endl;
869 if(cv[i].getTrknmb() != sv[i].getTrknmb())
871 std::cout <<
"In detId: " << lc->first << std::endl;
872 std::cout <<
"Correlated LCT Track numbers do not match: " << sv[
i].getTrknmb()
873 <<
" != " << cv[
i].getTrknmb() << std::endl;
877 if(
tracks.get().size() != simtracks.get().size())
879 std::cout <<
"Major error! # of L1 Tracks is not equal between sim and unpacked!" << std::endl;
880 std::vector<csc::L1Track> a = simtracks.get();
881 std::vector<csc::L1Track> b =
tracks.get();
883 for(std::vector<csc::L1Track>::const_iterator i = a.begin(); i != a.end(); ++
i)
885 std::cout <<
"UNPACKER OUTPUT:" << std::endl;
886 for(std::vector<csc::L1Track>::const_iterator i = b.begin(); i != b.end(); ++
i)
edm::InputTag csctfstubs2
std::vector< CSCComparatorDigi > zeroSupCompDigis(std::vector< CSCComparatorDigi >::const_iterator, std::vector< CSCComparatorDigi >::const_iterator)
std::vector< CSCComparatorDigi > relabelCompDigis(const CSCChamberMap *m, CSCDetId _id, std::vector< CSCComparatorDigi >::const_iterator b, std::vector< CSCComparatorDigi >::const_iterator e)
edm::InputTag csctfstubs1
U second(std::pair< T, U > const &p)
const T & max(const T &a, const T &b)
bool getByLabel(InputTag const &tag, Handle< PROD > &result) const
std::vector< DigiType >::const_iterator const_iterator
std::vector< CSCStripDigi > zeroSupStripDigis(std::vector< CSCStripDigi >::const_iterator, std::vector< CSCStripDigi >::const_iterator)
std::vector< CSCWireDigi > sanitizeWireDigis(std::vector< CSCWireDigi >::const_iterator, std::vector< CSCWireDigi >::const_iterator)
tuple size
Write out results.
std::vector< CSCStripDigi > relabelStripDigis(const CSCChamberMap *, CSCDetId, std::vector< CSCStripDigi >::const_iterator, std::vector< CSCStripDigi >::const_iterator)