]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - PWGJE/AliAnalysisTaskJetCore.cxx
option to run in current directory
[u/mrichter/AliRoot.git] / PWGJE / AliAnalysisTaskJetCore.cxx
index 273710f53dfa22879e56db499918fa5fe6bc2feb..a9f92cb8650b3e8e5780106ffa4521d6c5fe714b 100644 (file)
@@ -1,4 +1,3 @@
-
 // ******************************************
 // This task computes several jet observables like 
 // the fraction of energy in inner and outer coronnas,
@@ -512,7 +511,7 @@ void AliAnalysisTaskJetCore::UserCreateOutputObjects()
         const Int_t dimSpec = 5;
        const Int_t nBinsSpec[dimSpec]     = {100,6, 140, 50, fNRPBins};
        const Double_t lowBinSpec[dimSpec] = {0,0,-80, 0, 0};
-       const Double_t hiBinSpec[dimSpec]  = {100,1, 200, 50, fNRPBins};
+       const Double_t hiBinSpec[dimSpec]  = {100,1, 200, 50,  static_cast<Double_t>(fNRPBins)};
        fHJetSpec = new THnSparseF("fHJetSpec","Recoil jet spectrum",dimSpec,nBinsSpec,lowBinSpec,hiBinSpec);
 
              //change binning in jet area
@@ -603,7 +602,17 @@ void AliAnalysisTaskJetCore::UserExec(Option_t *)
    // -- event selection --
    fHistEvtSelection->Fill(1); // number of events before event selection
 
-   // physics selection
+
+       Bool_t selected=kTRUE;
+       selected = AliAnalysisHelperJetTasks::Selected();
+       if(!selected){
+      // no selection by the service task, we continue
+       PostData(1,fOutputList);
+       return;}
+    
+
+
+  // physics selection: this is now redundant, all should appear as accepted after service task selection
    AliInputEventHandler* inputHandler = (AliInputEventHandler*)
    ((AliAnalysisManager::GetAnalysisManager())->GetInputEventHandler());
         std::cout<<inputHandler->IsEventSelected()<<" "<<fOfflineTrgMask<<std::endl;
@@ -614,6 +623,8 @@ void AliAnalysisTaskJetCore::UserExec(Option_t *)
       return;
    }
 
+
+      
    // vertex selection
    if(!aod){
      if(fDebug) Printf("%s:%d No AOD",(char*)__FILE__,__LINE__);
@@ -840,7 +851,7 @@ void AliAnalysisTaskJetCore::UserExec(Option_t *)
                    if(phitt<0)phitt+=TMath::Pi()*2.; 
                    Int_t phiBintt = GetPhiBin(phitt-fRPAngle);
 
-                  Double_t fillspec[] = {centValue,jetbig->EffectiveAreaCharged(),ptcorr,partback->Pt(),phiBintt};
+                  Double_t fillspec[] = {centValue,jetbig->EffectiveAreaCharged(),ptcorr,partback->Pt(), static_cast<Double_t>(phiBintt)};
                  fHJetSpec->Fill(fillspec);