<commit_before>#include "AliRunAnalysis.h"
//________________________________
///////////////////////////////////////////////////////////
//
// class AliRunAnalysis
//
//
//
// <EMAIL>
//
///////////////////////////////////////////////////////////

#include <stdlib.h>

#include <TString.h>
#include <TObjString.h>
#include <TClass.h>
#include <TFile.h>
#include <TKey.h>
#include <TObjArray.h>

#include <AliRun.h>
#include <AliRunLoader.h>
#include <AliStack.h>
#include <AliESDtrack.h>
#include <AliESD.h>


#include "AliEventCut.h"
#include "AliReader.h"
#include "AliVAODParticle.h"


ClassImp(AliRunAnalysis)
AliRunAnalysis::AliRunAnalysis():
 TTask("RunAnalysis","Alice Analysis Manager")	,
 fReader(0x0),
 fEventCut(0x0),
 fCutOnSim(kFALSE),
 fCutOnRec(kTRUE)
{
  //ctor
}
/*********************************************************/

AliRunAnalysis::~AliRunAnalysis()
{
  //dtor
  delete fReader;
  delete fEventCut;
}
/*********************************************************/

Int_t AliRunAnalysis::Run()
{
 //makes analysis

  if (fReader == 0x0)
   {
     Error("Run","Reader is not set");
     return 1;
   }
  TDirectory* cwd = gDirectory; 
 /******************************/ 
 /*  Init Event                */ 
 /******************************/ 
 for (Int_t an = 0; an < fAnalysies.GetEntries(); an++)
  {
      AliAnalysis* analysis = (AliAnalysis*)fAnalysies.At(an);
      analysis->Init();
  }
 
 while (fReader->Next() == kFALSE)
  {
   AliAOD* eventsim = fReader->GetEventSim();
   AliAOD* eventrec = fReader->GetEventRec();
   
      /******************************/ 
      /*  Event Cut                 */ 
      /******************************/ 
      if ( Rejected(eventrec,eventsim) )
       {
         if (AliVAODParticle::GetDebug()) Info("Run","Event rejected by Event Cut");
         continue; //Did not pass the 
       }
      /******************************/ 
      /*  Process Event             */ 
      /******************************/ 
      for (Int_t an = 0; an < fAnalysies.GetEntries(); an++)
       {
           AliAnalysis* analysis = (AliAnalysis*)fAnalysies.At(an);
           analysis->ProcessEvent(eventrec,eventsim);
       }
    
  }//end of loop over events

 /******************************/ 
 /*  Finish Event              */ 
 /******************************/ 
 if (cwd) cwd->cd();
 for (Int_t an = 0; an < fAnalysies.GetEntries(); an++)
  {
      AliAnalysis* analysis = (AliAnalysis*)fAnalysies.At(an);
      analysis->Finish();
  }

 return 0;   
}
/*********************************************************/

void  AliRunAnalysis::Add(AliAnalysis* a)
{<commit_msg>Cosmetic correction<commit_after>#include "AliRunAnalysis.h"
//________________________________
///////////////////////////////////////////////////////////
//
// class AliRunAnalysis
//
//
//
// <EMAIL>
//
///////////////////////////////////////////////////////////

#include <stdlib.h>

#include <TString.h>
#include <TObjString.h>
#include <TClass.h>
#include <TFile.h>
#include <TKey.h>
#include <TObjArray.h>

#include <AliRun.h>
#include <AliRunLoader.h>
#include <AliStack.h>
#include <AliESDtrack.h>
#include <AliESD.h>


#include "AliEventCut.h"
#include "AliReader.h"
#include "AliVAODParticle.h"


ClassImp(AliRunAnalysis)
AliRunAnalysis::AliRunAnalysis():
 TTask("RunAnalysis","Alice Analysis Manager")	,
 fReader(0x0),
 fEventCut(0x0),
 fCutOnSim(kFALSE),
 fCutOnRec(kTRUE)
{
  //ctor
}
/*********************************************************/

AliRunAnalysis::~AliRunAnalysis()
{
  //dtor
  delete fReader;
  delete fEventCut;
}
/*********************************************************/

Int_t AliRunAnalysis::Run()
{
 //makes analysis

  if (fReader == 0x0)
   {
     Error("Run","Reader is not set");
     return 1;
   }
  TDirectory* cwd = gDirectory; 
 /******************************/ 
 /*  Init Event                */ 
 /******************************/ 
 for (Int_t an = 0; an < fAnalysies.GetEntries(); an++)
  {
      AliAnalysis* analysis = (AliAnalysis*)fAnalysies.At(an);
      analysis->Init();
  }
 
 while (fReader->Next() == kFALSE)
  {
     AliAOD* eventrec = fReader->GetEventRec();
     AliAOD* eventsim = fReader->GetEventSim();

     /******************************/ 
     /*  Event Cut                 */ 
     /******************************/ 
     if ( Rejected(eventrec,eventsim) )
      {
        if (AliVAODParticle::GetDebug()) Info("Run","Event rejected by Event Cut");
        continue; //Did not pass the 
      }
     /******************************/ 
     /*  Process Event             */ 
     /******************************/ 
     for (Int_t an = 0; an < fAnalysies.GetEntries(); an++)
      {
          AliAnalysis* analysis = (AliAnalysis*)fAnalysies.At(an);
          analysis->ProcessEvent(eventrec,eventsim);
      }
    
  }//end of loop over events

 /******************************/ 
 /*  Finish Event              */ 
 /******************************/ 
 if (cwd) cwd->cd();
 for (Int_t an = 0; an < fAnalysies.GetEntries(); an++)
  {
      AliAnalysis* analysis = (AliAnalysis*)fAnalysies.At(an);
      analysis->Finish();
  }

 return 0;   
}
/*********************************************************/

void  AliRunAnalysis::Add(AliAnalysis* a)
{
{'fraction_non_alphanumeric': 0.33072070349837507, 'fraction_numerical': 0.004205696807493787, 'mean_word_length': 2.6923076923076925, 'pattern_counts': {'":': 0, '<': 35, '<?xml version=': 0, '>': 43, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2331068', 'n_tokens_mistral': 1617, 'n_tokens_neox': 1539, 'n_words': 289}