Changeset 5507 for trunk/MagicSoft
- Timestamp:
- 11/29/04 20:58:20 (20 years ago)
- Location:
- trunk/MagicSoft/Mars/mpedestal
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/mpedestal/MExtractPedestal.cc
r5504 r5507 151 151 #include "MExtractPedestal.h" 152 152 #include "MExtractTimeAndCharge.h" 153 #include "MExtractTimeAndChargeDigitalFilter.h" 153 154 154 155 #include "MParList.h" … … 420 421 421 422 if (fExtractor) 422 fExtractor->InitArrays(); 423 423 { 424 fExtractor->InitArrays(); 425 SetExtractWindow(fExtractor->GetHiGainFirst(),(Int_t)fExtractor->GetNumHiGainSamples()); 426 if (fExtractor->InheritsFrom("MExtractTimeAndChargeDigitalFilter")) 427 { 428 MExtractTimeAndChargeDigitalFilter* df = (MExtractTimeAndChargeDigitalFilter*)fExtractor; 429 if (!df->IsWeightsSet()) 430 if (!df->ReadWeightsFile(df->GetNameWeightsFile())) 431 return kFALSE; 432 } 433 } 434 424 435 Print(); 425 436 … … 510 521 511 522 // 4. Scale the mean, variance and AB-noise to the number of slices: 512 ped /= fExtract WinSize;513 var /= fExtract WinSize;514 abOffs /= fExtract WinSize;523 ped /= fExtractor ? fExtractor->GetNumHiGainSamples() : fExtractWinSize; 524 var /= fExtractor ? fExtractor->GetNumHiGainSamples() : fExtractWinSize; 525 abOffs /= fExtractor ? fExtractor->GetNumHiGainSamples() : fExtractWinSize; 515 526 516 527 // 5. Calculate the RMS from the Variance: … … 549 560 // 4. Scale the mean, variance and AB-noise to the number of slices: 550 561 // 551 ped /= fExtract WinSize;552 var /= fExtract WinSize;553 abOffs /= fExtract WinSize;562 ped /= fExtractor ? fExtractor->GetNumHiGainSamples() : fExtractWinSize; 563 var /= fExtractor ? fExtractor->GetNumHiGainSamples() : fExtractWinSize; 564 abOffs /= fExtractor ? fExtractor->GetNumHiGainSamples() : fExtractWinSize; 554 565 // 555 566 // 5. Scale the mean, variance and AB-noise to the number of pixels: … … 596 607 // 4. Scale the mean, variance and AB-noise to the number of slices: 597 608 // 598 ped /= fExtract WinSize;599 var /= fExtract WinSize;600 abOffs /= fExtract WinSize;609 ped /= fExtractor ? fExtractor->GetNumHiGainSamples() : fExtractWinSize; 610 var /= fExtractor ? fExtractor->GetNumHiGainSamples() : fExtractWinSize; 611 abOffs /= fExtractor ? fExtractor->GetNumHiGainSamples() : fExtractWinSize; 601 612 // 602 613 // 5. Scale the mean, variance and AB-noise to the number of pixels: -
trunk/MagicSoft/Mars/mpedestal/MPedCalcFromLoGain.cc
r5505 r5507 137 137 138 138 #include "MExtractTimeAndCharge.h" 139 #include "MExtractTimeAndChargeDigitalFilter.h"140 139 141 140 #include "MParList.h" … … 243 242 244 243 if (fExtractor) 245 { 246 SetExtractWindow(fExtractor->GetHiGainFirst(),(Int_t)fExtractor->GetNumHiGainSamples()); 247 lastavailable = losamples-1; 248 if (fExtractor->InheritsFrom("MExtractTimeAndChargeDigitalFilter")) 249 { 250 MExtractTimeAndChargeDigitalFilter* df = (MExtractTimeAndChargeDigitalFilter*)fExtractor; 251 if (!df->IsWeightsSet()) 252 if (!df->ReadWeightsFile(df->GetNameWeightsFile())) 253 return kFALSE; 254 } 255 } 244 lastavailable = losamples-1; 256 245 257 246 // If the size is not yet set, set the size -
trunk/MagicSoft/Mars/mpedestal/MPedCalcPedRun.cc
r5505 r5507 122 122 123 123 #include "MExtractTimeAndCharge.h" 124 #include "MExtractTimeAndChargeDigitalFilter.h"125 124 126 125 #include "MParList.h" … … 204 203 { 205 204 206 if (fExtractor)207 {208 SetExtractWindow(fExtractor->GetHiGainFirst(),(Int_t)fExtractor->GetNumHiGainSamples());209 if (fExtractor->InheritsFrom("MExtractTimeAndChargeDigitalFilter"))210 {211 MExtractTimeAndChargeDigitalFilter* df = (MExtractTimeAndChargeDigitalFilter*)fExtractor;212 if (!df->IsWeightsSet())213 if (!df->ReadWeightsFile(df->GetNameWeightsFile()))214 return kFALSE;215 }216 }217 218 205 MExtractPedestal::ReInit(pList); 219 206 … … 470 457 { 471 458 459 if (fRunHeader->GetRunNumber() == 38996) 460 return kTRUE; 461 472 462 if (fRunHeader->GetRunNumber() < gkFirstRunWithFinalBits) 473 463 return kFALSE;
Note:
See TracChangeset
for help on using the changeset viewer.