Changeset 2422 for trunk/MagicSoft/Mars/mimage/MImgCleanTGB.cc
- Timestamp:
- 10/23/03 01:38:16 (21 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/mimage/MImgCleanTGB.cc
r2377 r2422 29 29 // MImgCleanTGB 30 30 // 31 // The Image Cleaning task selects the pixels you use for the Hillas32 // parameters calculation.33 //34 // There are two methods to make the selection: the standard one, as done35 // in the analysis of CT1 data, and the democratic one, as suggested by36 // W.Wittek. The number of photo-electrons of a pixel is compared with the37 // pedestal RMS of the pixel itself (standard method) or with the average38 // RMS of the inner pixels (democratic method).39 // In both cases, the possibility to have a camera with pixels of40 // different area is taken into account.41 // The too noisy pixels can be recognized and eventally switched off42 // (Unmap: set blind pixels to UNUSED) separately, using the43 // MBlindPixelCalc Class. In the MBlindPixelCalc class there is also the44 // function to replace the value of the noisy pixels with the interpolation45 // of the content of the neighbors (SetUseInterpolation).46 //47 // Example:48 // ...49 // MBlindPixelCalc blind;50 // blind.SetUseInterpolation();51 // blind.SetUseBlindPixels();52 //53 // MImgCleanTGB clean;54 // ...55 // tlist.AddToList(&blind);56 // tlist.AddToList(&clean);57 //58 // Look at the MBlindPixelCalc Class for more details.59 //60 // Starting point: default values ----------------------------------------61 //62 // When an event is read, before the image cleaning, all the pixels that63 // are in MCerPhotEvt are set as USED and NOT CORE. All the pixels belong64 // to RING number 1 (like USED pixels).65 // Look at MCerPhotPix.h to see how these informations of the pixel are66 // stored.67 // The default cleaning METHOD is the STANDARD one and the number of the68 // rings around the CORE pixel it analyzes is 1. Look at the Constructor69 // of the class in MImgCleanTGB.cc to see (or change) the default values.70 //71 // Example: To modify this setting, use the member functions72 // SetMethod(MImgCleanTGB::kDemocratic) and SetCleanRings(UShort_t n).73 //74 // MImgCleanTGB:CleanStep1 -----------------------------------------------75 //76 // The first step of cleaning defines the CORE pixels. The CORE pixels are77 // the ones which contain the informations about the core of the electro-78 // magnetic shower.79 // The ratio (A_0/A_i) is calculated from fCam->GetPixRatio(i). A_0 is80 // the area of the central pixel of the camera, A_i is the area of the81 // examined pixel. In this way, if we have a MAGIC-like camera, with the82 // outer pixels bigger than the inner ones, the level of cleaning in the83 // two different regions is weighted.84 // This avoids problems of deformations of the shower images.85 // The signal S_i and the pedestal RMS Prms_i of the pixel are called from86 // the object MCerPhotPix.87 // If (default method = kStandard)88 //Begin_Html89 // <img src="images/MImgCleanTGB-f1.png">90 //End_Html91 // the pixel is set as CORE pixel. L_1 (n=1) is called "first level of92 // cleaning" (default: fCleanLvl1 = 3).93 // All the other pixels are set as UNUSED and belong to RING 0.94 // After this point, only the CORE pixels are set as USED, with RING95 // number 1.96 //97 // MImgCleanTGB:CleanStep2 ----------------------------------------------98 //99 // The second step of cleaning looks at the isolated CORE pixels and sets100 // them to UNUSED. An isolated pixel is a pixel without CORE neighbors.101 // At the end of this point, we have set as USED only CORE pixels with at102 // least one CORE neighbor.103 //104 // MImgCleanTGB:CleanStep3 ----------------------------------------------105 //106 // The third step of cleaning looks at all the pixels (USED or UNUSED) that107 // surround the USED pixels.108 // If the content of the analyzed pixel survives at the second level of109 // cleaning, i.e. if110 //Begin_Html111 // <img src="images/MImgCleanTGB-f1.png">112 //End_Html113 // the pixel is set as USED. L_2 (n=2) is called "second level of cleaning"114 // (default:fCleanLvl2 = 2.5).115 //116 // When the number of RINGS to analyze is 1 (default value), only the117 // pixels that have a neighbor CORE pixel are analyzed.118 //119 // There is the option to decide the number of times you want to repeat120 // this procedure (number of RINGS analyzed around the core pixels = n).121 // Every time the level of cleaning is the same (fCleanLvl2) and the pixel122 // will belong to ring r+1, 1 < r < n+1. This is described in123 // MImgCleanTGB:CleanStep4 .124 //125 // Dictionary and member functions ---------------------------------------126 //127 // Here there is the detailed description of the member functions and of128 // the terms commonly used in the class.129 //130 // STANDARD CLEANING:131 // =================132 // This is the method used for the CT1 data analysis. It is the default133 // method of the class.134 // The number of photo-electrons of a pixel (S_i) is compared to the135 // pedestal RMS of the pixel itself (Prms_i). To have the comparison to136 // the same photon density for all the pixels, taking into account they137 // can have different areas, we have to keep in mind that the number of138 // photons that hit each pixel, goes linearly with the area of the pixel.139 // The fluctuations of the LONS are proportional to sqrt(A_i), so when we140 // compare S_i with Prms_i, only a factor sqrt(A_0/A_i) is missing to141 // have the same (N.photons/Area) threshold for all the pixels.142 //143 // !!WARNING: if noise independent from the144 // pixel size (example: electronic noise) is introduced,145 // then the noise fluctuations are no longer proportional146 // to sqrt(A_i), and then the cut value (for a camera with147 // pixels of different sizes) resulting from the above148 // procedure would not be proportional to pixel size as we149 // intend. In that case, democratic cleaning is preferred.150 //151 // If152 //Begin_Html153 // <img src="images/MImgCleanTGB-f1.png">154 //End_Html155 // the pixel survives the cleaning and it is set as CORE (when L_n is the156 // first level of cleaning, fCleanLvl1) or USED (when L_n is the second157 // level of cleaning, fCleanLvl2).158 //159 // Example:160 //161 // MImgCleanTGB clean;162 // //creates a default Cleaning object, with default setting163 // ...164 // tlist.AddToList(&clean);165 // // add the image cleaning to the main task list166 //167 // DEMOCRATIC CLEANING:168 // ===================169 // You use this cleaning method when you want to compare the number of170 // photo-electons of each pixel with the average pedestal RMS171 // (fInnerNoise = fSgb->GetSigmabarInner()) of the inner pixels (for the172 // MAGIC camera they are the smaller ones):173 //Begin_Html174 // <img src="images/MImgCleanTGB-f2.png">175 //End_Html176 // In this case, the simple ratio (A_0/A_i) is used to weight the level of177 // cleaning, because both the inner and the outer pixels (that in MAGIC178 // have a different area) are compared to the same pedestal RMS, coming179 // from the inner pixels.180 // To calculate the average pedestal RMS of the inner pixels, you have to181 // add to the main task list an object of type MSigmabarCalc before the182 // MImgCleanTGB object. To know how the calculation of fInnerNoise is done183 // look at the MSigmabarCalc Class.184 //185 // Example:186 //187 // MSigmabarCalc sbcalc;188 // //creates an object that calcutates the average pedestal RMS189 // MImgCleanTGB clean;190 // ...191 // tlist.AddToList(&sbcalc);192 // tlist.AddToList(&clean);193 //194 // Member Function: SetMethod()195 // ============================196 // When you call the MImgCleanTGB task, the default method is kStandard.197 //198 // If you want to switch to the kDemocratic method you have to199 // call this member function.200 //201 // Example:202 //203 // MImgCleanTGB clean;204 // //creates a default Cleaning object, with default setting205 //206 // clean.SetMethod(MImgCleanTGB::kDemocratic);207 // //now the method of cleaning is changed to Democratic208 //209 // FIRST AND SECOND CLEANING LEVEL210 // ===============================211 // When you call the MImgCleanTGB task, the default cleaning levels are212 // fCleanLvl1 = 3, fCleanLvl2 = 2.5. You can change them easily when you213 // create the MImgCleanTGB object.214 //215 // Example:216 //217 // MImgCleanTGB clean(Float_t lvl1,Float_t lvl2);218 // //creates a default cleaning object, but the cleaning levels are now219 // //lvl1 and lvl2.220 //221 // RING NUMBER222 // ===========223 // The standard cleaning procedure is such that it looks for the224 // informations of the boundary part of the shower only on the first225 // neighbors of the CORE pixels.226 // There is the possibility now to look not only at the firs neighbors227 // (first ring),but also further away, around the CORE pixels. All the new228 // pixels you can find with this method, are tested with the second level229 // of cleaning and have to have at least an USED neighbor.230 //231 // They will be also set as USED and will be taken into account during the232 // calculation of the image parameters.233 // The only way to distinguish them from the other USED pixels, is the234 // Ring number, that is bigger than 1.235 //236 // Example: You can decide how many rings you want to analyze using:237 //238 // MImgCleanTGB clean;239 // //creates a default cleaning object (default number of rings =1)240 // clean.SetCleanRings(UShort_t r);241 // //now it looks r times around the CORE pixels to find new pixels with242 // //signal.243 //244 31 // 245 32 // Input Containers:
Note:
See TracChangeset
for help on using the changeset viewer.