623{
624 cout << "EdbShowAlg_SA::Execute()" << endl;
625 cout << "EdbShowAlg_SA::Execute DOING MAIN SHOWER RECONSTRUCTION HERE" << endl;
626
630
631 Bool_t StillToLoop=kTRUE;
632 Int_t ActualPID;
633 Int_t newActualPID;
634 Int_t STEP=-1;
635 Int_t NLoopedPattern=0;
637 if (
gEDBDEBUGLEVEL>3) cout <<
"EdbShowAlg_SA::Execute--- STEP for patternloop direction = " << STEP << endl;
638
639
640
641
642
644
645
646 if (
gEDBDEBUGLEVEL==2)
if ((i%100)==0) cout <<
eInBTArrayN <<
" InBT in total, still to do:"<<Form(
"%4d",i)<<
"\r\r\r\r"<<flush;
647
648
649
650
651
652
653
655
656
659
660
661
662
663 RecoShower -> AddSegment(InBT);
664 if (
gEDBDEBUGLEVEL>4) cout <<
"Segment (InBT) " << Segment <<
" was added to RecoShower." << endl;
665
666
667
669
670
671
672
673
674
675
676 ActualPID= InBT->
PID() ;
677 newActualPID= InBT->
PID() ;
678
679 while (StillToLoop) {
680 if (
gEDBDEBUGLEVEL>3) cout <<
"EdbShowAlg_SA::Execute--- --- Doing patterloop " << ActualPID << endl;
681
682 for (Int_t btloop_cnt=0; btloop_cnt<
eAli->
GetPattern(ActualPID)->GetN(); ++btloop_cnt) {
683
686
687
688
689 if (Segment->
MCEvt()!=InBT->
MCEvt())
continue;
691
692
693
694
695
696 if (Segment->
X()==InBT->
X()&&Segment->
Y()==InBT->
Y()) {
697 ;
698 }
699 else {
700 RecoShower -> AddSegment(Segment);
701 }
702 if (
gEDBDEBUGLEVEL>4) cout <<
"Segment " << Segment <<
" was added at &Segment : " << &Segment << endl;
703
704 }
705
706
707 newActualPID=ActualPID+STEP;
708 ++NLoopedPattern;
709
710 if (
gEDBDEBUGLEVEL>3) cout <<
"EdbShowAlg_SA::Execute--- --- newActualPID= " << newActualPID << endl;
711 if (
gEDBDEBUGLEVEL>3) cout <<
"EdbShowAlg_SA::Execute--- --- NLoopedPattern= " << NLoopedPattern << endl;
713 if (
gEDBDEBUGLEVEL>3) cout <<
"EdbShowAlg_SA::Execute--- --- StillToLoop= " << StillToLoop << endl;
714
715
716 if (STEP==1) {
718 if (newActualPID>
eLastPlate_eAliPID) cout <<
"EdbShowAlg_SA::Execute--- ---Stop Loop since: newActualPID>eLastPlate_eAliPID"<<endl;
719 }
720
721 if (STEP==-1) {
723 if (newActualPID<eLastPlate_eAliPID && gEDBDEBUGLEVEL>3) cout << "EdbShowAlg_SA::Execute--- ---Stop Loop since: newActualPID<eLastPlate_eAliPID"<<endl;
724 }
725
728
729 ActualPID=newActualPID;
730 }
731
732
734
735
736
737
738
739
740
741
742
743
744
745 if (RecoShower->
N()>1) {
747 }
748 else {
749
750
751 Log(3,
"EdbShowAlg_SA::Execute()",
"InBT # %d RecoShower->N()<=1: Dont add shower to RecoShowerArray. Delete this shower for memory safing.");
752 delete RecoShower;
754 }
755
756
757 StillToLoop=kTRUE;
758 NLoopedPattern=0;
759 }
760
761
762
764
765 cout <<
"EdbShowAlg_SA::eRecoShowerArray() Entries: " <<
eRecoShowerArray->GetEntries() << endl;
766 cout << "EdbShowAlg_SA::Execute()...done." << endl;
767 return;
768}
bool Log(int level, const char *location, const char *fmt,...)
Definition: EdbLog.cxx:75
EdbPattern * GetPattern(int id) const
Definition: EdbPattern.cxx:1721
Float_t X() const
Definition: EdbSegP.h:173
Float_t P() const
Definition: EdbSegP.h:152
Float_t Y() const
Definition: EdbSegP.h:174
void PrintNice() const
Definition: EdbSegP.cxx:392
Int_t PID() const
Definition: EdbSegP.h:148
Int_t MCEvt() const
Definition: EdbSegP.h:145
EdbSegP * GetSegment(int i) const
Definition: EdbPattern.h:66
void Transform_eAli(EdbSegP *InitiatorBT, Float_t ExtractSize)
Definition: EdbShowAlg.cxx:107
Float_t eParaValue[10]
Definition: EdbShowAlg.h:52
void AddRecoShowerArray(EdbShowerP *shower)
Definition: EdbShowAlg.h:120
void SetRecoShowerArrayN(Int_t RecoShowerArrayN)
Definition: EdbShowAlg.h:117
TObjArray * eRecoShowerArray
Definition: EdbShowAlg.h:70
Int_t eFirstPlate_eAliPID
Definition: EdbShowAlg.h:65
Int_t eLastPlate_eAliPID
Definition: EdbShowAlg.h:66
Int_t eInBTArrayN
Definition: EdbShowAlg.h:63
TObjArray * eInBTArray
Definition: EdbShowAlg.h:62
EdbPVRec * eAli
Definition: EdbShowAlg.h:59
Int_t eNumberPlate_eAliPID
Definition: EdbShowAlg.h:68
Int_t eActualAlgParametersetNr
Definition: EdbShowAlg.h:54
Definition: EdbShowerP.h:28
Int_t N() const
Definition: EdbShowerP.h:412
void Update()
Definition: EdbShowerP.cxx:975
gEDBDEBUGLEVEL
Definition: energy.C:7
#define NULL
Definition: nidaqmx.h:84