-AliAnalysisTask *AddTaskHFEtpctofPbPb(Bool_t isaod, Bool_t isMC,Int_t aodfilter=-1, Int_t tpcCls=120, Int_t tpcClsPID = 80, Double_t tpcClsRatio = 0.6, Double_t tpcClShared = 1.1, Int_t itsCls=4,Double_t itsChi2PerClusters=36.,Int_t itspixelcut=AliHFEextraCuts::kBoth, Double_t dcaxy=1.0, Double_t dcaz=2.0, Bool_t usetof=kFALSE, Double_t tofs=3.,Bool_t etacor=kFALSE,TString listname="",Double_t tpceff=0.5, Float_t prodlow=0., Float_t prodhigh=100.,Bool_t kMCQA = kFALSE){
+AliAnalysisTask *AddTaskHFEtpctofPbPb(Bool_t isaod, Bool_t isMC,Int_t aodfilter=16,Int_t clusterdef=AliHFEextraCuts::kFoundAll, Int_t clusterrdef=AliHFEextraCuts::kFoundAllOverFindable,Int_t tpcCls=130, Int_t tpcClsPID = 80, Double_t tpcClsRatio = 0.6, Double_t tpcClShared = 1.1, Bool_t rejectkinkmother = kFALSE, Int_t itsCls=4,Double_t itsChi2PerClusters=-1,Int_t itspixelcut=AliHFEextraCuts::kBoth, Double_t dcaxy=1.0, Double_t dcaz=2.0, Bool_t usetof=kTRUE, Double_t tofs=3.,Bool_t etacor=kFALSE,TString listname="",Double_t tpceff=0.5, Float_t prodlow=0., Float_t prodhigh=3.,Bool_t kNoPhotonic = kTRUE){
// libraries in case
gSystem->Load("libANALYSIS.so");
//set config file name
- //TString configFile("$ALICE_ROOT/PWGHF/hfe/macros/configs/PbPb/ConfigHFEpbpb.C");
- TString configFile("/d/alice12/bailhache/AliRootInstallations/07_10_2012/AliRoot/PWGHF/hfe/macros/configs/PbPb/ConfigHFEpbpb.C");
+ TString configFile("$ALICE_ROOT/PWGHF/hfe/macros/configs/PbPb/ConfigHFEpbpb.C");
+ //TString configFile("/d/alice12/bailhache/AliRootInstallations/07_10_2012/AliRoot/PWGHF/hfe/macros/configs/PbPb/ConfigHFEpbpb.C");
TString checkconfig="ConfigHFEpbpb";
if (!gROOT->GetListOfGlobalFunctions()->FindObject(checkconfig.Data()))
gROOT->LoadMacro(configFile.Data());
Int_t iprodlow = (Int_t) (prodlow*10);
Int_t iprodhigh = (Int_t) (prodhigh*10);
Int_t itof = 0;
- Int_t iMCQA = 0;
+ Int_t iNoPhotonic = 0;
Int_t ietacor = 0;
Int_t itpceff = (Int_t) (tpceff*10);
+ Int_t irejectkinkmother = 0;
if(usetof) itof=kTRUE;
- if(kMCQA) iMCQA = 1;
+ if(kNoPhotonic) iNoPhotonic = 1;
if(etacor) ietacor = 1;
+ if(rejectkinkmother) irejectkinkmother = 1;
- TString appendix(TString::Format("f%dt%dtp%dtr%dts%di%dic%di%ddcaxy%dz%dtof%dts%de%dtpc%dprodlow%dhigh%dmc%d",aodfilter,tpcCls,tpcClsPID,itpcClsRatio,itpcClShared,itsCls,iitsChi2PerClusters,itspixelcut,idcaxy,idcaz,itof,itofs,ietacor,itpceff,iprodlow,iprodhigh,iMCQA));
+ TString appendix(TString::Format("f%dcd%dcr%dt%dtp%dtr%dts%dkm%di%dic%di%ddcaxy%dz%dtof%dts%de%dtpc%dprodlow%dhigh%dnhfe%d",aodfilter,clusterdef,clusterrdef,tpcCls,tpcClsPID,itpcClsRatio,itpcClShared,irejectkinkmother,itsCls,iitsChi2PerClusters,itspixelcut,idcaxy,idcaz,itof,itofs,ietacor,itpceff,iprodlow,iprodhigh,iNoPhotonic));
printf("appendix %s\n", appendix.Data());
if (inputDataType == "AOD") isaod = kTRUE;
- // TPC cut
+ // TPC cut 2010
// 0-5,5-10,10-20,20-30,30-40,40-50,50-60,60-70,70-80,80-90,90-100,one more per history
// http://www.physi.uni-heidelberg.de/~pachmay/projects/hfe/pid/tpc/
// without eta correction 50%
// Task
AliAnalysisDataContainer *cinput = mgr->GetCommonInputContainer();
- AliAnalysisTaskHFE *task = ConfigHFEpbpb(isaod,isMC,appendix,aodfilter,tpcCls,tpcClsPID,tpcClsRatio,tpcClShared,itsCls,itsChi2PerClusters,itspixelcut,dcaxy,dcaz,usetof,tofs,etacor,listname,tpcdEdxcutlow,tpcdEdxcuthigh,prodlow,prodhigh,kMCQA);
+ AliAnalysisTaskHFE *task = ConfigHFEpbpb(isaod,isMC,appendix,aodfilter,clusterdef,clusterrdef,tpcCls,tpcClsPID,tpcClsRatio,tpcClShared,irejectkinkmother,itsCls,itsChi2PerClusters,itspixelcut,dcaxy,dcaz,usetof,tofs,etacor,listname,tpcdEdxcutlow,tpcdEdxcuthigh,prodlow,prodhigh,kNoPhotonic);
mgr->AddTask(task);
Bool_t useMC,
TString appendix,
Int_t aodfilter=-1,
+ Int_t clusterdef=AliHFEextraCuts::kFound, Int_t clusterrdef=AliHFEextraCuts::kFoundOverFindable,
UChar_t TPCcl=70, UChar_t TPCclPID = 80,
Double_t TPCclRatio = 0.6, Double_t TPCclshared = 1.1,
+ Bool_t rejectkinkmother = kFALSE,
UChar_t ITScl=3, Double_t ITSchi2perclusters=99999999.,
Int_t itspixelcut=AliHFEextraCuts::kBoth,
Double_t dcaxy=1.0, Double_t dcaz=2.0,
Bool_t etacor=kFALSE,TString listname="",
Double_t* tpcdEdxcutlow=NULL,Double_t* tpcdEdxcuthigh=NULL,
Float_t prodlow=0., Float_t prodhigh=100.,
- Bool_t kMCQA = kFALSE,
+ Bool_t kNoPhotonic = kFALSE,
Int_t nondefaultcentr=0, Float_t* arraycentr=NULL,
Int_t ptbin=0){
//
hfecuts->SetMinNClustersTPC(TPCcl);
hfecuts->SetMinNClustersTPCPID(TPCclPID);
hfecuts->SetMinRatioTPCclusters(TPCclRatio);
- hfecuts->SetTPCmodes(AliHFEextraCuts::kFound, AliHFEextraCuts::kFoundOverFindable);
+ hfecuts->SetTPCmodes(clusterdef, clusterrdef);
hfecuts->SetFractionOfSharedTPCClusters(TPCclshared);
hfecuts->SetMinNClustersITS(ITScl);
//hfecuts->SetTPCPIDCleanUpStep(kTRUE);
hfecuts->SetQAOn();
+ // Background Subtraction
+ AliHFENonPhotonicElectron *backe = new AliHFENonPhotonicElectron(appendix,"Background subtraction");
+ AliESDtrackCuts *hfeBackgroundCuts = new AliESDtrackCuts();
+ hfeBackgroundCuts->SetName("backgroundcuts");
+ //hfeBackgroundCuts->SetAcceptKinkDaughters(kFALSE);
+ hfeBackgroundCuts->SetRequireTPCRefit(kTRUE);
+ hfeBackgroundCuts->SetRequireITSRefit(kTRUE);
+ hfeBackgroundCuts->SetMinNClustersITS(2);
+ hfeBackgroundCuts->SetEtaRange(-0.8,0.8);
+ hfeBackgroundCuts->SetRequireSigmaToVertex(kTRUE);
+ hfeBackgroundCuts->SetMaxChi2PerClusterTPC(3.5);
+ hfeBackgroundCuts->SetMinNClustersTPC(100);
+ hfeBackgroundCuts->SetPtRange(0.3,1e10);
+ AliHFEpid *pidbackground = backe->GetPIDBackground();
+ if(useMC) pidbackground->SetHasMCData(kTRUE);
+ pidbackground->AddDetector("TPC", 1);
+ pidbackground->ConfigureTPCasymmetric(0.0,9999.,-3.,3.);
+ backe->SetHFEBackgroundCuts(hfeBackgroundCuts);
+
+ // task
AliAnalysisTaskHFE *task = new AliAnalysisTaskHFE(appendix);
task->SetHFECuts(hfecuts);
+ task->SetHFEBackgroundSubtraction(backe);
task->SetPbPbAnalysis(kTRUE);
task->SetRemovePileUp(kFALSE);
+ task->SetRejectKinkMother(rejectkinkmother);
task->GetPIDQAManager()->SetHighResolutionHistos();
if(useMC) task->SetHasMCData(kTRUE); // necessary for AOD
printf("AOD filter %d On/OFF?\n",aodfilter);
task->SetUseFilterAOD(kTRUE);
task->SetFilter(aodfilter);
}
+ else {
+ task->SetUseFilterAOD(kFALSE);
+ }
if((nondefaultcentr!=0) && arraycentr) {
// QA
task->SetQAOn(AliAnalysisTaskHFE::kPIDqa);
//task->SetFillSignalOnly(kFALSE); // for DE pluging for MC
- if(kMCQA) task->SetQAOn(AliAnalysisTaskHFE::kMCqa);
+ if(kNoPhotonic) task->SwitchOnPlugin(AliAnalysisTaskHFE::kNonPhotonicElectron);
//task->SwitchOnPlugin(AliAnalysisTaskHFE::kIsElecBackGround);
//task->SwitchOnPlugin(AliAnalysisTaskHFE::kSecVtx);
//task->SwitchOnPlugin(AliAnalysisTaskHFE::kDEstep);