332 if (!myL1MuDTChambPhContainer.
isValid()) {
333 edm::LogInfo(
"DataNotFound") <<
"can't find L1MuDTChambPhContainer with label "
338 myL1MuDTChambPhContainer->getContainer();
343 if (!myL1MuDTChambThContainer.
isValid()) {
344 edm::LogInfo(
"DataNotFound") <<
"can't find L1MuDTChambThContainer with label "
346 edm::LogInfo(
"DataNotFound") <<
"if this fails try to add DATA to the process name." ;
351 myL1MuDTChambThContainer->getContainer();
353 int ndttpgphtrack = 0;
354 int ndttpgthtrack = 0;
355 int NumberOfSegmentsPhi[3]={0,0,0};
357 for( L1MuDTChambPhContainer::Phi_Container::const_iterator
358 DTPhDigiItr = myPhContainer->begin() ;
359 DTPhDigiItr != myPhContainer->end() ;
362 int bx = DTPhDigiItr->bxNum() - DTPhDigiItr->Ts2Tag();
364 NumberOfSegmentsPhi[0]++;
366 NumberOfSegmentsPhi[1]++;
368 NumberOfSegmentsPhi[2]++;
372 for(
int k=0;
k<3;
k++){
375 int bxCounterDttfPhi=0;
376 for (
int k=0;
k<3;
k++){
377 if (NumberOfSegmentsPhi[
k]>0)
384 if(bxCounterDttfPhi==0){
386 }
else if(bxCounterDttfPhi==1){
387 for(
int k=0;
k<3;
k++){
388 if(NumberOfSegmentsPhi[
k]>0)
391 }
else if(bxCounterDttfPhi==2){
392 for(
int k=0;
k<3;
k++){
393 if(NumberOfSegmentsPhi[
k]==0)
396 }
else if(bxCounterDttfPhi==3){
407 for( L1MuDTChambPhContainer::Phi_Container::const_iterator
408 DTPhDigiItr = myPhContainer->begin() ;
409 DTPhDigiItr != myPhContainer->end() ;
415 int bxindex = DTPhDigiItr->bxNum() - DTPhDigiItr->Ts2Tag() + 1;
420 cout <<
"DTTPG phi wheel number " << DTPhDigiItr->whNum() << endl;
425 cout <<
"DTTPG phi station number " << DTPhDigiItr->stNum() << endl;
430 cout <<
"DTTPG phi sector number " << DTPhDigiItr->scNum() << endl;
445 cout <<
"DTTPG phi quality " << DTPhDigiItr->code() << endl;
450 cout <<
"DTTPG phi ts2tag " << DTPhDigiItr->Ts2Tag() << endl;
458 int ypos = DTPhDigiItr->scNum();
459 int xpos = DTPhDigiItr->stNum()+4*(DTPhDigiItr->whNum()+2);
461 if (DTPhDigiItr->Ts2Tag())
464 if (DTPhDigiItr->code()>3)
467 if (bestPhQualMap[DTPhDigiItr->whNum()+2][ DTPhDigiItr->scNum()][DTPhDigiItr->stNum()-1]==0 ||
468 bestPhQualMap[DTPhDigiItr->whNum()+2][ DTPhDigiItr->scNum()][DTPhDigiItr->stNum()-1]->
code()<DTPhDigiItr->code())
470 bestPhQualMap[DTPhDigiItr->whNum()+2][ DTPhDigiItr->scNum()][DTPhDigiItr->stNum()-1]=&(*DTPhDigiItr);
475 for (
int iwh=0; iwh<5; iwh++){
476 for (
int isec=0; isec<12; isec++){
477 for (
int ist=0; ist<4; ist++){
478 if (bestPhQualMap[iwh][isec][ist]){
479 int xpos = iwh*4+ist+1;
481 if(bestPhQualMap[iwh][isec][ist]->code()>3)
489 int bestThQualMap[5][12][3];
490 memset(bestThQualMap,0,180*
sizeof(
int));
492 for( L1MuDTChambThContainer::The_Container::const_iterator
493 DTThDigiItr = myThContainer->begin() ;
494 DTThDigiItr != myThContainer->end() ;
499 int bxindex = DTThDigiItr->bxNum() + 1;
504 cout <<
"DTTPG theta wheel number " << DTThDigiItr->whNum() << endl;
509 cout <<
"DTTPG theta station number " << DTThDigiItr->stNum() << endl;
514 cout <<
"DTTPG theta sector number " << DTThDigiItr->scNum() << endl;
519 cout <<
"DTTPG theta bx number " << DTThDigiItr->bxNum() << endl;
521 int thcode[7]= {0,0,0,0,0,0,0};
522 for (
int j = 0;
j < 7;
j++)
527 cout <<
"DTTPG theta position " << DTThDigiItr->position(
j) << endl;
529 thcode[
j]=DTThDigiItr->code(
j);
533 cout <<
"DTTPG theta quality " << DTThDigiItr->code(j) << endl;
537 int ypos = DTThDigiItr->scNum();
538 int xpos = DTThDigiItr->stNum()+4*(DTThDigiItr->whNum()+2);
542 for (
int pos = 0; pos < 7; pos++){
543 if (thcode[pos]>bestqual)
544 bestqual=thcode[pos];
549 if (bestThQualMap[DTThDigiItr->whNum()+2][ DTThDigiItr->scNum()][DTThDigiItr->stNum()-1] < bestqual)
551 bestThQualMap[DTThDigiItr->whNum()+2][ DTThDigiItr->scNum()][DTThDigiItr->stNum()-1]=bestqual;
555 for (
int iwh=0; iwh<5; iwh++){
556 for (
int isec=0; isec<12; isec++){
557 for (
int ist=0; ist<3; ist++){
558 if (bestThQualMap[iwh][isec][ist]){
559 int xpos = iwh*4+ist+1;
561 if(bestThQualMap[iwh][isec][ist]==2)
572 cout <<
"DTTPG phi ntrack " << ndttpgphtrack << endl;
576 cout <<
"DTTPG theta ntrack " << ndttpgthtrack << endl;
582 if (!myL1MuDTTrackContainer.
isValid()) {
583 edm::LogInfo(
"DataNotFound") <<
"can't find L1MuDTTrackContainer with label "
592 int NumberOfSegmentsOut[3]={0,0,0};
593 for ( L1MuDTTrackContainer::TrackContainer::const_iterator
i
594 = t->begin();
i != t->end(); ++
i ) {
596 NumberOfSegmentsOut[0]++;
598 NumberOfSegmentsOut[1]++;
600 NumberOfSegmentsOut[2]++;
605 for(
int k=0;
k<3;
k++){
611 int bxCounterDttfOut=0;
612 for (
int k=0;
k<3;
k++){
613 if (NumberOfSegmentsOut[
k]>0)
618 if(bxCounterDttfOut==0){
620 }
else if(bxCounterDttfOut==1){
621 for(
int k=0;
k<3;
k++){
622 if(NumberOfSegmentsOut[
k]>0)
625 }
else if(bxCounterDttfOut==2){
626 for(
int k=0;
k<3;
k++){
627 if(NumberOfSegmentsOut[
k]==0)
630 }
else if(bxCounterDttfOut==3){
643 for ( L1MuDTTrackContainer::TrackContainer::const_iterator
i
644 = t->begin();
i != t->end(); ++
i ) {
648 std::cout <<
"quality (packed) = " <<
i->quality_packed()
650 std::cout <<
"pt (packed) = " <<
i->pt_packed()
652 std::cout <<
"phi (packed) = " <<
i->phi_packed()
654 std::cout <<
"charge (packed) = " <<
i->charge_packed()
659 int bxindex =
i->bx() + 1;
MonitorElement * dttpgthbestmaph
MonitorElement * dttf_p_phi[3]
MonitorElement * dttpgphmap
MonitorElement * dttpgphbestmapcorr
MonitorElement * dttpgphmapcorr
MonitorElement * dttpgphbx[8]
bool getByToken(EDGetToken token, Handle< PROD > &result) const
edm::EDGetTokenT< L1MuDTChambThContainer > dttpgSourceThContainer_token_
MonitorElement * dttpgththeta[3]
MonitorElement * dttpgphwheel[3]
MonitorElement * dttpgthbestmap
MonitorElement * dttpgphbxcomp
edm::EDGetTokenT< L1MuDTTrackContainer > trToken_
MonitorElement * dttpgthmaph
MonitorElement * dttpgthsector[3]
MonitorElement * dttpgthmapbx[3]
MonitorElement * dttpgthwheel[3]
MonitorElement * dttpgthmap
std::vector< L1MuDTTrackCand > TrackContainer
MonitorElement * dttf_p_qual[3]
MonitorElement * dttpgthbx[3]
MonitorElement * dttpgthquality[3]
std::vector< L1MuDTChambPhDigi > Phi_Container
MonitorElement * dttf_p_pt[3]
std::vector< L1MuDTChambThDigi > The_Container
MonitorElement * dttpgphbestmap
MonitorElement * dttpgthntrack
edm::InputTag dttpgSource_
MonitorElement * dttpgphts2tag[3]
MonitorElement * dttpgphntrack
edm::EDGetTokenT< L1MuDTChambPhContainer > dttpgSourcePhContainer_token_
MonitorElement * dttf_p_q[3]
MonitorElement * dttpgphmapbx[3]
MonitorElement * dttpgthstation[3]
MonitorElement * dttpgphsector[3]
MonitorElement * dttpgphquality[3]
MonitorElement * dttpgphmap2nd
MonitorElement * dttpgphstation[3]