Changeset 4125 for trunk/MagicSoft/Mars


Ignore:
Timestamp:
05/22/04 14:52:30 (21 years ago)
Author:
gaug
Message:
*** empty log message ***
Location:
trunk/MagicSoft/Mars
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/MagicSoft/Mars/Changelog

    r4124 r4125  
    3030       Allocation (like suggested by TBretz).
    3131
    32    * mcalib/MCalibrationRelTimeCalc.cc
     32   * mcalib/MCalibrationRelTimeCalc.[h,cc]
    3333     - replaced the relative limit for acceptance of the time resolution
    3434       by an absolute limit
  • trunk/MagicSoft/Mars/mcalib/MCalibrationRelTimeCalc.cc

    r3982 r4125  
    7272using namespace std;
    7373
    74 const Float_t MCalibrationRelTimeCalc::fgRelTimeRelErrLimit      = 10.;
     74const Float_t MCalibrationRelTimeCalc::fgRelTimeResolutionLimit = 1.;
    7575// --------------------------------------------------------------------------
    7676//
     
    8080//
    8181// Initializes:
    82 // - fRelTimeRelErrLimit to fgRelTimeRelErrimit
     82// - fRelTimeResolutionLimit to fgRelTimeResolutionimit
    8383//
    8484// Calls:
     
    9292  fTitle = title ? title : "Task to finalize the relative time calibration";
    9393 
    94   SetRelTimeRelErrLimit();
     94  SetRelTimeResolutionLimit();
    9595 
    9696  Clear();
     
    238238
    239239  PrintUncalibrated(MBadPixelsPix::kDeviatingTimeResolution,   
    240                     Form("%s%2.1f%s","Time resolution less than ",fRelTimeRelErrLimit," sigma from Mean:   "));
     240                    Form("%s%2.1f%s","Time resolution less than ",fRelTimeResolutionLimit," FADC slices from Mean:   "));
    241241  PrintUncalibrated(MBadPixelsPix::kRelTimeOscillating,   
    242242                    "Pixels with changing Rel. Times   over time:      ");
     
    254254//             MBadPixelsPix::kUnreliableRun (see FinalizeBadPixels())
    255255//             
    256 // Second loop: Exclude those deviating by more than fRelTimeRelErrLimit mean
    257 //              sigmas from the mean (obtained in first loop). Set
     256// Second loop: Exclude those deviating by more than fRelTimeResolutionLimit FADC slices
     257//              from the mean (obtained in first loop). Set
    258258//              MBadPixelsPix::kDeviatingTimeResolution if excluded.
    259259//
     
    267267  Float_t upplim       [nareas];
    268268  Float_t areasum      [nareas];
    269   Float_t areasum2     [nareas];
     269  //  Float_t areasum2     [nareas];
    270270  Int_t   numareavalid [nareas];
    271271  Int_t   useunreliable[nareas];
     
    274274  memset(upplim        ,0, nareas   * sizeof(Float_t));
    275275  memset(areasum       ,0, nareas   * sizeof(Float_t));
    276   memset(areasum2      ,0, nareas   * sizeof(Float_t));
     276  //  memset(areasum2      ,0, nareas   * sizeof(Float_t));
    277277  memset(numareavalid  ,0, nareas   * sizeof(Int_t  ));
    278278  memset(useunreliable ,0, nareas   * sizeof(Int_t  ));
     
    325325
    326326      areasum     [aidx] += res;
    327       areasum2    [aidx] += res*res;
     327      //      areasum2    [aidx] += res*res;
    328328      numareavalid[aidx] ++;
    329329    }
     
    340340 
    341341      // Calculate the rms out of sum2:
     342      /*
    342343      areasum2[aidx]  = (areasum2[aidx] - areasum[aidx]*areasum[aidx]/numareavalid[aidx]);
    343344      areasum2[aidx] /= (numareavalid[aidx]-1.);
     345      */
    344346      areasum [aidx] /= numareavalid[aidx];
    345347      lowlim  [aidx]  = 0.;
    346       upplim  [aidx]  = areasum [aidx] + fRelTimeRelErrLimit*areasum2[aidx];
     348      upplim  [aidx]  = areasum [aidx] + fRelTimeResolutionLimit;
    347349     
    348350      *fLog << endl;
Note: See TracChangeset for help on using the changeset viewer.