Changeset 5679 for trunk/MagicSoft/Mars/mcalib
- Timestamp:
- 12/22/04 20:13:41 (20 years ago)
- Location:
- trunk/MagicSoft/Mars/mcalib
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/mcalib/MCalibColorSteer.cc
r5481 r5679 51 51 52 52 #include "MHCalibrationCam.h" 53 #include "MCalibrationCam.h" 54 #include "MCalibrationBlindCam.h" 53 55 54 56 #include "MCalibrationIntensityChargeCam.h" … … 78 80 : fHeader(NULL), fGeom(NULL), fParList(NULL), 79 81 fIntensCharge(NULL), fIntensRelTime(NULL), fIntensBad(NULL), 80 fChargeCalc(NULL), fRelTimeCalc(NULL), 81 fPattern(0) 82 fBad(NULL), fChargeCalc(NULL), fRelTimeCalc(NULL), fPattern(0) 82 83 { 83 84 … … 135 136 // 136 137 fIntensBad = (MBadPixelsIntensityCam*)pList->FindCreateObj("MBadPixelsIntensityCam"); 137 138 *fLog << inf << "Found MBadPixelsIntensityCam ... " << flush; 138 if (fIntensBad) 139 *fLog << inf << "Found MBadPixelsIntensityCam ... " << flush; 140 else 141 return kFALSE; 142 143 // 144 // Look for the MBadPixels Intensity Cam 145 // 146 fBad = (MBadPixelsCam*)pList->FindObject("MBadPixelsCam"); 147 if (fBad) 148 { 149 *fLog << inf << "Found also MBadPixelsCam ... " << flush; 150 fIntensBad->GetCam()->Merge(*fBad); 151 } 152 else 153 return kFALSE; 154 139 155 // 140 156 // Look for the MCalibrationIntensityBlindCam … … 142 158 fIntensBlind = (MCalibrationIntensityBlindCam*)pList->FindCreateObj("MCalibrationIntensityBlindCam"); 143 159 144 *fLog << inf << "Found MCalibrationIntensityBlindCam ... " << flush; 145 160 if (fIntensBlind) 161 *fLog << inf << "Found MCalibrationIntensityBlindCam ... " << flush; 162 else 163 return kFALSE; 164 146 165 // 147 166 // Look for the MFillH name "FillChargeCam". In case yes, initialize the … … 208 227 // 209 228 // Reads the pattern from MRawEvtHeader and initializes new containers in the 210 // Intensity Cams, if the pattern has changed. Executes CallPostProcessof the229 // Intensity Cams, if the pattern has changed. Executes Finalize of the 211 230 // MCalibration*Calc classes in that case. 212 231 // … … 214 233 { 215 234 216 const UInt_t pattern = fHeader->GetCalibrationPattern(); 217 218 if (pattern == fPattern) 219 return kTRUE; 235 const UInt_t pattern = fHeader->GetPulserSlotPattern(); 220 236 221 237 if (fPattern == 0) … … 225 241 } 226 242 243 if (pattern == 0 || pattern == fPattern) 244 return kTRUE; 245 246 *fLog << inf << GetDescriptor() << " : old pattern: " << fPattern << flush; 247 227 248 fPattern = pattern; 228 249 250 *fLog << " : new pattern: " << pattern << flush; 251 229 252 // 230 253 // Finalize Possible calibration histogram classes... … … 243 266 *fLog << inf << GetDescriptor() << " : Finalize calibration calculations..." << flush; 244 267 if (fChargeCalc) 245 fChargeCalc-> CallPostProcess();268 fChargeCalc->Finalize(); 246 269 if (fRelTimeCalc) 247 fRelTimeCalc-> CallPostProcess();270 fRelTimeCalc->Finalize(); 248 271 249 272 ReInitialize(); … … 267 290 hist->Finalize(); 268 291 hist->ResetHists(); 292 hist->SetColor( fHeader->GetPulserColor()); 269 293 return kTRUE; 270 294 } … … 284 308 285 309 *fLog << endl; 286 310 311 TString namep = GetNamePattern(); 312 287 313 if (fIntensBad) 288 314 { 289 fIntensBad->AddToList(Form("MBadPixelsCam%s",GetNamePattern()),*fGeom); 290 *fLog << inf << "New MBadPixelsCam with " << GetNamePattern() << endl; 315 fIntensBad->AddToList(Form("MBadPixelsCam%s",namep.Data()),*fGeom); 316 *fLog << inf << "New MBadPixelsCam with " << namep << endl; 317 fIntensBad->GetCam()->Merge(*fBad); 318 *fLog << inf << "Merged new MBadPixelsCam with first of list" << endl; 291 319 } 292 320 if (fIntensCharge) 293 321 { 294 fIntensCharge->AddToList(Form("MCalibrationChargeCam%s",GetNamePattern()),*fGeom); 295 *fLog << inf << "New MCalibrationChargeCam with " << GetNamePattern() << endl; 322 fIntensCharge->AddToList(Form("MCalibrationChargeCam%s",namep.Data()),*fGeom); 323 MCalibrationCam *cam = fIntensCharge->GetCam(); 324 cam->SetPulserColor(fHeader->GetPulserColor()); 325 *fLog << inf << "New MCalibrationChargeCam with name: " << cam->GetName() << endl; 296 326 } 297 327 if (fIntensQE) 298 328 { 299 fIntensQE->AddToList(Form("MCalibrationQECam%s",GetNamePattern()),*fGeom); 300 *fLog << inf << "New MCalibrationQECam with " << GetNamePattern() << endl; 301 } 329 fIntensQE->AddToList(Form("MCalibrationQECam%s",namep.Data()),*fGeom); 330 *fLog << inf << "New MCalibrationQECam with: " << namep << endl; 331 } 332 302 333 if (fIntensBlind) 303 334 { 304 fIntensBlind->AddToList(Form("MCalibrationBlindCam%s",GetNamePattern()),*fGeom); 305 *fLog << inf << "New MCalibrationBlindCam with " << GetNamePattern() << endl; 335 fIntensBlind->AddToList(Form("MCalibrationBlindCam%s",namep.Data()),*fGeom); 336 MCalibrationCam *cam = fIntensBlind->GetCam(); 337 cam->SetPulserColor(fHeader->GetPulserColor()); 338 *fLog << inf << "New MCalibrationBlindCam with name: " << cam->GetName() << endl; 339 } 340 341 if (fIntensRelTime) 342 { 343 fIntensRelTime->AddToList(Form("MCalibrationRelTimeCam%s",namep.Data()),*fGeom); 344 MCalibrationCam *cam = fIntensRelTime->GetCam(); 345 cam->SetPulserColor(fHeader->GetPulserColor()); 346 *fLog << inf << "New MCalibrationRelTimeCam with name: " << cam->GetName() << endl; 306 347 } 307 348 … … 310 351 } 311 352 312 const char* MCalibColorSteer::GetNamePattern() 313 { 314 315 Float_t number[MCalibrationCam::gkNumPulserColors]; 316 memset(number,0,MCalibrationCam::gkNumPulserColors*sizeof(Float_t)); 317 318 enum ColorCode_t 319 { 320 k5LedGreen = BIT(0 ), 321 k2LedGreen = BIT(1 ), 322 k5LedBlue2 = BIT(2 ), 323 k1LedUV = BIT(3 ), 324 k2LedUV = BIT(4 ), 325 k5LedBlue3 = BIT(5 ), 326 k5LedBlue4 = BIT(6 ), 327 k2LedBlue = BIT(7 ), 328 k01LedBlue = BIT(8 ), 329 k1LedBlue = BIT(10), 330 k5LedUV1 = BIT(11), 331 k5LedUV2 = BIT(12), 332 k5LedBlue1 = BIT(13), 333 k1LedGreen = BIT(14), 334 k01LedGreen = BIT(15), 335 kCT1Pulser = BIT(16) 336 }; 337 338 if (fPattern & k5LedGreen) 339 number[MCalibrationCam::kGREEN] += 5; 340 if (fPattern & k2LedGreen) 341 number[MCalibrationCam::kGREEN] += 2; 342 if (fPattern & k5LedBlue2) 343 number[MCalibrationCam::kBLUE] += 2; 344 if (fPattern & k1LedUV) 345 number[MCalibrationCam::kUV] += 1; 346 if (fPattern & k2LedUV) 347 number[MCalibrationCam::kUV] += 2; 348 if (fPattern & k5LedBlue3) 349 number[MCalibrationCam::kBLUE] += 5; 350 if (fPattern & k5LedBlue4) 351 number[MCalibrationCam::kBLUE] += 5; 352 if (fPattern & k2LedBlue) 353 number[MCalibrationCam::kBLUE] += 2; 354 if (fPattern & k01LedBlue) 355 number[MCalibrationCam::kBLUE] += 0.5; 356 if (fPattern & k1LedBlue) 357 number[MCalibrationCam::kBLUE] += 1; 358 if (fPattern & k5LedUV1) 359 number[MCalibrationCam::kUV] += 5; 360 if (fPattern & k5LedUV2) 361 number[MCalibrationCam::kUV] += 5; 362 if (fPattern & k5LedBlue1) 363 number[MCalibrationCam::kBLUE] += 5; 364 if (fPattern & k1LedGreen) 365 number[MCalibrationCam::kGREEN] += 1; 366 if (fPattern & k01LedGreen) 367 number[MCalibrationCam::kGREEN] += 0.5; 368 if (fPattern & kCT1Pulser) 369 number[MCalibrationCam::kCT1] += 1; 370 371 TString result; 372 373 for (Int_t i=0; i<MCalibrationCam::gkNumPulserColors; i++) 374 { 375 switch (i) 376 { 377 case MCalibrationCam::kGREEN: 378 if (number[i] > 0.1) 379 result = Form("%2.1f%s",number[i],"GREEN"); 380 break; 381 case MCalibrationCam::kBLUE: 382 if (number[i] > 0.1) 383 result = Form("%2.1f%s",number[i],"BLUE"); 384 break; 385 case MCalibrationCam::kUV: 386 if (number[i] > 0.1) 387 result = Form("%2.1f%s",number[i],"UV"); 388 break; 389 case MCalibrationCam::kCT1: 390 if (number[i] > 0.1) 391 result = Form("%2.1f%s",number[i],"CT1"); 392 break; 393 } 394 } 395 return result.Data(); 396 } 353 TString MCalibColorSteer::GetNamePattern() 354 { 355 356 const Float_t strength = fHeader->GetPulserStrength(); 357 const MCalibrationCam::PulserColor_t col = fHeader->GetPulserColor(); 358 359 TString result = Form("%2.1f",strength); 360 361 switch (col) 362 { 363 case MCalibrationCam::kCT1: 364 result += "CT1"; 365 break; 366 case MCalibrationCam::kGREEN: 367 result += "GREEN"; 368 break; 369 case MCalibrationCam::kBLUE: 370 result += "BLUE"; 371 break; 372 case MCalibrationCam::kUV: 373 result += "UV"; 374 break; 375 default: 376 break; 377 } 378 return result; 379 } -
trunk/MagicSoft/Mars/mcalib/MCalibrationChargeCalc.cc
r5563 r5679 239 239 const Float_t MCalibrationChargeCalc::fgFFactorErrLimit = 4.5; 240 240 const TString MCalibrationChargeCalc::fgNamePedestalCam = "MPedestalCam"; 241 242 241 // -------------------------------------------------------------------------- 243 242 // … … 324 323 fNumInnerFFactorMethodUsed = 0; 325 324 325 fNumProcessed = 0; 326 326 327 fIntensBad = NULL; 327 328 fBadPixels = NULL; … … 337 338 fPedestals = NULL; 338 339 339 fPulserPattern = 0;340 340 SetPulserColor ( MCalibrationCam::kNONE ); 341 341 … … 355 355 Int_t MCalibrationChargeCalc::PreProcess(MParList *pList) 356 356 { 357 fHeader = (MRawEvtHeader*)pList->FindObject("MRawEvtHeader"); 358 if (!fHeader) 359 { 360 *fLog << err << "MRawEvtHeader not found... abort." << endl; 361 return kFALSE; 362 } 363 364 fSignal = (MExtractedSignalCam*)pList->FindObject("MExtractedSignalCam"); 365 if (!fSignal) 366 { 367 *fLog << err << "MExtractedSignalCam not found... aborting" << endl; 368 return kFALSE; 369 } 370 371 if (fPedestals) 372 return kTRUE; 373 374 fPedestals = (MPedestalCam*)pList->FindObject(AddSerialNumber(fNamePedestalCam), "MPedestalCam"); 375 if (!fPedestals) 376 { 377 *fLog << err << fNamePedestalCam << " not found... aborting" << endl; 378 return kFALSE; 379 } 380 357 358 fHeader = (MRawEvtHeader*)pList->FindObject("MRawEvtHeader"); 359 if (!fHeader) 360 { 361 *fLog << err << "MRawEvtHeader not found... abort." << endl; 362 return kFALSE; 363 } 364 365 // 366 // Containers that have to be there. 367 // 368 fSignal = (MExtractedSignalCam*)pList->FindObject("MExtractedSignalCam"); 369 if (!fSignal) 370 { 371 *fLog << err << "MExtractedSignalCam not found... aborting" << endl; 372 return kFALSE; 373 } 374 375 if (fPedestals) 381 376 return kTRUE; 377 378 fPedestals = (MPedestalCam*)pList->FindObject(AddSerialNumber(fNamePedestalCam), "MPedestalCam"); 379 if (!fPedestals) 380 { 381 *fLog << err << GetDescriptor() << fNamePedestalCam << " not found... aborting" << endl; 382 return kFALSE; 383 } 384 385 return kTRUE; 382 386 } 383 387 … … 509 513 } 510 514 511 fNumHiGainSamples = fSignal->GetNumUsedHiGainFADCSlices();512 fNumLoGainSamples = fSignal->GetNumUsedLoGainFADCSlices();513 514 fSqrtHiGainSamples = TMath::Sqrt(fNumHiGainSamples);515 fSqrtLoGainSamples = TMath::Sqrt(fNumLoGainSamples);516 517 518 515 MCalibrationQECam *qecam = fIntensQE 519 516 ? (MCalibrationQECam*) fIntensQE->GetCam() : fQECam; … … 532 529 MBadPixelsPix &bad = (*badcam) [i]; 533 530 534 pix.SetPixId(i);535 pqe.SetPixId(i);536 537 531 if (bad.IsBad()) 538 532 { … … 556 550 { 557 551 558 const UInt_t pattern = fHeader->GetCalibrationPattern(); 559 560 if (pattern == fPulserPattern) 552 const MCalibrationCam::PulserColor_t col = fHeader->GetPulserColor(); 553 554 if (col == fPulserColor) 555 { 556 fNumProcessed++; 557 return kTRUE; 558 } 559 560 if (col == MCalibrationCam::kNONE) 561 561 return kTRUE; 562 563 enum ColorCode_t 564 { 565 kSlot1Green = BIT(0), 566 kSlot2Green = BIT(1), 567 kSlot3Blue = BIT(2), 568 kSlot4UV = BIT(3), 569 kSlot5UV = BIT(4), 570 kSlot6Blue = BIT(5), 571 kSlot7Blue = BIT(6), 572 kSlot8Blue = BIT(7), 573 kSlot9AttBlue = BIT(8), 574 kSlot10Blue = BIT(9), 575 kSlot11Blue = BIT(10), 576 kSlot12UV = BIT(11), 577 kSlot13UV = BIT(12), 578 kSlot14Blue = BIT(13), 579 kSlot15Green = BIT(14), 580 kSlot16AttGreen = BIT(15), 581 kCT1Pulser = BIT(16), 582 kAnyGreen = kSlot1Green | kSlot2Green | kSlot15Green | kSlot16AttGreen, 583 kAnyUV = kSlot4UV | kSlot5UV | kSlot12UV | kSlot13UV, 584 kAnyBlue = kSlot3Blue | kSlot6Blue | kSlot7Blue | kSlot8Blue 585 | kSlot9AttBlue| kSlot10Blue | kSlot11Blue | kSlot14Blue 586 }; 587 588 // 589 // The pattern has changed, we have to initialize everything new!!! 590 // 591 *fLog << inf << GetDescriptor() << "- New pulser pattern: " ; 592 for (Int_t i=16; i>= 0; i--) 593 *fLog << (pattern >> i & 1); 594 *fLog << endl; 562 595 563 // 596 564 // Now retrieve the colour and check if not various colours have been used 597 565 // 598 if ((pattern & kAnyBlue || 599 pattern & kAnyUV || 600 pattern & kAnyGreen || 601 pattern & kCT1Pulser) && fPulserColor != MCalibrationCam::kNONE) 602 { 603 *fLog << err << "Multiple colours used simultaneously in calibration file. Will reset histograms " 604 << " and merge the MCalibrationQECam!" << endl; 605 fHCam->Finalize(); 606 fHBlindCam->Finalize(); 607 fHCam->ResetHists(); 608 fHBlindCam->ResetHists(); 609 CallPostProcess(); 610 } 611 612 fPulserColor = MCalibrationCam::kNONE; 613 fPulserPattern = pattern; 614 615 if (fPulserPattern & kAnyGreen) 616 fPulserColor = MCalibrationCam::kGREEN; 617 if (fPulserPattern & kAnyBlue) 618 fPulserColor = MCalibrationCam::kBLUE; 619 if (fPulserPattern & kAnyUV) 620 fPulserColor = MCalibrationCam::kUV; 621 if (fPulserPattern & kCT1Pulser) 622 fPulserColor = MCalibrationCam::kCT1; 566 if (!fIntensCam) 567 { 568 if (fPulserColor != MCalibrationCam::kNONE) 569 { 570 *fLog << err << "Multiple colours used simultaneously in calibration file. Will reset histograms " 571 << " and merge the MCalibrationQECam!" << endl; 572 fHCam->Finalize(); 573 fHBlindCam->Finalize(); 574 fHCam->ResetHists(); 575 fHBlindCam->ResetHists(); 576 Finalize(); 577 } 578 } 579 580 fPulserColor = col; 623 581 624 582 *fLog << inf << "Found new colour ... " << flush; 625 583 626 switch ( fPulserColor)627 { 628 case MCalibrationCam::kGREEN: *fLog << "Green ."; break;629 case MCalibrationCam::kBLUE: *fLog << "Blue ."; break;630 case MCalibrationCam::kUV: *fLog << "UV ."; break;631 case MCalibrationCam::kCT1: *fLog << "CT1 ."; break;584 switch (col) 585 { 586 case MCalibrationCam::kGREEN: *fLog << "Green"; break; 587 case MCalibrationCam::kBLUE: *fLog << "Blue"; break; 588 case MCalibrationCam::kUV: *fLog << "UV"; break; 589 case MCalibrationCam::kCT1: *fLog << "CT1"; break; 632 590 default: break; 633 591 } 634 *fLog << endl; 635 636 MCalibrationBlindCam *blindcam = fIntensBlind 637 ? (MCalibrationBlindCam*) fIntensBlind->GetCam() : fBlindCam; 638 MCalibrationChargeCam *chargecam = fIntensCam 639 ? (MCalibrationChargeCam*)fIntensCam->GetCam() : fCam; 640 641 // 642 // Initialize the pulser colours 643 // 644 chargecam ->SetPulserColor( fPulserColor ); 645 blindcam ->SetPulserColor( fPulserColor ); 646 fHCam ->SetColor ( fPulserColor ); 647 fHBlindCam->SetColor ( fPulserColor ); 648 592 593 *fLog << inf << " with strength: " << fHeader->GetPulserStrength() << endl; 594 649 595 if (fPINDiode) 650 596 fPINDiode->SetColor( fPulserColor ); 651 597 598 fNumProcessed = 0; 599 652 600 return kTRUE; 653 601 } … … 655 603 // ----------------------------------------------------------------------- 656 604 // 657 // Analogue to the MTask::CallPostProcess, but without the manipulation 658 // of the bit fIsPreProcessed. Needed in order to call PostProcess multiple 659 // times in the intensity calibration. 660 // 661 Int_t MCalibrationChargeCalc::CallPostProcess() 605 // Return if number of executions is null. 606 // 607 Int_t MCalibrationChargeCalc::PostProcess() 662 608 { 663 609 664 // if (!fIsPreprocessed) 665 // return kTRUE; 666 667 *fLog << all << fName << "... " << flush; 668 if (fDisplay) 669 fDisplay->SetStatusLine2(*this); 670 671 return PostProcess(); 610 if (GetNumExecutions()==0) 611 return kFALSE; 612 613 if (fPulserColor == MCalibrationCam::kNONE) 614 return kTRUE; 615 616 if (fNumProcessed == 0) 617 return kTRUE; 618 619 *fLog << endl; 620 621 return Finalize(); 672 622 } 673 623 674 624 // ----------------------------------------------------------------------- 675 625 // 676 // Return if number of executions is null.677 // 678 // First loop over pixels, average areas and sectors, call: 626 // Return kTRUE if fPulserColor is kNONE 627 // 628 // First loop over pixels, average areas and sectors, call: 679 629 // - FinalizePedestals() 680 630 // - FinalizeCharges() … … 700 650 // Print out some statistics 701 651 // 702 Int_t MCalibrationChargeCalc:: PostProcess()652 Int_t MCalibrationChargeCalc::Finalize() 703 653 { 704 if (GetNumExecutions()==0) 705 return kFALSE; 706 654 655 fNumHiGainSamples = fSignal->GetNumUsedHiGainFADCSlices(); 656 fNumLoGainSamples = fSignal->GetNumUsedLoGainFADCSlices(); 657 658 fSqrtHiGainSamples = TMath::Sqrt(fNumHiGainSamples); 659 fSqrtLoGainSamples = TMath::Sqrt(fNumLoGainSamples); 660 707 661 if (fPINDiode) 708 662 if (!fPINDiode->IsValid()) 709 663 { 710 *fLog << warn << "MCalibrationChargePINDiode is declared not valid... no PIN Diode method! " << endl; 664 *fLog << warn << GetDescriptor() 665 << ": MCalibrationChargePINDiode is declared not valid... no PIN Diode method! " << endl; 711 666 fPINDiode = NULL; 712 667 } … … 753 708 if (nvalid == 0) 754 709 { 755 *fLog << err << "All pixels have non-valid calibration. "710 *fLog << err << GetDescriptor() << ": All pixels have non-valid calibration. " 756 711 << "Did you forget to fill the histograms " 757 712 << "(filling MHCalibrationChargeCam from MExtractedSignalCam using MFillH) ? " << endl; 758 *fLog << err << "Or, maybe, you have used a pedestal run "713 *fLog << err << GetDescriptor() << ": Or, maybe, you have used a pedestal run " 759 714 << "instead of a calibration run " << endl; 760 715 return kFALSE; … … 770 725 FinalizeCharges(pix, 771 726 fIntensCam ? fIntensCam->GetAverageBadArea(aidx) : fCam->GetAverageBadArea(aidx), 772 "area id x");727 "area id"); 773 728 } 774 729 … … 922 877 prms * fSqrtLoGainSamples, 923 878 prmserr * fSqrtLoGainSamples); 924 cal.CalcLoGainPedestal( (Float_t)fNumLoGainSamples);879 cal.CalcLoGainPedestal(fNumLoGainSamples); 925 880 } 926 881 else … … 1006 961 } 1007 962 963 if (cal.GetPheFFactorMethod() < 0.) 964 { 965 bad.SetUncalibrated(MBadPixelsPix::kDeviatingNumPhes); 966 bad.SetUnsuitable(MBadPixelsPix::kUnsuitableRun); 967 cal.SetFFactorMethodValid(kFALSE); 968 return kFALSE; 969 } 970 1008 971 if (!cal.CalcConvFFactor()) 1009 972 { … … 1246 1209 } 1247 1210 1211 if (mean < 0.) 1212 { 1213 *fLog << inf << GetDescriptor() << ": Fitted mean number of photo-electrons " 1214 << "with area idx " << i << ": " << mean << " is smaller than 0. " << endl; 1215 *fLog << warn << GetDescriptor() << ": Will use the simple mean and rms " << endl; 1216 delete hist; 1217 continue; 1218 } 1219 1248 1220 *fLog << inf << GetDescriptor() << ": Mean number of photo-electrons " 1249 1221 << "with area idx " << i << ": " … … 1350 1322 *fLog << inf << GetDescriptor() 1351 1323 << ": Average total number phes in area idx " << aidx << ": " 1352 << Form("%7.2f %s%6.2f",areaphes[aidx]," +- ",TMath::Sqrt(areaweights[aidx])) << endl;1324 << Form("%7.2f +- 6.2f",areaphes[aidx],TMath::Sqrt(areaweights[aidx])) << endl; 1353 1325 1354 1326 apix.SetPheFFactorMethod ( areaphes[aidx] ); -
trunk/MagicSoft/Mars/mcalib/MCalibrationChargeCalc.h
r5552 r5679 74 74 75 75 MCalibrationCam::PulserColor_t fPulserColor; // Calibration LEDs colour 76 UInt_t fPulserPattern; // Calibration LEDs Pulser Pattern77 76 78 77 Int_t fNumInnerFFactorMethodUsed; // Number of inner pixels used for F-Factor Method calibration … … 86 85 TString fOutputFile; // Name of the output file 87 86 TString fNamePedestalCam; // Name of the 'MPedestalCam' container 87 88 Int_t fNumProcessed; // Number of processed events (for Intensity calibration) 88 89 89 90 // Pointers … … 169 170 MCalibrationChargeCalc(const char *name=NULL, const char *title=NULL); 170 171 171 Int_t CallPostProcess();172 173 172 void Clear(const Option_t *o=""); 173 174 Int_t Finalize(); 174 175 175 176 Bool_t IsDebug() const { return TESTBIT(fFlags,kDebug); } … … 195 196 b ? SETBIT(fCheckFlags,kCheckOscillations) 196 197 : CLRBIT(fCheckFlags,kCheckOscillations); } 197 198 void SetDebug ( const Bool_t b=kTRUE ) { b ? SETBIT(fFlags, kDebug) : CLRBIT(fFlags, kDebug); } 198 void SetDebug ( const Bool_t b=kTRUE ) { 199 b ? SETBIT(fFlags, kDebug) 200 : CLRBIT(fFlags, kDebug); } 199 201 200 202 void SetPedestals(MPedestalCam *cam) { fPedestals=cam; } -
trunk/MagicSoft/Mars/mcalib/MCalibrationRelTimeCalc.cc
r5413 r5679 187 187 MBadPixelsPix &bad = (*badcam)[i]; 188 188 189 pix.SetPixId(i);190 191 189 if (bad.IsBad()) 192 190 { … … 204 202 // ----------------------------------------------------------------------- 205 203 // 206 // Analogue to the MTask::CallPostProcess, but without the manipulation 207 // of the bit fIsPreProcessed. Needed in order to call PostProcess multiple 208 // times in the intensity calibration. 209 // 210 Int_t MCalibrationRelTimeCalc::CallPostProcess() 211 { 212 213 // if (!fIsPreprocessed) 214 // return kTRUE; 215 216 *fLog << all << fName << "... " << flush; 217 if (fDisplay) 218 fDisplay->SetStatusLine2(*this); 219 220 return PostProcess(); 221 } 222 204 // Return if number of executions is null. 205 // 206 Int_t MCalibrationRelTimeCalc::PostProcess() 207 { 208 209 if (GetNumExecutions()==0) 210 return kFALSE; 211 212 return Finalize(); 213 } 223 214 224 215 // ----------------------------------------------------------------------- 225 //226 // Return if number of executions is null.227 216 // 228 217 // First loop over pixels, average areas and sectors, call: … … 237 226 // Print out some statistics 238 227 // 239 Int_t MCalibrationRelTimeCalc::PostProcess() 240 { 241 242 if (GetNumExecutions()==0) 243 return kFALSE; 244 228 Int_t MCalibrationRelTimeCalc::Finalize() 229 { 230 245 231 // 246 232 // First loop over pixels, call FinalizePedestals and FinalizeRelTimes -
trunk/MagicSoft/Mars/mcalib/MCalibrationRelTimeCalc.h
r5133 r5679 64 64 MCalibrationRelTimeCalc(const char *name=NULL, const char *title=NULL); 65 65 66 Int_t CallPostProcess();66 void Clear(const Option_t *o=""); 67 67 68 void Clear(const Option_t *o="");68 Int_t Finalize(); 69 69 70 70 Bool_t IsDebug() const { return TESTBIT(fFlags,kDebug); }
Note:
See TracChangeset
for help on using the changeset viewer.