Changeset 2834


Ignore:
Timestamp:
01/16/04 15:17:09 (21 years ago)
Author:
gaug
Message:
*** empty log message ***
Location:
trunk/MagicSoft/Mars
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/MagicSoft/Mars/Changelog

    r2833 r2834  
    2222   * mcalib/MCalibrationPINDiode.cc
    2323   * mcalib/MCalibrationCam.cc
     24   * mcalib/MHCalibrationBlindPixel.cc
     25   * mcalib/MHCalibrationPixel.cc
    2426     - fixed the warns and errs in fLog's
    2527
  • trunk/MagicSoft/Mars/mcalib/MHCalibrationBlindPixel.cc

    r2829 r2834  
    398398                     + fSinglePhePedFit->GetParError(2)/fSinglePhePedFit->GetParameter(2);
    399399
    400   *fLog << "Results of the Blind Pixel Fit: " << endl;
    401   *fLog << "Chisquare: " << fChisquare << endl;
    402   *fLog << "DoF: " << fNdf << endl;
    403   *fLog << "Probability: " << fProb << endl;
     400  *fLog << inf << "Results of the Blind Pixel Fit: " << endl;
     401  *fLog << inf << "Chisquare: " << fChisquare << endl;
     402  *fLog << inf << "DoF: " << fNdf << endl;
     403  *fLog << inf << "Probability: " << fProb << endl;
    404404
    405405  //
     
    410410  if (fProb < gkProbLimit)
    411411    {
    412       *fLog << err << "Prob: " << fProb << " is smaller than the allowed value: " << gkProbLimit << endl;
     412      *fLog << err << "ERROR: Fit Probability " << fProb
     413            << " is smaller than the allowed value: " << gkProbLimit << endl;
    413414      fFitOK = kFALSE;
    414415      return kFALSE;
    415416    }
    416417
     418  if (fProb < 0.01)
     419    *fLog << warn << "WARNING: Fit Probability " << fProb << " is smaller than 1% " << endl;
     420
    417421  Float_t contSinglePhe = TMath::Exp(-1.0*fLambda)*fLambda*entries;
    418422 
    419423  if (contSinglePhe < 100.)
    420424    {
    421       *fLog << err << "Statistics is too low: Only " << contSinglePhe
    422             << " in the first electron peak " << endl;
     425      *fLog << err << "ERROR: Statistics is too low: Only " << contSinglePhe
     426            << " in the Single Photo-Electron peak " << endl;
    423427      fFitOK = kFALSE;
    424428      return kFALSE;
    425429    }
    426430  else
    427     *fLog << GetDescriptor() << ": " << contSinglePhe
    428           << " in first electron peak " << endl;
     431    *fLog << inf << GetDescriptor() << ": " << contSinglePhe
     432          << " in Single Photo-Electron peak " << endl;
    429433 
    430434  fFitOK = kTRUE;
     
    478482  fHBlindPixelTime->Fit(fTimeGausFit,opt);
    479483
    480 
    481484  fMeanTime     = fTimeGausFit->GetParameter(2);
    482485  fSigmaTime    = fTimeGausFit->GetParameter(3);
     
    484487  fSigmaTimeErr = fTimeGausFit->GetParError(3);
    485488
    486   Float_t prob = fTimeGausFit->GetProb();
    487 
    488   *fLog << "Results of the Times Fit: " << endl;
    489   *fLog << "Chisquare: "   << fTimeGausFit->GetChisquare() << endl;
    490   *fLog << "Ndf: "         << fTimeGausFit->GetNDF() << endl;
    491   *fLog << "Probability: " << prob << endl;
    492 
    493   if (prob < gkProbLimit)
    494     {
    495       *fLog << warn << "Fit of the Arrival times failed ! " << endl;
    496       return kFALSE;
    497     }
    498  
     489  *fLog << inf << "Results of the Times Fit: " << endl;
     490  *fLog << inf << "Chisquare: "   << fTimeGausFit->GetChisquare() << endl;
     491  *fLog << inf << "Ndf: "         << fTimeGausFit->GetNDF() << endl;
     492
    499493  return kTRUE;
    500494
  • trunk/MagicSoft/Mars/mcalib/MHCalibrationPixel.cc

    r2831 r2834  
    600600  if (!fTimeGausFit)
    601601    {
    602     *fLog << err << dbginf << "Could not create fit function for Gauss fit" << endl;
     602    *fLog << warn << dbginf << "WARNING: Could not create fit function for Time fit" << endl;
    603603    return kFALSE;
    604604    }
     
    626626  fTimeSigma     = fTimeGausFit->GetParameter(2);
    627627
    628   if (fTimeChisquare > 30.)  // Cannot use Probability because Ndf is sometimes < 1
    629     {
    630       *fLog << warn << "Fit of the Arrival times failed ! " << endl;
     628  if (fTimeChisquare > 20.)  // Cannot use Probability because Ndf is sometimes < 1
     629    {
     630      *fLog << warn << "WARNING: Fit of the Arrival times failed ! " << endl;
    631631      return kFALSE;
    632632    }
     
    656656  if (!fTimeGausFit)
    657657    {
    658     *fLog << err << dbginf << "Could not create fit function for Gauss fit" << endl;
     658    *fLog << warn << dbginf << "WARNING: Could not create fit function for Time fit" << endl;
    659659    return kFALSE;
    660660    }
     
    682682  fTimeSigma     = fTimeGausFit->GetParameter(2);
    683683
    684   if (fTimeChisquare > 30.)  // Cannot use Probability because Ndf is sometimes < 1
    685     {
    686       *fLog << warn << "Fit of the Arrival times failed ! " << endl;
     684  if (fTimeChisquare > 20.)  // Cannot use Probability because Ndf is sometimes < 1
     685    {
     686      *fLog << warn << "WARNING: Fit of the Arrival times failed ! " << endl;
    687687      return kFALSE;
    688688    }
     
    720720  if (!fChargeGausFit)
    721721    {
    722     *fLog << err << dbginf << "Could not create fit function for Gauss fit" << endl;
     722    *fLog << warn << dbginf << "WARNING: Could not create fit function for Gauss fit" << endl;
    723723    return kFALSE;
    724724    }
     
    755755  if (fChargeProb < gkProbLimit)
    756756    {
    757       *fLog << warn << "Prob: " << fChargeProb
     757      *fLog << warn << "WARNING: Fit Probability " << fChargeProb
    758758            << " is smaller than the allowed value: " << gkProbLimit << endl;
    759759      fFitOK = kFALSE;
     
    794794  if (!fChargeGausFit)
    795795    {
    796     *fLog << err << dbginf << "Could not create fit function for Gauss fit" << endl;
     796    *fLog << warn << dbginf << "WARNING: Could not create fit function for Charges fit" << endl;
    797797    return kFALSE;
    798798    }
     
    835835  if (fChargeProb < gkProbLimit)
    836836    {
    837       *fLog << warn << "Prob: " << fChargeProb << " is smaller than the allowed value: " << gkProbLimit << endl;
     837      *fLog << warn << "WARNING: Fit Probability " << fChargeProb
     838            << " is smaller than the allowed value: " << gkProbLimit << endl;
    838839      fFitOK = kFALSE;
    839840      return kFALSE;
     
    874875{
    875876 
    876   *fLog << "Results of the Summed Charges Fit: "                      << endl;
    877   *fLog << "Chisquare: "        << fChargeChisquare                   << endl;
    878   *fLog << "DoF: "              << fChargeNdf                         << endl;
    879   *fLog << "Probability: "      << fChargeProb                        << endl;
    880   *fLog                                                               << endl;
     877  *fLog << all << "Results of the Summed Charges Fit: "                      << endl;
     878  *fLog << all << "Chisquare: "        << fChargeChisquare                   << endl;
     879  *fLog << all << "DoF: "              << fChargeNdf                         << endl;
     880  *fLog << all << "Probability: "      << fChargeProb                        << endl;
     881  *fLog << all                                                               << endl;
    881882 
    882883}
     
    885886{
    886887
    887   *fLog << "Results of the Time Slices Fit: "                        << endl;
    888   *fLog << "Chisquare: "   << fTimeChisquare                         << endl;
    889   *fLog << "Ndf: "         << fTimeNdf                               << endl;
    890   *fLog << "Probability: " << fTimeProb                              << endl;
    891   *fLog                                                              << endl;
    892 
    893 }
     888  *fLog << all << "Results of the Time Slices Fit: "                        << endl;
     889  *fLog << all << "Chisquare: "   << fTimeChisquare                         << endl;
     890  *fLog << all << "Ndf: "         << fTimeNdf                               << endl;
     891  *fLog << all << "Probability: " << fTimeProb                              << endl;
     892  *fLog << all                                                              << endl;
     893
     894}
Note: See TracChangeset for help on using the changeset viewer.