HighEnergyRemover.h
Go to the documentation of this file.
1 ////////////////////////////////////////////////////////////////////////
2 // \file: HighEnergyRemover.h
3 // \brief Remove hits associated with high-energy activity.
4 // \author Justin Vasel <justin.vasel@gmail.com>
5 // \date 2020-08-09
6 ////////////////////////////////////////////////////////////////////////
7 
8 #ifndef HIGHENERGYREMOVER_H
9 #define HIGHENERGYREMOVER_H
10 
11 // STL includes
12 #include <cstdint>
13 
14 // ROOT includes
15 #include "TH1.h"
16 
17 // ART includes
21 
22 // NOvASoft includes
23 #include "RecoBase/CellHit.h"
25 
26 
27 namespace sn {
29  public:
30  HighEnergyRemover(sn::HitVetoMap& vetoMapHit);
32 
33  int NumRemoved() {return fNumRemoved;};
34  int32_t TotalVetoedTDC();
35  int32_t TotalTDC();
36  std::pair<int, int> RegionAroundPeak(TH1F* h, int peakBin, double baseline, float padding);
38  int NPeaks();
39  int TotalTDCVetoed();
40 
41  void SetPeakThreshold(float val) {this->fPeakThreshold = val;};
43 
44  void remove(std::vector<art::Ptr<rb::CellHit>>& hits);
45 
46  private:
49  int32_t fTotalTDC;
50  std::vector<std::pair<int32_t, int32_t>> fTDCVetoWindows;
51 
54  };
55 }
56 
57 #endif
std::vector< std::pair< int32_t, int32_t > > fTDCVetoWindows
HighEnergyRemover(sn::HitVetoMap &vetoMapHit)
void SetVetoWindowPadding(float val)
double baseline
void SetPeakThreshold(float val)
void hits()
Definition: readHits.C:15
std::pair< int, int > RegionAroundPeak(TH1F *h, int peakBin, double baseline, float padding)
Remove hits from hot and cold channels.
A rawdata::RawDigit with channel information decoded.
Definition: CellHit.h:27
sn::HitVetoMap * fHitVetoMap
bool HitInTDCVetoWindow(rb::CellHit h)