Changeset 8518
- Timestamp:
- 05/16/07 14:48:37 (18 years ago)
- Location:
- trunk/MagicSoft/Mars
- Files:
-
- 11 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/Changelog
r8517 r8518 18 18 19 19 -*-*- END OF LINE -*-*- 20 2007/05/16 Thomas Bretz 21 22 * callisto.cc: 23 - switch of storage of job2 only in movie mode 24 25 * mjobs/MJCalibrateSignal.[h,cc]: 26 - do not write the interleaced containers anymore 27 they have no real meaning if only the ones of the last 28 calibration are written 29 - removed obsolete references to MCalibrationPulseTimeCam 30 - changed default writingmode for the signal file to UPDATE 31 32 * mjobs/MJCalibration.cc, mjobs/MJCut.cc: 33 - write display by adding it to the array 34 35 * mjobs/MJPedestal.[h,cc]: 36 - added const qualifier to argument of DisplayResult 37 - removed obsolete WriteResult 38 - added a new function WritePulsePos 39 - call WritePulsePos if PulsePosCheck is enabled 40 41 * mjobs/MJob.[h,cc]: 42 - removed automatic writing of fDisplay from WriteContainer 43 - added a new function WriteDisplay 44 45 46 20 47 2007/05/14 Stefan Ruegamer 21 48 -
trunk/MagicSoft/Mars/NEWS
r8515 r8518 2 2 3 3 *** <cvs> 4 5 - database: the position used for the pulse pos check was missing 6 in the callisto output and could thus not be filled into the DB. 7 Also the old values seemed not exactly the PulsePos used for 8 teh check. 4 9 5 10 -
trunk/MagicSoft/Mars/callisto.cc
r8434 r8518 514 514 // 515 515 MJPedestal job2(Form("MJPedestalY2 #%d", seq.GetSequence())); 516 job2.SetNoStorage( );516 job2.SetNoStorage(kMovie); 517 517 job2.SetSequence(seq); 518 518 job2.SetEnv(&env); -
trunk/MagicSoft/Mars/mjobs/MJCalibrateSignal.cc
r8498 r8518 62 62 #include "MCalibrationRelTimeCam.h" 63 63 #include "MCalibrationChargePINDiode.h" 64 #include "MCalibrationPulseTimeCam.h"65 64 #include "MCalibrationPatternDecode.h" 66 65 … … 144 143 } 145 144 146 Bool_t MJCalibrateSignal::WriteResult( TObjArray &cont)145 Bool_t MJCalibrateSignal::WriteResult() const 147 146 { 148 if (IsNoStorage() || fIsMovieMode) 149 return kTRUE; 150 151 const TString name(Form("signal%08d.root", fSequence.GetSequence())); 152 return WriteContainer(cont, name); 147 if (IsNoStorage() || fIsMovieMode) 148 return kTRUE; 149 150 // FIXME: This is not nice because it will update the signal 151 // file always. Which might make the usage outside of 152 // callisto difficult. 153 const TString name(Form("signal%08d.root", fSequence.GetSequence())); 154 return WriteDisplay(name, "UPDATE"); 153 155 } 154 156 … … 263 265 MCalibrationRelTimeCam tmcam; 264 266 //MCalibrationHiLoCam hilcam; 265 MCalibrationPulseTimeCam pulcam;267 //MCalibrationPulseTimeCam pulcam; 266 268 267 269 MBadPixelsCam badpix; … … 346 348 plist.AddToList(&calibcont); // Using AddToList(TObjArray *) 347 349 plist.AddToList(&interlacedcont); // Using AddToList(TObjArray *) 348 plist.AddToList(&pulcam);350 //plist.AddToList(&pulcam); 349 351 350 352 // Setup Tasklist … … 872 874 // hilocam[fCheckedPixId].DrawClone(""); 873 875 } 876 interlacedcont.Add(&pulcam); 874 877 */ 875 interlacedcont.Add(&pulcam);876 878 877 879 //if (fIsHiLoCalibration) … … 884 886 // interlacedcont.Add(plist.FindObject("MHCalibrationHiLoCam")); 885 887 886 if (!WriteResult( interlacedcont))888 if (!WriteResult()) 887 889 return kFALSE; 888 890 -
trunk/MagicSoft/Mars/mjobs/MJCalibrateSignal.h
r8406 r8518 30 30 void DisplayResult(MParList &plist); 31 31 32 Bool_t WriteResult( TObjArray &cont);32 Bool_t WriteResult() const; 33 33 Bool_t ReadCalibration(TObjArray &o, MBadPixelsCam &bpix, 34 34 MExtractor* &ext1, MExtractor* &ext2, TString &geom) const; -
trunk/MagicSoft/Mars/mjobs/MJCalibration.cc
r8504 r8518 2024 2024 } 2025 2025 2026 if (fDisplay) 2027 cont.Add(fDisplay); 2028 2026 2029 return WriteContainer(cont, GetOutputFileName(), "UPDATE"); 2027 2030 } … … 2029 2032 void MJCalibration::DisplayDoubleProject(MHCamera *cam, const char* whatsmall, const char* whatbig) const 2030 2033 { 2031 2034 2032 2035 TArrayI inner(1); 2033 2036 inner[0] = 0; 2034 2037 2035 2038 TArrayI outer(1); 2036 2039 outer[0] = 1; 2037 2040 2038 2041 TArrayI s1(3); 2039 2042 s1[0] = 6; 2040 2043 s1[1] = 1; 2041 2044 s1[2] = 2; 2042 2045 2043 2046 TArrayI s2(3); 2044 2047 s2[0] = 3; 2045 2048 s2[1] = 4; 2046 2049 s2[2] = 5; 2047 2050 2048 2051 TVirtualPad *pad = gPad; 2049 2052 pad->Divide(2,1); 2050 2053 2051 2054 TH1D *inout[2]; 2052 2055 … … 2056 2059 gPad->SetBorderMode(0); 2057 2060 gPad->SetTicks(); 2058 2061 2059 2062 inout[i] = cam->ProjectionS(TArrayI(), TArrayI(1,&i), i==0 ? "Inner" : "Outer"); 2060 2063 FixDataCheckHist(inout[i]); … … 2081 2084 2082 2085 TLegend *leg2 = new TLegend(0.55,0.4,0.99,0.6); 2083 2086 2084 2087 // 2085 2088 // Display the two half of the camera separately … … 2088 2091 half[0] = cam->ProjectionS(s1, TArrayI(1,&i), "Sector 6-1-2"); 2089 2092 half[1] = cam->ProjectionS(s2, TArrayI(1,&i), "Sector 3-4-5"); 2090 2093 2091 2094 for (int j=0; j<2; j++) 2092 2095 { -
trunk/MagicSoft/Mars/mjobs/MJCut.cc
r8456 r8518 316 316 } 317 317 } 318 319 if (fDisplay) 320 arr.Add(fDisplay); 318 321 319 322 return WriteContainer(arr, fname, "UPDATE"); -
trunk/MagicSoft/Mars/mjobs/MJPedestal.cc
r8504 r8518 201 201 // If Display type "kDataCheck" was chosen, also the reference lines are displayed. 202 202 // 203 void MJPedestal::DisplayResult( MParList &plist)203 void MJPedestal::DisplayResult(const MParList &plist) 204 204 { 205 205 if (!fDisplay) … … 825 825 //--------------------------------------------------------------------------------- 826 826 // 827 // Try to write the created MPedestalCam in the output file. 828 // If possible, also an MBadPixelsCam and the corresponding display is written. 829 // 830 // In case of Storage type "kNoStorage" or if any of the containers 831 // cannot be written, return kFALSE, otherwise kTRUE. 832 // 833 Bool_t MJPedestal::WriteResult() 827 Bool_t MJPedestal::WritePulsePos(TObject *obj) const 834 828 { 835 829 if (IsNoStorage()) 836 830 return kTRUE; 837 831 838 TObjArray cont; 839 840 cont.Add(&fPedestalCamOut); 841 cont.Add(&fBadPixels); 842 843 return WriteContainer(cont, GetOutputFileName(), fOverwrite?"RECREATE":"NEW"); 832 const TString name(Form("signal%08d.root", fSequence.GetSequence())); 833 834 TObjArray arr; 835 arr.Add(obj); 836 return WriteContainer(arr, name, fOverwrite?"RECREATE":"NEW"); 844 837 } 845 838 … … 869 862 Float_t rmspulsetime = 1.0; 870 863 864 MCalibrationPulseTimeCam *cam = NULL; 871 865 if (!fSequence.IsMonteCarlo()) 872 866 { … … 887 881 } 888 882 889 MCalibrationPulseTimeCam *cam = (MCalibrationPulseTimeCam*)plist.FindObject("MCalibrationPulseTimeCam");883 cam = (MCalibrationPulseTimeCam*)plist.FindObject("MCalibrationPulseTimeCam"); 890 884 if (!cam) 891 885 { … … 897 891 rmspulsetime = cam->GetAverageArea(0).GetHiGainRms(); 898 892 } 893 894 if (!WritePulsePos(cam)) 895 return kFALSE; 899 896 900 897 *fLog << all << "Mean pulse time (" << (fSequence.IsMonteCarlo()?"MC":"cosmics") << "): "; … … 1274 1271 DisplayResult(plist); 1275 1272 1276 if (!WriteResult())1277 return kFALSE;1273 // if (!WriteResult()) 1274 // return kFALSE; 1278 1275 1279 1276 const Int_t rc = PulsePosCheck(plist); -
trunk/MagicSoft/Mars/mjobs/MJPedestal.h
r7561 r8518 76 76 MExtractor *ReadCalibration(); 77 77 Bool_t ReadPedestalCam(); 78 Bool_t WriteResult(); 78 //Bool_t WriteResult(); 79 Bool_t WritePulsePos(TObject *obj) const; 79 80 //Bool_t WriteEventloop(MEvtLoop &evtloop) const; 80 81 81 void DisplayResult( MParList &plist);82 void DisplayResult(const MParList &plist); 82 83 void DisplayReferenceLines(MHCamera *cam, const Int_t what) const; 83 84 void DisplayOutliers(TH1D *hist) const; -
trunk/MagicSoft/Mars/mjobs/MJob.cc
r8245 r8518 302 302 } 303 303 304 if (fDisplay)305 cont.Add((TObject*)(fDisplay));306 307 304 return WriteContainer(cont); 305 } 306 307 Bool_t MJob::WriteDisplay(const char *name, const char *option, const int compr) const 308 { 309 if (!fDisplay) 310 return kTRUE; 311 312 TObjArray arr; 313 arr.Add((TObject*)(fDisplay)); 314 return WriteContainer(arr, name, option, compr); 308 315 } 309 316 -
trunk/MagicSoft/Mars/mjobs/MJob.h
r8245 r8518 49 49 Bool_t ReadContainer(TCollection &list) const; 50 50 Bool_t WriteContainer(TCollection &cont, const char *name, const char *option="RECREATE", const int compr=2) const; 51 Bool_t WriteDisplay(const char *name, const char *option="RECREATE", const int comp=2) const; 51 52 52 53 public:
Note:
See TracChangeset
for help on using the changeset viewer.