- TCanvas * canvasToTTime = new TCanvas("canvasToTTime", " ToT and Time ",400, 30, 550, 630) ;
- canvasToTTime->Divide(1,2);
- canvasToTTime->cd(1);
- fhToT->SetLineColor(4);
- fhToT->GetXaxis()->SetTitle("ToT (ns)");
- fhToT->Draw("hist");
- canvasToTTime->cd(2);
- fhTime->SetLineColor(4);
- fhTime->GetXaxis()->SetTitle("Time (ns)");
- fhTime->Draw("hist");
- canvasToTTime->Update();
- canvasToTTime->Print("ToTTime.gif");
-
- TCanvas * canvasExpTime = new TCanvas("canvasExpTime", " Expected Times ",400, 30, 550, 630) ;
- canvasExpTime->Divide(1,3);
- canvasExpTime->cd(1);
- fhExpTimePi->SetLineColor(4);
- fhExpTimePi->GetXaxis()->SetTitle("Exp Time (ns), #pi");
- fhExpTimePi->Draw("hist");
- canvasExpTime->cd(2);
- fhExpTimeKa->SetLineColor(4);
- fhExpTimeKa->GetXaxis()->SetTitle("Exp Time (ns), K");
- fhExpTimeKa->Draw("hist");
- canvasExpTime->cd(3);
- fhExpTimePr->SetLineColor(4);
- fhExpTimePr->GetXaxis()->SetTitle("Exp Time (ns), p");
- fhExpTimePr->Draw("hist");
-
- canvasExpTime->Print("ExpTime.gif");
-
- TCanvas * canvasPID = new TCanvas("canvasPID", " Combinatorial PID ",400, 30, 550, 400);
- fhPID->GetXaxis()->SetTitle("Comb PID");
- fhPID->GetXaxis()->SetBinLabel(1,"#pi");
- fhPID->GetXaxis()->SetBinLabel(2,"K");
- fhPID->GetXaxis()->SetBinLabel(3,"p");
- fhPID->Draw("hist");
-
- canvasPID->Print("PID.gif");
-
- TCanvas * canvasrndch = new TCanvas("canvasrndch", " TOF channel ",400, 30, 550, 400);
- fhch->GetXaxis()->SetTitle("TOF ch");
- fhch->Draw("hist");
- Float_t meanTOFch = 0;
- for (Int_t ibin=0;ibin<TOFCHANNELS;ibin++){
- meanTOFch+=(Float_t)fhch->GetBinContent(ibin+1);
+ if (!gROOT->IsBatch()){
+
+ fListOfHistos = dynamic_cast<TList*>(GetOutputData(1));
+
+ fhToT = (TH1F*)fListOfHistos->At(0);
+ fhTime = (TH1F*)fListOfHistos->At(1);
+ fhExpTimePi = (TH1F*)fListOfHistos->At(2);
+ fhExpTimeKa = (TH1F*)fListOfHistos->At(3);
+ fhExpTimePr = (TH1F*)fListOfHistos->At(4);
+ fhPID = (TH1I*)fListOfHistos->At(5);
+ fhch = (TH1D*)fListOfHistos->At(6);
+
+ fhESD = (TH1I*)fListOfHistos->At(7);
+ fhESDselected = (TH1I*)fListOfHistos->At(8);
+ fhESDkTOFout = (TH1I*)fListOfHistos->At(9);
+ fhESDkTIME = (TH1I*)fListOfHistos->At(10);
+ fhESDassTOFcl = (TH1I*)fListOfHistos->At(11);
+ fhESDTIMEcut = (TH1I*)fListOfHistos->At(12);
+ fhESDTRDcut = (TH1I*)fListOfHistos->At(13);
+
+ TCanvas * canvasToTTime = new TCanvas("canvasToTTime", " ToT and Time ",400, 30, 550, 630) ;
+ canvasToTTime->Divide(1,2);
+ canvasToTTime->cd(1);
+ fhToT->SetLineColor(4);
+ fhToT->GetXaxis()->SetTitle("ToT (ns)");
+ fhToT->DrawCopy("hist");
+ canvasToTTime->cd(2);
+ fhTime->SetLineColor(4);
+ fhTime->GetXaxis()->SetTitle("Time (ns)");
+ fhTime->DrawCopy("hist");
+ canvasToTTime->Update();
+ //canvasToTTime->Print("ToTTime.gif");
+
+ TCanvas * canvasExpTime = new TCanvas("canvasExpTime", " Expected Times ",400, 30, 550, 630) ;
+ canvasExpTime->Divide(1,3);
+ canvasExpTime->cd(1);
+ fhExpTimePi->SetLineColor(4);
+ fhExpTimePi->GetXaxis()->SetTitle("Exp Time (ns), #pi");
+ fhExpTimePi->DrawCopy("hist");
+ canvasExpTime->cd(2);
+ fhExpTimeKa->SetLineColor(4);
+ fhExpTimeKa->GetXaxis()->SetTitle("Exp Time (ns), K");
+ fhExpTimeKa->DrawCopy("hist");
+ canvasExpTime->cd(3);
+ fhExpTimePr->SetLineColor(4);
+ fhExpTimePr->GetXaxis()->SetTitle("Exp Time (ns), p");
+ fhExpTimePr->DrawCopy("hist");
+
+ //canvasExpTime->Print("ExpTime.gif");
+
+ TCanvas * canvasPID = new TCanvas("canvasPID", " Combinatorial PID ",400, 30, 550, 400);
+ canvasPID->cd();
+ fhPID->GetXaxis()->SetTitle("Comb PID");
+ fhPID->GetXaxis()->SetBinLabel(1,"#pi");
+ fhPID->GetXaxis()->SetBinLabel(2,"K");
+ fhPID->GetXaxis()->SetBinLabel(3,"p");
+ fhPID->DrawCopy("hist");
+
+ //canvasPID->Print("PID.gif");
+
+ TCanvas * canvasrndch = new TCanvas("canvasrndch", " TOF channel ",400, 30, 550, 400);
+ canvasrndch->cd();
+ fhch->GetXaxis()->SetTitle("TOF ch");
+ fhch->Draw("hist");
+ Float_t meanTOFch = 0;
+ for (Int_t ibin=0;ibin<TOFCHANNELS;ibin++){
+ meanTOFch+=(Float_t)fhch->GetBinContent(ibin+1);
+ }
+
+ meanTOFch/=TOFCHANNELS;
+ AliDebug(1,Form(" Mean number of tracks/channel = %f ",meanTOFch));
+
+ //canvasrndch->Print("rndch.gif");
+
+ /*
+ char line[1024] ;
+ sprintf(line, ".!tar -zcvf %s.tar.gz *.gif", GetName()) ;
+ gROOT->ProcessLine(line);
+ sprintf(line, ".!rm -fR *.gif");
+ gROOT->ProcessLine(line);
+ AliInfo(Form("*** TOF Calib Task: plots saved in %s.tar.gz...\n", GetName())) ;
+ */
+
+ AliInfo(Form(" Number of analyzed ESD tracks: %i",(Int_t)fhESD->GetEntries()));
+ AliInfo(Form(" Number of selected ESD tracks: %i",(Int_t)fhESDselected->GetEntries()));
+ AliInfo(Form(" Number of ESD tracks with kTOFout: %i",(Int_t)fhESDkTOFout->GetEntries()));
+ AliInfo(Form(" Number of ESD tracks with kTIME: %i",(Int_t)fhESDkTIME->GetEntries()));
+ AliInfo(Form(" Number of ESD tracks with TRDcut: %i",(Int_t)fhESDTRDcut->GetEntries()));
+ AliInfo(Form(" Number of ESD tracks with TIMEcut: %i",(Int_t)fhESDTIMEcut->GetEntries()));
+ AliInfo(Form(" Number of ESD tracks with assTOFcl: %i",(Int_t)fhESDassTOFcl->GetEntries()));