ClassImp(AliITSPlaneEff)
//______________________________________________________________________
-AliITSPlaneEff::AliITSPlaneEff(): TObject(),
+AliITSPlaneEff::AliITSPlaneEff(): AliPlaneEff(),
fRunNumber(0),
fCDBUri(""),
fInitCDBCalled(kFALSE)
InitCDB();
}
//______________________________________________________________________
-AliITSPlaneEff::AliITSPlaneEff(const AliITSPlaneEff &s) : TObject(s),
+AliITSPlaneEff::AliITSPlaneEff(const AliITSPlaneEff &s) : AliPlaneEff(s),
fRunNumber(s.fRunNumber),
fCDBUri(s.fCDBUri),
fInitCDBCalled(s.fInitCDBCalled)
source.Copy(*this);
}
return *this;
-// if(&s == this) return *this;
-// this->fRunNumber = s.fRunNumber;
-// this->fCDBUri = s.fCDBUri;
-// this->fInitCDBCalled = s.fInitCDBCalled;
-// return *this;
}
-//_____________________________________________________________
+//_________________________________________________________________________
+/*
+AliPlaneEff& AliITSPlaneEff::operator=(const
+ AliPlaneEff &s){
+ // Assignment operator
+ // Inputs:
+ // AliPlaneEff &s The original class for which
+ // this class is a copy of
+ // Outputs:
+ // none.
+ // Return:
+
+ if(&s == this) return *this;
+ AliWarning("AliITSPlaneEff Not allowed to make a = Using default creator instead");
+ return *this;
+}
+*/
+//_________________________________________________________________________
void AliITSPlaneEff::Copy(TObject &obj) const {
// copy this to obj
((AliITSPlaneEff& ) obj).fRunNumber = fRunNumber;
/* Copyright(c) 2007-2009, ALICE Experiment at CERN, All rights reserved. *
* See cxx source for full Copyright notice */
-#include <TObject.h>
#include <TString.h>
+#include "AliPlaneEff.h"
#include "AliLog.h"
class AliITSsegmentation;
/* $Id$ */
-class AliITSPlaneEff : public TObject {
+class AliITSPlaneEff : public AliPlaneEff {
public:
AliITSPlaneEff();// Default constructor
// Standard constructor
- //AliITSPlaneEff(AliITSDetTypeSim *dettyp);
virtual ~AliITSPlaneEff(){;};
// copy constructor. See detector specific implementation.
AliITSPlaneEff(const AliITSPlaneEff &source);
Double_t ErrPlaneEff(Int_t nfound,Int_t ntried) const;
virtual void GetPlaneEff(Int_t nfound,Int_t ntried,Double_t &eff, Double_t &err) const
{eff=PlaneEff(nfound,ntried); err=ErrPlaneEff(nfound,ntried); return;};
+ //
+ virtual Double_t PlaneEff(const UInt_t key) const=0;
// Plane efficiency for active detector (excluding dead/noisy channels)
virtual Double_t LivePlaneEff(UInt_t) const
{AliWarning("This method gives just a rough estimate of the live-Det Efficiency!");
{AliError("This method must be implemented in a derived class"); return kFALSE;};
virtual Bool_t AddFromCDB()
{AliError("This method must be implemented in a derived class"); return kFALSE;};
+ // method to locate a basic block from Detector Local coordinate
+ virtual UInt_t GetKeyFromDetLocCoord(Int_t, Int_t, Float_t, Float_t) const
+ {AliError("This method must be implemented in a derived class"); return 999999;};
+ virtual UInt_t Nblock() const // return the number of basic blocks
+ {AliError("This method must be implemented in a derived class"); return 999999;};
protected:
**************************************************************************/
///////////////////////////////////////////////////////////////////////////
// Plane Efficiency class for ITS
-// It is used for chip by chip efficiency (eventually with subwing division
-// along the drift direction ) of the SDD,
+// It is used for chip by chip efficiency (eventually with sui-bwing division
+// along the drift direction) of the SDD,
// evaluated by tracks
// (Inherits from AliITSPlaneEff)
// Author: G.E. Bruno
#include "AliCDBEntry.h"
#include "AliCDBManager.h"
//#include "AliCDBRunRange.h"
+#include "AliITSgeom.h"
#include "AliITSCalibrationSDD.h"
+#include "AliITSsegmentationSDD.h"
ClassImp(AliITSPlaneEffSDD)
//______________________________________________________________________
AliITSPlaneEffSDD::AliITSPlaneEffSDD():
AliITSPlaneEff(){
- // Default constructor
for (UInt_t i=0; i<kNModule*kNChip*kNWing*kNSubWing; i++){
fFound[i]=0;
fTried[i]=0;
// Return:
if(&s == this) return *this;
- Error("AliITSPlaneEffSDD","Not allowed to make a = with "
- "AliITSPlaneEffSDD","Using default creater instead");
-
+ AliError("operator=: Not allowed to make a =, use default creater instead");
return *this;
}
//_______________________________________________________________________
// Return: the estimated n. of tracks
//
if (im>=kNModule || ic>=kNChip || iw>=kNWing || is>=kNSubWing)
- {Error("AliITSPlaneEffSDD","you asked for a non existing block");
+ {AliError("GetMissingTracksForGivenEff: you asked for a non existing block");
return -1;}
else return GetNTracksForGivenEff(eff,RelErr)-fTried[GetKey(im,ic,iw,is)];
}
// iw -> wing number [0,1]
// is -> chip number [0,kNSubWing-1]
if (im>=kNModule || ic>=kNChip || iw>=kNWing || is>=kNSubWing)
- {Error("AliITSPlaneEffSDD","you asked for a non existing block"); return -1.;}
+ {AliError("PlaneEff(UInt_t,UInt_t,UInt_t,UInt_t): you asked for a non existing block"); return -1.;}
Int_t nf=fFound[GetKey(im,ic,iw,is)];
Int_t nt=fTried[GetKey(im,ic,iw,is)];
return AliITSPlaneEff::PlaneEff(nf,nt);
// iw -> wing number [0,1]
// is -> chip number [0,kNSubWing-1]
if (im>=kNModule || ic>=kNChip || iw>=kNWing || is>=kNSubWing)
- {Error("AliITSPlaneEffSDD","you asked for a non existing block"); return -1.;}
+ {AliError("ErrPlaneEff(UInt_t,UInt_t,UInt_t,UInt_t): you asked for a non existing block"); return -1.;}
Int_t nf=fFound[GetKey(im,ic,iw,is)];
Int_t nt=fTried[GetKey(im,ic,iw,is)];
return AliITSPlaneEff::ErrPlaneEff(nf,nt);
const UInt_t iw, const UInt_t is) {
// Update efficiency for a basic block
if (im>=kNModule || ic>=kNChip || iw>=kNWing || is>=kNSubWing)
- {Error("AliITSPlaneEffSDD","you asked for a non existing block"); return kFALSE;}
+ {AliError("UpDatePlaneEff: you asked for a non existing block"); return kFALSE;}
fTried[GetKey(im,ic,iw,is)]++;
if(Kfound) fFound[GetKey(im,ic,iw,is)]++;
return kTRUE;
// Retun the chip number [0,3] and the wing number [0,1] given the anode number
// input: anode number [0,511]
if(anode>=kNAnode*kNChip*kNWing)
- {Error("AliITSPlaneEffSDD::ChipAndWingFromAnode","you asked for a non existing anode");
+ {AliError("ChipAndWingFromAnode: you asked for a non existing anode");
chip=999;
wing=99;
return;}
// Retun the chip number [0,3] given the anode number
// input: anode number [0,511]
if(anode>=kNAnode*kNChip*kNWing)
- {Error("AliITSPlaneEffSDD::ChipFromAnode","you asked for a non existing anode"); return 999;}
+ {AliError("ChipFromAnode: you asked for a non existing anode"); return 999;}
Int_t wing=0;
Int_t chip=anode/kNAnode;
if(anode>=kNChip*kNAnode) wing=1;
// return the wing number [0,1] given the anode number
// input: anode number [0,511]
if(anode>=kNAnode*kNChip*kNWing)
- {Error("AliITSPlaneEffSDD::GetWingFromAnode","you asked for a non existing anode"); return 99;}
+ {AliError("WingFromAnode: you asked for a non existing anode"); return 99;}
Int_t wing=0;
if(anode>=kNChip*kNAnode) wing=1;
return wing;
const UInt_t wing, const UInt_t subw) const {
// get key given a basic block
if(mod>=kNModule || chip>=kNChip || wing>= kNWing || subw>=kNSubWing)
- {Error("AliITSPlaneEffSDD::GetKey","you asked for a non existing block"); return 99999;}
+ {AliError("GetKey: you asked for a non existing block"); return 99999;}
return mod*kNChip*kNWing*kNSubWing+chip*kNWing*kNSubWing+wing*kNSubWing+subw;
}
//__________________________________________________________________________
UInt_t AliITSPlaneEffSDD::GetModFromKey(const UInt_t key) const {
// get mod. from key
if(key>=kNModule*kNChip*kNWing*kNSubWing)
- {Error("AliITSPlaneEffSDD::GetModFromKey","you asked for a non existing key"); return 9999;}
+ {AliError("GetModFromKey: you asked for a non existing key"); return 9999;}
return key/(kNChip*kNWing*kNSubWing);
}
//__________________________________________________________________________
UInt_t AliITSPlaneEffSDD::GetChipFromKey(const UInt_t key) const {
// retrieves chip from key
if(key>=kNModule*kNChip*kNWing*kNSubWing)
- {Error("AliITSPlaneEffSDD::GetChipFromKey","you asked for a non existing key"); return 999;}
+ {AliError("GetChipFromKey: you asked for a non existing key"); return 999;}
return (key%(kNChip*kNWing*kNSubWing))/(kNWing*kNSubWing);
}
//__________________________________________________________________________
UInt_t AliITSPlaneEffSDD::GetWingFromKey(const UInt_t key) const {
// retrieves wing from key
if(key>=kNModule*kNChip*kNWing*kNSubWing)
- {Error("AliITSPlaneEffSDD::GetWingFromKey","you asked for a non existing key"); return 99;}
+ {AliError("GetWingFromKey: you asked for a non existing key"); return 99;}
return ((key%(kNChip*kNWing*kNSubWing))%(kNWing*kNSubWing))/(kNSubWing);
}
//__________________________________________________________________________
UInt_t AliITSPlaneEffSDD::GetSubWingFromKey(const UInt_t key) const {
// retrieves sub-wing from key
if(key>=kNModule*kNChip*kNWing*kNSubWing)
- {Error("AliITSPlaneEffSDD::GetSubWingFromKey","you asked for a non existing key"); return 9;}
+ {AliError("GetSubWingFromKey: you asked for a non existing key"); return 9;}
return ((key%(kNChip*kNWing*kNSubWing))%(kNWing*kNSubWing))%(kNSubWing);
}
//__________________________________________________________________________
UInt_t& wing,UInt_t& subw) const {
// get module, chip, wing and subwing from a key
if(key>=kNModule*kNChip*kNWing*kNSubWing)
- {Error("AliITSPlaneEffSDD::GetAllFromKey","you asked for a non existing key");
+ {AliError("GetAllFromKey: you asked for a non existing key");
mod=9999;
chip=999;
wing=99;
Double_t AliITSPlaneEffSDD::LivePlaneEff(UInt_t key) const {
// returns plane efficieny after adding the fraction of sensor which is bad
if(key>=kNModule*kNChip*kNWing*kNSubWing)
- {Error("AliITSPlaneEffSDD::LivePlaneEff","you asked for a non existing key");
+ {AliError("LivePlaneEff: you asked for a non existing key");
return -1.;}
Double_t leff=AliITSPlaneEff::LivePlaneEff(0); // this just for the Warning
leff=PlaneEff(key)+GetFracBad(key);
Double_t AliITSPlaneEffSDD::ErrLivePlaneEff(UInt_t key) const {
// returns error on live plane efficiency
if(key>=kNModule*kNChip*kNWing*kNSubWing)
- {Error("AliITSPlaneEffSDD::ErrLivePlaneEff","you asked for a non existing key");
+ {AliError("ErrLivePlaneEff: you asked for a non existing key");
return -1.;}
Int_t nf=fFound[key];
Double_t triedInLive=GetFracLive(key)*fTried[key];
Double_t AliITSPlaneEffSDD::GetFracLive(const UInt_t key) const {
// returns the fraction of the sensor which is OK
if(key>=kNModule*kNChip*kNWing*kNSubWing)
- {Error("AliITSPlaneEffSDD::GetFracLive","you asked for a non existing key");
+ {AliError("GetFracLive: you asked for a non existing key");
return -1.;}
// Compute the fraction of bad (dead+noisy) detector
UInt_t bad=0;
// (it depends on the chip, not on the sub-wing)
nrBadInBlock=0;
if(key>=kNModule*kNChip*kNWing*kNSubWing)
- {Error("AliITSPlaneEffSDD::GetBadInBlock","you asked for a non existing key");
+ {AliError("GetBadInBlock: you asked for a non existing key");
return;}
//
if(!fInitCDBCalled)
- {Error("AliITSPlaneEffSDD::GetBadInBlock","CDB not inizialized: call InitCDB first");
+ {AliError("GetBadInBlock: CDB not inizialized: call InitCDB first");
return;};
AliCDBManager* man = AliCDBManager::Instance();
// retrieve map of dead Pixel
if(cdbSDD) {
sddEntry = (TObjArray*)cdbSDD->GetObject();
if(!sddEntry)
- {Error("AliITSPlaneEffSDD::GetBadInBlock"," SDDEntry not found in CDB");
+ {AliError("GetBadInBlock: SDDEntry not found in CDB");
return;}
} else {
- Error("AliITSPlaneEffSDD::GetBadInBlock","Did not find Calib/CalibSDD");
+ AliError("GetBadInBlock: Did not find Calib/CalibSDD");
return;
}
//
Double_t AliITSPlaneEffSDD::GetFracBad(const UInt_t key) const {
// returns 1-fractional live
if(key>=kNModule*kNChip*kNWing*kNSubWing)
- {Error("AliITSPlaneEffSDD::GetFracBad","you asked for a non existing key");
+ {AliError("GetFracBad: you asked for a non existing key");
return -1.;}
return 1.-GetFracLive(key);
}
Bool_t AliITSPlaneEffSDD::WriteIntoCDB() const {
// write onto CDB
if(!fInitCDBCalled)
- {Error("AliITSPlaneEffSDD::WriteIntoCDB","CDB not inizialized: call InitCDB first");
+ {AliError("WriteIntoCDB: CDB not inizialized: call InitCDB first");
return kFALSE;}
// to be written properly: now only for debugging
AliCDBMetaData *md= new AliCDBMetaData(); // metaData describing the object
Bool_t AliITSPlaneEffSDD::ReadFromCDB() {
// read from CDB
if(!fInitCDBCalled)
- {Error("AliITSPlaneEffSDD::ReadFromCDB","CDB not inizialized: call InitCDB first");
+ {AliError("ReadFromCDB: CDB not inizialized: call InitCDB first");
return kFALSE;}
//if(!AliCDBManager::Instance()->IsDefaultStorageSet()) {
// AliCDBManager::Instance()->SetDefaultStorage("local://$ALICE_ROOT");
eff->Copy(*this);
return kTRUE;
}
+//_____________________________________________________________________________
+UInt_t AliITSPlaneEffSDD::GetKeyFromDetLocCoord(Int_t ilay, Int_t idet,
+ Float_t locx, Float_t locz) const {
+// method to locate a basic block from Detector Local coordinate (to be used in tracking)
+//
+// If kNSubWing = 1, i.e. no sub-wing subdivision, then the numbering scheme of the
+// unique key is the following, e.g. for the first detector (idet=0, ilayer=2)
+//
+// ^x_loc (cm)
+// |
+// _________________________|__________________________ 3.5085
+// | | | | |
+// | | | | |
+// | | | | |
+// | key=1 | key=3 | key=5 | key=7 |
+// | | | | |
+// |____________|____________|____________|____________|_0_____\ local z (cm)
+// | | | | | /
+// | | | | |
+// | key=0 | key=2 | key=4 | key=6 |
+// | | | | |
+// | | | | |
+// |____________|____________|____________|____________| -3.5085
+//-3.7632 -1.8816 0 1.1186 3.7632
+//
+// for the second detector (idet=2, ilay=2), first key is 8 (bottom-left),
+// last one is 15 (upper-right), and so on.
+//
+// If subwing division has been applied, then you count in each wing, starting from
+// the one with negative local , from the anode side (outer part) towards the
+// cathod strip (center).
+// first column:
+// bottom wing (from below): 0,1,..,kNSubWing-1,
+// upper wing (from up): kNSubWing, ... , 2*kNSubWing-1
+// 2nd column
+// bottom wing (from below): 2*kNSubWing, .. , 3*kNSubWing-1
+// upper wing (from up): 3*kNSubWing, ... ,4*kNSubWing-1
+// ...
+// 4nd (last) column :
+// bottom wing (from below): 6*kNSubWing, .. , 7*kNSubWing-1
+// upper wing (from up): 7*kNSubWing, ... ,8*kNSubWing-1
+//
+// E.g. kNSubWing=2.
+//
+// ^x_loc (cm)
+// |
+// _________________________|__________________________ 3.5085
+// | | | | |
+// | key=2 | key=6 | key=10 | key=14 |
+// |____________|____________|____________|____________|
+// | | | | |
+// | key=3 | key=7 | key=11 | key=15 |
+// |____________|____________|____________|____________|_0_____\ local z (cm)
+// | | | | | /
+// | key=1 | key=5 | key=9 | key=13 |
+// |____________|____________|____________|____________|
+// | | | | |
+// | key=0 | key=4 | key=8 | key=12 |
+// |____________|____________|____________|____________| -3.5085
+//-3.7632 -1.8816 0 1.1186 3.7632
+//
+//___________________________________________________________________________
+//
+UInt_t key=999999;
+if(ilay<2 || ilay>3)
+ {AliError("GetKeyFromDetLocCoord: you asked for a non existing layer");
+ return key;}
+if(ilay==2 && (idet<0 || idet>83))
+ {AliError("GetKeyFromDetLocCoord: you asked for a non existing detector");
+ return key;}
+if(ilay==3 && (idet<0 || idet>175))
+ {AliError("GetKeyFromDetLocCoord: you asked for a non existing detector");
+ return key;}
+UInt_t mod=idet;
+if(ilay==3) mod+=84;
+UInt_t chip=0,wing=0,subw=0;
+ChipAndWingAndSubWingFromLocCoor(locx,locz,chip,wing,subw);
+key=GetKey(mod,chip,wing,subw);
+return key;
+}
+//_____________________________________________________________________________
+void AliITSPlaneEffSDD::ChipAndWingAndSubWingFromLocCoor(Float_t xloc, Float_t zloc,
+ UInt_t& chip, UInt_t& wing, UInt_t& subw) const {
+AliITSgeom* geom=NULL;
+//AliITSsegmentationSDD* sdd=new AliITSsegmentationSDD(geom);
+AliITSsegmentationSDD sdd=AliITSsegmentationSDD(geom);
+sdd.SetDriftSpeed(sdd.GetDriftSpeed()); // this only for setting fSetDriftSpeed=kTRUE !!!
+Int_t ix,iz;
+Int_t ntb;
+UInt_t anode=0;
+if(sdd.LocalToDet(xloc,zloc,ix,iz)) {
+ anode+=iz;
+ ChipAndWingFromAnode(anode,chip,wing);
+ if(sdd.LocalToDet(0.,0.,ntb,iz)) { // in this way the sub-division along time coordinate
+ subw=SubWingFromTimeBin(ix,ntb); } // is purely geometrical one and it does not
+ else { // depen on the drift-velocity.
+ AliError("ChipAndWingAndSubWingFromLocCoor: cannot calculate n. of time bins for SubWing.");
+ subw=9;
+ }
+} else {
+ AliError("ChipAndWingAndSubWingFromLocCoor: cannot calculate anode number and time bin.");
+ chip=999;
+ wing=99;
+ subw=9;
+}
+delete geom;
+}
+//__________________________________________________________________________________
+UInt_t AliITSPlaneEffSDD::SubWingFromTimeBin(const Int_t tb, const Int_t ntb) const {
+if(tb<0 || tb>ntb || ntb<0) {
+ AliError(Form("SubWingFromTimeBin: you asked time bin = %d with %d n. of bins",tb,ntb));
+ return 9;
+}
+//AliDebug(Form("tb = %d, ntb= %d , NSubWing = %d",tb,ntb,kNSubWing));
+Float_t h=tb;
+ h/=ntb;
+ h*=(kNSubWing-1);
+return TMath::Nint(h);
+}
enum {kNSubWing = 1}; // Eventually sub-divide each wing (by 2 ?) to account for different
// efficiencies due to different drift times.
enum {kNAnode = 64}; // Number of channels/chip (i.e. anodes per chip)
- enum {kNTimeBin = 72}; // granularity along drift direction (i.e. segmentation in r-phi)
+ //enum {kNTimeBin = 174}; // granularity along drift direction (i.e. segmentation in r-phi)
//
// Plane efficiency for active detector (excluding dead/noisy channels)
// access to DB is needed
virtual Bool_t ReadFromCDB(); // this method reads Data Members (statistics) from DataBase
virtual Bool_t AddFromCDB() // this method updates Data Members (statistics) from DataBase
{AliError("AddFromCDB: Still To be implemented"); return kFALSE;}
+ // method to locate a basic block from Detector Local coordinate (to be used in tracking)
+ // see file cxx for numbering convention.
+ // here idet runs from 0 to 83 for layer 2 and from 0 to 175 for layer 3
+ UInt_t GetKeyFromDetLocCoord(Int_t ilay,Int_t idet, Float_t locx, Float_t locz) const;
+ UInt_t Nblock() const; // return the number of basic blocks
protected:
virtual void Copy(TObject &obj) const;
UInt_t ChipFromAnode(const UInt_t anode) const; // return the chip number (from 0 to kNChip-1)
UInt_t WingFromAnode(const UInt_t anode) const; // return the wing number (from 0 to kNWing-1)
void ChipAndWingFromAnode(const UInt_t anode,UInt_t& chip,UInt_t& wing) const;
+ // return the Subwing (from 0 to kNSubWing-1) from the cell time bin in the range
+ // [0,ntb] and from the number of time bins
+ UInt_t SubWingFromTimeBin(const Int_t tb, const Int_t ntb) const;
+
+ void ChipAndWingAndSubWingFromLocCoor(Float_t locx, Float_t locz,
+ UInt_t& chip, UInt_t& wing, UInt_t& subw) const;
//
void GetAllFromKey(const UInt_t key, UInt_t& mod, UInt_t& chip,
UInt_t& wing, UInt_t& subw) const;
ClassDef(AliITSPlaneEffSDD,1) // SDD Plane Efficiency class
};
+//
+inline UInt_t AliITSPlaneEffSDD::Nblock() const {return kNModule*kNChip*kNWing*kNSubWing;}
+//
#endif
#include "AliCDBEntry.h"
#include "AliCDBManager.h"
//#include "AliCDBRunRange.h"
+//#include "AliITSsegmentationSPD.h"
#include "AliITSCalibrationSPD.h"
ClassImp(AliITSPlaneEffSPD)
// Return:
if(&s == this) return *this;
- Error("AliITSPlaneEffSPD","Not allowed to make a = with "
- "AliITSPlaneEffSPD","Using default creater instead");
-
+ AliError("operator=: Not allowed to make a =, use default creater instead");
return *this;
}
//_______________________________________________________________________
// Return: the estimated n. of tracks
//
if (im>=kNModule || ic>=kNChip)
- {Error("AliITSPlaneEffSPD","you asked for a non existing chip");
+ {AliError("GetMissingTracksForGivenEff: you asked for a non existing chip");
return -1;}
else return GetNTracksForGivenEff(eff,RelErr)-fTried[GetKey(im,ic)];
}
// im -> module number [0,249]
// ic -> chip number [0,4]
if (im>=kNModule || ic>=kNChip)
- {Error("AliITSPlaneEffSPD","you asked for a non existing chip"); return -1.;}
+ {AliError("PlaneEff(Uint_t,Uint_t): you asked for a non existing chip"); return -1.;}
Int_t nf=fFound[GetKey(im,ic)];
Int_t nt=fTried[GetKey(im,ic)];
return AliITSPlaneEff::PlaneEff(nf,nt);
// im -> module number [0,249]
// ic -> chip number [0,4]
if (im>=kNModule || ic>=kNChip)
- {Error("AliITSPlaneEffSPD","you asked for a non existing chip"); return -1.;}
+ {AliError("ErrPlaneEff(Uint_t,Uint_t): you asked for a non existing chip"); return -1.;}
Int_t nf=fFound[GetKey(im,ic)];
Int_t nt=fTried[GetKey(im,ic)];
return AliITSPlaneEff::ErrPlaneEff(nf,nt);
const UInt_t im, const UInt_t ic) {
// Update efficiency for a basic block
if (im>=kNModule || ic>=kNChip)
- {Error("AliITSPlaneEffSPD","you asked for a non existing chip"); return kFALSE;}
+ {AliError("UpDatePlaneEff: you asked for a non existing chip"); return kFALSE;}
fTried[GetKey(im,ic)]++;
if(Kfound) fFound[GetKey(im,ic)]++;
return kTRUE;
UInt_t AliITSPlaneEffSPD::GetChipFromCol(const UInt_t col) const {
// get chip given the column
if(col>=kNCol*kNChip)
- {Error("AliITSPlaneEffSPD","you asked for a non existing column"); return 10;}
+ {AliDebug(1,Form("GetChipFromCol: you asked for a non existing column %d",col)); return 10;}
return col/kNCol;
}
//__________________________________________________________________________
UInt_t AliITSPlaneEffSPD::GetKey(const UInt_t mod, const UInt_t chip) const {
// get key given a basic block
if(mod>=kNModule || chip>=kNChip)
- {Error("AliITSPlaneEffSPD::GetKey","you asked for a non existing block"); return 99999;}
+ {AliWarning("GetKey: you asked for a non existing block"); return 99999;}
return mod*kNChip+chip;
}
//__________________________________________________________________________
UInt_t AliITSPlaneEffSPD::GetModFromKey(const UInt_t key) const {
// get mod. from key
if(key>=kNModule*kNChip)
- {Error("AliITSPlaneEffSPD::GetModFromKey","you asked for a non existing key"); return 9999;}
+ {AliError("GetModFromKey: you asked for a non existing key"); return 9999;}
return key/kNChip;
}
//__________________________________________________________________________
UInt_t AliITSPlaneEffSPD::GetChipFromKey(const UInt_t key) const {
// retrieves chip from key
if(key>=kNModule*kNChip)
- {Error("AliITSPlaneEffSPD::GetChipFromKey","you asked for a non existing key"); return 999;}
+ {AliError("GetChipFromKey: you asked for a non existing key"); return 999;}
return (key%(kNModule*kNChip))%kNChip;
}
//__________________________________________________________________________
void AliITSPlaneEffSPD::GetModAndChipFromKey(const UInt_t key,UInt_t& mod,UInt_t& chip) const {
// get module and chip from a key
if(key>=kNModule*kNChip)
- {Error("AliITSPlaneEffSPD::GetModAndChipFromKey","you asked for a non existing key");
+ {AliError("GetModAndChipFromKey: you asked for a non existing key");
mod=9999;
chip=999;
return;}
Double_t AliITSPlaneEffSPD::LivePlaneEff(UInt_t key) const {
// returns plane efficieny after adding the fraction of sensor which is bad
if(key>=kNModule*kNChip)
- {Error("AliITSPlaneEffSPD::LivePlaneEff","you asked for a non existing key");
+ {AliError("LivePlaneEff: you asked for a non existing key");
return -1.;}
Double_t leff=AliITSPlaneEff::LivePlaneEff(0); // this just for the Warning
leff=PlaneEff(key)+GetFracBad(key);
Double_t AliITSPlaneEffSPD::ErrLivePlaneEff(UInt_t key) const {
// returns error on live plane efficiency
if(key>=kNModule*kNChip)
- {Error("AliITSPlaneEffSPD::ErrLivePlaneEff","you asked for a non existing key");
+ {AliError("ErrLivePlaneEff: you asked for a non existing key");
return -1.;}
Int_t nf=fFound[key];
Double_t triedInLive=GetFracLive(key)*fTried[key];
Double_t AliITSPlaneEffSPD::GetFracLive(const UInt_t key) const {
// returns the fraction of the sensor which is OK
if(key>=kNModule*kNChip)
- {Error("AliITSPlaneEffSPD::GetFracLive","you asked for a non existing key");
+ {AliError("GetFracLive: you asked for a non existing key");
return -1.;}
// Compute the fraction of bad (dead+noisy) detector
UInt_t dead=0,noisy=0;
nrDeadInChip=0;
nrNoisyInChip=0;
if(key>=kNModule*kNChip)
- {Error("AliITSPlaneEffSPD::GetDeadAndNoisyInChip","you asked for a non existing key");
+ {AliError("GetDeadAndNoisyInChip: you asked for a non existing key");
return;}
// Compute the number of bad (dead+noisy) pixel in a chip
//
if(!fInitCDBCalled)
- {Error("AliITSPlaneEffSPD::GetDeadAndNoisyInChip","CDB not inizialized: call InitCDB first");
+ {AliError("GetDeadAndNoisyInChip: CDB not inizialized: call InitCDB first");
return;};
AliCDBManager* man = AliCDBManager::Instance();
// retrieve map of dead Pixel
if(cdbSPDDead) {
spdDead = (TObjArray*)cdbSPDDead->GetObject();
if(!spdDead)
- {Error("AliITSPlaneEffSPD::GetDeadAndNoisyInChip"," SPDDead not found in CDB");
+ {AliError("GetDeadAndNoisyInChip: SPDDead not found in CDB");
return;}
} else {
- Error("AliITSPlaneEffSPD::GetDeadAndNoisyInChip","Did not find Calib/SPDDead.");
+ AliError("GetDeadAndNoisyInChip: did not find Calib/SPDDead.");
return;
}
// retrieve map of noisy Pixel
if(cdbSPDNoisy) {
spdNoisy = (TObjArray*)cdbSPDNoisy->GetObject();
if(!spdNoisy)
- {Error("AliITSPlaneEffSPD::GetDeadAndNoisyInChip"," SPDNoisy not found in CDB");
+ {AliError("GetDeadAndNoisyInChip: SPDNoisy not found in CDB");
return;}
} else {
- Error("AliITSPlaneEffSPD::GetDeadAndNoisyInChip","Did not find Calib/SPDNoisy.");
+ AliError("GetDeadAndNoisyInChip: did not find Calib/SPDNoisy.");
return;
}
//
Double_t AliITSPlaneEffSPD::GetFracBad(const UInt_t key) const {
// returns 1-fractional live
if(key>=kNModule*kNChip)
- {Error("AliITSPlaneEffSPD::GetFracBad","you asked for a non existing key");
+ {AliError("GetFracBad: you asked for a non existing key");
return -1.;}
return 1.-GetFracLive(key);
}
Bool_t AliITSPlaneEffSPD::WriteIntoCDB() const {
// write onto CDB
if(!fInitCDBCalled)
- {Error("AliITSPlaneEffSPD::WriteIntoCDB","CDB not inizialized: call InitCDB first");
+ {AliError("WriteIntoCDB: CDB not inizialized. Call InitCDB first");
return kFALSE;}
// to be written properly: now only for debugging
AliCDBMetaData *md= new AliCDBMetaData(); // metaData describing the object
Bool_t AliITSPlaneEffSPD::ReadFromCDB() {
// read from CDB
if(!fInitCDBCalled)
- {Error("AliITSPlaneEffSPD::ReadFromCDB","CDB not inizialized: call InitCDB first");
+ {AliError("ReadFromCDB: CDB not inizialized. Call InitCDB first");
return kFALSE;}
//if(!AliCDBManager::Instance()->IsDefaultStorageSet()) {
// AliCDBManager::Instance()->SetDefaultStorage("local://$ALICE_ROOT");
eff->Copy(*this);
return kTRUE;
}
+//_____________________________________________________________________________
+UInt_t AliITSPlaneEffSPD::GetKeyFromDetLocCoord(Int_t ilay, Int_t idet,
+ Float_t, Float_t locz) const {
+// method to locate a basic block from Detector Local coordinate (to be used in tracking)
+UInt_t key=999999;
+if(ilay<0 || ilay>1)
+ {AliError("GetKeyFromDetLocCoord: you asked for a non existing layer");
+ return key;}
+if(ilay==0 && (idet<0 || idet>79))
+ {AliError("GetKeyFromDetLocCoord: you asked for a non existing detector");
+ return key;}
+if(ilay==1 && (idet<0 || idet>159))
+ {AliError("GetKeyFromDetLocCoord: you asked for a non existing detector");
+ return key;}
+
+UInt_t mod=idet;
+if(ilay==1) mod+=80;
+key=GetKey(mod,GetChipFromCol(GetColFromLocZ(locz)));
+return key;
+}
+//_____________________________________________________________________________
+UInt_t AliITSPlaneEffSPD::GetColFromLocZ(Float_t zloc) const {
+UInt_t col=0;
+/* note: as it is now, the AliITSsegmentationSPD::Init() does not properly initialize (6 chips !!!)
+AliITSsegmentationSPD spd;
+spd.Init();
+Int_t ix,iz;
+if(spd.LocalToDet(0,zloc,ix,iz)) col+=iz;
+else {
+ AliError("GetColFromLocZ: cannot compute column number from local z");
+ col=99999;}
+return col;
+*/
+const Float_t kconv = 1.0E-04; // converts microns to cm.
+Float_t bz[160];
+for(Int_t i=000;i<160;i++) bz[i] = 425.0; // most are 425 microns except below
+bz[ 31] = bz[ 32] = 625.0; // first chip boundry
+bz[ 63] = bz[ 64] = 625.0; // first chip boundry
+bz[ 95] = bz[ 96] = 625.0; // first chip boundry
+bz[127] = bz[128] = 625.0; // first chip boundry
+//
+Int_t j=-1;
+Float_t dz=0;
+for(Int_t i=000;i<160;i++) dz+=bz[i];
+dz = -0.5*kconv*dz;
+if(zloc<dz || zloc>-1*dz) { // outside z range
+ AliDebug(1,Form("GetColFromLocZ: cannot compute column number from local z=%f",zloc));
+ return 99999;}
+for(j=0;j<160;j++){
+ dz += kconv*bz[j];
+ if(zloc<dz) break;
+} // end for j
+col+=j;
+//
+return col;
+}
+//________________________________________________________
AliITSPlaneEffSPD(const AliITSPlaneEffSPD &source);
// ass. operator
AliITSPlaneEffSPD& operator=(const AliITSPlaneEffSPD &s);
- virtual AliITSPlaneEff& operator=(const AliITSPlaneEff &source);
+ AliITSPlaneEff& operator=(const AliITSPlaneEff &source);
+ //AliPlaneEff& operator=(const AliPlaneEff &source);
// Simple way to add another class (i.e. statistics).
AliITSPlaneEffSPD& operator +=( const AliITSPlaneEffSPD &add);
// Getters for average Plane efficiency (icluding dead/noisy)
virtual Bool_t ReadFromCDB(); // this method reads Data Members (statistics) from DataBase
virtual Bool_t AddFromCDB() // this method updates Data Members (statistics) from DataBase
{AliError("AddFromCDB: Still To be implemented"); return kFALSE;}
+ // method to locate a basic block from Detector Local coordinate (to be used in tracking)
+ // see file cxx for numbering convention.
+ // here idet runs from 0 to 79 for layer 0 and from 0 to 159 for layer 1
+ UInt_t GetKeyFromDetLocCoord(Int_t ilay,Int_t idet, Float_t, Float_t locz) const;
+ UInt_t Nblock() const; // return the number of basic blocks
protected:
virtual void Copy(TObject &obj) const;
UInt_t GetModFromKey(const UInt_t key) const;
UInt_t GetChipFromKey(const UInt_t key) const;
UInt_t GetChipFromCol(const UInt_t col) const; // get the chip number (from 0 to kNChip)
+ UInt_t GetColFromLocZ(Float_t zloc) const; // get the Column from the local z
void GetModAndChipFromKey(const UInt_t key, UInt_t& mod, UInt_t& chip) const;
void GetDeadAndNoisyInChip(const UInt_t key, UInt_t& dead, UInt_t& noisy) const;
ClassDef(AliITSPlaneEffSPD,1) // SPD Plane Efficiency class
};
+//
+inline UInt_t AliITSPlaneEffSPD::Nblock() const {return kNModule*kNChip;}
+//
#endif
//
///////////////////////////////////////////////////////////////////////////
-/* $Id$ */
+/* $Id$ */
#include <TMath.h>
#include "AliITSPlaneEffSSD.h"
//______________________________________________________________________
AliITSPlaneEffSSD::AliITSPlaneEffSSD():
AliITSPlaneEff(){
- // Default constructor
for (UInt_t i=0; i<kNModule; i++){
fFound[i]=0;
fTried[i]=0;
// Return:
if(&s == this) return *this;
- Error("AliITSPlaneEffSSD","Not allowed to make a = with "
- "AliITSPlaneEffSSD","Using default creater instead");
-
+ AliError("operator=: Not allowed to make a =, use default creater instead");
return *this;
}
//_______________________________________________________________________
// Return: the estimated n. of tracks
//
if (im>=kNModule)
- {Error("AliITSPlaneEffSSD","you asked for a non existing module");
+ {AliError("GetMissingTracksForGivenEff: you asked for a non existing module");
return -1;}
else return GetNTracksForGivenEff(eff,RelErr)-fTried[GetKey(im)];
}
// Inputs:
// im -> module number [0,1697]
if (im>=kNModule)
- {Error("AliITSPlaneEffSSD","you asked for a non existing module"); return -1.;}
+ {AliError("PlaneEff(UInt_t): you asked for a non existing module"); return -1.;}
Int_t nf=fFound[GetKey(im)];
Int_t nt=fTried[GetKey(im)];
return AliITSPlaneEff::PlaneEff(nf,nt);
// Inputs:
// im -> module number [0,1697]
if (im>=kNModule)
- {Error("AliITSPlaneEffSSD","you asked for a non existing module"); return -1.;}
+ {AliError("ErrPlaneEff(UInt_t): you asked for a non existing module"); return -1.;}
Int_t nf=fFound[GetKey(im)];
Int_t nt=fTried[GetKey(im)];
return AliITSPlaneEff::ErrPlaneEff(nf,nt);
Bool_t AliITSPlaneEffSSD::UpDatePlaneEff(const Bool_t Kfound, const UInt_t im) {
// Update efficiency for a basic block
if (im>=kNModule)
- {Error("AliITSPlaneEffSSD","you asked for a non existing module"); return kFALSE;}
+ {AliError("UpDatePlaneEff: you asked for a non existing module"); return kFALSE;}
fTried[GetKey(im)]++;
if(Kfound) fFound[GetKey(im)]++;
return kTRUE;
UInt_t AliITSPlaneEffSSD::GetKey(const UInt_t mod) const {
// get key given a basic block
if(mod>=kNModule)
- {Error("AliITSPlaneEffSSD::GetKey","you asked for a non existing block"); return 99999;}
+ {AliError("GetKey: you asked for a non existing block"); return 99999;}
return mod;
}
//__________________________________________________________________________
UInt_t AliITSPlaneEffSSD::GetModFromKey(const UInt_t key) const {
// get mod. from key
if(key>=kNModule)
- {Error("AliITSPlaneEffSSD::GetModFromKey","you asked for a non existing key"); return 9999;}
+ {AliError("GetModFromKey: you asked for a non existing key"); return 9999;}
return key;
}
//__________________________________________________________________________
Double_t AliITSPlaneEffSSD::LivePlaneEff(UInt_t key) const {
// returns plane efficieny after adding the fraction of sensor which is bad
if(key>=kNModule)
- {Error("AliITSPlaneEffSSD::LivePlaneEff","you asked for a non existing key");
+ {AliError("LivePlaneEff: you asked for a non existing key");
return -1.;}
Double_t leff=AliITSPlaneEff::LivePlaneEff(0); // this just for the Warning
leff=PlaneEff(key)+GetFracBad(key);
Double_t AliITSPlaneEffSSD::ErrLivePlaneEff(UInt_t key) const {
// returns error on live plane efficiency
if(key>=kNModule)
- {Error("AliITSPlaneEffSSD::ErrLivePlaneEff","you asked for a non existing key");
+ {AliError("ErrLivePlaneEff: you asked for a non existing key");
return -1.;}
Int_t nf=fFound[key];
Double_t triedInLive=GetFracLive(key)*fTried[key];
Double_t AliITSPlaneEffSSD::GetFracLive(const UInt_t key) const {
// returns the fraction of the sensor which is OK
if(key>=kNModule)
- {Error("AliITSPlaneEffSSD::GetFracLive","you asked for a non existing key");
+ {AliError("GetFracLive: you asked for a non existing key");
return -1.;}
// Compute the fraction of bad (dead+noisy) detector
UInt_t bad=0;
// returns the number of dead and noisy pixels
nrBadInMod=0;
if(key>=kNModule)
- {Error("AliITSPlaneEffSSD::GetDeadAndNoisyInModule","you asked for a non existing key");
+ {AliError("GetBadInModule: you asked for a non existing key");
return;}
// Compute the number of bad (dead+noisy) pixel in a module
//
if(!fInitCDBCalled)
- {Error("AliITSPlaneEffSSD::GetDeadAndNoisyInModule","CDB not inizialized: call InitCDB first");
+ {AliError("GetBadInModule: CDB not inizialized: call InitCDB first");
return;};
AliCDBManager* man = AliCDBManager::Instance();
// retrieve map of dead Pixel
if(cdbSSD) {
ssdEntry = (TObjArray*)cdbSSD->GetObject();
if(!ssdEntry)
- {Error("AliITSPlaneEffSSD::GetDeadAndNoisyInChip"," SSDEntry not found in CDB");
+ {AliError("GetBadInChip: SSDEntry not found in CDB");
return;}
} else {
- Error("AliITSPlaneEffSSD::GetDeadAndNoisyInChip","Did not find Calib/BadChannelsSSD");
+ AliError("GetBadInChip: did not find Calib/BadChannelsSSD");
return;
}
//
Double_t AliITSPlaneEffSSD::GetFracBad(const UInt_t key) const {
// returns 1-fractional live
if(key>=kNModule)
- {Error("AliITSPlaneEffSSD::GetFracBad","you asked for a non existing key");
+ {AliError("GetFracBad: you asked for a non existing key");
return -1.;}
return 1.-GetFracLive(key);
}
Bool_t AliITSPlaneEffSSD::WriteIntoCDB() const {
// write onto CDB
if(!fInitCDBCalled)
- {Error("AliITSPlaneEffSSD::WriteIntoCDB","CDB not inizialized: call InitCDB first");
+ {AliError("WriteIntoCDB: CDB not inizialized. Call InitCDB first");
return kFALSE;}
// to be written properly: now only for debugging
AliCDBMetaData *md= new AliCDBMetaData(); // metaData describing the object
Bool_t AliITSPlaneEffSSD::ReadFromCDB() {
// read from CDB
if(!fInitCDBCalled)
- {Error("AliITSPlaneEffSSD::ReadFromCDB","CDB not inizialized: call InitCDB first");
+ {AliError("ReadFromCDB: CDB not inizialized. Call InitCDB first");
return kFALSE;}
//if(!AliCDBManager::Instance()->IsDefaultStorageSet()) {
// AliCDBManager::Instance()->SetDefaultStorage("local://$ALICE_ROOT");
eff->Copy(*this);
return kTRUE;
}
+//_____________________________________________________________________________
+UInt_t AliITSPlaneEffSSD::GetKeyFromDetLocCoord(Int_t ilay, Int_t idet,
+ Float_t, Float_t) const {
+// method to locate a basic block from Detector Local coordinate (to be used in tracking)
+UInt_t key=999999;
+if(ilay<4 || ilay>5)
+ {AliError("GetKeyFromDetLocCoord: you asked for a non existing layer");
+ return key;}
+if(ilay==4 && (idet<0 || idet>747))
+ {AliError("GetKeyFromDetLocCoord: you asked for a non existing detector");
+ return key;}
+if(ilay==5 && (idet<0 || idet>949))
+ {AliError("GetKeyFromDetLocCoord: you asked for a non existing detector");
+ return key;}
+
+UInt_t mod=idet;
+if(ilay==1) mod+=748;
+key=GetKey(mod);
+return key;
+}
virtual Bool_t ReadFromCDB(); // this method reads Data Members (statistics) from DataBase
virtual Bool_t AddFromCDB() // this method updates Data Members (statistics) from DataBase
{AliError("AddFromCDB: Still To be implemented"); return kFALSE;}
+ // method to locate a basic block from Detector Local coordinate (to be used in tracking)
+ // see file cxx for numbering convention.
+ // here idet runs from 0 to 747 for layer 4 and from 0 to 949 for layer 5
+ UInt_t GetKeyFromDetLocCoord(Int_t ilay,Int_t idet, Float_t, Float_t locz) const;
+ UInt_t Nblock() const; // return the number of basic blocks
protected:
virtual void Copy(TObject &obj) const;
ClassDef(AliITSPlaneEffSSD,1) // SSD Plane Efficiency class
};
+//
+inline UInt_t AliITSPlaneEffSSD::Nblock() const {return kNModule;}
+//
#endif
#include "AliTrackPointArray.h"
#include "AliAlignObj.h"
#include "AliITSClusterParam.h"
-#include "AliITSPlaneEff.h"
#include "AliCDBManager.h"
#include "AliCDBEntry.h"
#include "AliITSCalibrationSPD.h"
#include "AliITSCalibrationSDD.h"
#include "AliITSCalibrationSSD.h"
+#include "AliITSPlaneEff.h"
+#include "AliITSPlaneEffSPD.h"
+#include "AliITSPlaneEffSDD.h"
+#include "AliITSPlaneEffSSD.h"
#include "AliITStrackerMI.h"
ClassImp(AliITStrackerMI)
fDebugStreamer = new TTreeSRedirector("ITSdebug.root");
+ // only for plane efficiency evaluation
+ if (AliITSReconstructor::GetRecoParam()->GetComputePlaneEff()) {
+ for(Int_t ilay=0;ilay<6;ilay++) {
+ if(AliITSReconstructor::GetRecoParam()->GetLayersToSkip(ilay)) {
+ if (ilay<2) fPlaneEff = new AliITSPlaneEffSPD();
+ else if (ilay<4) fPlaneEff = new AliITSPlaneEffSDD();
+ else fPlaneEff = new AliITSPlaneEffSSD();
+ break; // only one layer type to skip at once
+ }
+ }
+ if(!fPlaneEff->ReadFromCDB())
+ {AliWarning("AliITStrackerMI reading of AliITSPlaneEff from OCDB failed") ;}
+ }
}
//------------------------------------------------------------------------
AliITStrackerMI::AliITStrackerMI(const AliITStrackerMI &tracker):AliTracker(tracker),
fTrackToFollow.ResetCovariance(10.);
//Refitting...
- if (RefitAt(AliITSRecoParam::GetrInsideSPD1(),&fTrackToFollow,t,kTRUE)) {
+ Bool_t pe=AliITSReconstructor::GetRecoParam()->GetComputePlaneEff();
+ if (RefitAt(AliITSRecoParam::GetrInsideSPD1(),&fTrackToFollow,t,kTRUE,pe)) {
fTrackToFollow.SetLabel(t->GetLabel());
// fTrackToFollow.CookdEdx();
CookdEdx(&fTrackToFollow);
}
//------------------------------------------------------------------------
Bool_t AliITStrackerMI::RefitAt(Double_t xx,AliITStrackMI *track,
- const AliITStrackMI *clusters,Bool_t extra)
+ const AliITStrackMI *clusters,Bool_t extra, Bool_t planeeff)
{
//--------------------------------------------------------------------
// This function refits the track "track" at the position "x" using
// the clusters from "clusters"
// If "extra"==kTRUE,
// the clusters from overlapped modules get attached to "track"
+ // If "planeff"==kTRUE,
+ // special approach for plane efficiency evaluation is applyed
//--------------------------------------------------------------------
Int_t index[AliITSgeomTGeo::kNLayers];
index[ilayer]=idx;
}
- return RefitAt(xx,track,index,extra); // call the method below
+ return RefitAt(xx,track,index,extra,planeeff); // call the method below
}
//------------------------------------------------------------------------
Bool_t AliITStrackerMI::RefitAt(Double_t xx,AliITStrackMI *track,
- const Int_t *clusters,Bool_t extra)
+ const Int_t *clusters,Bool_t extra, Bool_t planeeff)
{
//--------------------------------------------------------------------
// This function refits the track "track" at the position "x" using
// the clusters from array
// If "extra"==kTRUE,
// the clusters from overlapped modules get attached to "track"
+ // If "planeff"==kTRUE,
+ // special approach for plane efficiency evaluation is applyed
//--------------------------------------------------------------------
Int_t index[AliITSgeomTGeo::kNLayers];
Int_t k;
maxchi2=chi2;
modstatus = 1; // found
} else {
- return kFALSE;
+ return kFALSE; //
}
}
} else { // no cluster in this layer
if (skip==1) {
modstatus = 3; // skipped
+ if (planeeff) { // Plane Eff determination:
+ if (IsOKForPlaneEff(track,ilayer)) // only adequate track for plane eff. evaluation
+ UseTrackForPlaneEff(track,ilayer);
+ }
} else {
modstatus = 5; // no cls in road
// check dead
return kTRUE;
}
//------------------------------------------------------------------------
+Bool_t AliITStrackerMI::IsOKForPlaneEff(AliITStrackMI* track, Int_t ilayer) const {
+// Method still to be implemented:
+//
+// it will apply a pre-selection to obtain good quality tracks.
+// Here also you will have the possibility to put a control on the
+// impact point of the track on the basic block, in order to exclude border regions
+// this will be done by calling a proper method of the AliITSPlaneEff class.
+//
+// input: AliITStrackMI* track, ilayer= layer number [0,5]
+// output: Bool_t -> kTRUE if usable track, kFALSE if not usable.
+return kTRUE;
+}
+//------------------------------------------------------------------------
+void AliITStrackerMI::UseTrackForPlaneEff(AliITStrackMI* track, Int_t ilayer) {
+//
+// This Method has to be optimized! For the time-being it uses the same criteria
+// as those used in the search of extra clusters for overlapping modules.
+//
+// Method Purpose: estabilish whether a track has produced a recpoint or not
+// in the layer under study (For Plane efficiency)
+//
+// inputs: AliITStrackMI* track (pointer to a usable track)
+// outputs: none
+// side effects: update (by 1 count) the Plane Efficiency statistics of the basic block
+// traversed by this very track. In details:
+// - if a cluster can be associated to the track then call
+// AliITSPlaneEff::UpDatePlaneEff(key,kTRUE);
+// - if not, the AliITSPlaneEff::UpDatePlaneEff(key,kFALSE) is called
+//
+ AliITSlayer &layer=fgLayers[ilayer];
+ Double_t r=layer.GetR();
+ //AliITStrackV2 tmp(*track);
+ AliITStrackMI tmp(*track);
+
+// detector number
+ Double_t phi,z;
+ if (!tmp.GetPhiZat(r,phi,z)) return;
+ Int_t idet=layer.FindDetectorIndex(phi,z);
+
+ if(idet<0) return;
+
+ Double_t trackGlobXYZ1[3];
+ tmp.GetXYZ(trackGlobXYZ1);
+
+// Get the budget to the primary vertex for the current track being prolonged
+ Double_t budgetToPrimVertex = GetEffectiveThickness();
+
+//propagate to the intersection with the detector plane
+ const AliITSdetector &det=layer.GetDetector(idet);
+ if (!tmp.Propagate(det.GetPhi(),det.GetR())) return;
+
+ //Float_t xloc,zloc;
+
+//***************
+// DEFINITION OF SEARCH ROAD FOR CLUSTERS SELECTION
+//
+ Double_t dz=AliITSReconstructor::GetRecoParam()->GetNSigmaRoadZ()*
+ TMath::Sqrt(tmp.GetSigmaZ2() +
+ AliITSReconstructor::GetRecoParam()->GetNSigmaZLayerForRoadZ()*
+ AliITSReconstructor::GetRecoParam()->GetNSigmaZLayerForRoadZ()*
+ AliITSReconstructor::GetRecoParam()->GetSigmaZ2(ilayer));
+ Double_t dy=AliITSReconstructor::GetRecoParam()->GetNSigmaRoadY()*
+ TMath::Sqrt(tmp.GetSigmaY2() +
+ AliITSReconstructor::GetRecoParam()->GetNSigmaYLayerForRoadY()*
+ AliITSReconstructor::GetRecoParam()->GetNSigmaYLayerForRoadY()*
+ AliITSReconstructor::GetRecoParam()->GetSigmaY2(ilayer));
+
+// road in global (rphi,z) [i.e. in tracking ref. system]
+ Double_t zmin = tmp.GetZ() - dz;
+ Double_t zmax = tmp.GetZ() + dz;
+ Double_t ymin = tmp.GetY() + r*det.GetPhi() - dy;
+ Double_t ymax = tmp.GetY() + r*det.GetPhi() + dy;
+
+// select clusters in road
+ layer.SelectClusters(zmin,zmax,ymin,ymax);
+
+// Define criteria for track-cluster association
+ Double_t msz = tmp.GetSigmaZ2() +
+ AliITSReconstructor::GetRecoParam()->GetNSigmaZLayerForRoadZ()*
+ AliITSReconstructor::GetRecoParam()->GetNSigmaZLayerForRoadZ()*
+ AliITSReconstructor::GetRecoParam()->GetSigmaZ2(ilayer);
+ Double_t msy = tmp.GetSigmaY2() +
+ AliITSReconstructor::GetRecoParam()->GetNSigmaYLayerForRoadY()*
+ AliITSReconstructor::GetRecoParam()->GetNSigmaYLayerForRoadY()*
+ AliITSReconstructor::GetRecoParam()->GetSigmaY2(ilayer);
+ // if (constrain) {
+ msz *= AliITSReconstructor::GetRecoParam()->GetNSigma2RoadZC();
+ msy *= AliITSReconstructor::GetRecoParam()->GetNSigma2RoadYC();
+ // } else {
+ // msz *= AliITSReconstructor::GetRecoParam()->GetNSigma2RoadZNonC();
+ // msy *= AliITSReconstructor::GetRecoParam()->GetNSigma2RoadYNonC();
+ // }
+ msz = 1./msz; // 1/RoadZ^2
+ msy = 1./msy; // 1/RoadY^2
+//
+
+ const AliITSRecPoint *cl=0; Int_t clidx=-1, ci=-1;
+ Int_t idetc=-1;
+ Double_t maxchi2=1000.*AliITSReconstructor::GetRecoParam()->GetMaxChi2(), tolerance=0.1;
+ while ((cl=layer.GetNextCluster(clidx))!=0) {
+ idetc = cl->GetDetectorIndex();
+ if(idet!=idetc) continue;
+ //Int_t ilay = cl->GetLayer();
+
+ if (TMath::Abs(tmp.GetZ() - cl->GetZ()) > tolerance) continue;
+ if (TMath::Abs(tmp.GetY() - cl->GetY()) > tolerance) continue;
+
+ Double_t chi2=tmp.GetPredictedChi2(cl);
+ if (chi2<maxchi2) { maxchi2=chi2; ci=clidx; }
+ }
+ Float_t locx; // to be changed (if no cluster)
+ Float_t locz; // to be changed (if no cluster)
+ LocalModuleCoord(ilayer,idet,&tmp,locx,locz);
+//
+ AliDebug(2,Form("ilayer= %d, idet=%d, x= %f, z=%f",ilayer,idet,locx,locz));
+ UInt_t key=fPlaneEff->GetKeyFromDetLocCoord(ilayer,idet,locx,locz);
+ if(key>fPlaneEff->Nblock()) return;
+ Bool_t found=kFALSE;
+ if (ci>=0) {
+ cl=layer.GetCluster(ci);
+ // here real control to see whether the cluster can be associated to the track.
+ // if() ....
+ found=kTRUE;
+ // track->SetExtraCluster(ilayer,(ilayer<<28)+ci);
+ // track->SetExtraModule(ilayer,idetExtra);
+ }
+ if(!fPlaneEff->UpDatePlaneEff(found,key))
+ AliError(Form("UseTrackForPlaneEff: cannot UpDate PlaneEff for key=%d",key));
+return;
+}
#include "AliITSRecPoint.h"
#include "AliITStrackMI.h"
#include "AliITSPlaneEff.h"
+#include "AliPlaneEff.h"
#include "AliTracker.h"
//-------------------------------------------------------------------------
Int_t PropagateBack(AliESDEvent *event);
Int_t RefitInward(AliESDEvent *event);
Bool_t RefitAt(Double_t x, AliITStrackMI *track,
- const AliITStrackMI *clusters, Bool_t extra=kFALSE);
+ const AliITStrackMI *clusters, Bool_t extra=kFALSE, Bool_t planeeff=kFALSE);
Bool_t RefitAt(Double_t x, AliITStrackMI *track,
- const Int_t *clusters, Bool_t extra=kFALSE);
+ const Int_t *clusters, Bool_t extra=kFALSE, Bool_t planeeff=kFALSE);
void SetupFirstPass(Int_t *flags, Double_t *cuts=0);
void SetupSecondPass(Int_t *flags, Double_t *cuts=0);
void GetDCASigma(AliITStrackMI* track, Float_t & sigmarfi, Float_t &sigmaz);
Double_t GetPredictedChi2MI(AliITStrackMI* track, const AliITSRecPoint *cluster,Int_t layer);
Int_t UpdateMI(AliITStrackMI* track, const AliITSRecPoint* cl,Double_t chi2,Int_t layer) const;
+ AliPlaneEff *GetPlaneEff() {return (AliPlaneEff*)fPlaneEff;} // return the pointer to AliPlaneEff
class AliITSdetector {
public:
AliITSdetector():fR(0),fPhi(0),fSinPhi(0),fCosPhi(0),fYmin(0),fYmax(0),fZmin(0),fZmax(0){}
Int_t CheckDeadZone(/*AliITStrackMI *track,*/Int_t ilayer,Int_t idet,Double_t zmin,Double_t zmax/*,Double_t ymin,Double_t ymax*/) const;
Bool_t LocalModuleCoord(Int_t ilayer,Int_t idet,AliITStrackMI *track,
Float_t &xloc,Float_t &zloc) const;
+// method to be used for Plane Efficiency evaluation
+ Bool_t IsOKForPlaneEff(AliITStrackMI* track, Int_t ilayer) const; // Check if a track is usable
+ // for Plane Eff evaluation
+ void UseTrackForPlaneEff(AliITStrackMI* track, Int_t ilayer); // Use this track for Plane Eff
+//
Int_t fI; // index of the current layer
static AliITSlayer fgLayers[AliITSgeomTGeo::kNLayers];// ITS layers
AliITStrackMI fTracks[AliITSgeomTGeo::kNLayers]; // track estimations at the ITS layers
+#if !defined(__CINT__) || defined(__MAKECINT__)
+#include <TRandom3.h>
+#include "AliCDBManager.h"
+#include "AliCDBMetaData.h"
+#include "AliCDBStorage.h"
+#include "AliCDBRunRange.h"
+#include "AliCDBId.h"
+#include "AliITSPlaneEffSDD.h"
+#endif
void MakeITSPlaneEfficiencySDD(Int_t firstRun=0,Int_t lastRun=AliCDBRunRange::Infinity()){
if(!AliCDBManager::Instance()->IsDefaultStorageSet()) {
md1->SetObjectClassName("AliITSPlaneEff");
md1->SetResponsible("Giuseppe Bruno");
md1->SetBeamPeriod(0);
- md1->SetAliRootVersion("head 02/01/08"); //root version
+ md1->SetAliRootVersion("head 16/01/08"); //root version
AliCDBId idplaneeffSDD("ITS/PlaneEff/PlaneEffSDD",firstRun, lastRun);
AliITSPlaneEffSDD* planeeffSDD = new AliITSPlaneEffSDD();
+ TRandom3 *gran = new TRandom3();
// planeeffSDD->SetOwner(kFALSE);
// suppose to have 1000 tracks in each block and an average efficiency of 99%
for(Int_t j=0; j<1000; j++) {
BFound=kFALSE;
- if (gRandom->Uniform(0,1000)>10) BFound=kTRUE;
+ //if (gRandom->Uniform(0,1000)>10) BFound=kTRUE;
+ if (1000*gran->Uniform()>10) BFound=kTRUE;
planeeffSDD->UpDatePlaneEff(BFound,mod,chip,wing,subw);
}
}}}}
if(AliCDBManager::Instance()->GetDefaultStorage()->Put(planeeffSDD, idplaneeffSDD, md1))
- {cout << "Riuscito " << endl;}
+ printf("Local CDB file with random SDD plane efficiencies written \n");
+ delete gran;
+ delete planeeffSDD;
+ delete md1;
}
-void MakeITSPlaneEfficiencySPD(Int_t firstRun=0,Int_t lastRun=AliCDBRunRange::Infinity()){
+#if !defined(__CINT__) || defined(__MAKECINT__)
+#include <TRandom3.h>
+#include "AliCDBManager.h"
+#include "AliCDBMetaData.h"
+#include "AliCDBStorage.h"
+#include "AliCDBRunRange.h"
+#include "AliCDBId.h"
+#include "AliITSPlaneEffSPD.h"
+#endif
+
+void MakeITSPlaneEfficiencySPD(Int_t firstRun=0, Int_t lastRun=AliCDBRunRange::Infinity(),
+ Double_t eff=0.99, Int_t nTried=1000){
+ if(eff<0 || eff > 1) {
+ printf("Efficiency must be in the range [0,1]: nothing done");
+ }
if(!AliCDBManager::Instance()->IsDefaultStorageSet()) {
AliCDBManager::Instance()->SetDefaultStorage("local://$ALICE_ROOT");
}
md1->SetObjectClassName("AliITSPlaneEff");
md1->SetResponsible("Giuseppe Bruno");
md1->SetBeamPeriod(0);
- md1->SetAliRootVersion("head 19/11/07"); //root version
+ md1->SetAliRootVersion("head 16/02/08"); //root version
AliCDBId idplaneeffSPD("ITS/PlaneEff/PlaneEffSPD",firstRun, lastRun);
AliITSPlaneEffSPD* planeeffSPD = new AliITSPlaneEffSPD();
+ TRandom3 *gran = new TRandom3();
// planeeffSPD->SetOwner(kFALSE);
-
+// Int_t nTried=1000;
+ Double_t limit=nTried;
+ limit*=(1-eff);
+ printf("limit = %f",limit);
// loop over SPD chip
Bool_t BFound=kFALSE;
- //for(Int_t key=0;key<1200;key++){
- for(UInt_t mod=0;mod<240;mod++){
- for(UInt_t chip=0;chip<5;chip++){
+ for(UInt_t key=0;key<planeeffSPD->Nblock();key++){
+ //for(UInt_t mod=0;mod<240;mod++){
+ //for(UInt_t chip=0;chip<5;chip++){
// suppose to have 1000 tracks in each chip and an average efficiency of 99%
- for(Int_t j=0; j<1000; j++) {
+ for(Int_t j=0; j<nTried; j++) {
BFound=kFALSE;
- if (gRandom->Uniform(0,1000)>10) BFound=kTRUE;
- planeeffSPD->UpDatePlaneEff(BFound,mod,chip);
+ //if (gRandom->Uniform(0,1000)>10) BFound=kTRUE;
+ if (nTried*gran->Uniform()>limit) BFound=kTRUE;
+ //planeeffSPD->UpDatePlaneEff(BFound,mod,chip);
+ planeeffSPD->UpDatePlaneEff(BFound,key);
}
- }}
+ //}}
+ }
if(AliCDBManager::Instance()->GetDefaultStorage()->Put(planeeffSPD, idplaneeffSPD, md1))
- {cout << "Riuscito " << endl;}
-}
\ No newline at end of file
+ printf("Local CDB file with random SPD plane efficiencies written \n");
+ delete gran;
+ delete planeeffSPD;
+ delete md1;
+}
+#if !defined(__CINT__) || defined(__MAKECINT__)
+#include <TRandom3.h>
+#include "AliCDBManager.h"
+#include "AliCDBMetaData.h"
+#include "AliCDBStorage.h"
+#include "AliCDBRunRange.h"
+#include "AliCDBId.h"
+#include "AliITSPlaneEffSSD.h"
+#endif
+
void MakeITSPlaneEfficiencySSD(Int_t firstRun=0,Int_t lastRun=AliCDBRunRange::Infinity()){
if(!AliCDBManager::Instance()->IsDefaultStorageSet()) {
AliCDBId idplaneeffSSD("ITS/PlaneEff/PlaneEffSSD",firstRun, lastRun);
AliITSPlaneEffSSD* planeeffSSD = new AliITSPlaneEffSSD();
+ TRandom3 *gran = new TRandom3();
// planeeffSSD->SetOwner(kFALSE);
// suppose to have 1000 tracks in each module and an average efficiency of 99%
for(Int_t j=0; j<1000; j++) {
BFound=kFALSE;
- if (gRandom->Uniform(0,1000)>10) BFound=kTRUE;
+ //if (gRandom->Uniform(0,1000)>10) BFound=kTRUE;
+ if (1000*gran->Uniform()>10) BFound=kTRUE;
planeeffSSD->UpDatePlaneEff(BFound,mod);
}
}
if(AliCDBManager::Instance()->GetDefaultStorage()->Put(planeeffSSD, idplaneeffSSD, md1))
- {cout << "Riuscito " << endl;}
+ printf("Local CDB file with random SSD plane efficiencies written \n");
+ delete gran;
+ delete planeeffSSD;
+ delete md1;
}
--- /dev/null
+/**************************************************************************
+ * Copyright(c) 2007-2009, 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. *
+ **************************************************************************/
+///////////////////////////////////////////////////////////////////////////
+// Virtual base Plane Efficiency class
+// Specific detector implementation is done in
+// AliITSPlaneEff
+// AliTRDPlaneEff
+// AliTOFPlaneEff
+//
+// Author: G.E. Bruno
+// giuseppe.bruno@ba.infn.it
+//
+///////////////////////////////////////////////////////////////////////////
+
+
+#include <TMath.h>
+#include "AliPlaneEff.h"
+#include "AliLog.h"
+//#include "AliCDBManager.h"
+//#include "AliCDBStorage.h"
+
+ClassImp(AliPlaneEff)
+//______________________________________________________________________
+AliPlaneEff::AliPlaneEff(): TObject()/*,
+fRunNumber(0),
+fCDBUri(""),
+fInitCDBCalled(kFALSE)*/
+{
+ // Default constructor
+ // Inputs:
+ // none.
+ // Outputs:
+ // none.
+ // Return:
+ // a default constructed AliPlaneEff class
+ //InitCDB();
+}
+//______________________________________________________________________
+AliPlaneEff::AliPlaneEff(const AliPlaneEff &s) : TObject(s)/*,
+fRunNumber(s.fRunNumber),
+fCDBUri(s.fCDBUri),
+fInitCDBCalled(s.fInitCDBCalled)*/
+{
+ // Copy Constructor
+ // Inputs:
+ // const AliPlaneEff &s simulation class to copy from
+ // Outputs:
+ // none.
+ // Return:
+ // a standard constructed AliPlaneEff class with values the same
+ // as that of s.
+
+}
+//_________________________________________________________________________
+AliPlaneEff& AliPlaneEff::operator=(const AliPlaneEff &source){
+ // Assignment operator
+ // Inputs:
+ // const AliPlaneEff &source simulation class to copy from
+ // Outputs:
+ // none.
+ // Return:
+ // a standard constructed AliPlaneEff class with values the same
+ // as that of s.
+ if(this != &source){
+ source.Copy(*this);
+ }
+ return *this;
+}
+//_____________________________________________________________
+void AliPlaneEff::Copy(TObject &obj) const {
+ // copy this to obj
+/* ((AliPlaneEff& ) obj).fRunNumber = fRunNumber;
+ ((AliPlaneEff& ) obj).fCDBUri = fCDBUri;
+ ((AliPlaneEff& ) obj).fInitCDBCalled = fInitCDBCalled;
+*/
+}
+//_________________________________________________________________________
--- /dev/null
+#ifndef ALIPLANEEFF_H
+#define ALIPLANEEFF_H
+/* Copyright(c) 2007-2009, ALICE Experiment at CERN, All rights reserved. *
+ * See cxx source for full Copyright notice */
+
+#include <TObject.h>
+#include <TString.h>
+#include "AliLog.h"
+
+//class Alisegmentation;
+//class Aligeom;
+
+////////////////////////////////////////////////////
+// //
+// Virtual base class for Plane Efficiency //
+// Origin: Giuseppe.Bruno@ba.infn.it //
+// //
+////////////////////////////////////////////////////
+
+class AliPlaneEff : public TObject {
+ public:
+
+ AliPlaneEff();// Default constructor
+ virtual ~AliPlaneEff(){;};
+ // copy constructor. See detector specific implementation.
+ AliPlaneEff(const AliPlaneEff &source);
+ // Assignment operator. See detector specific implementation.
+ AliPlaneEff& operator=(const AliPlaneEff &source);
+ // Average Plane efficiency (including dead/noisy)
+ //Int_t GetRunNumber() const {return fRunNumber;}
+ //void SetRunNumber(Int_t n) {fRunNumber=n;}
+ //
+ // Write into the data base
+ virtual Bool_t WriteIntoCDB() const
+ {AliError("This method must be implemented in a derived class"); return kFALSE;};
+ virtual Bool_t ReadFromCDB()
+ {AliError("This method must be implemented in a derived class"); return kFALSE;};
+ virtual Bool_t AddFromCDB()
+ {AliError("This method must be implemented in a derived class"); return kFALSE;};
+
+ protected:
+
+ virtual void InitCDB(){;};
+ virtual void Copy(TObject &obj) const;
+ //Int_t fRunNumber; //! run number (to access CDB)
+ //TString fCDBUri; //! Uri of the default CDB storage
+ //Bool_t fInitCDBCalled; //! flag to check if CDB storages are already initialized
+
+ private:
+ //Int_t fRunNumber; // run number (to access CDB)
+
+ ClassDef(AliPlaneEff,1) // Plane Efficiency virtual base class
+};
+#endif
#include "AliQA.h"
#include "AliQADataMakerSteer.h"
+#include "AliPlaneEff.h"
+
#include "AliSysInfo.h" // memory snapshots
fSetRunNumberFromDataCalled(kFALSE),
fRunQA(kTRUE),
fRunGlobalQA(kFALSE),
- fInLoopQA(kFALSE)
+ fInLoopQA(kFALSE),
+
+ fRunPlaneEff(kFALSE)
{
// create reconstruction object with default parameters
fSetRunNumberFromDataCalled(rec.fSetRunNumberFromDataCalled),
fRunQA(rec.fRunQA),
fRunGlobalQA(rec.fRunGlobalQA),
- fInLoopQA(rec.fInLoopQA)
+ fInLoopQA(rec.fInLoopQA),
+ fRunPlaneEff(rec.fRunPlaneEff)
{
// copy constructor
}
}
+ //Initialize the Plane Efficiency framework
+ if (fRunPlaneEff && !InitPlaneEff()) {
+ if(fStopOnError) {CleanUp(file, fileOld); return kFALSE;}
+ }
//******* The loop over events
for (Int_t iEvent = 0; iEvent < fRunLoader->GetNumberOfEvents(); iEvent++) {
esdFile->Close();
}
+// Finish with Plane Efficiency evaluation
+ if (fRunPlaneEff && !FinishPlaneEff()) {
+ AliWarning("Finish PlaneEff evaluation failed");
+ }
+
+ gROOT->cd();
+ CleanUp(file, fileOld);
+
// Create tags for the events in the ESD tree (the ESD tree is always present)
// In case of empty events the tags will contain dummy values
AliESDTagCreator *esdtagCreator = new AliESDTagCreator();
}
return index ;
}
+//_____________________________________________________________________________
+Bool_t AliReconstruction::FinishPlaneEff() {
+ //
+ // Here execute all the necessary operationis, at the end of the tracking phase,
+ // in case that evaluation of PlaneEfficiencies was required for some detector.
+ // E.g., write into a DataBase file the PlaneEfficiency which have been evaluated.
+ //
+ // This Preliminary version works only FOR ITS !!!!!
+ // other detectors (TOF,TRD, etc. have to develop their specific codes)
+ //
+ // Input: none
+ // Return: kTRUE if all operations have been done properly, kFALSE otherwise
+ //
+ Bool_t ret=kFALSE;
+ //for (Int_t iDet = 0; iDet < fgkNDetectors; iDet++) {
+ for (Int_t iDet = 0; iDet < 1; iDet++) { // for the time being only ITS
+ //if (!IsSelected(fgkDetectorName[iDet], detStr)) continue;
+ //if(fReconstructor[iDet]->GetRecoParam()->GetComputePlaneEff()) continue;
+ ret=fTracker[iDet]->GetPlaneEff()->WriteIntoCDB();
+ }
+ return ret;
+}
+//_____________________________________________________________________________
+Bool_t AliReconstruction::InitPlaneEff() {
+//
+ // Here execute all the necessary operations, before of the tracking phase,
+ // for the evaluation of PlaneEfficiencies, in case required for some detectors.
+ // E.g., read from a DataBase file a first evaluation of the PlaneEfficiency
+ // which should be updated/recalculated.
+ //
+ // This Preliminary version will work only FOR ITS !!!!!
+ // other detectors (TOF,TRD, etc. have to develop their specific codes)
+ //
+ // Input: none
+ // Return: kTRUE if all operations have been done properly, kFALSE otherwise
+ //
+ AliWarning(Form("Implementation of this method not yet done !! Method return kTRUE"));
+ return kTRUE;
+}
void SetRunGlobalQA(Bool_t flag=kTRUE){fRunGlobalQA = flag;}
void SetInLoopQA(Bool_t flag=kTRUE) {fInLoopQA = flag;}
+ // Plane Efficiency Evaluation
+ void SetRunPlaneEff(Bool_t flag=kFALSE) {fRunPlaneEff = flag;}
+
private:
void InitCDB();
void SetCDBLock();
const Int_t GetQACycles(const char * detector) { return fQACycles[GetDetIndex(detector)] ; }
void CheckQA() ;
+ // Plane Efficiency evaluation
+ Bool_t FinishPlaneEff(); //ultimate tasks related to Plane Eff. evaluation
+ Bool_t InitPlaneEff(); // initialize what is needed for Plane Eff. evaluation
+
//*** Global reconstruction flags *******************
Bool_t fUniformField; // uniform field tracking flag
Bool_t fRunVertexFinder; // run the vertex finder
Bool_t fRunQA ; // Run QA flag
Bool_t fRunGlobalQA; // Run global QA flag
Bool_t fInLoopQA; // In-loop QA flag
+ // Plane Efficiency Evaluation
+ Bool_t fRunPlaneEff ; // Evaluate Plane Efficiency
ClassDef(AliReconstruction, 19) // class for running the reconstruction
};
// Origin: Iouri Belikov, CERN, Jouri.Belikov@cern.ch
//-------------------------------------------------------------------------
#include <TObject.h>
+#include <AliPlaneEff.h>
class TTree;
class AliMagF;
virtual Int_t LoadClusters(TTree *)=0;
virtual void UnloadClusters()=0;
virtual AliCluster *GetCluster(Int_t index) const=0;
+ virtual AliPlaneEff *GetPlaneEff() {return NULL;}
virtual Bool_t GetTrackPoint(Int_t /* index */ , AliTrackPoint& /* p */) const { return kFALSE;}
virtual Bool_t GetTrackPointTrackingError(Int_t /* index */,
AliTrackPoint& /* p */, const AliESDtrack* /* t */) { return kFALSE;}
#pragma link C++ class AliSurveyObj+;
#pragma link C++ class AliSurveyPoint+;
+#pragma link C++ class AliCodeTimer+;
+#pragma link C++ class AliCodeTimer::AliPair+;
+
#pragma link C++ class AliFstream+;
#pragma link C++ class AliCTPRawData+;
#pragma link C++ class AliDetectorRecoParam+;
#pragma link C++ class AliRecoParam+;
+#pragma link C++ class AliPlaneEff+;
#endif
AliSelectorRL.cxx \
AliMagFMapsV1.cxx \
AliSurveyObj.cxx AliSurveyPoint.cxx \
+AliCodeTimer.cxx \
AliFstream.cxx \
AliCTPRawData.cxx \
AliQADataMaker.cxx \
AliQACheckerBase.cxx \
AliMillepede.cxx \
AliRecoParam.cxx \
-AliDetectorRecoParam.cxx
-
+AliDetectorRecoParam.cxx \
+AliPlaneEff.cxx
HDRS:= $(SRCS:.cxx=.h)