Changeset 8741 for trunk/MagicSoft/Mars/mpedestal
- Timestamp:
- 09/05/07 20:36:37 (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/mpedestal/MExtractPedestal.cc
r8633 r8741 1 1 /* ======================================================================== *\ 2 ! $Name: not supported by cvs2svn $:$Id: MExtractPedestal.cc,v 1.3 4 2007-07-14 00:02:24tbretz Exp $2 ! $Name: not supported by cvs2svn $:$Id: MExtractPedestal.cc,v 1.35 2007-09-05 19:36:36 tbretz Exp $ 3 3 ! -------------------------------------------------------------------------- 4 4 ! … … 350 350 const UInt_t num = fRunHeader->GetNumSamplesHiGain()+fRunHeader->GetNumSamplesLoGain(); 351 351 352 // Check upper bound for check window 352 353 if (fCheckWinLast >= num) 353 354 { 354 *fLog << "CheckWindow [" << fCheckWinFirst << "," << fCheckWinLast;355 *fLog << inf << "CheckWindow [" << fCheckWinFirst << "," << fCheckWinLast; 355 356 *fLog << "] out of range [0," << num-1 << "]... "; 356 357 *fLog << "reset upper edge." << endl; … … 359 360 } 360 361 361 if (offset+fExtractWinLast >= num) 362 { 363 *fLog << "ExtractWindow [" << fExtractWinFirst+offset << "," << fExtractWinLast+offset; 362 // Now check lower bound for check window 363 if (fCheckWinFirst>fCheckWinLast) 364 { 365 *fLog << err << "CheckWindow first slice " << fCheckWinFirst; 366 *fLog << " greater than last slice " << fCheckWinLast; 367 *fLog << "... reset to 0." << endl; 368 369 fCheckWinFirst = 0; 370 } 371 372 // check upper bound for extaction window 373 if (fExtractWinLast+offset >= num) 374 { 375 *fLog << inf << "ExtractWindow [" << fExtractWinFirst+offset << "," << fExtractWinLast+offset; 364 376 *fLog << "] out of range [0," << num-1 << "]... "; 365 377 *fLog << "reset upper edge." << endl; … … 368 380 } 369 381 382 // Now check lower bound for check window 383 if (fExtractWinFirst>fExtractWinLast) 384 { 385 *fLog << err << "ExtractionWindow first slice " << fExtractWinFirst+offset; 386 *fLog << " greater than last slice " << fExtractWinLast+offset; 387 *fLog << "... reset to 0." << endl; 388 389 fExtractWinFirst = 0; 390 } 391 392 // Calculate window size for extraction window 370 393 fExtractWinSize = fExtractWinLast-fExtractWinFirst+1; 371 394 395 // Check if use tries to do a fundamental pedestal extraction 396 // with an odd number of slices 372 397 if (fExtractor || TMath::Even(fExtractWinSize)) 373 398 return; 374 399 400 // Make sure the number of extracted slices is even 375 401 fExtractWinLast += offset+fExtractWinLast==num-1 ? -1 : +1; 376 402 377 *fLog << "ExtractionWindow odd... set to [";403 *fLog << inf << "ExtractionWindow odd... set to ["; 378 404 *fLog << fExtractWinFirst+offset << "," << fExtractWinLast+offset << "]" << endl; 379 405
Note:
See TracChangeset
for help on using the changeset viewer.