Changeset 4648 for trunk/MagicSoft/Mars/mpedestal
- Timestamp:
- 08/17/04 13:31:40 (20 years ago)
- Location:
- trunk/MagicSoft/Mars/mpedestal
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/mpedestal/MPedCalcFromLoGain.cc
r4609 r4648 357 357 return kFALSE; 358 358 359 if (fNumEventsDump<=0 && fPedestalUpdate) 360 { 361 *fLog << warn << "Pedestal Update switched on and Number of Events to dump <= 0... fNumEventsDump=1000" << endl; 362 fNumEventsDump=1000; 363 } 364 359 365 return kTRUE; 360 366 } … … 518 524 // Calculate the amplitude of the 150MHz "AB" noise 519 525 520 Int_t abFlag = (fRunHeader->GetNumSamplesHiGain() 521 + fLoGainFirst 522 + pixel.HasABFlag()) & 0x1; 523 for (Int_t islice=0; islice<fWindowSizeLoGain; islice+=2) 526 if (pixel.IsABFlagValid()) 524 527 { 525 Int_t sliceAB0 = islice + abFlag; 526 Int_t sliceAB1 = islice - abFlag + 1; 527 fSumAB0[idx] += firstSlice[sliceAB0]; 528 fSumAB1[idx] += firstSlice[sliceAB1]; 528 const Int_t abFlag = (fRunHeader->GetNumSamplesHiGain() 529 + fLoGainFirst + pixel.HasABFlag()) & 0x1; 530 for (Int_t islice=0; islice<fWindowSizeLoGain; islice+=2) 531 { 532 const Int_t sliceAB0 = islice + abFlag; 533 const Int_t sliceAB1 = islice - abFlag + 1; 534 fSumAB0[idx] += firstSlice[sliceAB0]; 535 fSumAB1[idx] += firstSlice[sliceAB1]; 536 } 529 537 } 530 538 … … 543 551 if (fPedestalUpdate) 544 552 { 545 fPedestals->ReCalc(*fGeom);553 //fPedestals->ReCalc(*fGeom); 546 554 fPedestals->SetReadyToSave(); 547 555 } … … 606 614 if (IsEnvDefined(env, prefix, "NumEventsDump", print)) 607 615 { 608 Set DumpEvents(GetEnvValue(env, prefix, "NumEventsDump", fNumEventsDump));616 SetNumEventsDump(GetEnvValue(env, prefix, "NumEventsDump", fNumEventsDump)); 609 617 rc = kTRUE; 610 618 } -
trunk/MagicSoft/Mars/mpedestal/MPedCalcFromLoGain.h
r4609 r4648 65 65 void SetWindowSize(Byte_t windowh=fgHiGainWindowSize, Byte_t windowl=fgLoGainWindowSize); 66 66 void SetMaxHiGainVar(Byte_t maxvar=fgMaxHiGainVar); 67 void Set DumpEvents(UInt_t dumpevents = 0) {fNumEventsDump = dumpevents;}67 void SetNumEventsDump(UInt_t dumpevents = 0) { fNumEventsDump = dumpevents; } 68 68 void SetPedestalUpdate(Bool_t pedupdate) {fPedestalUpdate = pedupdate;} 69 69
Note:
See TracChangeset
for help on using the changeset viewer.