// AliITSVertexerCosmics //
//////////////////////////////////////////////////////////////////////
+/* $Id$ */
+
//______________________________________________________________________
AliITSVertexer::AliITSVertexer():AliVertexer(),
fLadders(),
{
// Default Constructor
SetLaddersOnLayer2();
+ for(Int_t i=0; i<kNSPDMod;i++) fUseModule[i]=kTRUE;
}
//______________________________________________________________________
// //
///////////////////////////////////////////////////////////////////
+/* $Id$ */
+
class TString;
class AliITSVertexer : public AliVertexer {
void SetLastEvent(Int_t ev){fLastEvent = ev;}
const Float_t GetPipeRadius()const {return fgkPipeRadius;}
void SetLaddersOnLayer2(Int_t ladwid=4);
+ virtual void SetUseModule(Int_t imod, Bool_t optUse){
+ if(imod>=0 && imod<kNSPDMod) fUseModule[imod]=optUse;
+ }
+ virtual Bool_t IsModuleUsed(Int_t imod) const {
+ if(imod>=0 && imod<kNSPDMod) return fUseModule[imod];
+ else return 0;
+ }
+ enum{kNSPDMod=240};
// Methods containing run-loaders, should be moved to some other class
void Init(TString filename);
UShort_t *fLadders; // array with layer1-layer2 ladders correspondances
Int_t fLadOnLay2; // (2*fLadOnLay2+1)=number of layer2 ladders
// associated to a layer1 ladder
+ Bool_t fUseModule[kNSPDMod]; // flag for enabling/disabling SPD modules
private:
// copy constructor (NO copy allowed: the constructor is protected
Int_t fFirstEvent; // First event to be processed by FindVertices
Int_t fLastEvent; // Last event to be processed by FindVertices
- ClassDef(AliITSVertexer,5);
+ ClassDef(AliITSVertexer,6);
};
#endif
Int_t nolines = 0;
// Loop on modules of layer 1
for(Int_t modul1= firstL1; modul1<=lastL1;modul1++){ // Loop on modules of layer 1
+ if(!fUseModule[modul1]) continue;
UShort_t ladder=int(modul1/4)+1; // ladders are numbered starting from 1
branch->GetEvent(modul1);
Int_t nrecp1 = itsRec->GetEntries();
Int_t ladmod=fLadders[ladder-1]+ladl2;
if(ladmod>AliITSgeomTGeo::GetNLadders(2)) ladmod=ladmod-AliITSgeomTGeo::GetNLadders(2);
Int_t modul2=AliITSgeomTGeo::GetModuleIndex(2,ladmod,k+1);
+ if(!fUseModule[modul2]) continue;
branch->GetEvent(modul2);
Int_t nrecp2 = itsRec->GetEntries();
for(Int_t j2=0;j2<nrecp2;j2++){
static TClonesArray points("AliITSZPoint",maxdim);
Int_t nopoints =0;
for(Int_t modul1= fFirstL1; modul1<=fLastL1;modul1++){ // Loop on modules of layer 1
+ if(!fUseModule[modul1]) continue;
UShort_t ladder=int(modul1/4)+1; // ladders are numbered starting from 1
branch->GetEvent(modul1);
Int_t nrecp1 = itsRec->GetEntries();
Int_t ladmod=fLadders[ladder-1]+ladl2;
if(ladmod>AliITSgeomTGeo::GetNLadders(2)) ladmod=ladmod-AliITSgeomTGeo::GetNLadders(2);
Int_t modul2=AliITSgeomTGeo::GetModuleIndex(2,ladmod,k+1);
+ if(!fUseModule[modul2]) continue;
branch->GetEvent(modul2);
Int_t nrecp2 = itsRec->GetEntries();
for(Int_t j2=0;j2<nrecp2;j2++){
TH1F *hc = fZCombc;
- if(hc->GetBinContent(hc->GetMaximumBin())<3)hc->Rebin(3);
+ if(hc->GetBinContent(hc->GetMaximumBin())<3)hc->Rebin(4);
Int_t binmin,binmax;
Int_t nPeaks=GetPeakRegion(hc,binmin,binmax);
if(nPeaks==2)AliWarning("2 peaks found");