Changeset 6191
- Timestamp:
- 02/02/05 10:12:41 (20 years ago)
- Location:
- trunk/MagicSoft/Mars
- Files:
-
- 4 added
- 2 deleted
- 9 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/Changelog
r6189 r6191 20 20 21 21 -*-*- END OF LINE -*-*- 22 23 2005/02/02 Markus Gaug 24 25 * mjobs/MJCalib.[h,cc] 26 - put the data type enum in a new base class 27 28 * mjobs/MJCalibTest.[h,cc] 29 - re-name old class MJExtractCalibTest to MJCalibTest and make it 30 compatible with the sequence-files. 31 32 * mjobs/MJExtractCalibTest.[h,cc] 33 - remove 34 22 35 23 36 2005/02/01 Raquel de los Reyes -
trunk/MagicSoft/Mars/mjobs/JobsLinkDef.h
r5683 r6191 6 6 7 7 #pragma link C++ class MJob+; 8 #pragma link C++ class MJCalib+; 8 9 #pragma link C++ class MSequence+; 9 10 … … 14 15 #pragma link C++ class MJCalibrateSignalFromOutside+; 15 16 #pragma link C++ class MJExtractSignal+; 16 #pragma link C++ class MJ ExtractCalibTest+;17 #pragma link C++ class MJCalibTest+; 17 18 18 19 #endif -
trunk/MagicSoft/Mars/mjobs/MJCalibrateSignal.cc
r6182 r6191 114 114 // Default constructor. 115 115 // 116 // Sets fRuns to 0, fExtractor to NULL, 116 // Sets: 117 // - fIsInterlaced to kTRUE 118 // - fIsRelTimesUpdate to kFALSE 119 // - fIsHiLoCalibration to kFALSE 117 120 // 118 121 MJCalibrateSignal::MJCalibrateSignal(const char *name, const char *title) 119 : fRuns(0), fIsInterlaced(kTRUE), fIsRelTimesUpdate(kFALSE), fIsHiLoCalibration(kFALSE), 120 fDataFlag(0) 122 : fIsInterlaced(kTRUE), fIsRelTimesUpdate(kFALSE), fIsHiLoCalibration(kFALSE) 121 123 { 122 124 fName = name ? name : "MJCalibrateSignal"; 123 125 fTitle = title ? title : "Tool to calibrate data"; 124 126 125 SetUseRootData();126 127 } 127 128 … … 399 400 400 401 MFTriggerPattern ftp; 401 ftp.RequireCalibration();402 //ftp.DenyCalibration();403 //ftp.DenyPedestal();402 // ftp.RequireCalibration(); 403 ftp.DenyCalibration(); 404 ftp.DenyPedestal(); 404 405 // ftp.DenyPinDiode(); 405 //ftp.SetInverted();406 ftp.SetInverted(); 406 407 MContinue conttp(&ftp, "ContTrigPattern"); 407 408 // --> tlist2 -
trunk/MagicSoft/Mars/mjobs/MJCalibrateSignal.h
r6177 r6191 6 6 #endif 7 7 8 #ifndef MARS_MJCalib 9 #include "MJCalib.h" 10 #endif 11 8 12 class TEnv; 9 13 class TList; 10 class MRunIter;11 14 class MTask; 12 15 class MParList; … … 17 20 class MBadPixelsCam; 18 21 19 class MJCalibrateSignal : public MJob 22 class MJCalibrateSignal : public MJob, public MJCalib 20 23 { 21 24 private: 22 23 MRunIter *fRuns; // Data files24 25 25 26 Bool_t fIsInterlaced; // Distinguish interlaced from other calibration … … 27 28 Bool_t fIsHiLoCalibration; // Choose to calibrate the high-gain vs. low-gains 28 29 29 30 enum DataType_t31 {32 kIsUseRawData,33 kIsUseRootData,34 kIsUseMC35 };36 37 Byte_t fDataFlag; // Bit-field to store the data type38 39 Bool_t IsUseRawData() const { return TESTBIT(fDataFlag,kIsUseRawData); }40 Bool_t IsUseRootData() const { return TESTBIT(fDataFlag,kIsUseRootData); }41 Bool_t IsUseMC() const { return TESTBIT(fDataFlag,kIsUseMC); }42 43 void SetUseRawData ( const Bool_t b=kTRUE ) { b ? SETBIT(fDataFlag,kIsUseRawData) : CLRBIT(fDataFlag,kIsUseRawData); }44 void SetUseRootData( const Bool_t b=kTRUE ) { b ? SETBIT(fDataFlag,kIsUseRootData) : CLRBIT(fDataFlag,kIsUseRootData); }45 void SetUseMC ( const Bool_t b=kTRUE ) { b ? SETBIT(fDataFlag,kIsUseMC) : CLRBIT(fDataFlag,kIsUseMC); }46 47 30 Bool_t CheckEnvLocal(); 48 31 … … 63 46 void SetHiLoCalibration( const Bool_t b=kTRUE ) { fIsHiLoCalibration = b; } 64 47 65 void SetInput ( MRunIter *iter ) { fRuns = iter; }66 67 48 ClassDef(MJCalibrateSignal, 0) // Tool to create a pedestal file (MPedestalCam) 68 49 }; -
trunk/MagicSoft/Mars/mjobs/MJCalibration.cc
r6181 r6191 186 186 // 187 187 MJCalibration::MJCalibration(const char *name, const char *title) 188 : f Runs(0), fExtractor(NULL), fTimeExtractor(NULL),188 : fExtractor(NULL), fTimeExtractor(NULL), 189 189 fColor(MCalibrationCam::kNONE), fDisplayType(kDataCheckDisplay), 190 f DataFlag(0), fGeometry("MGeomCamMagic")190 fGeometry("MGeomCamMagic") 191 191 { 192 192 -
trunk/MagicSoft/Mars/mjobs/MJCalibration.h
r6177 r6191 5 5 #include "MJob.h" 6 6 #endif 7 #ifndef MARS_MJCalib 8 #include "MJCalib.h" 9 #endif 7 10 #ifndef MARS_MCalibrationIntensityChargeCam 8 11 #include "MCalibrationIntensityChargeCam.h" … … 45 48 46 49 class MTask; 47 class MRunIter;48 50 class MParList; 49 51 class MPedestalCam; … … 55 57 class MHCamera; 56 58 57 class MJCalibration : public MJob 59 class MJCalibration : public MJob, public MJCalib 58 60 { 59 61 private: … … 96 98 TString fReferenceFile; // File name containing the reference values 97 99 98 MRunIter *fRuns; // Calibration files99 100 100 MExtractor *fExtractor; // Signal extractor 101 101 MExtractTime *fTimeExtractor; // Arrival Time extractor … … 146 146 Byte_t fFlags; // Bit-field for the flags 147 147 148 enum DataType_t149 {150 kIsUseRawData,151 kIsUseRootData,152 kIsUseMC153 };154 155 Byte_t fDataFlag; // Bit-field to store the data type156 157 Bool_t IsUseRawData() const { return TESTBIT(fDataFlag,kIsUseRawData); }158 Bool_t IsUseRootData() const { return TESTBIT(fDataFlag,kIsUseRootData); }159 Bool_t IsUseMC() const { return TESTBIT(fDataFlag,kIsUseMC); }160 161 void SetUseRawData ( const Bool_t b=kTRUE ) { b ? SETBIT(fDataFlag,kIsUseRawData) : CLRBIT(fDataFlag,kIsUseRawData); }162 void SetUseRootData( const Bool_t b=kTRUE ) { b ? SETBIT(fDataFlag,kIsUseRootData) : CLRBIT(fDataFlag,kIsUseRootData); }163 void SetUseMC ( const Bool_t b=kTRUE ) { b ? SETBIT(fDataFlag,kIsUseMC) : CLRBIT(fDataFlag,kIsUseMC); }164 165 166 148 TString fGeometry; // Class name geometry 167 149 … … 216 198 void SetExtractor ( MExtractor* ext) { fExtractor = ext; } 217 199 void SetExtractorCam ( const MPedestalCam &ped) { ped.Copy(fExtractorCam); fExtractorCam.SetName(ped.GetName()); } 218 void SetInput ( MRunIter *iter) { fRuns = iter; }219 200 void SetQECam ( const MCalibrationQECam &qe) { qe.Copy(fQECam); } 220 201 void SetTimeExtractor( MExtractTime* ext) { fTimeExtractor = ext; } -
trunk/MagicSoft/Mars/mjobs/MJPedestal.cc
r6181 r6191 101 101 // 102 102 MJPedestal::MJPedestal(const char *name, const char *title) 103 : f Runs(0), fExtractor(NULL), fDisplayType(kDisplayDataCheck),104 fExtractType(kUsePedRun), fExtractionType(kFundamental) , fDataFlag(0)103 : fExtractor(NULL), fDisplayType(kDisplayDataCheck), 104 fExtractType(kUsePedRun), fExtractionType(kFundamental) 105 105 { 106 106 fName = name ? name : "MJPedestal"; -
trunk/MagicSoft/Mars/mjobs/MJPedestal.h
r6177 r6191 4 4 #ifndef MARS_MJob 5 5 #include "MJob.h" 6 #endif 7 #ifndef MARS_MJCalib 8 #include "MJCalib.h" 6 9 #endif 7 10 #ifndef MARS_MPedestalCam … … 14 17 class TCanvas; 15 18 class MParList; 16 class MRunIter;17 19 class MHCamera; 18 20 class TH1D; … … 21 23 class MEvtLoop; 22 24 23 class MJPedestal : public MJob 25 class MJPedestal : public MJob, public MJCalib 24 26 { 25 27 private: … … 46 48 TString fReferenceFile; // File name containing the reference values 47 49 48 MRunIter *fRuns; // Used pedestal runs49 50 MExtractor *fExtractor; // Signal extractor, used to find the nr. of used FADC slices 50 51 … … 64 65 enum Extraction { kFundamental, kWithExtractorRndm, kWithExtractor }; 65 66 Int_t fExtractionType; // Flag if the extractor is used to calculate the pedestals 66 67 enum DataType_t68 {69 kIsUseRawData,70 kIsUseRootData,71 kIsUseMC72 };73 74 Byte_t fDataFlag; // Bit-field to store the data type75 76 Bool_t IsUseRawData() const { return TESTBIT(fDataFlag,kIsUseRawData); }77 Bool_t IsUseRootData() const { return TESTBIT(fDataFlag,kIsUseRootData); }78 Bool_t IsUseMC() const { return TESTBIT(fDataFlag,kIsUseMC); }79 80 void SetUseRawData ( const Bool_t b=kTRUE ) { b ? SETBIT(fDataFlag,kIsUseRawData) : CLRBIT(fDataFlag,kIsUseRawData); }81 void SetUseRootData( const Bool_t b=kTRUE ) { b ? SETBIT(fDataFlag,kIsUseRootData) : CLRBIT(fDataFlag,kIsUseRootData); }82 void SetUseMC ( const Bool_t b=kTRUE ) { b ? SETBIT(fDataFlag,kIsUseMC) : CLRBIT(fDataFlag,kIsUseMC); }83 67 84 68 MExtractor *ReadCalibration() const; … … 115 99 void SetPedestals(const MPedestalCam &ped) { ped.Copy(fPedestalCamIn); } 116 100 void SetExtractor(MExtractor* ext); 117 void SetInput(MRunIter *iter) { fRuns = iter; }118 101 void SetUseData() { fExtractType = kUseData; } 119 102 void SetUseHists() { fExtractType = kUseHists; } -
trunk/MagicSoft/Mars/mjobs/Makefile
r5804 r6191 27 27 SRCFILES = MSequence.cc \ 28 28 MJob.cc \ 29 MJCalib.cc \ 29 30 MJStar.cc \ 30 31 MJPedestal.cc \ … … 33 34 MJCalibrateSignalFromOutside.cc \ 34 35 MJExtractSignal.cc \ 35 MJ ExtractCalibTest.cc36 MJCalibTest.cc 36 37 37 38 ############################################################
Note:
See TracChangeset
for help on using the changeset viewer.