- Timestamp:
- 05/11/07 16:47:18 (18 years ago)
- Location:
- trunk/MagicSoft/Mars
- Files:
-
- 11 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/Changelog
r8496 r8498 70 70 - adapted GetPixelContent accordingly 71 71 - increased class version to 2 72 73 * manalysis/MCameraData.cc: 74 - added include of TArrayI (previously included from MPedestalCam) 75 76 * mcalib/MCalibrationChargeCam.cc, mcalib/MCalibrationRelTimeCam.cc: 77 - fixed GetPixelContant to give more proper output 78 - reformatted GetPIxelContent code 79 - added const-qualifiers 80 81 * mjobs/MJCalibTest.cc, mjobs/MJCalibrateSignal.cc, 82 mjobs/MJCalibration.cc, mjobs/MJPedestal.cc, 83 mpedestal/MExtractPedestal.[h,cc], msignal/MExtractor.[h,cc], 84 msignal/MExtractBlindPixel.cc, msignal/MExtractPINDiode.cc: 85 - removed data members fPedestal and fPedestalsIn respectively, 86 and all referencing functions because it was never used at all 72 87 73 88 -
trunk/MagicSoft/Mars/mjobs/MJCalibTest.cc
r8434 r8498 396 396 MExtractTimeAndChargeSpline spline; 397 397 398 spline.SetPedestals(&pedcam);399 400 398 MTaskEnv taskenv1("ExtractSignal"); 401 399 MTaskEnv taskenv2("ExtractTime"); 402 400 403 401 if (extractor1) 404 {405 extractor1->SetPedestals(&pedcam);406 402 taskenv1.SetDefault(extractor1); 407 }408 403 409 404 if (extractor2) 410 {411 fTimeExtractor->SetPedestals(&pedcam);412 405 taskenv2.SetDefault(fTimeExtractor); 413 }414 406 else if (!(extractor1->InheritsFrom("MExtractTimeAndCharge"))) 415 407 { 416 spline.SetPedestals(&pedcam);417 408 spline.SetWindowSize(8,8); 418 409 taskenv2.SetDefault(&spline); … … 544 535 545 536 } 546 -
trunk/MagicSoft/Mars/mjobs/MJCalibrateSignal.cc
r8489 r8498 418 418 pedlo2.SetPedestalUpdate(kTRUE); 419 419 pedlo2.SetRandomCalculation(kTRUE); 420 pedlo2.SetNamePedestalCamIn("MPedestalFundamental");421 420 pedlo2.SetNamePedestalCamOut("MPedestalFromExtractorRndm"); 422 421 … … 424 423 pedlo3.SetPedestalUpdate(kTRUE); 425 424 pedlo3.SetRandomCalculation(kFALSE); 426 pedlo3.SetNamePedestalCamIn("MPedestalFundamental");427 425 pedlo3.SetNamePedestalCamOut("MPedestalFromExtractor"); 428 426 … … 432 430 return kFALSE; 433 431 } 434 435 extractor1->SetPedestals(&pedcamab);436 432 437 433 // Setup to use the hi-gain extraction window in the lo-gain … … 460 456 } 461 457 462 if (extractor2)463 extractor2->SetPedestals(&pedcamab);464 465 if (extractor3)466 extractor3->SetPedestals(&pedcamab);467 468 458 //------------------------------ 469 459 MFTriggerPattern ftp2; … … 530 520 MCalibCalcFromPast pacalc; 531 521 532 pinext.SetPedestals(&pedcamab);533 bldext.SetPedestals(&pedcamab);534 522 chcalc.SetPedestals(&pedcamextr); 535 523 -
trunk/MagicSoft/Mars/mjobs/MJCalibration.cc
r8484 r8498 1802 1802 // Produce pedestal subtracted raw-data 1803 1803 MPedestalSubtract pedsub; 1804 pedsub.SetPedestalCam(fExtractor->GetPedestals());1805 1804 tlist.AddToList(&pedsub); 1806 1805 -
trunk/MagicSoft/Mars/mjobs/MJPedestal.cc
r8449 r8498 1188 1188 } 1189 1189 1190 pedcalc.SetPedestalsIn(&fPedestalCamIn);1191 pedlogain.SetPedestalsIn(&fPedestalCamIn);1192 1193 1190 pedcalc.SetPedestalsOut(&fPedestalCamOut); 1194 1191 pedlogain.SetPedestalsOut(&fPedestalCamOut); … … 1197 1194 if (fExtractor) 1198 1195 { 1199 fExtractor->SetPedestals(&fPedestalCamIn);1200 1201 1196 if (fExtractionType!=kFundamental) 1202 1197 { -
trunk/MagicSoft/Mars/mpedestal/MExtractPedestal.cc
r8490 r8498 1 1 /* ======================================================================== *\ 2 ! $Name: not supported by cvs2svn $:$Id: MExtractPedestal.cc,v 1. 29 2007-05-11 10:25:45tbretz Exp $2 ! $Name: not supported by cvs2svn $:$Id: MExtractPedestal.cc,v 1.30 2007-05-11 15:47:18 tbretz Exp $ 3 3 ! -------------------------------------------------------------------------- 4 4 ! … … 194 194 // 195 195 MExtractPedestal::MExtractPedestal(const char *name, const char *title) 196 : fGeom(NULL), fPedestalsIn (NULL), fPedestalsInter(NULL),196 : fGeom(NULL), fPedestalsInter(NULL), 197 197 fPedestalsOut(NULL), fExtractor(NULL), fSignal(0), 198 198 fExtractWinFirst(0), fExtractWinSize(0), fUseSpecialPixels(kFALSE) … … 204 204 SetRandomCalculation ( kTRUE ); 205 205 206 SetNamePedestalCamIn();207 206 SetNamePedestalCamOut(); 208 207 SetNamePedestalCamInter(); … … 427 426 } 428 427 429 if (fExtractor && !fPedestalsIn)430 {431 fPedestalsIn = (MPedestalCam*)pList->FindObject(AddSerialNumber(fNamePedestalCamIn), "MPedestalCam");432 if (!fPedestalsIn)433 {434 *fLog << err << AddSerialNumber(fNamePedestalCamIn) << " not found... aborting." << endl;435 return kFALSE;436 }437 }438 439 428 if (!fPedestalsInter && fIntermediateStorage) 440 429 { … … 603 592 Int_t MExtractPedestal::PostProcess() 604 593 { 605 fPedestalsIn = NULL;606 594 return fExtractor ? fExtractor->CallPostProcess() : kTRUE; 607 595 } … … 947 935 { 948 936 *fLog << GetDescriptor() << ":" << endl; 949 *fLog << "Name of input MPedestalCam: " << (fPedestalsIn?fPedestalsIn->GetName():fNamePedestalCamIn.Data()) << " (" << fPedestalsIn << ")" << endl;950 937 *fLog << "Name of interm. MPedestalCam: " << (fPedestalsInter?fPedestalsInter->GetName():fNamePedestalCamInter.Data()) << " (" << fPedestalsInter << ")" << endl; 951 938 *fLog << "Name of output MPedestalCam: " << (fPedestalsOut?fPedestalsOut->GetName():fNamePedestalCamOut.Data()) << " (" << fPedestalsOut << ")" << endl; … … 1033 1020 } 1034 1021 1035 // find resource for MPedestalCam1036 if (IsEnvDefined(env, prefix, "NamePedestalCamIn", print))1037 {1038 SetNamePedestalCamIn(GetEnvValue(env, prefix, "NamePedestalCamIn", fNamePedestalCamIn));1039 rc = kTRUE;1040 }1041 1042 1022 if (IsEnvDefined(env, prefix, "NamePedestalCamInter", print)) 1043 1023 { -
trunk/MagicSoft/Mars/mpedestal/MExtractPedestal.h
r8490 r8498 34 34 static const UShort_t fgMaxSignalVar; //! The maximum difference between the highest and lowest slice 35 35 36 TString fNamePedestalCamIn; // Name of the incoming 'MPedestalCam' container37 36 TString fNamePedestalCamOut; // Name of the outgoing 'MPedestalCam' container 38 37 TString fNamePedestalCamInter; // Name of the intermediate 'MPedestalCam' container … … 50 49 51 50 MGeomCam *fGeom; //! Camera geometry 52 MPedestalCam *fPedestalsIn; //! Pedestals of all pixels in the camera (incoming)53 51 MPedestalCam *fPedestalsInter; //! Pedestals of all pixels in the camera (intermediate) 54 52 MPedestalCam *fPedestalsOut; //! Pedestals of all pixels in the camera (outgoing) … … 130 128 131 129 // names 132 void SetNamePedestalCamIn (const char *name=fgNamePedestalCam) { fNamePedestalCamIn = name; }133 130 void SetNamePedestalCamInter(const char *name=fgNamePedestalCam) { fNamePedestalCamInter = name; } 134 131 void SetNamePedestalCamOut (const char *name=fgNamePedestalCam) { fNamePedestalCamOut = name; } … … 137 134 // pointers 138 135 void SetExtractor ( MExtractTimeAndCharge *e) { fExtractor = e; } 139 void SetPedestalsIn ( MPedestalCam *pedcam ) { fPedestalsIn = pedcam; }140 136 void SetPedestalsInter( MPedestalCam *pedcam ) { fPedestalsInter = pedcam; } 141 137 void SetPedestalsOut ( MPedestalCam *pedcam ) { fPedestalsOut = pedcam; } -
trunk/MagicSoft/Mars/msignal/MExtractBlindPixel.cc
r8490 r8498 231 231 232 232 fBlindPixel->SetExtractionType(fExtractionType); 233 233 /* 234 234 for (UInt_t i=0;i<fBlindPixelIdx.GetSize();i++) 235 235 { … … 246 246 } 247 247 } 248 /* 248 249 249 const Int_t higainsamples = fRunHeader->GetNumSamplesHiGain(); 250 250 const Int_t logainsamples = fRunHeader->GetNumSamplesLoGain(); -
trunk/MagicSoft/Mars/msignal/MExtractPINDiode.cc
r8367 r8498 208 208 209 209 fPedMean.Reset(); 210 210 /* 211 211 const MPedestalPix &ped = (*fPedestals)[fPINDiodeIdx]; 212 212 … … 222 222 return kFALSE; 223 223 } 224 224 */ 225 225 if (fSlices) 226 226 delete fSlices; -
trunk/MagicSoft/Mars/msignal/MExtractor.cc
r8364 r8498 115 115 116 116 const UInt_t MExtractor::fgSaturationLimit = 245; 117 const TString MExtractor::fgNamePedestalCam = "MPedestalCam";118 117 const TString MExtractor::fgNameSignalCam = "MExtractedSignalCam"; 119 118 const Float_t MExtractor::fgOffsetLoGain = 1.51; // 5 ns … … 127 126 // - all variables to 0 128 127 // - fSaturationLimit to fgSaturationLimit 129 // - fNamePedestalCam to fgNamePedestalCam130 128 // - fNameSignalCam to fgNameSignalCam 131 129 // - fNoiseCalculation to kFALSE … … 133 131 MExtractor::MExtractor(const char *name, const char *title) 134 132 : fResolutionPerPheHiGain(0), fResolutionPerPheLoGain(0), 135 fPedestals(NULL), fSignals(NULL), fRawEvt(NULL), fRunHeader(NULL), 136 fSignal(NULL), 133 fSignals(NULL), fRawEvt(NULL), fRunHeader(NULL), fSignal(NULL), 137 134 /*fHiLoLast(0),*/ fNumHiGainSamples(0), fNumLoGainSamples(0) 138 135 { … … 140 137 fTitle = title ? title : "Base class for signal extractors"; 141 138 142 SetNamePedestalCam();143 139 SetNameSignalCam(); 144 140 SetOffsetLoGain(); … … 162 158 // MRawEvtData 163 159 // MRawRunHeader 164 // MPedestalCam165 160 // 166 161 Int_t MExtractor::PreProcessStd(MParList *pList) … … 185 180 { 186 181 *fLog << err << AddSerialNumber("MPedestalSubtractedEvt") << " not found... aborting." << endl; 187 return kFALSE;188 }189 190 191 if (fPedestals)192 return kTRUE;193 194 fPedestals = (MPedestalCam*)pList->FindObject(AddSerialNumber(fNamePedestalCam), "MPedestalCam");195 if (!fPedestals)196 {197 *fLog << err << AddSerialNumber(fNamePedestalCam) << " [MPedestalCam] not found... aborting" << endl;198 182 return kFALSE; 199 183 } … … 207 191 // - MRawEvtData 208 192 // - MRawRunHeader 209 // - MPedestalCam210 193 // 211 194 // The following output containers are also searched and created if … … 480 463 *fLog << " Num Samples Hi/Lo: " << Form("%2.1f %2.1f", fNumHiGainSamples, fNumLoGainSamples) << endl; 481 464 } 482 if (fPedestals) 483 *fLog << " Pedestals: " << fPedestals->GetName() << ", " << fPedestals << endl; 484 } 465 } -
trunk/MagicSoft/Mars/msignal/MExtractor.h
r8364 r8498 17 17 class MRawRunHeader; 18 18 19 class MPedestalCam;20 19 class MPedestalSubtractedEvt; 21 20 class MExtractedSignalCam; … … 33 32 protected: 34 33 static const UInt_t fgSaturationLimit; //! Default for fSaturationLimit (now set to: 254) 35 static const TString fgNamePedestalCam; //! "MPedestalCam"36 34 static const TString fgNameSignalCam; //! "MExtractedSignalCam" 37 35 38 36 Float_t fOffsetLoGain; // Offset of the low-gain signal w.r.t. the High-Gain slices 39 37 40 MPedestalCam *fPedestals; //! Pedestals of all pixels in the camera41 38 MExtractedSignalCam *fSignals; //! Extracted signal of all pixels in the camera 42 39 43 40 MRawEvtData *fRawEvt; //! Raw event data (time slices) 44 41 MRawRunHeader *fRunHeader; //! RunHeader information 45 42 46 43 MPedestalSubtractedEvt *fSignal; //! 47 44 48 45 Byte_t fHiGainFirst; // First FADC slice nr. to extract the High Gain signal 49 46 Byte_t fHiGainLast; // Last FADC slice nr. to extract the High Gain signal … … 61 58 UInt_t fSaturationLimit; // Highest FADC slice value until being declared saturated 62 59 63 TString fNamePedestalCam; // Name of the 'MPedestalCam' container64 60 TString fNameSignalCam; // Name of the 'MExtractedSignalCam' container 65 61 … … 107 103 void SetOffsetLoGain ( const Float_t f=fgOffsetLoGain ) { fOffsetLoGain = f; } 108 104 void SetSaturationLimit ( const UInt_t lim=fgSaturationLimit ) { fSaturationLimit = lim; } 109 void SetNamePedestalCam ( const char *name=fgNamePedestalCam.Data()) { fNamePedestalCam = name; }110 105 void SetNameSignalCam ( const char *name=fgNameSignalCam.Data() ) { fNameSignalCam = name; } 111 106 void SetNoiseCalculation( const Bool_t b=kTRUE ) { fNoiseCalculation = b; } 112 113 void SetPedestals (MPedestalCam *pedcam) { fPedestals = pedcam; }114 MPedestalCam *GetPedestals() { return fPedestals; }115 107 116 108 // TObject
Note:
See TracChangeset
for help on using the changeset viewer.