Changeset 4328 for trunk/MagicSoft/Mars/mtemp/mifae
- Timestamp:
- 06/22/04 20:49:26 (20 years ago)
- Location:
- trunk/MagicSoft/Mars/mtemp/mifae
- Files:
-
- 10 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/mtemp/mifae/Changelog
r4316 r4328 22 22 * library/MDispCalc.[h,cc] 23 23 - Included first version of DISP method evaluation classes. 24 25 2004/06/22 Javier Rico 26 * library/MControlPlots.[h,cc] 27 - Added 28 29 * library/Makefile, IFAELinkDef.h 30 - Add MControlPlots. So far, it produces plots with the number 31 of times each pixel survives the cleaning. It needs a MIsland 32 object to be included on the parameter list 33 34 * programs/makeHillas.cc 35 - Change pointer to MWriteRootFile object for MWriteRootFile 36 object (otherwise the tree "Parameters" is not saved) 37 - Islands are always computed since are needed for some control 38 plots 39 40 * programs/srcPos.cc 41 - Add MControlPlots to the task list 24 42 25 43 2004/06/15 Javier Lopez -
trunk/MagicSoft/Mars/mtemp/mifae/library/IFAELinkDef.h
r4294 r4328 19 19 #pragma link C++ class MCalibrateDC+; 20 20 #pragma link C++ class MHPSFFromStars+; 21 #pragma link C++ class M SrcPosFromStars+;21 #pragma link C++ class MControlPlots+; 22 22 23 23 #endif -
trunk/MagicSoft/Mars/mtemp/mifae/library/MIslands.cc
r4218 r4328 46 46 *fLog << " + Pixel Number = " << fPixNum[i] << endl; 47 47 *fLog << " + SigToNoise = " << fSigToNoise[i] << endl; 48 *fLog << " + TimeSpread = " << fTimeSpread[i] << endl; 48 49 } 49 50 } -
trunk/MagicSoft/Mars/mtemp/mifae/library/MSrcPosFromFile.cc
r4117 r4328 142 142 if(srcpos) 143 143 fLastValidSrcPosCam = srcpos; 144 else if(run>fFirstRun) 145 for(UInt_t irun=run-1; irun>=fFirstRun;irun--) 146 if((srcpos=(MSrcPosCam*)fRunMap->GetValue(irun))) 147 { 148 *fLog << inf << " not found in file. Taking position for run "<< irun; 149 fLastValidSrcPosCam = srcpos; 150 break; 151 } 144 152 else if(fLastValidSrcPosCam) 145 153 *fLog << inf << " not found in file. Taking previous position: "; 146 else 154 155 if(!fLastValidSrcPosCam) 147 156 { 148 *fLog << warn << "MSrcPosFromFile::ComputeNewSrcPosition warning: no value for the first run. Taking first found run in file, run number " << fFirstRun << endl;149 fLastValidSrcPosCam = (MSrcPosCam*)fRunMap->GetValue( run);157 *fLog << warn << "MSrcPosFromFile::ComputeNewSrcPosition warning: no value for the first run. Taking first found run in file, run number " << fFirstRun; 158 fLastValidSrcPosCam = (MSrcPosCam*)fRunMap->GetValue(fFirstRun); 150 159 } 151 160 -
trunk/MagicSoft/Mars/mtemp/mifae/library/Makefile
r4294 r4328 63 63 MCalibrateDC.cc \ 64 64 MHPSFFromStars.cc \ 65 MSrcPosFromStars.cc 65 MControlPlots.cc 66 66 67 67 68 ############################################################ -
trunk/MagicSoft/Mars/mtemp/mifae/programs/Makefile
r4117 r4328 28 28 -I../../../mfbase \ 29 29 -I../../../mjobs \ 30 -I../../../mpedestal \30 -I../../../mpedestal \ 31 31 -I../../../mbadpixels \ 32 32 -I../../../mfileio \ … … 42 42 -I../../../mpointing \ 43 43 -I../../../mcamera \ 44 -I../../../mhist \ 44 45 -I../../../mastro 45 46 -
trunk/MagicSoft/Mars/mtemp/mifae/programs/makeHillas.cc
r4286 r4328 22 22 #include "MExtractor.h" 23 23 #include "MExtractFixedWindow.h" 24 #include "MExtractSlidingWindow.h" 24 25 #include "MExtractSignal.h" 25 26 #include "MCalibrationChargeCalc.h" … … 122 123 return -1; 123 124 } 125 124 126 makeHillas(); 125 127 } … … 131 133 MExtractFixedWindow extractor; 132 134 extractor.SetRange(hifirst,hilast,lofirst,lolast); 133 135 136 // MExtractSlidingWindow extractor; 137 // extractor.SetRange(hifirst,hilast,lofirst,lolast); 138 // extractor.SetWindowSize(2,2); 139 134 140 MGeomCamMagic geomcam; 135 141 MGeomApply geomapl; … … 232 238 233 239 MArrivalTimeCam timecam; 234 240 241 242 // islands 235 243 MIslands isl; 236 isl.SetName("MIslands1");237 238 244 MIslands isl2; 245 MIslands isl3; 246 247 isl.SetName("MIslands"); 239 248 isl2.SetName("MIslands2"); 240 241 MIslands isl3;242 249 isl3.SetName("MIslands3"); 243 250 244 if (islflag == 1 || islflag == 2 || islflag == 3) 245 { 246 plist4.AddToList(&timecam); 247 plist4.AddToList(&isl); 248 } 251 plist4.AddToList(&timecam); 252 plist4.AddToList(&isl); 249 253 250 254 if (islflag == 2) 251 { 252 plist4.AddToList(&isl2); 253 } 254 255 plist4.AddToList(&isl2); 255 256 if (islflag == 3) 256 { 257 plist4.AddToList(&isl3); 258 } 257 plist4.AddToList(&isl3); 259 258 260 259 plist4.AddToList(&geomcam); … … 280 279 281 280 MImgCleanStd clean(lcore,ltail); 282 283 281 MArrivalTimeCalc2 timecalc; 284 285 282 MIslandCalc island; 286 island.SetOutputName("MIslands 1");283 island.SetOutputName("MIslands"); 287 284 island.SetAlgorithm(kalgorithm); 288 285 … … 291 288 292 289 MIslandClean islclean(lnew); 293 islclean.SetInputName("MIslands 1");290 islclean.SetInputName("MIslands"); 294 291 islclean.SetMethod(kmethod); 295 292 … … 307 304 MContinue applycut(&cut); 308 305 applycut.SetInverted(kTRUE); 309 MWriteRootFile* write=NULL; 306 MWriteRootFile write(outname,"RECREATE"); 307 310 308 MHillasDisplay* disphillas=NULL; 311 309 312 write = new MWriteRootFile(outname,"RECREATE"); 313 314 write->AddContainer("MHillas" , "Parameters"); 315 write->AddContainer("MHillasSrc" , "Parameters"); 316 write->AddContainer("MHillasExt" , "Parameters"); 317 write->AddContainer("MNewImagePar" , "Parameters"); 318 write->AddContainer("MRawEvtHeader" , "Parameters"); 319 write->AddContainer("MRawRunHeader" , "Parameters"); 320 write->AddContainer("MConcentration" , "Parameters"); 321 write->AddContainer("MSrcPosCam" , "Parameters"); 322 323 if (islflag == 1 || islflag == 2 || islflag == 3) 324 write->AddContainer("MIslands1" , "Parameters"); 310 write.AddContainer("MHillas" , "Parameters"); 311 write.AddContainer("MHillasSrc" , "Parameters"); 312 write.AddContainer("MHillasExt" , "Parameters"); 313 write.AddContainer("MNewImagePar" , "Parameters"); 314 write.AddContainer("MRawEvtHeader" , "Parameters"); 315 write.AddContainer("MRawRunHeader" , "Parameters"); 316 write.AddContainer("MConcentration" , "Parameters"); 317 write.AddContainer("MSrcPosCam" , "Parameters"); 318 write.AddContainer("MIslands" , "Parameters"); 319 325 320 if (islflag == 2) 326 write ->AddContainer("MIslands2" , "Parameters");321 write.AddContainer("MIslands2" , "Parameters"); 327 322 if (islflag == 3) 328 write ->AddContainer("MIslands3" , "Parameters");323 write.AddContainer("MIslands3" , "Parameters"); 329 324 330 325 … … 332 327 { 333 328 disphillas = new MHillasDisplay(&nphot,&geomcam); 334 if (islflag == 1) 335 disphillas->SetIslandsName("MIslands1"); 329 disphillas->SetIslandsName("MIslands"); 336 330 if (islflag == 2) 337 331 disphillas->SetIslandsName("MIslands2"); … … 347 341 tlist4.AddToList(&interpolatebadpixels); 348 342 tlist4.AddToList(&clean); 349 350 if (islflag == 1 || islflag == 2 || islflag == 3) 351 { 352 tlist4.AddToList(&timecalc); 353 tlist4.AddToList(&island); 354 } 343 tlist4.AddToList(&timecalc); 344 tlist4.AddToList(&island); 355 345 356 346 if (islflag == 2) … … 366 356 } 367 357 368 369 //tlist4.AddToList(&blind2);370 358 tlist4.AddToList(&hcalc); 371 359 tlist4.AddToList(&csrc1); 372 360 if(filter.Length()) 373 361 tlist4.AddToList(&applycut); 374 tlist4.AddToList( write);362 tlist4.AddToList(&write); 375 363 if(display) 376 364 { … … 381 369 tlist4.AddToList(disphillas); 382 370 } 383 384 371 385 372 // Create and setup the eventloop -
trunk/MagicSoft/Mars/mtemp/mifae/programs/optimizeCuts.cc
r4234 r4328 113 113 ton->SetAlias("length","MHillas.fLength*0.6/189"); 114 114 ton->SetAlias("width","MHillas.fWidth*0.6/189"); 115 // ton->SetAlias("length","MHillas.fLength"); 116 // ton->SetAlias("width","MHillas.fWidth"); 115 117 ton->SetAlias("dist","MHillasSrc.fDist*0.6/189"); 116 118 ton->SetAlias("conc","MNewImagePar.fConc"); … … 121 123 toff->SetAlias("length","MHillas.fLength*0.6/189"); 122 124 toff->SetAlias("width","MHillas.fWidth*0.6/189"); 125 //toff->SetAlias("length","MHillas.fLength"); 126 //toff->SetAlias("width","MHillas.fWidth"); 123 127 toff->SetAlias("dist","MHillasSrc.fDist*0.6/189"); 124 128 toff->SetAlias("conc","MNewImagePar.fConc"); -
trunk/MagicSoft/Mars/mtemp/mifae/programs/psffit.cc
r4045 r4328 39 39 #include "MPSFFitCalc.h" 40 40 #include "MEvtLoop.h" 41 #include "MCalibrateDC.h" 41 42 42 43 using namespace std; … … 104 105 MGeomApply geomapl; 105 106 107 TString continuoslightfile = 108 "/nfs/magic/CaCodata/rootdata/Miscellaneous/Period016/2004_04_16/dc_2004_04_16_04_46_18_22368_Off3c279-2CL100.root"; 109 MCalibrateDC dccal; 110 dccal.SetFileName(continuoslightfile); 111 106 112 const Int_t numrings = 3; 107 const Int_t numblind = 23; 108 const Short_t x[numblind] = { 8, 27, 224, 279, 339, 109 507, 508, 509, 510, 511, 512, 513, 514, 110 543, 111 559, 560, 561, 562, 563, 564, 565, 566, 567}; 113 // const Int_t numblind = 187; 114 112 115 113 116 // 2004_02_15 … … 118 121 523, 524, 525, 526, 527, 528, 529, 530, 531}; 119 122 */ 123 const Int_t numblind = 260; 124 Short_t x[numblind]; 125 126 for (int i=0;i<246;i++) 127 x[i+14]=i+331; 128 x[0]=124; 129 x[1]=123; 130 x[2]=125; 131 x[3]=166; 132 x[4]=165; 133 x[5]=88; 134 x[6]=89; 135 x[7]=282; 136 x[8]=283; 137 x[9]=226; 138 x[10]=227; 139 x[11]=228; 140 x[12]=177; 141 x[13]=178; 142 120 143 const TArrayS blindpixels(numblind,(Short_t*)x); 121 144 MPSFFitCalc psfcalc; … … 128 151 tlist.AddToList(&geomapl); 129 152 tlist.AddToList(&read); 153 tlist.AddToList(&dccal, "Currents"); 130 154 tlist.AddToList(&psfcalc, "Currents"); 131 155 -
trunk/MagicSoft/Mars/mtemp/mifae/programs/srcPos.cc
r4094 r4328 31 31 #include "MWriteRootFile.h" 32 32 #include "MTime.h" 33 #include "MControlPlots.h" 34 #include "MIslands.h" 33 35 34 36 using namespace std; … … 54 56 Double_t fDEC= -1.; 55 57 TString srcFile; 58 TString controlplotsfilename="controlplots.ps"; 56 59 57 60 //----------------------------------------------------------------------------- … … 107 110 MParList plist; 108 111 MTaskList tlist; 112 MIslands islands; 109 113 110 114 // include containers in parameter list 111 115 plist.AddToList(&tlist); 116 plist.AddToList(&islands); 112 117 113 118 // tasks … … 144 149 write.AddContainer("MConcentration" , "Parameters"); 145 150 write.AddContainer("MSrcPosCam" , "Parameters"); 146 151 write.AddContainer("MIslands" , "Parameters"); 152 //write.AddContainer("MIslands2" , "Parameters"); 153 154 MControlPlots controlplots(controlplotsfilename); 155 controlplots.SetProduceFile(kFALSE); 156 147 157 // include tasks in task list 148 158 tlist.AddToList(&read); … … 156 166 } 157 167 tlist.AddToList(&csrc1); 168 tlist.AddToList(&controlplots); 158 169 tlist.AddToList(&write); 159 170 … … 184 195 write2.AddContainer("MConcentration" , "Parameters"); 185 196 write2.AddContainer("MSrcPosCam" , "Parameters"); 197 write2.AddContainer("MIslands" , "Parameters"); 198 // write2.AddContainer("MIslands2" , "Parameters"); 186 199 tlist.AddToListBefore(&write2,&write,"All"); 187 200 tlist.RemoveFromList(&write); … … 191 204 else 192 205 srcrotate.SetMode(MSrcPlace::kOff); 206 207 controlplots.SetMode(MControlPlots::kOff); 208 controlplots.SetProduceFile(kTRUE); 193 209 194 210 if (!evtloop.Eventloop(nmaxevents))
Note:
See TracChangeset
for help on using the changeset viewer.