bug fixed in decoding pedestal mean and rms
authorbasanta <basanta@f7af4fe6-9843-0410-8265-dc069ae4e863>
Tue, 14 Oct 2008 16:30:47 +0000 (16:30 +0000)
committerbasanta <basanta@f7af4fe6-9843-0410-8265-dc069ae4e863>
Tue, 14 Oct 2008 16:30:47 +0000 (16:30 +0000)
PMD/AliPMDCalibrator.cxx
PMD/AliPMDClusterFinder.cxx
PMD/AliPMDClusteringV1.cxx
PMD/AliPMDDigitizer.cxx
PMD/AliPMDcluster.cxx
PMD/AliPMDcluster.h

index b78e630..0bfb1e3 100644 (file)
@@ -256,7 +256,7 @@ void AliPMDCalibrator::CalculateIsoCell()
              // Pedestal Subtraction
              Int_t   pedmeanrms = 
                fCalibPed->GetPedMeanRms(idet,ismn,irow,icol);
-             Int_t   pedrms1    = (Int_t) pedmeanrms%1000;
+             Int_t   pedrms1    = (Int_t) pedmeanrms%100;
              Float_t pedrms     = (Float_t)pedrms1/10.;
              Float_t pedmean    = (Float_t) (pedmeanrms - pedrms1)/1000.0;
              Float_t isig = isig1 - (pedmean + 3.0*pedrms);
index 23f555e..a1cff39 100644 (file)
@@ -323,7 +323,7 @@ void AliPMDClusterFinder::Digits2RecPoints(TTree *digitsTree,
          
          // Pedestal Subtraction
          Int_t   pedmeanrms = fCalibPed->GetPedMeanRms(det,smn,xpos,ypos);
-         Int_t   pedrms1    = (Int_t) pedmeanrms%1000;
+         Int_t   pedrms1    = (Int_t) pedmeanrms%100;
          Float_t pedrms     = (Float_t)pedrms1/10.;
          Float_t pedmean    = (Float_t) (pedmeanrms - pedrms1)/1000.0;
          //printf("%f %f\n",pedmean, pedrms);
@@ -489,7 +489,7 @@ void AliPMDClusterFinder::Digits2RecPoints(AliRawReader *rawReader,
 
          // Pedestal Subtraction
          Int_t   pedmeanrms = fCalibPed->GetPedMeanRms(det,smn,row,col);
-         Int_t   pedrms1    = (Int_t) pedmeanrms%1000;
+         Int_t   pedrms1    = (Int_t) pedmeanrms%100;
          Float_t pedrms     = (Float_t)pedrms1/10.;
          Float_t pedmean    = (Float_t) (pedmeanrms - pedrms1)/1000.0;
 
@@ -735,7 +735,7 @@ void AliPMDClusterFinder::Digits2RecPoints(Int_t ievt, AliRawReader *rawReader)
            }
          // Pedestal Subtraction
          Int_t   pedmeanrms = fCalibPed->GetPedMeanRms(det,smn,row,col);
-         Int_t   pedrms1    = (Int_t) pedmeanrms%1000;
+         Int_t   pedrms1    = (Int_t) pedmeanrms%100;
          Float_t pedrms     = (Float_t)pedrms1/10.;
          Float_t pedmean    = (Float_t) (pedmeanrms - pedrms1)/1000.0;
 
index e03a864..a081946 100644 (file)
@@ -849,13 +849,7 @@ void AliPMDClusteringV1::RefClust(Int_t incr, Double_t edepcell[])
              Int_t Ncell=1;
              for (Int_t ii = 0; ii < cellCount[kcl]; ii++)
                {
-                 Float_t xx = x[cellXY[ii][kcl]];
-                 Float_t yy = y[cellXY[ii][kcl]];
-
-                 rr=Distance(xclust[kcl],yclust[kcl],xx,yy);
-                 // Natasha
-                 // We store only the nearest and nest-nearest neighbours
-                 if(rr<2.2) 
+                 if(ii<18) 
                    {   
                      clxy[Ncell] = t[cellXY[ii][kcl]];
                      Ncell++;
index bdd4b76..2c5eb06 100644 (file)
@@ -700,11 +700,10 @@ void AliPMDDigitizer::Hits2Digits(Int_t ievt)
                      // Pedestal Decalibration
                      Int_t   pedmeanrms = 
                          fCalibPed->GetPedMeanRms(idet,ism,jrow,kcol);
-                     Int_t   pedrms1    = (Int_t) pedmeanrms%1000;
+                     Int_t   pedrms1    = (Int_t) pedmeanrms%100;
                      Float_t pedrms     = (Float_t)pedrms1/10.;
                      Float_t pedmean    = 
                          (Float_t) (pedmeanrms - pedrms1)/1000.0;
-                     //printf("%f %f\n",pedmean, pedrms);
                      if (adc > 0.)
                      {
                          adc += (pedmean + 3.0*pedrms);
@@ -792,11 +791,9 @@ void AliPMDDigitizer::SDigits2Digits(Int_t ievt)
          }
          // Pedestal Decalibration
          Int_t   pedmeanrms = fCalibPed->GetPedMeanRms(det,smn,irow,icol);
-         Int_t   pedrms1    = (Int_t) pedmeanrms%1000;
+         Int_t   pedrms1    = (Int_t) pedmeanrms%100;
          Float_t pedrms     = (Float_t)pedrms1/10.;
          Float_t pedmean    = (Float_t) (pedmeanrms - pedrms1)/1000.0;
-         //printf("%f %f\n",pedmean, pedrms);
-         
          if(adc > 0.)
          {
              adc += (pedmean + 3.0*pedrms);
@@ -894,11 +891,10 @@ void AliPMDDigitizer::Exec(Option_t *option)
                      // Pedestal Decalibration
                      Int_t   pedmeanrms = 
                          fCalibPed->GetPedMeanRms(idet,ism,jrow,kcol);
-                     Int_t   pedrms1    = (Int_t) pedmeanrms%1000;
+                     Int_t   pedrms1    = (Int_t) pedmeanrms%100;
                      Float_t pedrms     = (Float_t)pedrms1/10.;
                      Float_t pedmean    = 
                          (Float_t) (pedmeanrms - pedrms1)/1000.0;
-                     //printf("%f %f\n",pedmean, pedrms);
                      if (adc > 0.)
                      {
                          adc += (pedmean + 3.0*pedrms);
index 865fd36..90fc096 100644 (file)
@@ -35,7 +35,7 @@ AliPMDcluster::AliPMDcluster():
     {
       fClusData[i] = 0.;
     }
-  for (Int_t i = 0; i < 15; i++)
+  for (Int_t i = 0; i < 19; i++)
     {
       fClusCellDataX[i] = 0;
       fClusCellDataY[i] = 0;
@@ -53,7 +53,7 @@ AliPMDcluster::AliPMDcluster(Int_t idet, Int_t ismn, Float_t *clusdata,
     {
       fClusData[i] = clusdata[i];
     }
-  for (Int_t i = 0; i < 15; i++)
+  for (Int_t i = 0; i < 19; i++)
     {
       fClusCellDataX[i] = celldataX[i];
       fClusCellDataY[i] = celldataY[i];
@@ -79,7 +79,7 @@ AliPMDcluster::AliPMDcluster(const AliPMDcluster &pmdcluster):
     {
       this->fClusData[i] = pmdcluster.fClusData[i];
     }
-  for(Int_t i=0; i<15; i++)
+  for(Int_t i=0; i<19; i++)
     {
       this->fClusCellDataX[i] = pmdcluster.fClusCellDataX[i];
       this->fClusCellDataY[i] = pmdcluster.fClusCellDataY[i];
@@ -98,7 +98,7 @@ AliPMDcluster & AliPMDcluster::operator=(const AliPMDcluster &pmdcluster)
        {
          this->fClusData[i] = pmdcluster.fClusData[i];
        }
-      for(Int_t i=0; i<15; i++)
+      for(Int_t i=0; i<19; i++)
        {
          this->fClusCellDataX[i] = pmdcluster.fClusCellDataX[i];
          this->fClusCellDataY[i] = pmdcluster.fClusCellDataY[i];
index b2f56b2..59a5da6 100644 (file)
@@ -42,8 +42,8 @@ class AliPMDcluster : public TObject
 
   Int_t   fDet;               // Detector No (0:PRE, 1:CPV)
   Int_t   fSMN;               // Serial Module No.
-  Int_t   fClusCellDataX[15]; // Array containing cell X
-  Int_t   fClusCellDataY[15]; // Array containing cell Y
+  Int_t   fClusCellDataX[19]; // Array containing cell X
+  Int_t   fClusCellDataY[19]; // Array containing cell Y
   Float_t fClusData[6];       // Array containing cluster information
   /*
     fDet         : Det (0:PRE, 1:CPV), fSMN         : SerialModuleNo