#include "AliITSLoader.h"
#include "AliITSMultReconstructor.h"
#include "AliITSRecPointContainer.h"
+#include "AliRunLoader.h"
const Float_t AliITSVertexer::fgkPipeRadius = 3.0;
//////////////////////////////////////////////////////////////////////
// Base class for primary vertex reconstruction //
// AliESDVertexer is a class for full 3D primary vertex finding //
-// derived classes: AliITSVertexerIons AliITSvertexer3D //
+// derived classes: AliITSvertexer3D, AliITSVertexerZ. //
// AliITSVertexerCosmics //
//////////////////////////////////////////////////////////////////////
//______________________________________________________________________
AliITSVertexer::AliITSVertexer():AliVertexer(),
-fLadders(),
+fLadders(NULL),
fLadOnLay2(0),
+fComputeMultiplicity(kFALSE),
fDetTypeRec(NULL),
fMinTrackletsForPilup(0),
fIsPileup(0),
// Invokes AliITSMultReconstructor to determine the
// charged multiplicity in the pixel layers
if(fMult){delete fMult; fMult = 0;}
+
Bool_t success=kTRUE;
Bool_t cosmics=kFALSE;
if(!fCurrentVertex)success=kFALSE;
if(!success){
if(!cosmics) {
- AliWarning("Tracklets multiplicity not determined because the primary vertex was not found");
- AliWarning("Just counting the number of cluster-fired chips on the SPD layers");
+ AliDebug(1,"Tracklets multiplicity not determined because the primary vertex was not found");
+ AliDebug(1,"Just counting the number of cluster-fired chips on the SPD layers");
}
if (!itsClusterTree) {
AliError(" Invalid ITS cluster tree !\n");
multReco.LoadClusterFiredChips(itsClusterTree);
Short_t nfcL1 = multReco.GetNFiredChips(0);
Short_t nfcL2 = multReco.GetNFiredChips(1);
- fMult = new AliMultiplicity(0,0,0,0,0,0,0,0,0,0,nfcL1,nfcL2,fastOrFiredMap);
+ fMult = new AliMultiplicity(0,0,0,0,0,0,0,0,0,0,0,nfcL1,nfcL2,fastOrFiredMap);
fMult->SetFiredChipMap(firedChipMap);
AliITSRecPointContainer* rcont = AliITSRecPointContainer::Instance();
fMult->SetITSClusters(0,rcont->GetNClustersInLayer(1,itsClusterTree));
Int_t nosingleclus=multReco.GetNSingleClusters();
Float_t *ths = new Float_t [nosingleclus];
Float_t *phs = new Float_t [nosingleclus];
+ Int_t *labelss = new Int_t [nosingleclus];
for(Int_t i=0;i<nosingleclus;i++){
ths[i] = multReco.GetCluster(i)[0];
phs[i] = multReco.GetCluster(i)[1];
+ labelss[i] = (Int_t)multReco.GetCluster(i)[2];
}
Short_t nfcL1 = multReco.GetNFiredChips(0);
Short_t nfcL2 = multReco.GetNFiredChips(1);
- fMult = new AliMultiplicity(notracks,tht,phi,dtht,dphi,labels,labelsL2,nosingleclus,ths,phs,nfcL1,nfcL2,fastOrFiredMap);
+ fMult = new AliMultiplicity(notracks,tht,phi,dtht,dphi,labels,labelsL2,nosingleclus,ths,phs,labelss,nfcL1,nfcL2,fastOrFiredMap);
fMult->SetFiredChipMap(firedChipMap);
AliITSRecPointContainer* rcont = AliITSRecPointContainer::Instance();
fMult->SetITSClusters(0,rcont->GetNClustersInLayer(1,itsClusterTree));
delete [] phs;
delete [] labels;
delete [] labelsL2;
+ delete [] labelss;
return;
}
void AliITSVertexer::SetLaddersOnLayer2(Int_t ladwid){
// Calculates the array of ladders on layer 2 to be used with a
// given ladder on layer 1
+ if(ladwid == fLadOnLay2 && fLadders)return;
fLadOnLay2=ladwid;
Int_t ladtot1=AliITSgeomTGeo::GetNLadders(1);
if(fLadders) delete [] fLadders;
}
}
-#include "AliRunLoader.h"
//______________________________________________________________________
void AliITSVertexer::Init(TString filename){
// analysis of an entire file
AliRunLoader *rl = AliRunLoader::Instance();
if(!rl){
- Fatal("AliITSVertexer","Run Loader not found");
+ AliFatal("Run Loader not found");
+ return;
}
if (fLastEvent < 0) SetLastEvent(rl->GetNumberOfEvents()-1);