Changeset 3840 for trunk/MagicSoft/Mars


Ignore:
Timestamp:
04/26/04 18:56:45 (21 years ago)
Author:
gaug
Message:
*** empty log message ***
Location:
trunk/MagicSoft/Mars
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/MagicSoft/Mars/Changelog

    r3839 r3840  
    5858       IsUnsuitableRun(MBadPixelsPix::kUnsuitableRun). This includes
    5959       now the oscillating pixels (which are sometimes many!!)
     60
     61   * mcalib/MHCalibrationRelTimePix.cc
     62     - commented re-normalization to ns in Renorm()
     63     - introduced Getter to fFADCSliceWidth
     64
     65   * mcalib/MHCalibrationRelTimeCam.cc
     66     - renorm to ns in GetPixelsContent()
     67     --> now, calibration in MCalibrateRelTimes is consistent
     68
    6069
    6170 2004/04/26: Abelardo Moralejo
  • trunk/MagicSoft/Mars/mcalib/MHCalibrationRelTimeCam.cc

    r3738 r3840  
    296296    }
    297297 
    298   const UInt_t npixels  = fGeom->GetNumPixels();
    299   const UInt_t nareas   = fGeom->GetNumAreas();
    300   const UInt_t nsectors = fGeom->GetNumSectors();
     298  const Int_t npixels  = fGeom->GetNumPixels();
     299  const Int_t nareas   = fGeom->GetNumAreas();
     300  const Int_t nsectors = fGeom->GetNumSectors();
    301301
    302302  Float_t sumareahi  [nareas],   sumarealo  [nareas];
     
    349349    }
    350350 
    351   for (UInt_t j=0; j<nareas; j++)
     351  for (Int_t j=0; j<nareas; j++)
    352352    {
    353353      MHGausEvents &histhi = GetAverageHiGainArea(j);
     
    358358    }
    359359 
    360   for (UInt_t j=0; j<nsectors; j++)
     360  for (Int_t j=0; j<nsectors; j++)
    361361    {
    362362      MHGausEvents &histhi = GetAverageHiGainSector(j);
     
    422422// ==============
    423423//
    424 // 0: Fitted Mean Relative Arrival Time              (calls: MHGausEvents::GetMean())
    425 // 1: Error of fitted Mean Relative Arrival Time     (calls: MHGausEvents::GetMeanErr())
    426 // 2: Sigma of fitted Relative Arrival Time          (calls: MHGausEvents::GetSigma())
    427 // 3: Error of Sigma of fitted Relative Arrival Time (calls: MHGausEvents::GetSigmaErr())
    428 //
     424// 0: Fitted Mean Relative Arrival Time in ns  (MHGausEvents::GetMean()*MHCalibrationRelTimePix::GetFADCSliceWidth())
     425// 1: Error Mean Relative Arrival Time in ns   (MHGausEvents::GetMeanErr()*MHCalibrationRelTimePix::GetFADCSliceWidth())
     426// 2: Sigma fitted Relative Arrival Time in ns (MHGausEvents::GetSigma()*MHCalibrationRelTimePix::GetFADCSliceWidth())
     427// 3: Error Sigma Relative Arrival Time in ns  (MHGausEvents::GetSigmaErr()*MHCalibrationRelTimePix::GetFADCSliceWidth())
    429428//
    430429// Useful variables derived from the fit results:
     
    445444    return kFALSE;
    446445
     446  const MHCalibrationRelTimePix &pix = (MHCalibrationRelTimePix&)(*this)[idx];
     447  const Float_t fadc2ns              = pix.GetFADCSliceWidth();
     448
    447449  switch (type)
    448450    {
    449451    case 0:
    450       val = (*this)[idx].GetMean();
     452      val = pix.GetMean()*fadc2ns;
    451453      break;
    452454    case 1:
    453       val = (*this)[idx].GetMeanErr();
     455      val = pix.GetMeanErr()*fadc2ns;
    454456      break;
    455457    case 2:
    456       val = (*this)[idx].GetSigma();
     458      val = pix.GetSigma()*fadc2ns;
    457459      break;
    458460    case 3:
    459       val = (*this)[idx].GetSigmaErr();
     461      val = pix.GetSigmaErr()*fadc2ns;
    460462      break;
    461463    case 4:
    462       val = (*this)[idx].GetProb();
     464      val = pix.GetProb();
    463465      break;
    464466    case 5:
    465       if (!(*this)[idx].IsGausFitOK())
     467      if (!pix.IsGausFitOK())
    466468        val = 1.;
    467469      break;
    468470    case 6:
    469       if (!(*this)[idx].IsFourierSpectrumOK())
     471      if (!pix.IsFourierSpectrumOK())
    470472        val = 1.;
    471473      break;
  • trunk/MagicSoft/Mars/mcalib/MHCalibrationRelTimePix.cc

    r3642 r3840  
    9999// If mean and sigma have not yet been set, returns.
    100100//
     101// HAS BEEN COMMENTED IN ORDER TO ALLOW FURTHER CALIBRATION OF OFFSETS IN DATA
     102// RETURNS ALWAYS WITHOUT RENORMALIZING!!
    101103// Results are re-normalized to a value per time (ns) with the formulae:
    102104//
     
    109111{
    110112
     113  /*
    111114  if (fMean == fMeanErr == fSigma == fSigmaErr == 0.)
    112115    return;
     
    116119  fSigma   *= fFADCSliceWidth;
    117120  fSigmaErr*= fFADCSliceWidth;
    118  
     121  */
    119122}
  • trunk/MagicSoft/Mars/mcalib/MHCalibrationRelTimePix.h

    r3641 r3840  
    2323  ~MHCalibrationRelTimePix() {}
    2424
     25  // Getters
     26  Float_t GetFADCSliceWidth() const    { return fFADCSliceWidth;  }
     27 
    2528  // Setters
    2629  void SetFADCSliceWidth( const Float_t f=fgFADCSliceWidth )  {  fFADCSliceWidth = f; }
Note: See TracChangeset for help on using the changeset viewer.