#include <TBranch.h>
#include <AliLoader.h>
-#include "AliFMDReconstruction.h"
-
class TClonesArray;
class AliFMD : public AliDetector {
void SetEventNumber(Int_t i) {fEvNrSig = i;}
void Eta2Radius(Float_t, Float_t, Float_t*);
- virtual void Reconstruct() const{ AliFMDReconstruction reco(GetLoader()->GetRunLoader()); reco.Exec();}
// Digitisation
+++ /dev/null
-// Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved.
-// See cxx source for full Copyright notice
-// AliFMDReconstruction.h
-// Task Class for making TreeR in FMD
-//-- Authors: Evgeny Karpechev (INR) and Alla Maevskaia (INR)
-/*
- Reconstruct nember of particles
- in given group of pads for given FMDvolume
- determine by numberOfVolume ,
- numberOfMinSector,numberOfMaxSector,
- numberOfMinRing, numberOfMaxRing
- Reconstruction method choose dependence on number of empty pads
- */
-
-
-#ifndef AliFMDReconstruction_h
-#define AliFMDReconstruction_h
-
-#include "TTask.h"
-class TString;
-class AliFMD;
-
-class AliRunLoader;
-
-class AliFMDReconstruction: public TTask
-{
- public:
- AliFMDReconstruction() ;
- AliFMDReconstruction(AliRunLoader* rl) ;
- virtual ~AliFMDReconstruction();
- virtual void Exec();
- void SetNEvents(Int_t Nevents){fNevents = Nevents;}
- Stat_t GetNEvents() {return fNevents;}
- TClonesArray *Digits() {return fDigits;}
-
- private:
- TClonesArray *fDigits; // ! array with digits
- Int_t fNevents ; // Number of events
-
- AliRunLoader* fRunLoader; //!Run Loader of that event
-
- ClassDef(AliFMDReconstruction,2)
-
-
-};
-#endif
-
-
-
-
-
-
-
-
-
**************************************************************************/
//_________________________________________________________________________
-// This is a TTask that constructs ReconstParticles (reconstructed particles)
+// This is a class that constructs ReconstParticles (reconstructed particles)
// out of Digits
//
//-- Authors: Evgeny Karpechev(INR) and Alla Maevsksia
#include "AliFMDReconstParticles.h"
#include "AliFMD.h"
#include "AliFMDv1.h"
-#include "AliFMDReconstruction.h"
+#include "AliFMDReconstructor.h"
#include "AliRun.h"
#include "AliConfig.h"
#include "AliHeader.h"
#include "AliGenEventHeader.h"
-ClassImp(AliFMDReconstruction)
+ClassImp(AliFMDReconstructor)
-//____________________________________________________________________________
-
-AliFMDReconstruction::AliFMDReconstruction():TTask("AliFMDReconstruction","")
-{
- fNevents = 0 ; // Number of events to rreconnstraction, 0 means all events in current file
- fRunLoader = 0x0;
-
-}
-//____________________________________________________________________________
-
-AliFMDReconstruction::AliFMDReconstruction(AliRunLoader* rl):TTask("AliFMDReconstruction","")
-{
-
- if (rl == 0x0)
- {
- Fatal("AliFMDReconstruction","Argument AliRunLoader* is null!");
- return;
- }
-
- fNevents = 0 ; // Number of events to rreconnstraction, 0 means all events in current file
-
- fRunLoader = rl;
- AliLoader* plFMD = fRunLoader->GetLoader("FMDLoader");
- if (plFMD == 0x0)
- {
- Fatal("AliFMDReconstruction","Can not find FMD (loader) in specified event");
- return;//never reached
- }
- //add Task to //root/Tasks folder
-// gime->PostReconstructioner(this);
-}
-
-//____________________________________________________________________________
-
-AliFMDReconstruction::~AliFMDReconstruction()
-{
- AliLoader* plFMD = fRunLoader->GetLoader("FMDLoader");
- plFMD->CleanReconstructioner();
-}
-
//____________________________________________________________________________
-void AliFMDReconstruction::Exec()
+void AliFMDReconstructor::Reconstruct(AliRunLoader* runLoader) const
{
//Collects all digits in the same active volume into number of particles
/*
determine by numberOfVolume ,
numberOfMinSector,numberOfMaxSector,
numberOfMinRing, numberOgMaxRing
- Reconstruction method choose dependence on number of empty pads
+ Reconstructor method choose dependence on number of empty pads
*/
// number of ring for boundary 0.1 eta
- if (fRunLoader == 0x0)
+ if (runLoader == 0x0)
{
Error("Exec","Run Loader loader is NULL - Session not opened");
return;
}
- AliLoader* plFMD = fRunLoader->GetLoader("FMDLoader");
+ AliLoader* plFMD = runLoader->GetLoader("FMDLoader");
if (plFMD == 0x0)
{
- Fatal("AliFMDReconstruction","Can not find FMD (loader) in specified event");
+ Fatal("AliFMDReconstructor","Can not find FMD (loader) in specified event");
return;//never reached
}
- if (!fRunLoader->GetAliRun()) fRunLoader->LoadgAlice();
- if (!fRunLoader->TreeE()) fRunLoader->LoadHeader();
+ if (!runLoader->GetAliRun()) runLoader->LoadgAlice();
+ if (!runLoader->TreeE()) runLoader->LoadHeader();
TDirectory* cwd = gDirectory;
gDirectory = 0x0;
}
gDirectory = cwd;
+ plFMD->LoadRecPoints("RECREATE");
Int_t retval=0;
- if(fNevents == 0) fNevents=Int_t (fRunLoader->TreeE()->GetEntries());
+ Int_t nevents=Int_t (runLoader->TreeE()->GetEntries());
#ifdef DEBUG
- cout<<" fNevents "<<fNevents<<endl;
+ cout<<" nevents "<<nevents<<endl;
#endif
- for(Int_t ievent=0;ievent<fNevents;ievent++)
+ for(Int_t ievent=0;ievent<nevents;ievent++)
{
#ifdef DEBUG
cout<<" *** event "<<ievent<<endl;
#endif
- fRunLoader->GetEvent(ievent) ;
+ runLoader->GetEvent(ievent) ;
//event z-vertex for correction eta-rad dependence
- AliHeader *header = fRunLoader->GetHeader();
+ AliHeader *header = runLoader->GetHeader();
AliGenEventHeader* genHeader = header->GenEventHeader();
TArrayF *o = new TArrayF(3);
genHeader->PrimaryVertex(*o);
plFMD->WriteRecPoints("OVERWRITE");
plFMD->UnloadDigits();
} //event loop
+ plFMD->UnloadRecPoints();
#ifdef DEBUG
Info(" Exec"," finished");
#endif
}
+
+//_____________________________________________________________________________
+void AliFMDReconstructor::FillESD(AliRunLoader* /*runLoader*/,
+ AliESD* /*esd*/) const
+{
+// nothing to be done
+
+}
+
--- /dev/null
+// Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved.
+// See cxx source for full Copyright notice
+// AliFMDReconstructor.h
+// Task Class for making TreeR in FMD
+//-- Authors: Evgeny Karpechev (INR) and Alla Maevskaia (INR)
+/*
+ Reconstruct nember of particles
+ in given group of pads for given FMDvolume
+ determine by numberOfVolume ,
+ numberOfMinSector,numberOfMaxSector,
+ numberOfMinRing, numberOfMaxRing
+ Reconstruction method choose dependence on number of empty pads
+ */
+/* $Id$ */
+
+
+#ifndef ALIFMDRECONSTRUCTOR_H
+#define ALIFMDRECONSTRUCTOR_H
+
+#include "AliReconstructor.h"
+
+
+class AliFMDReconstructor: public AliReconstructor
+{
+ public:
+ AliFMDReconstructor(): AliReconstructor() {};
+ virtual ~AliFMDReconstructor() {};
+
+ virtual void Reconstruct(AliRunLoader* runLoader) const;
+ virtual void FillESD(AliRunLoader* runLoader, AliESD* esd) const;
+
+ ClassDef(AliFMDReconstructor, 0) // class for the FMD reconstruction
+
+
+};
+#endif
+
+
+
+
+
+
+
+
+
#pragma link C++ class AliFMDv1+;
#pragma link C++ class AliFMDhit+;
#pragma link C++ class AliFMDdigit+;
-#pragma link C++ class AliFMDReconstruction+;
+#pragma link C++ class AliFMDReconstructor+;
#pragma link C++ class AliFMDReconstParticles+;
#pragma link C++ class AliFMDDigitizer+;
-SRCS= AliFMD.cxx AliFMDv0.cxx AliFMDv1.cxx AliFMDhit.cxx AliFMDdigit.cxx AliFMDReconstruction.cxx AliFMDReconstParticles.cxx AliFMDDigitizer.cxx
+SRCS= AliFMD.cxx AliFMDv0.cxx AliFMDv1.cxx AliFMDhit.cxx AliFMDdigit.cxx AliFMDReconstructor.cxx AliFMDReconstParticles.cxx AliFMDDigitizer.cxx
HDRS= $(SRCS:.cxx=.h)
#include "AliMC.h"
#include "AliITSDigitizer.h"
#include "AliITSDDLRawData.h"
-#include "AliITSclustererV2.h"
-#include "AliITStrackerV2.h"
-#include "AliITStrackerSA.h"
-#include "AliITSpidESD.h"
-#include "AliV0vertexer.h"
-#include "AliITSVertexerPPZ.h"
-#include "AliITSVertexerFast.h"
-#include "AliITSVertexerZ.h"
-#include "AliITSVertexerIons.h"
-#include "AliCascadeVertexer.h"
-#include "AliESD.h"
#include "AliRun.h"
ClassImp(AliITS)
return fLoader;
}
-
-//_____________________________________________________________________________
-void AliITS::Reconstruct() const
-{
-// reconstruct clusters
-
- AliLoader* loader = GetLoader();
- loader->LoadRecPoints("recreate");
- loader->LoadDigits("read");
-
- AliITSclustererV2 clusterer(GetITSgeom());
- AliRunLoader* runLoader = loader->GetRunLoader();
- Int_t nEvents = runLoader->GetNumberOfEvents();
- runLoader->LoadKinematics();
-
- for (Int_t iEvent = 0; iEvent < nEvents; iEvent++) {
- runLoader->GetEvent(iEvent);
-
- TTree* treeClusters = loader->TreeR();
- if (!treeClusters) {
- loader->MakeTree("R");
- treeClusters = loader->TreeR();
- }
- TTree* treeDigits = loader->TreeD();
- if (!treeDigits) {
- Error("Reconstruct", "Can't get digits tree !");
- return;
- }
-
- clusterer.Digits2Clusters(treeDigits, treeClusters);
-
- loader->WriteRecPoints("OVERWRITE");
- }
-
- loader->UnloadRecPoints();
- loader->UnloadDigits();
-}
-
-//_____________________________________________________________________________
-AliTracker* AliITS::CreateTracker() const
-{
-// create an ITS tracker
-
- return new AliITStrackerSA(GetITSgeom());
-}
-//_____________________________________________________________________________
-AliVertexer* AliITS::CreateVertexer() const
-{
- // create a ITS vertexer
-
- if(fSelectedVertexer.Contains("ions") || fSelectedVertexer.Contains("IONS")){
- Info("CreateVertexer","a AliITSVertexerIons object has been selected\n");
- return new AliITSVertexerIons("null");
- }
- if(fSelectedVertexer.Contains("smear") || fSelectedVertexer.Contains("SMEAR")){
- Double_t smear[3]={0.005,0.005,0.01};
- Info("CreateVertexer","a AliITSVertexerFast object has been selected\n");
- return new AliITSVertexerFast(smear);
- }
- if(fSelectedVertexer.Contains("ppz") || fSelectedVertexer.Contains("PPZ")){
- Info("CreateVertexer","a AliITSVertexerPPZ object has been selected\n");
- return new AliITSVertexerPPZ("null");
- }
- // by default an AliITSVertexerZ object is instatiated
- Info("CreateVertexer","a AliITSVertexerZ object has been selected\n");
- return new AliITSVertexerZ("null");
-}
-
-//_____________________________________________________________________________
-void AliITS::FillESD(AliESD* esd) const
-{
-// make PID, find V0s and cascades
-
- Double_t parITS[] = {34., 0.15, 10.};
- AliITSpidESD itsPID(parITS);
- itsPID.MakePID(esd);
-
- // V0 finding
- Double_t cuts[]={33, // max. allowed chi2
- 0.16,// min. allowed negative daughter's impact parameter
- 0.05,// min. allowed positive daughter's impact parameter
- 0.08,// max. allowed DCA between the daughter tracks
- 0.99,// max. allowed cosine of V0's pointing angle
- 0.9, // min. radius of the fiducial volume
- 2.9 // max. radius of the fiducial volume
- };
- AliV0vertexer vtxer(cuts);
- Double_t vtx[3], cvtx[6];
- esd->GetVertex()->GetXYZ(vtx);
- esd->GetVertex()->GetSigmaXYZ(cvtx);
- vtxer.SetVertex(vtx);
- vtxer.Tracks2V0vertices(esd);
-
- // cascade finding
- Double_t cts[]={33., // max. allowed chi2
- 0.05, // min. allowed V0 impact parameter
- 0.008, // window around the Lambda mass
- 0.035, // min. allowed bachelor's impact parameter
- 0.10, // max. allowed DCA between a V0 and a track
- 0.9985, //max. allowed cosine of the cascade pointing angle
- 0.9, // min. radius of the fiducial volume
- 2.9 // max. radius of the fiducial volume
- };
- AliCascadeVertexer cvtxer=AliCascadeVertexer(cts);
- cvtxer.SetVertex(vtx);
- cvtxer.V0sTracks2CascadeVertices(esd);
-}
-
// Return pointer to rec points
TClonesArray *RecPoints() {return fRecPoints;}
- virtual void Reconstruct() const;
- virtual AliTracker* CreateTracker() const;
- virtual AliVertexer* CreateVertexer() const;
- virtual void FillESD(AliESD* esd) const;
-
protected:
//================== Data Members ==================================
AliITSgeom *fITSgeom; // Pointer to ITS geometry
--- /dev/null
+/**************************************************************************
+ * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
+ * *
+ * Author: The ALICE Off-line Project. *
+ * Contributors are mentioned in the code where appropriate. *
+ * *
+ * Permission to use, copy, modify and distribute this software and its *
+ * documentation strictly for non-commercial purposes is hereby granted *
+ * without fee, provided that the above copyright notice appears in all *
+ * copies and that both the copyright notice and this permission notice *
+ * appear in the supporting documentation. The authors make no claims *
+ * about the suitability of this software for any purpose. It is *
+ * provided "as is" without express or implied warranty. *
+ **************************************************************************/
+
+/* $Id$ */
+
+///////////////////////////////////////////////////////////////////////////////
+// //
+// class for ITS reconstruction //
+// //
+///////////////////////////////////////////////////////////////////////////////
+
+
+#include "AliITSReconstructor.h"
+#include "AliRunLoader.h"
+#include "AliITSclustererV2.h"
+#include "AliITStrackerSA.h"
+#include "AliITSVertexerIons.h"
+#include "AliITSVertexerFast.h"
+#include "AliITSVertexerPPZ.h"
+#include "AliITSVertexerZ.h"
+#include "AliESD.h"
+#include "AliITSpidESD.h"
+#include "AliV0vertexer.h"
+#include "AliCascadeVertexer.h"
+#include "AliRun.h"
+#include "AliITS.h"
+
+
+ClassImp(AliITSReconstructor)
+
+
+//_____________________________________________________________________________
+void AliITSReconstructor::Reconstruct(AliRunLoader* runLoader) const
+{
+// reconstruct clusters
+
+ AliLoader* loader = runLoader->GetLoader("ITSLoader");
+ if (!loader) {
+ Error("Reconstruct", "ITS loader not found");
+ return;
+ }
+ loader->LoadRecPoints("recreate");
+ loader->LoadDigits("read");
+ runLoader->LoadKinematics();
+
+ AliITSgeom* geom = GetITSgeom(runLoader);
+ if (!geom) return;
+ AliITSclustererV2 clusterer(geom);
+ Int_t nEvents = runLoader->GetNumberOfEvents();
+
+ for (Int_t iEvent = 0; iEvent < nEvents; iEvent++) {
+ runLoader->GetEvent(iEvent);
+
+ TTree* treeClusters = loader->TreeR();
+ if (!treeClusters) {
+ loader->MakeTree("R");
+ treeClusters = loader->TreeR();
+ }
+ TTree* treeDigits = loader->TreeD();
+ if (!treeDigits) {
+ Error("Reconstruct", "Can't get digits tree !");
+ return;
+ }
+
+ clusterer.Digits2Clusters(treeDigits, treeClusters);
+
+ loader->WriteRecPoints("OVERWRITE");
+ }
+
+ loader->UnloadRecPoints();
+ loader->UnloadDigits();
+ runLoader->UnloadKinematics();
+}
+
+//_____________________________________________________________________________
+AliTracker* AliITSReconstructor::CreateTracker(AliRunLoader* runLoader) const
+{
+// create a ITS tracker
+
+ AliITSgeom* geom = GetITSgeom(runLoader);
+ if (!geom) return NULL;
+ return new AliITStrackerSA(geom);
+}
+
+//_____________________________________________________________________________
+AliVertexer* AliITSReconstructor::CreateVertexer(AliRunLoader* /*runLoader*/) const
+{
+// create a ITS vertexer
+
+ TString selectedVertexer(" ");
+ if(selectedVertexer.Contains("ions") || selectedVertexer.Contains("IONS")){
+ Info("CreateVertexer","a AliITSVertexerIons object has been selected\n");
+ return new AliITSVertexerIons("null");
+ }
+ if(selectedVertexer.Contains("smear") || selectedVertexer.Contains("SMEAR")){
+ Double_t smear[3]={0.005,0.005,0.01};
+ Info("CreateVertexer","a AliITSVertexerFast object has been selected\n");
+ return new AliITSVertexerFast(smear);
+ }
+ if(selectedVertexer.Contains("ppz") || selectedVertexer.Contains("PPZ")){
+ Info("CreateVertexer","a AliITSVertexerPPZ object has been selected\n");
+ return new AliITSVertexerPPZ("null");
+ }
+ // by default an AliITSVertexerZ object is instatiated
+ Info("CreateVertexer","a AliITSVertexerZ object has been selected\n");
+ return new AliITSVertexerZ("null");
+}
+
+//_____________________________________________________________________________
+void AliITSReconstructor::FillESD(AliRunLoader* /*runLoader*/,
+ AliESD* esd) const
+{
+// make PID, find V0s and cascades
+
+ Double_t parITS[] = {34., 0.15, 10.};
+ AliITSpidESD itsPID(parITS);
+ itsPID.MakePID(esd);
+
+ // V0 finding
+ Double_t cuts[]={33, // max. allowed chi2
+ 0.16,// min. allowed negative daughter's impact parameter
+ 0.05,// min. allowed positive daughter's impact parameter
+ 0.08,// max. allowed DCA between the daughter tracks
+ 0.99,// max. allowed cosine of V0's pointing angle
+ 0.9, // min. radius of the fiducial volume
+ 2.9 // max. radius of the fiducial volume
+ };
+ AliV0vertexer vtxer(cuts);
+ Double_t vtx[3], cvtx[6];
+ esd->GetVertex()->GetXYZ(vtx);
+ esd->GetVertex()->GetSigmaXYZ(cvtx);
+ vtxer.SetVertex(vtx);
+ vtxer.Tracks2V0vertices(esd);
+
+ // cascade finding
+ Double_t cts[]={33., // max. allowed chi2
+ 0.05, // min. allowed V0 impact parameter
+ 0.008, // window around the Lambda mass
+ 0.035, // min. allowed bachelor's impact parameter
+ 0.10, // max. allowed DCA between a V0 and a track
+ 0.9985, //max. allowed cosine of the cascade pointing angle
+ 0.9, // min. radius of the fiducial volume
+ 2.9 // max. radius of the fiducial volume
+ };
+ AliCascadeVertexer cvtxer=AliCascadeVertexer(cts);
+ cvtxer.SetVertex(vtx);
+ cvtxer.V0sTracks2CascadeVertices(esd);
+}
+
+
+//_____________________________________________________________________________
+AliITSgeom* AliITSReconstructor::GetITSgeom(AliRunLoader* runLoader) const
+{
+// get the ITS geometry
+
+ if (!runLoader->GetAliRun()) runLoader->LoadgAlice();
+ if (!runLoader->GetAliRun()) {
+ Error("GetITSgeom", "couldn't get AliRun object");
+ return NULL;
+ }
+ AliITS* its = (AliITS*) runLoader->GetAliRun()->GetDetector("ITS");
+ if (!its) {
+ Error("GetITSgeom", "couldn't get ITS detector");
+ return NULL;
+ }
+ if (!its->GetITSgeom()) {
+ Error("GetITSgeom", "no ITS geometry available");
+ return NULL;
+ }
+ return its->GetITSgeom();
+}
--- /dev/null
+#ifndef ALIITSRECONSTRUCTOR_H
+#define ALIITSRECONSTRUCTOR_H
+/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
+ * See cxx source for full Copyright notice */
+
+/* $Id$ */
+
+#include "AliReconstructor.h"
+
+class AliITSgeom;
+
+
+class AliITSReconstructor: public AliReconstructor {
+public:
+ AliITSReconstructor(): AliReconstructor() {};
+ virtual ~AliITSReconstructor() {};
+
+ virtual void Reconstruct(AliRunLoader* runLoader) const;
+ virtual AliTracker* CreateTracker(AliRunLoader* runLoader) const;
+ virtual AliVertexer* CreateVertexer(AliRunLoader* runLoader) const;
+ virtual void FillESD(AliRunLoader* runLoader, AliESD* esd) const;
+
+private:
+ AliITSgeom* GetITSgeom(AliRunLoader* runLoader) const;
+
+ ClassDef(AliITSReconstructor, 0) // class for the ITS reconstruction
+};
+
+#endif
#pragma link C++ class AliITStrackSA+;
#pragma link C++ class AliITSVertexerFast+;
+#pragma link C++ class AliITSReconstructor+;
+
//
//#pragma link C++ class AliACORDEFunction+;
//#pragma link C++ class AliACORDEMaterial+;
AliITSBaseGeometry.cxx \
AliITSv11Geometry.cxx \
AliITSv11GeometrySupport.cxx \
+ AliITSReconstructor.cxx \
# AliITSAlignmentTrack.cxx AliITSAlignmentModule.cxx \
# AliACORDEFunctions.cxx \
#include "AliRICH.h"
#include "AliRICHParam.h"
#include "AliRICHChamber.h"
-#include "AliRICHClusterFinder.h"
#include <TArrayF.h>
#include <TGeometry.h>
#include <TBRIK.h>
1.0);
}//feedbacks loop
}//GenerateFeedbacks()
-//__________________________________________________________________________________________________
-
-void AliRICH::Reconstruct() const
-{
-// reconstruct clusters
-
- AliRICHClusterFinder clusterer(const_cast<AliRICH*>(this));
- clusterer.Exec();
-}
void AddReco(Int_t tid,Double_t thetaCherenkov,Int_t nPhotons)
{TClonesArray &tmp=*(TClonesArray*)fRecos;new(tmp[fNrecos++])AliRICHreco(tid,thetaCherenkov,nPhotons);}
- virtual void Reconstruct() const;
-
protected:
enum {kCSI=6,kGAP=9};
AliRICHParam *fpParam; //main RICH parametrization
--- /dev/null
+/**************************************************************************
+ * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
+ * *
+ * Author: The ALICE Off-line Project. *
+ * Contributors are mentioned in the code where appropriate. *
+ * *
+ * Permission to use, copy, modify and distribute this software and its *
+ * documentation strictly for non-commercial purposes is hereby granted *
+ * without fee, provided that the above copyright notice appears in all *
+ * copies and that both the copyright notice and this permission notice *
+ * appear in the supporting documentation. The authors make no claims *
+ * about the suitability of this software for any purpose. It is *
+ * provided "as is" without express or implied warranty. *
+ **************************************************************************/
+
+/* $Id$ */
+
+///////////////////////////////////////////////////////////////////////////////
+// //
+// class for RICH reconstruction //
+// //
+///////////////////////////////////////////////////////////////////////////////
+
+
+#include "AliRICHReconstructor.h"
+#include "AliRunLoader.h"
+#include "AliRun.h"
+#include "AliRICHClusterFinder.h"
+
+
+ClassImp(AliRICHReconstructor)
+
+
+//_____________________________________________________________________________
+void AliRICHReconstructor::Reconstruct(AliRunLoader* runLoader) const
+{
+// reconstruct clusters
+
+ AliRICH* rich = GetRICH(runLoader);
+ if (!rich) return;
+ AliRICHClusterFinder clusterer(rich);
+ clusterer.Exec();
+}
+
+//_____________________________________________________________________________
+void AliRICHReconstructor::FillESD(AliRunLoader* /*runLoader*/,
+ AliESD* /*esd*/) const
+{
+// nothing to be done
+
+}
+
+
+//_____________________________________________________________________________
+AliRICH* AliRICHReconstructor::GetRICH(AliRunLoader* runLoader) const
+{
+// get the RICH detector
+
+ if (!runLoader->GetAliRun()) runLoader->LoadgAlice();
+ if (!runLoader->GetAliRun()) {
+ Error("GetRICH", "couldn't get AliRun object");
+ return NULL;
+ }
+ AliRICH* rich = (AliRICH*) runLoader->GetAliRun()->GetDetector("RICH");
+ if (!rich) {
+ Error("GetRICH", "couldn't get RICH detector");
+ return NULL;
+ }
+ return rich;
+}
--- /dev/null
+#ifndef ALIRICHRECONSTRUCTOR_H
+#define ALIRICHRECONSTRUCTOR_H
+/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
+ * See cxx source for full Copyright notice */
+
+/* $Id$ */
+
+#include "AliReconstructor.h"
+
+class AliRICH;
+
+
+class AliRICHReconstructor: public AliReconstructor {
+public:
+ AliRICHReconstructor(): AliReconstructor() {};
+ virtual ~AliRICHReconstructor() {};
+
+ virtual void Reconstruct(AliRunLoader* runLoader) const;
+ virtual void FillESD(AliRunLoader* runLoader, AliESD* esd) const;
+
+private:
+ AliRICH* GetRICH(AliRunLoader* runLoader) const;
+
+ ClassDef(AliRICHReconstructor, 0) // class for the RICH reconstruction
+};
+
+#endif
#pragma link C++ class AliRICHRecon+;
#pragma link C++ class AliRICHDigitizer+;
#pragma link C++ class AliRICHDisplFast+;
+#pragma link C++ class AliRICHReconstructor+;
#endif
AliRICHClusterFinder.cxx AliRICHMap.cxx\
AliRICHChamber.cxx AliRICHRecon.cxx\
AliRICHDisplFast.cxx\
- AliRICHDigitizer.cxx
+ AliRICHDigitizer.cxx AliRICHReconstructor.cxx
HDRS = $(SRCS:.cxx=.h)
DHDR= RICHLinkDef.h
{
return new AliSTARTDigitizer(manager);
}
-
-//_____________________________________________________________________________
-void AliSTART::FillESD(AliESD* pESD) const
-{
- AliSTARTvertex reco;
- reco.Reconstruct(fLoader->GetRunLoader(), pESD);
-}
-
#include <AliDetector.h>
#include <TTree.h>
-#include "AliSTARTvertex.h"
class TDirectory;
class TFile;
TClonesArray *Photons() {return fPhotons;}
virtual AliDigitizer* CreateDigitizer(AliRunDigitizer* manager) const;
- // virtual void Reconstruct() const{ AliSTARTvertex reco; reco.Reconstruct();}
- virtual void FillESD(AliESD* pESD) const;
protected:
Int_t fIdSens; // Sensetive Cherenkov radiator
/* $Id$ */
#include <Riostream.h>
-#include <stdlib.h>
#include <TDirectory.h>
-#include <TVirtualMC.h>
-#include <AliRun.h>
#include <AliRunLoader.h>
-#include "AliSTART.h"
#include "AliSTARTLoader.h"
#include "AliSTARTdigit.h"
-#include "AliSTARThit.h"
-#include "AliSTARTvertex.h"
+#include "AliSTARTReconstructor.h"
#include <AliESD.h>
-ClassImp(AliSTARTvertex)
+ClassImp(AliSTARTReconstructor)
-void AliSTARTvertex::Reconstruct(AliRunLoader* rl, AliESD *pESD)
+void AliSTARTReconstructor::Reconstruct(AliRunLoader* /*rl*/) const
+{
+// nothing to be done
+
+}
+
+void AliSTARTReconstructor::FillESD(AliRunLoader* rl, AliESD *pESD) const
{
/***************************************************
Resonstruct digits to vertex position
<<" Zposit "<<Zposit<<endl;
}
- fZposition = Zposit;
pESD->SetT0zVertex(Zposit);
if (rl->GetDebug()>1) {
--- /dev/null
+#ifndef ALISTARTRECONSTRUCTOR_H
+#define ALISTARTRECONSTRUCTOR_H
+/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
+ * See cxx source for full Copyright notice */
+
+/* $Id$ */
+
+#include "AliReconstructor.h"
+
+
+class AliSTARTReconstructor: public AliReconstructor {
+public:
+ AliSTARTReconstructor(): AliReconstructor() {};
+ virtual ~AliSTARTReconstructor() {};
+
+ virtual void Reconstruct(AliRunLoader* runLoader) const;
+ virtual void FillESD(AliRunLoader* runLoader, AliESD* esd) const;
+
+ ClassDef(AliSTARTReconstructor, 0) // class for the START reconstruction
+};
+
+#endif
+++ /dev/null
-#ifndef STARTVERTEX_H
-#define STARTVERTEX_H
-/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
- * See cxx source for full Copyright notice */
-
-/* $Id$ */
-
-
-
-#include <AliESD.h>
-
-//___________________________________________
-class AliSTARTvertex : public TObject {
-
-
-////////////////////////////////////////////////////////////////////////
- public:
- AliSTARTvertex():TObject(),fZposition(0) {}
- virtual ~AliSTARTvertex() {}
-
- void Reconstruct(AliRunLoader* runLoader, AliESD *pESD);
-
- Float_t GetVertex() const {return fZposition;}
- void SetVertex(Float_t zPosition) {fZposition=zPosition;}
-
- private:
- Float_t fZposition; // Z position of vertex (mm)
-
- ClassDef(AliSTARTvertex,1) //Reconstructive vertex (Header) object
-};
-#endif
#pragma link C++ class AliSTARThit+;
#pragma link C++ class AliSTARThitPhoton+;
#pragma link C++ class AliSTARTdigit+;
-#pragma link C++ class AliSTARTvertex+;
+#pragma link C++ class AliSTARTReconstructor+;
#pragma link C++ class AliSTARTDigitizer+;
#pragma link C++ class AliSTARTLoader+;
-SRCS= AliSTART.cxx AliSTARTv0.cxx AliSTARTv1.cxx AliSTARThit.cxx AliSTARTdigit.cxx AliSTARTvertex.cxx AliSTARTDigitizer.cxx AliSTARThitPhoton.cxx AliSTARTLoader.cxx
+SRCS= AliSTART.cxx AliSTARTv0.cxx AliSTARTv1.cxx AliSTARThit.cxx AliSTARTdigit.cxx AliSTARTReconstructor.cxx AliSTARTDigitizer.cxx AliSTARThitPhoton.cxx AliSTARTLoader.cxx
HDRS= $(SRCS:.cxx=.h)
#include "AliTOFhitT0.h"
#include "AliMC.h"
#include "AliTOFDigitizer.h"
-#include "AliTOFtracker.h"
ClassImp(AliTOF)
fSDigits = new TClonesArray("AliTOFSDigit", 1000);
}
-////////////////////////////////////////////////////////////////////////
-AliTracker* AliTOF::CreateTracker() const
-{
-// create a TOF tracker
-
- Double_t parPID[] = {130., 5.};
- return new AliTOFtracker(GetGeometry(), parPID);
-}
-
void CreateSDigitsArray();
AliTOFGeometry *GetGeometry() const { return fTOFGeometry; };
- virtual AliTracker* CreateTracker() const;
-
Int_t fNevents ; // Number of events to digitize
protected:
--- /dev/null
+/**************************************************************************
+ * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
+ * *
+ * Author: The ALICE Off-line Project. *
+ * Contributors are mentioned in the code where appropriate. *
+ * *
+ * Permission to use, copy, modify and distribute this software and its *
+ * documentation strictly for non-commercial purposes is hereby granted *
+ * without fee, provided that the above copyright notice appears in all *
+ * copies and that both the copyright notice and this permission notice *
+ * appear in the supporting documentation. The authors make no claims *
+ * about the suitability of this software for any purpose. It is *
+ * provided "as is" without express or implied warranty. *
+ **************************************************************************/
+
+/* $Id$ */
+
+///////////////////////////////////////////////////////////////////////////////
+// //
+// class for TOF reconstruction //
+// //
+///////////////////////////////////////////////////////////////////////////////
+
+
+#include "AliTOFReconstructor.h"
+#include "AliRunLoader.h"
+#include "AliRun.h"
+#include "AliTOF.h"
+#include "AliTOFtracker.h"
+
+
+ClassImp(AliTOFReconstructor)
+
+
+//_____________________________________________________________________________
+void AliTOFReconstructor::Reconstruct(AliRunLoader* /*runLoader*/) const
+{
+// nothing to be done
+
+}
+
+//_____________________________________________________________________________
+AliTracker* AliTOFReconstructor::CreateTracker(AliRunLoader* runLoader) const
+{
+// create a TOF tracker
+
+ AliTOFGeometry* geom = GetTOFGeometry(runLoader);
+ if (!geom) return NULL;
+ Double_t parPID[] = {130., 5.};
+ return new AliTOFtracker(geom, parPID);
+}
+
+//_____________________________________________________________________________
+void AliTOFReconstructor::FillESD(AliRunLoader* /*runLoader*/,
+ AliESD* /*esd*/) const
+{
+// nothing to be done
+
+}
+
+
+//_____________________________________________________________________________
+AliTOFGeometry* AliTOFReconstructor::GetTOFGeometry(AliRunLoader* runLoader) const
+{
+// get the TOF parameters
+
+ if (!runLoader->GetAliRun()) runLoader->LoadgAlice();
+ if (!runLoader->GetAliRun()) {
+ Error("GetTOFGeometry", "couldn't get AliRun object");
+ return NULL;
+ }
+ AliTOF* tof = (AliTOF*) runLoader->GetAliRun()->GetDetector("TOF");
+ if (!tof) {
+ Error("GetTOFGeometry", "couldn't get TOF detector");
+ return NULL;
+ }
+ if (!tof->GetGeometry()) {
+ Error("GetTOFGeometry", "no TOF geometry available");
+ return NULL;
+ }
+ return tof->GetGeometry();
+}
--- /dev/null
+#ifndef ALITOFRECONSTRUCTOR_H
+#define ALITOFRECONSTRUCTOR_H
+/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
+ * See cxx source for full Copyright notice */
+
+/* $Id$ */
+
+#include "AliReconstructor.h"
+
+class AliTOFGeometry;
+
+
+class AliTOFReconstructor: public AliReconstructor {
+public:
+ AliTOFReconstructor(): AliReconstructor() {};
+ virtual ~AliTOFReconstructor() {};
+
+ virtual void Reconstruct(AliRunLoader* runLoader) const;
+ virtual AliTracker* CreateTracker(AliRunLoader* runLoader) const;
+ virtual void FillESD(AliRunLoader* runLoader, AliESD* esd) const;
+
+private:
+ AliTOFGeometry* GetTOFGeometry(AliRunLoader* runLoader) const;
+
+ ClassDef(AliTOFReconstructor, 0) // class for the TOF reconstruction
+};
+
+#endif
#pragma link C++ class AliTOFpidESD+;
#pragma link C++ class AliTOFtracker+;
+#pragma link C++ class AliTOFReconstructor+;
#endif
AliTOFPID.cxx AliTOFT0.cxx AliTOFdigit.cxx AliTOFRawSector.cxx AliTOFRoc.cxx \
AliTOFRawDigit.cxx AliTOFDigitizer.cxx AliTOFSDigitizer.cxx AliTOFMerger.cxx \
AliTOFSDigit.cxx AliTOFHitMap.cxx AliTOFPad.cxx AliTOFRecHit.cxx AliTOFtrack.cxx \
- AliTOFProb.cxx AliTOFDigitMap.cxx AliTOFpidESD.cxx AliTOFtracker.cxx
+ AliTOFProb.cxx AliTOFDigitMap.cxx AliTOFpidESD.cxx AliTOFtracker.cxx \
+ AliTOFReconstructor.cxx
HDRS:= $(SRCS:.cxx=.h)
class AliTPCReconstructor: public AliReconstructor {
public:
+ AliTPCReconstructor(): AliReconstructor() {};
+ virtual ~AliTPCReconstructor() {};
+
virtual void Reconstruct(AliRunLoader* runLoader) const;
virtual AliTracker* CreateTracker(AliRunLoader* runLoader) const;
virtual void FillESD(AliRunLoader* runLoader, AliESD* esd) const;
#include "AliRun.h"
#include "AliTRD.h"
#include "AliTRDcluster.h"
-#include "AliTRDclusterizer.h"
#include "AliTRDdigit.h"
#include "AliTRDdigitizer.h"
#include "AliTRDdigitsManager.h"
#include "AliTRDtrackHits.h"
#include "AliTrackReference.h"
#include "AliMC.h"
-#include "AliTRDclusterizerV1.h"
-#include "AliTRDparameter.h"
-#include "AliTRDtracker.h"
ClassImp(AliTRD)
}
-//_____________________________________________________________________________
-void AliTRD::Reconstruct() const
-{
-// reconstruct clusters
-
- AliTRDclusterizerV1 clusterer("clusterer", "TRD clusterizer");
- AliRunLoader* runLoader = GetLoader()->GetRunLoader();
- runLoader->CdGAFile();
- AliTRDparameter* trdParam = (AliTRDparameter*) gFile->Get("TRDparameter");
- if (!trdParam) {
- Error("Reconstruct", "no TRD parameters found");
- return;
- }
- trdParam->ReInit();
- clusterer.SetParameter(trdParam);
- Int_t nEvents = runLoader->GetNumberOfEvents();
-
- for (Int_t iEvent = 0; iEvent < nEvents; iEvent++) {
- clusterer.Open(runLoader->GetFileName(), iEvent);
- clusterer.ReadDigits();
- clusterer.MakeClusters();
- clusterer.WriteClusters(-1);
- }
-}
-
-//_____________________________________________________________________________
-AliTracker* AliTRD::CreateTracker() const
-{
-// create a TRD tracker
-
- GetLoader()->GetRunLoader()->CdGAFile();
- return new AliTRDtracker(gFile);
-}
-
-
virtual void FinishPrimary();
virtual void RemapTrackHitIDs(Int_t *map);
- virtual void Reconstruct() const;
- virtual AliTracker* CreateTracker() const;
-
protected:
Int_t fGasMix; // Gas mixture. 0: Xe/Isobutane 1: Xe/CO2
--- /dev/null
+/**************************************************************************
+ * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
+ * *
+ * Author: The ALICE Off-line Project. *
+ * Contributors are mentioned in the code where appropriate. *
+ * *
+ * Permission to use, copy, modify and distribute this software and its *
+ * documentation strictly for non-commercial purposes is hereby granted *
+ * without fee, provided that the above copyright notice appears in all *
+ * copies and that both the copyright notice and this permission notice *
+ * appear in the supporting documentation. The authors make no claims *
+ * about the suitability of this software for any purpose. It is *
+ * provided "as is" without express or implied warranty. *
+ **************************************************************************/
+
+/* $Id$ */
+
+///////////////////////////////////////////////////////////////////////////////
+// //
+// class for TRD reconstruction //
+// //
+///////////////////////////////////////////////////////////////////////////////
+
+
+#include "AliTRDReconstructor.h"
+#include "AliRunLoader.h"
+#include "AliTRDparameter.h"
+#include "AliTRD.h"
+#include "AliTRDclusterizerV1.h"
+#include "AliTRDtracker.h"
+#include <TFile.h>
+
+
+ClassImp(AliTRDReconstructor)
+
+
+//_____________________________________________________________________________
+void AliTRDReconstructor::Reconstruct(AliRunLoader* runLoader) const
+{
+// reconstruct clusters
+
+ AliTRDclusterizerV1 clusterer("clusterer", "TRD clusterizer");
+ runLoader->CdGAFile();
+ AliTRDparameter* trdParam = GetTRDparameter(runLoader);
+ if (!trdParam) {
+ Error("Reconstruct", "no TRD parameters found");
+ return;
+ }
+ trdParam->ReInit();
+ clusterer.SetParameter(trdParam);
+ Int_t nEvents = runLoader->GetNumberOfEvents();
+
+ for (Int_t iEvent = 0; iEvent < nEvents; iEvent++) {
+ clusterer.Open(runLoader->GetFileName(), iEvent);
+ clusterer.ReadDigits();
+ clusterer.MakeClusters();
+ clusterer.WriteClusters(-1);
+ }
+}
+
+//_____________________________________________________________________________
+AliTracker* AliTRDReconstructor::CreateTracker(AliRunLoader* runLoader) const
+{
+// create a TRD tracker
+
+ runLoader->CdGAFile();
+ return new AliTRDtracker(gFile);
+}
+
+//_____________________________________________________________________________
+void AliTRDReconstructor::FillESD(AliRunLoader* /*runLoader*/,
+ AliESD* /*esd*/) const
+{
+}
+
+
+//_____________________________________________________________________________
+AliTRDparameter* AliTRDReconstructor::GetTRDparameter(AliRunLoader* runLoader) const
+{
+// get the TRD parameters
+
+ runLoader->CdGAFile();
+ AliTRDparameter* trdParam = (AliTRDparameter*) gFile->Get("TRDparameter");
+ if (!trdParam) {
+ Error("GetTRDparameter", "no TRD parameters available");
+ return NULL;
+ }
+ return trdParam;
+}
+
+
--- /dev/null
+#ifndef ALITRDRECONSTRUCTOR_H
+#define ALITRDRECONSTRUCTOR_H
+/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
+ * See cxx source for full Copyright notice */
+
+///////////////////////////////////////////////////////////////////////////////
+// //
+// class for TRD reconstruction //
+// //
+///////////////////////////////////////////////////////////////////////////////
+
+/* $Id$ */
+
+#include "AliReconstructor.h"
+
+class AliTRDparameter;
+
+
+class AliTRDReconstructor: public AliReconstructor {
+public:
+ AliTRDReconstructor(): AliReconstructor() {};
+ virtual ~AliTRDReconstructor() {};
+
+ virtual void Reconstruct(AliRunLoader* runLoader) const;
+ virtual AliTracker* CreateTracker(AliRunLoader* runLoader) const;
+ virtual void FillESD(AliRunLoader* runLoader, AliESD* esd) const;
+
+private:
+ AliTRDparameter* GetTRDparameter(AliRunLoader* runLoader) const;
+
+ ClassDef(AliTRDReconstructor, 0) // class for the TRD reconstruction
+};
+
+#endif
#pragma link C++ class AliTRDparameter+;
#pragma link C++ class AliTRDPartID+;
+#pragma link C++ class AliTRDReconstructor+;
+
#endif
AliTRDPartID.cxx \
AliTRDclusterMI.cxx \
AliTRDclusterizerMI.cxx \
- AliTRDclusterCorrection.cxx
+ AliTRDclusterCorrection.cxx \
+ AliTRDReconstructor.cxx
HDRS= $(SRCS:.cxx=.h)