PandaRoot
BSEmcFwEndcapBlindDeconvProcess.h
Go to the documentation of this file.
1 //****************************************************************************
2 //* This file is part of PandaRoot. *
3 //* *
4 //* PandaRoot is distributed under the terms of the *
5 //* GNU General Public License (GPL) version 3, *
6 //* copied verbatim in the file "LICENSE". *
7 //* *
8 //* Copyright (C) 2006 - 2024 FAIR GmbH and copyright holders of PandaRoot *
9 //* The copyright holders are listed in the file "COPYRIGHTHOLDERS". *
10 //* The authors are listed in the file "AUTHORS". *
11 //****************************************************************************
12 
13 #ifndef BSEMCFWENDCAPBLINDDECOFEATUREEXTRACTIONPROCESS_HH
14 #define BSEMCFWENDCAPBLINDDECOFEATUREEXTRACTIONPROCESS_HH
15 
16 #include <algorithm>
17 #include <memory>
18 #include <string>
19 #include <vector>
20 
21 #include "Rtypes.h"
22 #include "RtypesCore.h"
23 #include "TString.h"
24 
25 #include "PndConstContainer.h"
26 #include "PndMutableContainerI.h"
27 #include "PndProcess.h"
28 
29 #include "BSEmcDigi.h"
30 #include "BSEmcMultiWaveform.h"
31 
34 #include "BSEmcPSAFPGAPeakfinder.h"
37 
39 class BSEmcAbsPSA;
40 class BSEmcWaveform;
41 class TBuffer;
42 class TClass;
43 class TMemberInspector;
44 template <class T>
46 
55  public:
58 
59  virtual void SetDetectorName(const std::string &t_detectorName) /*override*/;
60  virtual void RequestDataContainer(PndContainerRegister *t_register) /*override*/;
61  virtual void GetDataContainer(PndContainerRegister *t_register) /*override*/;
62  virtual void SetupParameters(const PndParameterRegister *t_parameterRegister) /*override*/;
63  virtual void Process() /*override*/;
64 
65  std::vector<BSEmcPSAFPGAPeakFeatures_t> ExtractFeatures(const std::vector<Double_t> &t_samples, const Int_t t_detId) const;
66  std::vector<BSEmcDigi *> ExtractDigis(const std::vector<const BSEmcMultiWaveform *> &t_waveforms) const;
67  void SetMCDepositBranchName(const TString &t_branchname) { fMCDepositBranchName = t_branchname; }
68  void SetDigiBranchName(const TString &t_branchname) { fDigiBranchName = t_branchname; }
69  void SetWaveformBranchName(const TString &t_branchname) { fWaveformBranchName = t_branchname; }
70 
71  Bool_t IsVptt(const Int_t t_detId) const;
72  void SetVpttIds(const std::vector<Int_t> &t_vpttIds)
73  {
74  fVpttIds = t_vpttIds;
75  std::sort(fVpttIds.begin(), fVpttIds.end());
76  }
77 
78  protected:
79  TString fMCDepositBranchName{""};
80  TString fDigiBranchName{""};
81  TString fWaveformBranchName{""};
82 
85 
86  Double_t fEnergyDigiThreshold{0};
87 
93 
99 
100  std::vector<Int_t> fVpttIds{};
101 
103 };
104 
105 #endif /*BSEMCFWENDCAPBLINDDECOFEATUREEXTRACTIONPROCESS_HH*/
Base Process class.
Definition: PndProcess.h:36
virtual void SetupParameters(const PndParameterRegister *t_parameterRegister)
Fetch all parameters from the PndParameterRegister.
BSEmcPSAFPGAPileUpDetection fPileUpDetectorAPD
Baseclass for pulseshapeanalysis ( featureextraction )
Definition: BSEmcAbsPSA.h:38
represents a simulated waveform in an emc crystal
Definition: BSEmcWaveform.h:75
PndMutableContainerI< BSEmcDigi > * fDigiArray
BSEmcPSAFPGAPileUpDetection fPileUpDetectorVPTT
Blind deconvolution feature extraction approach for the FwEndcap.
std::vector< BSEmcDigi * > ExtractDigis(const std::vector< const BSEmcMultiWaveform *> &t_waveforms) const
PndContainerI< BSEmcMultiWaveform > * fWaveformArray
void SetWaveformBranchName(const TString &t_branchname)
virtual void SetDetectorName(const std::string &t_detectorName)
Set the Detector name. Important, as most EmcParameter need to know for which detector they need to b...
void SetVpttIds(const std::vector< Int_t > &t_vpttIds)
ClassDef(BSEmcFwEndcapBlindDeconvProcess, 1)
void SetDigiBranchName(const TString &t_branchname)
Deconvolution of waveforms based on a chosen target function (gaussian)
Bool_t IsVptt(const Int_t t_detId) const
virtual void Process()
The actual data transformation (digitizing, clustering, etc.) should be defined here.
void SetMCDepositBranchName(const TString &t_branchname)
Container to wrap PndTCA/STDConstContainer (not needed anymore)
Helper class to indirect the Parameter fetching via the FairRuntimeDb.
virtual void RequestDataContainer(PndContainerRegister *t_register)
Pass the container register to the process, and get the processes container requirements.
std::vector< BSEmcPSAFPGAPeakFeatures_t > ExtractFeatures(const std::vector< Double_t > &t_samples, const Int_t t_detId) const
virtual void GetDataContainer(PndContainerRegister *t_register)
Pass the container register to the process, and set the processes container requirements.