bug fix + offset centrality train
authorsnelling <snelling@f7af4fe6-9843-0410-8265-dc069ae4e863>
Thu, 11 Nov 2010 21:40:58 +0000 (21:40 +0000)
committersnelling <snelling@f7af4fe6-9843-0410-8265-dc069ae4e863>
Thu, 11 Nov 2010 21:40:58 +0000 (21:40 +0000)
PWG2/FLOW/AliFlowTasks/AliAnalysisTaskQAflow.cxx
PWG2/FLOW/macros/AddTaskFlowCentrality.C
PWG2/FLOW/macros/runFlowTaskCentralityTrain.C

index 9900d1b..5ccfb93 100644 (file)
@@ -123,7 +123,6 @@ void AliAnalysisTaskQAflow::UserCreateOutputObjects()
   //post data here as it doesn't change anyway (the pointer to list anyway)
 
   //restore dir add status
-  PostData(0, fNtuple);
   PostData(1, fOutput);
   PostData(2, fNtuple);
 }
index 814c657..d423712 100644 (file)
@@ -586,13 +586,13 @@ void AddTaskFlowCentrality( Int_t refMultMin=0,
                                             AliAnalysisManager::kOutputContainer,
                                             taskQAoutputFileName);
   AliAnalysisDataContainer* coutputQAtaskTree = mgr->CreateContainer(Form("flowQAntuple_%i",binnumber),
-                                            TTree::Class(),
+                                            TNtuple::Class(),
                                             AliAnalysisManager::kOutputContainer,
                                             taskQAoutputFileName);
   mgr->ConnectInput(taskQAflow,0,mgr->GetCommonInputContainer());
   mgr->ConnectInput(taskQAflow,1,coutputFE);
-  mgr->ConnectOutput(taskQAflow,0,coutputQAtaskTree);
   mgr->ConnectOutput(taskQAflow,1,coutputQAtask);
+  mgr->ConnectOutput(taskQAflow,2,coutputQAtaskTree);
 }
 
 
index ce65d00..e07a06c 100644 (file)
@@ -8,6 +8,8 @@ enum anaModes {mLocal,mLocalPAR,mPROOF,mGrid,mGridPAR};
 //          (Remark: when using this mode set also Bool_t bUseParFiles = kTRUE; in CreateAlienHandler.C)
  
 // CENTRALITY DEFINITION
+Int_t binfirst = 0;  //where do we start numbering bins
+Int_t binlast = 8;  //where do we stop numbering bins
 const Int_t numberOfCentralityBins = 9;
 Int_t centralityArray[numberOfCentralityBins+1] = {41,80,146,245,384,576,835,1203,1471,10000}; // in terms of reference multiplicity
 TString commonOutputFileName = "outputCentrality"; // e.g.: result for centrality bin 0 will be in the file "outputCentrality0.root", etc
@@ -57,7 +59,7 @@ void runFlowTaskCentralityTrain(Int_t mode = mPROOF, Int_t nRuns = 50000000,
   gROOT->LoadMacro("AddTaskFlowCentrality.C");
   
   // Setup analysis per centrality bin:
-  for (Int_t i=0; i<numberOfCentralityBins; i++)
+  for (Int_t i=binfirst; i<binlast+1; i++)
   {
     Int_t lowCentralityBinEdge = centralityArray[i];
     Int_t highCentralityBinEdge = centralityArray[i+1];