--- /dev/null
+void Digits2RecParticles(){
+
+ TFile * fRootFile = TFile::Open("galice.root","update");
+
+ //========== Get AliRun object from file
+ gAlice = (AliRun*) fRootFile->Get("gAlice") ;
+
+ //=========== Get the PHOS object and associated geometry from the file
+ AliPHOSv1 * fPHOS = (AliPHOSv1 *)gAlice->GetDetector("PHOS") ;
+ AliPHOSGeometry * fGeom = AliPHOSGeometry::GetInstance( fPHOS->GetGeometry()->GetName(), fPHOS->GetGeometry()->GetTitle() );
+
+ AliPHOSIndexToObject * fObjGetter = AliPHOSIndexToObject::GetInstance(fPHOS) ;
+
+
+
+ //========== Create the Clusterizer
+ AliPHOSClusterizerv1 * fClu = new AliPHOSClusterizerv1() ;
+
+ //========== Creates the track segment maker
+ AliPHOSTrackSegmentMakerv1 * fTrs = new AliPHOSTrackSegmentMakerv1() ;
+ // fTrs->UnsetUnfoldFlag() ;
+
+ //========== Creates the particle identifier
+ AliPHOSPIDv1* fPID = new AliPHOSPIDv1() ;
+ fPID->SetShowerProfileCuts(0.3, 1.8, 0.3, 1.8 ) ;
+
+ //========== Creates the Reconstructioner
+ AliPHOSReconstructioner * fRec = new AliPHOSReconstructioner(fClu, fTrs, fPID) ;
+ // fRec -> SetDebugReconstruction(kTRUE);
+
+ gAlice->GetEvent(0) ;
+
+ gAlice->TreeD()->GetEvent(0) ;
+
+ //=========== Do the reconstruction
+ fPHOS->Reconstruction(fRec);
+
+
+}
--- /dev/null
+void Hits2SDigits(){
+// gSystem->Setenv("CONFIG_SPLIT_FILE","1") ;
+ if (gSystem->Getenv("CONFIG_SPLIT_FILE"))
+ cout << "SPLIT" << endl;
+ else
+ cout << "NO SPLIT" << endl ;
+ TFile * f = TFile::Open("galice.root","update");
+ gAlice = (AliRun*) f->Get("gAlice") ;
+ AliPHOSv1* fPHOS = (AliPHOSv1 *)gAlice->GetDetector("PHOS") ;
+ fPHOS->Enable() ;
+ gAlice->Hits2SDigits() ;
+
+
+
+}
--- /dev/null
+void SDigits2Digits(){
+// gSystem->Setenv("CONFIG_SPLIT_FILE","1") ;
+
+ TFile * f = TFile::Open("galice.root","update") ;
+ gAlice = (AliRun*) f->Get("gAlice") ;
+ AliPHOSv1* fPHOS = (AliPHOSv1 *)gAlice->GetDetector("PHOS") ;
+ fPHOS->Enable() ;
+ gAlice->SDigits2Digits() ;
+
+
+
+}