Newer
Older
TB_Chris / TbUT / src / .svn / text-base / TbUTCMSIterativelyPerBeetle.h.svn-base
@iaro iaro on 9 May 2016 942 bytes first attempt of automated anal
  1. #pragma once
  2.  
  3. #include "TbUTICommonModeSubtractor.h"
  4. #include "TbUTIChannelMaskProvider.h"
  5.  
  6. #include <map>
  7.  
  8. namespace TbUT
  9. {
  10. class CMSIterativelyPerBeetle : public ICommonModeSubtractor
  11. {
  12. public:
  13. CMSIterativelyPerBeetle(IChannelMaskProvider& p_masksProvider);
  14. void processEvent(RawData<>* p_data, RawData<double> **p_output);
  15.  
  16. private:
  17. template<typename DATA_TYPE>
  18. void calculateCorrection(RawData<DATA_TYPE>* p_inputData);
  19. template<typename INPUT_DATA_TYPE, typename OUTPUT_TYPE_NAME>
  20. void removeCM(RawData<INPUT_DATA_TYPE>* p_data, RawData<OUTPUT_TYPE_NAME> **p_output);
  21. void resetHitThresholds();
  22.  
  23. void initializeCorrectionAndHitMaps();
  24.  
  25. IChannelMaskProvider& m_masksProvider;
  26. const int m_channelNumber;
  27. const int m_channelPerBeetle;
  28. std::map<int, double> m_correctionPerBeetle;
  29. std::map<int, double> m_hitThresholdPerBeetle;
  30. };
  31. }
  32.  
  33.  
  34.