- phys selection for AOD>070 - Expected signal for reconstructed ID
authorlmilano <lmilano@f7af4fe6-9843-0410-8265-dc069ae4e863>
Mon, 11 Jun 2012 11:57:01 +0000 (11:57 +0000)
committerlmilano <lmilano@f7af4fe6-9843-0410-8265-dc069ae4e863>
Mon, 11 Jun 2012 11:57:01 +0000 (11:57 +0000)
PWGLF/SPECTRA/PiKaPr/TestAOD/AliSpectraAODEventCuts.cxx
PWGLF/SPECTRA/PiKaPr/TestAOD/AliSpectraAODTrackCuts.h
PWGLF/SPECTRA/PiKaPr/TestAOD/MainAnalysis.C
PWGLF/SPECTRA/PiKaPr/TestAOD/QAPlots.C
PWGLF/SPECTRA/PiKaPr/TestAOD/runAODProof.C
PWGLF/SPECTRA/PiKaPr/TestAOD/runGrid.C

index 352041e..bcd9ea9 100644 (file)
@@ -62,8 +62,11 @@ Bool_t AliSpectraAODEventCuts::IsSelected(AliAODEvent * aod,AliSpectraAODTrackCu
   fAOD = aod;
   fTrackCuts = trackcuts;
   fHistoCuts->Fill(kProcessedEvents);
-  Bool_t isSelected = (((AliInputEventHandler*)(AliAnalysisManager::GetAnalysisManager()->GetInputEventHandler()))->IsEventSelected());//FIXME we can add the trigger mask here
+  Printf("\n\n\n\n\n\n\nProcessed");
+  Bool_t isSelected = (((AliInputEventHandler*)(AliAnalysisManager::GetAnalysisManager()->GetInputEventHandler()))->IsEventSelected() & AliVEvent::kMB);//FIXME we can add the trigger mask here
+  Printf("\n\n\n\n\n\n\nPHYSICS SELECTION:     %i",isSelected);
   if(!isSelected)return isSelected;
+  fHistoCuts->Fill(kPhysSelEvents);
   //loop on tracks, before event selection, filling QA histos
   AliAODVertex * vertex = fAOD->GetPrimaryVertex();//FIXME vertex is recreated
   if(vertex)fHistoVtxBefSel->Fill(vertex->GetZ());
index c398c9f..334f025 100644 (file)
@@ -73,6 +73,7 @@ class AliSpectraAODTrackCuts : public TNamed
    void SetPtTOFMatching(Float_t pt)     { fPtCutTOFMatching = pt; }
    void SetQvecMin(Float_t qvecmin)     { fQvecCutMin = qvecmin; }
    void SetQvecMax(Float_t qvecmax)     { fQvecCutMax = qvecmax; }
+   void SetTrackBits(UInt_t TrackBits) {fTrackBits=TrackBits;}
    Float_t GetEta()       const    { return fEtaCut; }
    Float_t GetY()         const    { return fYCut; }
    Float_t GetDCA()       const    { return fDCACut; }
index 4c4dbc6..8895c9a 100644 (file)
@@ -45,9 +45,11 @@ void MainAnalysis()  {
   mass[1]   = TDatabasePDG::Instance()->GetParticle("K+")->Mass();
   mass[2] = TDatabasePDG::Instance()->GetParticle("proton")->Mass();
   
-  TString fold="3SigmaPID_AOD048-049_FilterBit5";
+  //TString fold="3SigmaPID_AOD048-049_FilterBit5";
+  TString fold="3SigmaPID_AOD048-049_FilterBit1";
   //TString fold="3SigmaPID_AOD086-090_FilterBit10";
   //TString fold="3SigmaPID_AOD086-090_FilterBit7";
+  //TString fold="3SigmaPID_AOD086-090_FilterBit1";
   Int_t ibinToCompare=-1;
   
   TString sname="Cent0to5_QVec0.0to100.0";ibinToCompare=0;
index 915abcf..c704f73 100644 (file)
@@ -105,12 +105,12 @@ void QAPlots( AliSpectraAODHistoManager* hman_data, AliSpectraAODHistoManager* h
   //Track selection in data and Monte Carlo
   TCanvas *cTrackCuts=new TCanvas("TrackCuts","TrackCuts",700,500);
   cTrackCuts->Divide(1,2);
-  TH1F *hTrCuts_data=new TH1F("hTrCuts_data","hTrCuts_data",11,0,11);
+  TH1F *hTrCuts_data=new TH1F("hTrCuts_data","hTrCuts_data",20,0,20);
   for(Int_t ibin=1;ibin<=tcuts_data->GetHistoCuts()->GetNbinsX();ibin++){
     hTrCuts_data->SetBinContent(ibin,tcuts_data->GetHistoCuts()->GetBinContent(ibin)/tcuts_data->GetHistoCuts()->GetBinContent(6));
     hTrCuts_data->GetXaxis()->SetBinLabel(ibin,tcuts_data->GetHistoCuts()->GetXaxis()->GetBinLabel(ibin));
   }
-  TH1F *hTrCuts_mc=new TH1F("hTrCuts_mc","hTrCuts_mc",11,0,11);
+  TH1F *hTrCuts_mc=new TH1F("hTrCuts_mc","hTrCuts_mc",20,0,20);
   for(Int_t ibin=1;ibin<=tcuts_mc->GetHistoCuts()->GetNbinsX();ibin++){
     hTrCuts_mc->SetBinContent(ibin,tcuts_mc->GetHistoCuts()->GetBinContent(ibin)/tcuts_mc->GetHistoCuts()->GetBinContent(6));
     hTrCuts_mc->GetXaxis()->SetBinLabel(ibin,tcuts_mc->GetHistoCuts()->GetXaxis()->GetBinLabel(ibin));
@@ -177,6 +177,39 @@ void QAPlots( AliSpectraAODHistoManager* hman_data, AliSpectraAODHistoManager* h
   gPad->SetGridx();
   PIDSig_mc->DrawClone("colz");
 
+  
+  //dedx in data and MC (Only TPC with reconstructed ID)
+  TCanvas *cPIDSig=new TCanvas("cPIDSigRec","cPIDSigRec",700,500);
+  cPIDSig->Divide(2,1);
+  cPIDSig->cd(1);
+  TH2F *PIDSig_data = (TH2F*)((TH2F*)hman_data->GetPIDHistogram("hHistPIDTPC"))->Clone();
+  PIDSig_data->SetYTitle("TPC signal");
+  gPad->SetLogz();
+  gPad->SetGridy();
+  gPad->SetGridx();
+  PIDSig_data->DrawClone("colz");
+  for(Int_t ipart=0;ipart<3;ipart++){
+    TH2F *PIDSig_dataPart = (TH2F*)((TH2F*)hman_data->GetPIDHistogram(Form("hHistPIDTPC%sRec",Particle[ipart].Data())))->Clone();
+    PIDSig_dataPart->SetMarkerColor(ipart+1);
+    PIDSig_dataPart->SetMarkerStyle(22);
+    PIDSig_dataPart->SetMarkerSize(.5);
+    PIDSig_dataPart->DrawClone("same");
+  }
+  cPIDSig->cd(2);
+  TH2F *PIDSig_mc = (TH2F*)((TH2F*)hman_mc->GetPIDHistogram("hHistPIDTPC"))->Clone();
+  PIDSig_mc->SetYTitle("TPC signal");
+  gPad->SetLogz();
+  gPad->SetGridy();
+  gPad->SetGridx();
+  PIDSig_mc->DrawClone("colz");
+  for(Int_t ipart=0;ipart<3;ipart++){
+    TH2F *PIDSig_mcPart = (TH2F*)((TH2F*)hman_mc->GetPIDHistogram(Form("hHistPIDTPC%sRec",Particle[ipart].Data())))->Clone();
+    PIDSig_mcPart->SetMarkerColor(ipart+1);
+    PIDSig_mcPart->SetMarkerStyle(22);
+    PIDSig_mcPart->SetMarkerSize(.5);
+    PIDSig_mcPart->DrawClone("same");
+  }
+  
   //dedx projection in data and MC
   Double_t Proj1[2]={0.6,0.7};
   Double_t Proj2[2]={1.1,1.2};
index 6e7bb01..66a8871 100644 (file)
@@ -1,4 +1,4 @@
-void runAODProof(Int_t c=3, const char * proofMode = "full")
+void runAODProof(Int_t c=2, const char * proofMode = "full")
 { //1 data AOD049
   //2 MC AOD048
   //3 data AOD086
@@ -42,11 +42,13 @@ void runAODProof(Int_t c=3, const char * proofMode = "full")
   }
   if (c == 3){
     //handler->SetProofDataSet("/default/lmilano/LHC10h_000138653_AOD086_p2#aodTree|/default/lmilano/LHC10h_000138662_AOD086_p2#aodTree|/default/lmilano/LHC10h_000138666_AOD086_p2#aodTree|/default/lmilano/LHC10h_000139107_AOD086_p2#aodTree|/default/lmilano/LHC10h_000138275_AOD086_p2#aodTree");      
-    handler->SetProofDataSet("/default/lmilano/LHC10h_000138275_AOD086_p2#aodTree");      
+    handler->SetProofDataSet("/default/lmilano/LHC10h_000138653_AOD086_p2#aodTree|/default/lmilano/LHC10h_000138666_AOD086_p2#aodTree|/default/lmilano/LHC10h_000139107_AOD086_p2#aodTree|/default/lmilano/LHC10h_000138275_AOD086_p2#aodTree");      
+    //handler->SetProofDataSet("/default/lmilano/LHC10h_000138275_AOD086_p2#aodTree");      
   }
   if (c == 4){
-    //handler->SetProofDataSet("/default/lmilano/LHC11a10a_bis_138653_AOD090#aodTree|/default/lmilano/LHC11a10a_bis_138662_AOD090#aodTree|/default/lmilano/LHC11a10a_bis_138666_AOD090#aodTree|/default/lmilano/LHC11a10a_bis_139107_AOD090#aodTree|/default/lmilano/LHC11a10a_bis_138653_AOD090#aodTree");      
-    handler->SetProofDataSet("/default/lmilano/LHC11a10a_bis_138653_AOD090#aodTree");      
+    //handler->SetProofDataSet("/default/lmilano/LHC11a10a_bis_138653_AOD090#aodTree|/default/lmilano/LHC11a10a_bis_138662_AOD090#aodTree|/default/lmilano/LHC11a10a_bis_138666_AOD090#aodTree|/default/lmilano/LHC11a10a_bis_139107_AOD090#aodTree|/default/lmilano/LHC11a10a_bis_138275_AOD090#aodTree");      
+    handler->SetProofDataSet("/default/lmilano/LHC11a10a_bis_138653_AOD090#aodTree|/default/lmilano/LHC11a10a_bis_138666_AOD090#aodTree|/default/lmilano/LHC11a10a_bis_139107_AOD090#aodTree|/default/lmilano/LHC11a10a_bis_138275_AOD090#aodTree");      
+    //handler->SetProofDataSet("/default/lmilano/LHC11a10a_bis_138653_AOD090#aodTree");      
   }
    
   gROOT->LoadMacro("AliSpectraAODTrackCuts.cxx+g");
@@ -104,8 +106,8 @@ void runAODProof(Int_t c=3, const char * proofMode = "full")
     //if(c==3 || c==4)tcuts->SetTrackType(10); //AOD 086 & 090. Standard Raa cut
     //if(c==3 || c==4)tcuts->SetTrackType(4); //AOD 086 & 090. Jet analysis
     //if(c==3 || c==4)tcuts->SetTrackType(7); //AOD 086 & 090. TPC Only
-    tcuts->SetTrackType(1);
-    Printf("-------------------- tcuts->GetTrackType() %d",tcuts->GetTrackType());
+    tcuts->SetTrackBits(1);
+    Printf("\n\n\n\n\n\n\n-------------------- tcuts->GetTrackType() %d \n\n\n\n\n\n\n",tcuts->GetTrackType());
     tcuts->SetEta(.8);
     //tcuts->SetDCA(.1);
     tcuts->SetPt(5);
index c8451dc..a673ff3 100644 (file)
@@ -1,7 +1,7 @@
 class  AliAnalysisManager;
 class  AliAnalysisAlien;
 
-void runGrid(TString mode="terminate",Int_t mc=1,Int_t sub=1,Int_t hi=1,TString fname="AODAnalysis_6June2012") 
+void runGrid(TString mode="test",Int_t mc=0,Int_t sub=1,Int_t hi=1,TString fname="AODAnalysis_6June2012") 
 {
   //0 is AOD048-049 in this case you can choos FilterBit5 (loose DCA) or 6 (tight DCA)!!!!!!!!!
   //1 is AOD086-090
@@ -51,7 +51,7 @@ void runGrid(TString mode="terminate",Int_t mc=1,Int_t sub=1,Int_t hi=1,TString
   //setting the analysis
   Int_t iCut=0;
   //Double_t CentCut[2]={0,100};
-  Double_t CentCut[2]={0,5};
+  Double_t CentCut[2]={0,100};
   Double_t qVecCut[2]={0,100};
    
   //PID object
@@ -67,11 +67,12 @@ void runGrid(TString mode="terminate",Int_t mc=1,Int_t sub=1,Int_t hi=1,TString
   // Set the cuts
   AliSpectraAODEventCuts * vcuts = new AliSpectraAODEventCuts("Event Cuts");
   AliSpectraAODTrackCuts  * tcuts = new AliSpectraAODTrackCuts("Track Cuts");
-  if(sub==0){
-    tcuts->SetTrackType(5); //AOD 046 & 047. Standard Cuts with loose DCA
+  //if(sub==0){
+    //tcuts->SetTrackType(5); //AOD 046 & 047. Standard Cuts with loose DCA
     //tcuts->SetTrackType(6); //AOD 046 & 047. Standard Cuts with tight DCA
-  }
-  if(sub==1)tcuts->SetTrackType(10); //AOD 086 & 090. Standard Raa cuts
+  //}
+  //if(sub==1)tcuts->SetTrackType(10); //AOD 086 & 090. Standard Raa cuts
+  tcuts->SetTrackBits(1); 
   
   // set pid object
   task->SetPID(pid);