Changeset 2849


Ignore:
Timestamp:
01/19/04 15:46:56 (21 years ago)
Author:
moralejo
Message:
*** empty log message ***
Location:
trunk/MagicSoft/Mars
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • trunk/MagicSoft/Mars/Changelog

    r2848 r2849  
    44
    55                                                 -*-*- END OF LINE -*-*-
     6
     7 2004/01/19: Abelardo Moralejo
     8
     9   * manalysis/MCerPhotPix.[h,cc]
     10     - Added fIsSaturated to flag whether low gain of the pixel is
     11       saturated. Added corresponding getter and setter functions.
     12       Updated ClassDef to version 2.
     13
     14   * mcalib/MCalibrate.cc
     15     - Set the new saturation flag of MCerPhotPix to kTRUE if at least
     16       one low gain FADC slice is saturated.
     17
     18   * mimage/MNewImagePar.[h,cc]
     19     - Added new member variable fNumSaturatedPixels to count how many
     20       pixels were saturated. Updated ClassDef to version 2.
     21
    622
    723 2004/01/19: Thomas Bretz
  • trunk/MagicSoft/Mars/manalysis/MCerPhotPix.cc

    r2173 r2849  
    2323!
    2424\* ======================================================================== */
     25
     26
     27/////////////////////////////////////////////////////////////////////////////
     28//
     29// MCerPhotPix
     30//
     31// Storage container for the signal in a pixel in number of photons.
     32//
     33// Version 2:
     34// Added fIsSaturated, boolean variable set to kTRUE whenever one or more of
     35// the low gain FADC slices of the pixel is in saturation.
     36//
     37////////////////////////////////////////////////////////////////////////////
     38
    2539#include "MCerPhotPix.h"
    2640
     
    3751//
    3852MCerPhotPix::MCerPhotPix(Int_t pix, Float_t phot, Float_t errphot) :
    39     fPixId(pix), fRing(1), fIsCore(kFALSE), fPhot(phot), fErrPhot(errphot)
     53  fPixId(pix), fRing(1), fIsCore(kFALSE), fPhot(phot), fErrPhot(errphot), fIsSaturated(kFALSE)
    4054{
    4155}
     
    5064    gLog << (fRing>0?"   Used ":" Unused ");
    5165    gLog << (fIsCore?" Core ":"      ");
     66    gLog << (fIsSaturated?" Saturated ":"Not Saturated");
    5267    gLog << "Nphot= " << fPhot << " Error(Nphot)=" << fErrPhot << endl;
    5368}
  • trunk/MagicSoft/Mars/manalysis/MCerPhotPix.h

    r2056 r2849  
    1414    UShort_t fRing;      // NT: number of analyzed rings around the core pixels (fRing>0 means: used)
    1515    Bool_t   fIsCore;    // the pixel is a Core pixel -> kTRUE
     16    Bool_t   fIsSaturated; // the pixel is saturated
    1617
    1718    Float_t  fPhot;      // The number of Cerenkov photons
     
    4142    void     Set(Float_t np, Float_t ep) { fPhot = np; fErrPhot = ep; }
    4243
     44    void     SetPixelSaturated()         { fIsSaturated = kTRUE; }
     45    Bool_t   IsPixelSaturated() const    { return fIsSaturated; }
     46
    4347    void     AddNumPhotons(Float_t f)    { fPhot += f; }
    4448
     
    4751    void     Print(Option_t *opt = NULL) const;
    4852
    49     ClassDef(MCerPhotPix, 1)  // class containing information about the Cerenkov Photons in a pixel
     53    ClassDef(MCerPhotPix, 2)  // class containing information about the Cerenkov Photons in a pixel
    5054};
    5155
  • trunk/MagicSoft/Mars/mcalib/MCalibrate.cc

    r2771 r2849  
    126126
    127127    const UInt_t imaxnumpix = fSignals->GetSize();
    128    
     128
    129129    for (UInt_t pixidx=0; pixidx<imaxnumpix; pixidx++)
    130130    {
     
    161161        nphotErr  = TMath::Sqrt(nphotErr);
    162162
     163
    163164        fCerPhotEvt->AddPixel(pixidx, nphot, nphotErr);
     165
     166        if (sig.GetNumLoGainSaturated() > 0)
     167          (*fCerPhotEvt)[pixidx].SetPixelSaturated();
    164168    }
    165169
  • trunk/MagicSoft/Mars/mimage/MNewImagePar.cc

    r2624 r2849  
    3232// fLeakage2 ratio: (photons in the 2 outer rings of pixels) over fSize
    3333//
     34// Version 2:
     35// Added fNumSaturatedPixels: number of pixels in which at least one slice
     36// of the low gain FADC was saturated.
     37//
    3438/////////////////////////////////////////////////////////////////////////////
    3539#include "MNewImagePar.h"
     
    7478    fNumUsedPixels = -1;
    7579    fNumCorePixels = -1;
     80
     81    fNumSaturatedPixels = -1;
    7682}
    7783
     
    8692    fNumCorePixels = 0;
    8793
     94    fNumSaturatedPixels = 0;
     95
    8896    const UInt_t npixevt = evt.GetNumPixels();
    8997
     
    97105    {
    98106        const MCerPhotPix &pix = evt[i];
     107
     108        if (pix.IsPixelSaturated())
     109          fNumSaturatedPixels++;
     110
    99111        if (!pix.IsPixelUsed())
    100112            continue;
  • trunk/MagicSoft/Mars/mimage/MNewImagePar.h

    r2026 r2849  
    2222    Short_t fNumCorePixels; // number of core pixels
    2323
     24    Short_t fNumSaturatedPixels; // number of saturated pixels
     25
    2426public:
    2527    MNewImagePar(const char *name=NULL, const char *title=NULL);
     
    3638    Int_t GetNumCorePixels() const { return fNumCorePixels; }
    3739
     40    Short_t GetNumSaturatedPixels() const { return fNumSaturatedPixels; }
     41
    3842    void Print(Option_t *opt=NULL) const;
    3943
     
    4145              const MHillas &hillas);
    4246
    43     ClassDef(MNewImagePar, 1) // Container to hold new image parameters
     47    ClassDef(MNewImagePar, 2) // Container to hold new image parameters
    4448};
    4549
Note: See TracChangeset for help on using the changeset viewer.