virtual Float_t GetEmcEnergyThreshold() = 0 ;
virtual Float_t GetLocalMaxCut() = 0 ;
virtual Float_t GetLogWeightCut() = 0 ;
+ virtual Float_t GetLocalMaxCutCPV() = 0 ;
+ virtual Float_t GetLogWeightCutCPV() = 0 ;
virtual Float_t GetPpsdClusteringThreshold() = 0 ;
virtual Float_t GetPpsdEnergyThreshold() = 0 ;
virtual void SetEmcEnergyThreshold(Float_t enth) = 0 ;
virtual void SetLocalMaxCut(Float_t cut) = 0 ;
virtual void SetLogWeightCut(Float_t w) = 0 ;
+ virtual void SetLocalMaxCutCPV(Float_t cut) = 0 ;
+ virtual void SetLogWeightCutCPV(Float_t w) = 0 ;
virtual void SetPpsdClusteringThreshold(Float_t cluth) = 0 ;
virtual void SetPpsdEnergyThreshold(Float_t enth) = 0 ;
/* $Id$ */
+/* $Log:
+ 1 October 2000. Yuri Kharlov:
+ AreNeighbours()
+ PPSD upper layer is considered if number of layers>1
+
+ 18 October 2000. Yuri Kharlov:
+ AliPHOSClusterizerv1()
+ CPV clusterizing parameters added
+
+ MakeClusters()
+ After first PPSD digit remove EMC digits only once
+*/
+
//_________________________________________________________________________
// Implementation version 1 of the clusterization algorithm
//
fNumberOfPpsdClusters = 0 ;
fEmcClusteringThreshold = 0.1;
fEmcEnergyThreshold = 0.01;
- fPpsdClusteringThreshold = 0.00000015;
- fPpsdEnergyThreshold = 0.0000001;
+ fPpsdClusteringThreshold = 0.0;
+ fPpsdEnergyThreshold = 0.1;
fW0 = 4.5 ;
fLocMaxCut = 0.06 ;
+ fW0CPV = 4.5 ;
+ fLocMaxCutCPV = 0.06 ;
}
//____________________________________________________________________________
rv=2 ;
}
- if((relid1[1]>0) && (relid1[1]<16) ) rv = 2 ; //Do NOT clusterize upper PPSD
+
+ //Do NOT clusterize upper PPSD
+ if(fGeom->GetNumberOfCPVLayers() > 1 &&
+ relid1[1] > 0 &&
+ relid1[1] < fGeom->GetNumberOfPadsPhi()*fGeom->GetNumberOfPadsPhi() ) rv = 2 ;
+
return rv ;
}
TIter next(dl) ;
AliPHOSDigit * digit ;
-
-
-
while ( (digit = (AliPHOSDigit *)next()) ) {
// cout << " clusterizerv1 " << endl ;
AliPHOSDigit ** clusterdigitslist = new AliPHOSDigit*[dl->GetEntries()] ;
Int_t index ;
- if (( ( IsInEmc(digit) ) && ( Calibrate(digit->GetAmp() ) > fEmcClusteringThreshold ) ) ||
+ if (( ( IsInEmc(digit) ) && ( Calibrate(digit->GetAmp() ) > fEmcClusteringThreshold ) ) ||
( ( !IsInEmc(digit) ) && ( Calibrate(digit->GetAmp() ) > fPpsdClusteringThreshold ) ) ) {
Int_t iDigitInCluster = 0 ;
if ( IsInEmc(digit) ) {
// start a new EMC RecPoint
- if(fNumberOfEmcClusters >= emcl->GetSize())
- emcl->Expand(2*fNumberOfEmcClusters+1) ;
+ if(fNumberOfEmcClusters >= emcl->GetSize()) emcl->Expand(2*fNumberOfEmcClusters+1) ;
(*emcl)[fNumberOfEmcClusters] = new AliPHOSEmcRecPoint(fW0, fLocMaxCut) ;
clu = (AliPHOSEmcRecPoint *) emcl->At(fNumberOfEmcClusters) ;
fNumberOfEmcClusters++ ;
iDigitInCluster++ ;
tempodigitslist.Remove(digit) ;
- }
-
- else {
+ } else {
// start a new PPSD cluster
- if(fNumberOfPpsdClusters >= ppsdl->GetSize())
- ppsdl->Expand(2*fNumberOfPpsdClusters+1) ;
-
- (*ppsdl)[fNumberOfPpsdClusters] = new AliPHOSPpsdRecPoint() ;
- clu = (AliPHOSPpsdRecPoint *) ppsdl->At(fNumberOfPpsdClusters) ;
+ if(fNumberOfPpsdClusters >= ppsdl->GetSize()) ppsdl->Expand(2*fNumberOfPpsdClusters+1);
+ if (strcmp(fGeom->GetName(),"GPS2") == 0) {
+ (*ppsdl)[fNumberOfPpsdClusters] = new AliPHOSPpsdRecPoint() ;
+ clu = (AliPHOSPpsdRecPoint *) ppsdl->At(fNumberOfPpsdClusters) ;
+ }
+ else if (strcmp(fGeom->GetName(),"IHEP") == 0) {
+ (*ppsdl)[fNumberOfPpsdClusters] = new AliPHOSEmcRecPoint(fW0CPV, fLocMaxCutCPV) ;
+ clu = (AliPHOSEmcRecPoint *) ppsdl->At(fNumberOfPpsdClusters) ;
+ }
fNumberOfPpsdClusters++ ;
clu->AddDigit(*digit, Calibrate(digit->GetAmp()) ) ;
clusterdigitslist[iDigitInCluster] = digit ;
// Here we remove resting EMC digits, which cannot make cluster
if( notremoved ) {
-
while( ( digit = (AliPHOSDigit *)nextdigit() ) ) {
-
if( IsInEmc(digit) )
tempodigitslist.Remove(digit) ;
else
break ;
-
- } // while digit
-
- } // if notremoved
+ }
+ notremoved = kFALSE ;
+ }
} // else
digit = clusterdigitslist[index] ;
index++ ;
while ( (digitN = (AliPHOSDigit *)nextdigit()) ) { // scan over the reduced list of digits
- Int_t ineb = AreNeighbours(digit, digitN); // call (digit,digitN) in THAT oder !!!!!
+ Int_t ineb = AreNeighbours(digit, digitN); // call (digit,digitN) in THAT oder !!!!!
switch (ineb ) {
case 0 : // not a neighbour
- break ;
+ break ;
case 1 : // are neighbours
clu->AddDigit(*digitN, Calibrate( digitN->GetAmp() ) ) ;
clusterdigitslist[iDigitInCluster] = digitN ;
nextdigit.Reset() ;
} // loop over cluster
- } //below energy theshold
-
+ } //below energy theshold
+
delete[] clusterdigitslist ;
} // while digit
virtual void GetNumberOfClustersFound(Int_t * numb) ;
virtual void GetCalibrationParameters(Float_t & A, Float_t &B) { A = fA; B = fB; }
- virtual Float_t GetEmcClusteringThreshold() { return fEmcClusteringThreshold;}
- virtual Float_t GetEmcEnergyThreshold() { return fEmcEnergyThreshold; }
- virtual Float_t GetLocalMaxCut() { return fLocMaxCut;}
- virtual Float_t GetLogWeightCut() { return fW0;}
+ virtual Float_t GetEmcClusteringThreshold() { return fEmcClusteringThreshold;}
+ virtual Float_t GetEmcEnergyThreshold() { return fEmcEnergyThreshold; }
+ virtual Float_t GetLocalMaxCut() { return fLocMaxCut;}
+ virtual Float_t GetLogWeightCut() { return fW0;}
+ virtual Float_t GetLocalMaxCutCPV() { return fLocMaxCutCPV;}
+ virtual Float_t GetLogWeightCutCPV() { return fW0CPV;}
virtual Float_t GetPpsdClusteringThreshold() { return fPpsdClusteringThreshold; }
- virtual Float_t GetPpsdEnergyThreshold() { return fPpsdEnergyThreshold; }
+ virtual Float_t GetPpsdEnergyThreshold() { return fPpsdEnergyThreshold; }
virtual Bool_t IsInEmc(AliPHOSDigit * digit) ; // Tells if id digit is in EMC
virtual void MakeClusters(const DigitsList * dl,
AliPHOSRecPoint::RecPointsList * ppsdl) ; // does the job
virtual void PrintParameters() ;
virtual void SetCalibrationParameters(Float_t A,Float_t B){ fA = A ; fB = B;}
- virtual void SetEmcClusteringThreshold(Float_t cluth) { fEmcClusteringThreshold = cluth ; }
- virtual void SetEmcEnergyThreshold(Float_t enth) { fEmcEnergyThreshold = enth ; }
- virtual void SetLocalMaxCut(Float_t cut) { fLocMaxCut = cut ; }
- virtual void SetLogWeightCut(Float_t w) { fW0 = w ; }
+ virtual void SetEmcClusteringThreshold(Float_t cluth) { fEmcClusteringThreshold = cluth ; }
+ virtual void SetEmcEnergyThreshold(Float_t enth) { fEmcEnergyThreshold = enth ; }
+ virtual void SetLocalMaxCut(Float_t cut) { fLocMaxCut = cut ; }
+ virtual void SetLogWeightCut(Float_t w) { fW0 = w ; }
+ virtual void SetLocalMaxCutCPV(Float_t cut) { fLocMaxCutCPV = cut ; }
+ virtual void SetLogWeightCutCPV(Float_t w) { fW0CPV = w ; }
virtual void SetPpsdClusteringThreshold(Float_t cluth) { fPpsdClusteringThreshold = cluth ; }
- virtual void SetPpsdEnergyThreshold(Float_t enth) { fPpsdEnergyThreshold = enth ; }
+ virtual void SetPpsdEnergyThreshold(Float_t enth) { fPpsdEnergyThreshold = enth ; }
private:
AliPHOSGeometry * fGeom ; // pointer to geometry
Float_t fEmcClusteringThreshold ; // minimum energy to include a EMC digit in a cluster
Float_t fEmcEnergyThreshold ; // minimum energy of EMC digit to be considered
- Float_t fLocMaxCut ; // minimum energy difference to distinguish local maxima in a cluster
Int_t fNumberOfEmcClusters ; // number of EMC clusters found
Int_t fNumberOfPpsdClusters ; // number of PPSD clusters found
Float_t fPpsdClusteringThreshold ; // minimum energy to include a PPSD digit in a cluster
Float_t fPpsdEnergyThreshold ; // minimum energy of PPSD digit to be considered
+ Float_t fLocMaxCut ; // minimum energy difference to distinguish local maxima in a cluster
Float_t fW0 ; // logarithmic weight for the cluster center of gravity calculation
+
+ Float_t fLocMaxCutCPV ; // minimum energy difference to distinguish local maxima in a CPV cluster
+ Float_t fW0CPV ; // logarithmic weight for the CPV cluster center of gravity calculation
ClassDef(AliPHOSClusterizerv1,1) // Clusterizer implementation version 1