]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - MUON/AliMUONQADataMakerSim.cxx
Adding more bins in QA (Alis)
[u/mrichter/AliRoot.git] / MUON / AliMUONQADataMakerSim.cxx
index fb859cc4eadad37211b1088b951d718496c7603d..fd8bc01868f4e18203c1cdebb00a8f40bb2f418e 100644 (file)
@@ -52,7 +52,7 @@ AliMUONQADataMakerSim::AliMUONQADataMakerSim() :
 {
   /// Default constructor
 
-  AliDebug(1,"");
+      AliDebug(AliQAv1::GetQADebugLevel(),"");
 }
 
 //____________________________________________________________________________ 
@@ -63,7 +63,7 @@ AliMUONQADataMakerSim::AliMUONQADataMakerSim(const AliMUONQADataMakerSim& qadm)
 {
   /// Copy constructor
 
-  AliDebug(1,"");
+    AliDebug(AliQAv1::GetQADebugLevel(),"");
 
     if ( qadm.fHitStore ) 
     {
@@ -82,7 +82,7 @@ AliMUONQADataMakerSim& AliMUONQADataMakerSim::operator = (const AliMUONQADataMak
 {
   /// Assignment operator
 
-    AliDebug(1,"");
+  AliDebug(AliQAv1::GetQADebugLevel(),"");
 
     this->~AliMUONQADataMakerSim();
     new(this) AliMUONQADataMakerSim(qadm);
@@ -94,7 +94,7 @@ AliMUONQADataMakerSim::~AliMUONQADataMakerSim()
 {
   /// Destructor
 
-  AliDebug(1,"");
+  AliDebug(AliQAv1::GetQADebugLevel(),"");
 
   delete fHitStore;
   delete fDigitStore;
@@ -104,42 +104,55 @@ AliMUONQADataMakerSim::~AliMUONQADataMakerSim()
 void AliMUONQADataMakerSim::InitHits() 
 {
   /// Initialized hit spectra
-  TH1F* h0 = new TH1F("hHitDetElem", "DetElemId distribution in Hits", 1400, 100., 1500.); 
-  Add2HitsList(h0, 0);
+  const Bool_t expert   = kTRUE ; 
+  const Bool_t image    = kTRUE ; 
+  
+  TH1F* h0 = new TH1F("hHitDetElem", "DetElemId distribution in Hits;Detection element Id;Counts", 1400, 100., 1500.); 
+  Add2HitsList(h0, 0, !expert, image);
 
-  TH1F* h1 = new TH1F("hHitPtot", "P distribution in Hits ", 300, 0., 300.); 
-  Add2HitsList(h1, 1);
-  return;
+  TH1F* h1 = new TH1F("hHitPtot", "P distribution in Hits;P [erg];Counts ", 300, 0., 300.); 
+  Add2HitsList(h1, 1, !expert, image);
+  //
+  ClonePerTrigClass(AliQAv1::kHITS); // this should be the last line
 } 
 
 //__________________________________________________________________
 void AliMUONQADataMakerSim::InitSDigits() 
 {
   /// Initialized SDigits spectra
-  TH1I* h0 = new TH1I("hSDigitsDetElem", "Detection element distribution in SDigits",  1400, 100, 1500)
-  Add2SDigitsList(h0, 0);
-
-  TH1F* h1 = new TH1F("hSDigitsCharge", "Charge distribution in SDigits", 4096, 0, 4095); 
-  Add2SDigitsList(h1, 1);
+  const Bool_t expert   = kTRUE 
+  const Bool_t image    = kTRUE ; 
+  
+  TH1I* h0 = new TH1I("hSDigitsDetElem", "Detection element distribution in SDigits;Detection element Id;Counts",  1400, 100, 1500); 
+  Add2SDigitsList(h0, 0, !expert, image);
 
+  TH1F* h1 = new TH1F("hSDigitsCharge", "Charge distribution in SDigits;Charge [??];Counts", 4096, 0, 4095); 
+  Add2SDigitsList(h1, 1, !expert, image);
+  //
+  ClonePerTrigClass(AliQAv1::kSDIGITS); // this should be the last line
 }  
 
 //__________________________________________________________________
 void AliMUONQADataMakerSim::InitDigits() 
 {
   /// Initialized Digits spectra 
-  TH1I* h0 = new TH1I("hDigitsDetElem", "Detection element distribution in Digits",  1400, 100, 1500)
-  Add2DigitsList(h0, 0);
-
-  TH1I* h1 = new TH1I("hDigitsADC", "ADC distribution in Digits", 4096, 0, 4095); 
-  Add2DigitsList(h1, 1);  
+  const Bool_t expert   = kTRUE 
+  const Bool_t image    = kTRUE ; 
+  
+  TH1I* h0 = new TH1I("hDigitsDetElem", "Detection element distribution in Digits;Detection element Id;Counts",  1400, 100, 1500); 
+  Add2DigitsList(h0, 0, !expert, image);
 
+  TH1I* h1 = new TH1I("hDigitsADC", "ADC distribution in Digits;ACD value;Counts", 4096, 0, 4095); 
+  Add2DigitsList(h1, 1, !expert, image);  
+  //
+  ClonePerTrigClass(AliQAv1::kDIGITS); // this should be the last line
 } 
 
 //__________________________________________________________________
 void AliMUONQADataMakerSim::MakeHits(TTree* hitsTree)        
 {
   /// makes data from Hits
+
   if (!fHitStore)
     fHitStore = AliMUONVHitStore::Create(*hitsTree);
   fHitStore->Connect(*hitsTree, false);
@@ -151,17 +164,20 @@ void AliMUONQADataMakerSim::MakeHits(TTree* hitsTree)
 
   while ( ( hit = static_cast<AliMUONHit*>(next()) ) )
   {
-    GetHitsData(0)->Fill(hit->DetElemId());
-    GetHitsData(1)->Fill(hit->Momentum());
+    FillHitsData(0,hit->DetElemId());
+    FillHitsData(1,hit->Momentum());
   }
-
-  
+  //
+  IncEvCountCycleHits();
+  IncEvCountTotalHits();
+  //
 }
 
 //__________________________________________________________________
 void AliMUONQADataMakerSim::MakeSDigits(TTree* sdigitsTree)        
 {
   /// makes data from SDigits
+
   if (!fDigitStore)
     fDigitStore = AliMUONVDigitStore::Create(*sdigitsTree);
   fDigitStore->Connect(*sdigitsTree, false);
@@ -173,15 +189,20 @@ void AliMUONQADataMakerSim::MakeSDigits(TTree* sdigitsTree)
 
   while ( ( dig = static_cast<AliMUONVDigit*>(next()) ) )
   {
-    GetSDigitsData(0)->Fill(dig->DetElemId());
-    GetSDigitsData(1)->Fill(dig->Charge());
+    FillSDigitsData(0,dig->DetElemId());
+    FillSDigitsData(1,dig->Charge());
   }
+  //
+  IncEvCountCycleSDigits();
+  IncEvCountTotalSDigits();
+  //
 } 
 
 //__________________________________________________________________
 void AliMUONQADataMakerSim::MakeDigits(TTree* digitsTree)         
 {
    /// makes data from Digits
+  
   if (!fDigitStore)
     fDigitStore = AliMUONVDigitStore::Create(*digitsTree);
   fDigitStore->Connect(*digitsTree, false);
@@ -193,9 +214,13 @@ void AliMUONQADataMakerSim::MakeDigits(TTree* digitsTree)
 
   while ( ( dig = static_cast<AliMUONVDigit*>(next()) ) )
   {
-    GetDigitsData(0)->Fill(dig->DetElemId());
-    GetDigitsData(1)->Fill(dig->ADC());
+    FillDigitsData(0,dig->DetElemId());
+    FillDigitsData(1,dig->ADC());
   }
+  //
+  IncEvCountCycleDigits();
+  IncEvCountTotalDigits();
+  //
 }
       
 //____________________________________________________________________________ 
@@ -203,7 +228,8 @@ void AliMUONQADataMakerSim::EndOfDetectorCycle(AliQAv1::TASKINDEX_t task, TObjAr
 {
     ///Detector specific actions at end of cycle
     // do the QA checking
-    AliQAChecker::Instance()->Run(AliQAv1::kMUON, task, list) ;  
+  ResetEventTrigClasses();
+  AliQAChecker::Instance()->Run(AliQAv1::kMUON, task, list) ;  
 }