Changeset 3520


Ignore:
Timestamp:
03/16/04 11:49:29 (21 years ago)
Author:
blanch
Message:
*** empty log message ***
Location:
trunk/MagicSoft/Mars/mimage
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/MagicSoft/Mars/mimage/MNewImagePar.cc

    r3466 r3520  
    7979    fLeakage2 = -1;
    8080
     81    fInnerLeakage1 = -1;
     82    fInnerLeakage2 = -1;
     83    fInnerSize = -1;
     84
    8185    fConc  = -1;
    8286    fConc1 = -1;
     
    102106    fNumHGSaturatedPixels = 0;
    103107
     108    fInnerSize = 0;
     109
    104110    const UInt_t npixevt = evt.GetNumPixels();
    105111
     
    107113    Double_t edgepix2 = 0;
    108114
     115    Double_t edgepixin1 = 0;
     116    Double_t edgepixin2 = 0;
     117
     118    Float_t maxpix[9] = {0,0,0,0,0,0,0,0,0};             // [#phot]
    109119    Float_t maxpix1 = 0;                                 // [#phot]
    110120    Float_t maxpix2 = 0;                                 // [#phot]
     
    151161        nphot *= geom.GetPixRatio(pixid);
    152162
     163        // count inner pixels: To dependent on MAGIC Camera --> FIXME
     164
     165        if (pixid<397){
     166          fInnerSize += nphot;
     167          if(pixid>270){
     168            edgepixin2 += nphot;
     169            if(pixid>330)
     170              edgepixin1 += nphot;
     171          }
     172        }
     173
     174        // Compute Concentrations 1-8   
     175
     176        if(maxpix[0]<=nphot) {
     177          for(int i=0;i<8;i++)
     178            maxpix[8-i]=maxpix[7-i];
     179          maxpix[0]=nphot;
     180        }
     181        else
     182          for(int i=0;i<8;i++){
     183            if (nphot<maxpix[7-i]){
     184              for(int j=0;j<i-1;j++){ 
     185                maxpix[7-j]=maxpix[6-j];                    // [1]
     186              }
     187              maxpix[8-i]=nphot;
     188              break;
     189            }
     190          }
     191
     192        // Compute Concetration 1 -2
     193
    153194        if (nphot>maxpix1)
    154         {
     195          {
    155196            maxpix2  = maxpix1;
    156197            maxpix1  = nphot;                            // [1]
    157198            continue;                                    // [1]
    158         }
    159 
     199          }
     200       
    160201        if (nphot>maxpix2)
    161             maxpix2 = nphot;                             // [1]
     202          maxpix2 = nphot;                             // [1]
    162203    }
    163 
     204   
     205    fInnerLeakage1 = edgepixin1 / fInnerSize;
     206    fInnerLeakage2 = edgepixin2 / fInnerSize;
    164207    fLeakage1 = edgepix1 / hillas.GetSize();
    165208    fLeakage2 = edgepix2 / hillas.GetSize();
     
    167210    fConc  = (maxpix1+maxpix2)/hillas.GetSize();         // [ratio]
    168211    fConc1 = maxpix1/hillas.GetSize();                   // [ratio]
     212
     213    fConc3 = (maxpix[0]+maxpix[1]+maxpix[2]);
     214    fConc4 = (fConc3+maxpix[3]);
     215    fConc5 = (fConc4+maxpix[4]);
     216    fConc6 = (fConc5+maxpix[5]);
     217    fConc7 = (fConc6+maxpix[6]);
     218    fConc8 = (fConc7+maxpix[7]);
     219
     220    fConc3/=hillas.GetSize();                           // [ratio]
     221    fConc4/=hillas.GetSize();                           // [ratio]
     222    fConc5/=hillas.GetSize();                           // [ratio]
     223    fConc6/=hillas.GetSize();                           // [ratio]
     224    fConc7/=hillas.GetSize();                           // [ratio]
     225    fConc8/=hillas.GetSize();                           // [ratio]
    169226
    170227    SetReadyToSave();
  • trunk/MagicSoft/Mars/mimage/MNewImagePar.h

    r3466 r3520  
    1515    Float_t fLeakage1;           // (photons in most outer ring of pixels) over fSize
    1616    Float_t fLeakage2;           // (photons in the 2 outer rings of pixels) over fSize
     17    Float_t fInnerLeakage1;           // (photons in most outer rings of inner pixels) over fInnerSize
     18    Float_t fInnerLeakage2;           // (photons in the 2 outer rings of inner pixels) over fInnerSize
     19    Float_t fInnerSize;
    1720
    1821    Float_t fConc;               // [ratio] concentration ratio: sum of the two highest pixels / fSize
    1922    Float_t fConc1;              // [ratio] concentration ratio: sum of the highest pixel / fSize
     23    Float_t fConc3;              // [ratio] concentration ratio: sum of the 3 highest pixel / fSize
     24    Float_t fConc4;              // [ratio] concentration ratio: sum of the 4 highest pixel / fSize
     25    Float_t fConc5;              // [ratio] concentration ratio: sum of the 5 highest pixel / fSize
     26    Float_t fConc6;              // [ratio] concentration ratio: sum of the 6 highest pixel / fSize
     27    Float_t fConc7;              // [ratio] concentration ratio: sum of the 7 highest pixel / fSize
     28    Float_t fConc8;              // [ratio] concentration ratio: sum of the 8 highest pixel / fSize
    2029
    2130    Short_t fNumUsedPixels;      // Number of pixels which survived the image cleaning
Note: See TracChangeset for help on using the changeset viewer.