Ignore:
Timestamp:
05/23/06 17:07:28 (19 years ago)
Author:
tbretz
Message:
*** empty log message ***
Location:
trunk/MagicSoft/Mars/mbadpixels
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/MagicSoft/Mars/mbadpixels/MBadPixelsTreat.cc

    r7377 r7733  
    1818!   Author(s): Oscar Blanch 12/2001 <mailto:blanch@ifae.es>
    1919!   Author(s): Thomas Bretz 08/2002 <mailto:tbretz@astro.uni-wuerzburg.de>
     20!   Author(s): Stefan Ruegamer <mailto:snruegam@astro.uni-wuerzburg.de>
    2021!
    21 !   Copyright: MAGIC Software Development, 2000-2004
     22!   Copyright: MAGIC Software Development, 2000-2006
    2223!
    2324!
     
    107108MBadPixelsTreat::MBadPixelsTreat(const char *name, const char *title)
    108109    : fGeomCam(0), fEvt(0), fBadPixels(0), fPedPhot1(0), fPedPhot2(0),
    109     fFlags(0), fNumMinNeighbors(3)
     110    fFlags(0), fNumMinNeighbors(3), fMaxArrivalTimeDiff(1.0)
    110111{
    111112    fName  = name  ? name  : gsDefName.Data();
     
    425426void MBadPixelsTreat::InterpolateTimes() const
    426427{
    427     const Double_t tdiffshoweredge = 0.5;
    428 
    429428    const Int_t n = fEvt->GetNumPixels();
    430429    for (int i=0; i<n; i++)
     
    471470
    472471            // Calculate mean arrival time of pixel probably inside the shower
    473             if (TMath::Abs(tm1 - tm2)<tdiffshoweredge)
     472            if (TMath::Abs(tm1 - tm2)<fMaxArrivalTimeDiff)
    474473            {
    475474                sum2 += tm1+tm2;
     
    601600//   MBadPixelsTreat.ProcessPedestalEvt:  no
    602601//   MBadPixelsTreat.NumMinNeighbors:     3
     602//   MBadPixelsTreat.MaxArrivalTimeDiff:  1.0
    603603//
    604604Int_t MBadPixelsTreat::ReadEnv(const TEnv &env, TString prefix, Bool_t print)
     
    640640        SetNumMinNeighbors(GetEnvValue(env, prefix, "NumMinNeighbors", fNumMinNeighbors));
    641641    }
     642    if (IsEnvDefined(env, prefix, "MaxArrivalTimeDiff", print))
     643    {
     644        rc = kTRUE;
     645        SetMaxArrivalTimeDiff(GetEnvValue(env, prefix, "MaxArrivalTimeDiff", fMaxArrivalTimeDiff));
     646    }
    642647    return rc;
    643648}
  • trunk/MagicSoft/Mars/mbadpixels/MBadPixelsTreat.h

    r7376 r7733  
    2424    TList fPedPhotCams;
    2525
    26     Byte_t fFlags;       // flag for the method which is used
    27     Byte_t fNumMinNeighbors;
     26    Byte_t  fFlags;                // flag for the method which is used
     27    Byte_t  fNumMinNeighbors;      // Number of neighbors required
     28    Float_t fMaxArrivalTimeDiff;   // Maximum allowed arrival time difference of neighboring pixels
    2829
    2930    TList fNamePedPhotCams;
     
    9596    Bool_t IsUseInterpolation() const   { return TESTBIT(fFlags, kUseInterpolation); }
    9697
    97     void SetNumMinNeighbors(Byte_t num) { fNumMinNeighbors=num; }
     98    void SetNumMinNeighbors(Byte_t num)   { fNumMinNeighbors=num; }
     99    void SetMaxArrivalTimeDiff(Float_t d) { fMaxArrivalTimeDiff=d; }
    98100    void AddNamePedPhotCam(const char *name="MPedPhotCam");
    99101    void SetNamePedPhotCam(const char *name)
Note: See TracChangeset for help on using the changeset viewer.