X-Git-Url: http://git.uio.no/git/?a=blobdiff_plain;f=FMD%2FAliFMDQADataMakerSim.cxx;h=9f69ff5104bb993fcd4be59a6f1aae69f6622385;hb=047a3d66caababb37f4d1228dfef76f98b1670c2;hp=4e422b4713ffbc90c210cfc613880347137506dd;hpb=f2597905eb67c24eccdfc2766a88fbb587fbc547;p=u%2Fmrichter%2FAliRoot.git diff --git a/FMD/AliFMDQADataMakerSim.cxx b/FMD/AliFMDQADataMakerSim.cxx index 4e422b4713f..9f69ff5104b 100644 --- a/FMD/AliFMDQADataMakerSim.cxx +++ b/FMD/AliFMDQADataMakerSim.cxx @@ -57,14 +57,15 @@ AliFMDQADataMakerSim::AliFMDQADataMakerSim() AliFMDQADataMakerSim::AliFMDQADataMakerSim(const AliFMDQADataMakerSim& /*qadm*/) : AliQADataMakerSim() { - //copy ctor - + // copy ctor + // // Parameters: // qadm Object to copy from } //_____________________________________________________________________ -AliFMDQADataMakerSim& AliFMDQADataMakerSim::operator = (const AliFMDQADataMakerSim& ) +AliFMDQADataMakerSim& +AliFMDQADataMakerSim::operator = (const AliFMDQADataMakerSim& ) { return *this; @@ -81,6 +82,7 @@ void AliFMDQADataMakerSim::EndOfDetectorCycle(AliQAv1::TASKINDEX_t task, { //Detector specific actions at end of cycle // do the QA checking + ResetEventTrigClasses(); // reset triggers list to select all histos AliLog::Message(5,"FMD: end of detector cycle", "AliFMDQADataMakerSim","AliFMDQADataMakerSim", "AliFMDQADataMakerSim::EndOfDetectorCycle", @@ -95,9 +97,13 @@ void AliFMDQADataMakerSim::InitSDigits() const Bool_t expert = kTRUE ; const Bool_t image = kTRUE ; - TH1I* hADCCounts = new TH1I("hADCCounts","Dist of ADC counts;ADC counts;Entries",1024,0,1024); + TH1I* hADCCounts = new TH1I("hADCCounts", + "Dist of ADC counts;ADC counts;Entries", + 1024,0,1024); hADCCounts->SetXTitle("ADC counts"); Add2SDigitsList(hADCCounts, 0, !expert, image); + // + ClonePerTrigClass(AliQAv1::kSDIGITS); // this should be the last line } //____________________________________________________________________ @@ -107,10 +113,14 @@ void AliFMDQADataMakerSim::InitHits() const Bool_t expert = kTRUE ; const Bool_t image = kTRUE ; - TH1F* hEnergyOfHits = new TH1F("hEnergyOfHits","Energy distribution;Energy [MeV];Counts",100,0,3); + TH1F* hEnergyOfHits = new TH1F("hEnergyOfHits", + "Energy distribution;Energy [MeV];Counts", + 100,0,3); hEnergyOfHits->SetXTitle("Edep"); hEnergyOfHits->SetYTitle("Counts"); Add2HitsList(hEnergyOfHits, 0, !expert, image); + // + ClonePerTrigClass(AliQAv1::kHITS); // this should be the last line } //_____________________________________________________________________ @@ -120,9 +130,13 @@ void AliFMDQADataMakerSim::InitDigits() const Bool_t expert = kTRUE ; const Bool_t image = kTRUE ; - TH1I* hADCCounts = new TH1I("hADCCounts","Dist of ADC counts; ADC counts;Entries",1024,0,1024); + TH1I* hADCCounts = new TH1I("hADCCounts", + "Dist of ADC counts; ADC counts;Entries", + 1024,0,1024); hADCCounts->SetXTitle("ADC counts"); Add2DigitsList(hADCCounts, 0, !expert, image); + // + ClonePerTrigClass(AliQAv1::kDIGITS); // this should be the last line } //_____________________________________________________________________ @@ -134,19 +148,21 @@ void AliFMDQADataMakerSim::MakeHits() TIter next(fHitsArray); AliFMDHit * hit; - while ((hit = static_cast(next()))) - GetHitsData(0)->Fill(hit->Edep()/hit->Length()*0.032); + while ((hit = static_cast(next()))) FillHitsData(0,hit->Edep()/hit->Length()*0.032); + // } //_____________________________________________________________________ void AliFMDQADataMakerSim::MakeHits(TTree * hitTree) { // make QA data from Hit Tree - - if (fHitsArray) - fHitsArray->Clear() ; - else + // + // Parameters: + // hitTree Hits container + // + if (!fHitsArray) fHitsArray = new TClonesArray("AliFMDHit", 1000) ; + fHitsArray->Clear() ; TBranch * branch = hitTree->GetBranch("FMD") ; if (!branch) { @@ -155,35 +171,47 @@ void AliFMDQADataMakerSim::MakeHits(TTree * hitTree) } branch->SetAddress(&fHitsArray) ; - + // for (Int_t ientry = 0 ; ientry < branch->GetEntries() ; ientry++) { branch->GetEntry(ientry); MakeHits(); //tmp); fHitsArray->Clear() ; - } + } + // + IncEvCountCycleHits(); + IncEvCountTotalHits(); + // } //_____________________________________________________________________ void AliFMDQADataMakerSim::MakeDigits() { // makes data from Digits + // + // Parameters: + // none if(!fDigitsArray) return; for(Int_t i = 0 ; i < fDigitsArray->GetEntriesFast() ; i++) { //Raw ADC counts AliFMDDigit* digit = static_cast(fDigitsArray->At(i)); - GetDigitsData(0)->Fill(digit->Counts()); + FillDigitsData(0,digit->Counts()); } + // } //_____________________________________________________________________ void AliFMDQADataMakerSim::MakeDigits(TTree * digitTree) { + // Make data from digits. + // + // Parameters: + // digitTree Tree holding digits. + // RS: counters are incremented in MakeDigits() - if (fDigitsArray) - fDigitsArray->Clear(); - else + if (!fDigitsArray) fDigitsArray = new TClonesArray("AliFMDDigit", 1000) ; + fDigitsArray->Clear(); TBranch * branch = digitTree->GetBranch("FMD") ; if (!branch) { @@ -191,31 +219,46 @@ void AliFMDQADataMakerSim::MakeDigits(TTree * digitTree) return; } branch->SetAddress(&fDigitsArray) ; + + if (fDigitsArray) fDigitsArray->Clear(); + branch->GetEntry(0) ; MakeDigits() ; + // + IncEvCountCycleDigits(); + IncEvCountTotalDigits(); + // } //_____________________________________________________________________ void AliFMDQADataMakerSim::MakeSDigits() { // makes data from Digits + // + // Parameters: + // none if(!fSDigitsArray) return; - for(Int_t i = 0 ; i < fSDigitsArray->GetEntriesFast() ; i++) { + for(Int_t i = 0 ; i < fSDigitsArray->GetEntriesFast() ; i++) { //Raw ADC counts AliFMDSDigit* sdigit = static_cast(fSDigitsArray->At(i)); - GetSDigitsData(0)->Fill(sdigit->Counts()); + FillSDigitsData(0,sdigit->Counts()); } + // } //_____________________________________________________________________ void AliFMDQADataMakerSim::MakeSDigits(TTree * sdigitTree) { - - if (fSDigitsArray) - fSDigitsArray->Clear() ; - else + // Make data from digits. + // + // Parameters: + // digitTree Tree holding digits. + // + if (!fSDigitsArray) fSDigitsArray = new TClonesArray("AliFMDSDigit", 1000) ; + fSDigitsArray->Clear() ; + TBranch * branch = sdigitTree->GetBranch("FMD") ; if (!branch) { AliWarning("FMD branch in SDigit Tree not found") ; @@ -224,12 +267,19 @@ void AliFMDQADataMakerSim::MakeSDigits(TTree * sdigitTree) branch->SetAddress(&fSDigitsArray) ; branch->GetEntry(0) ; MakeSDigits() ; + // + IncEvCountCycleSDigits(); + IncEvCountTotalSDigits(); + // } //_____________________________________________________________________ void AliFMDQADataMakerSim::StartOfDetectorCycle() { - + // Does + // not + // do + // anything } //_____________________________________________________________________ //