HOPS
HOPS class reference
MHO_DelayRate.hh
Go to the documentation of this file.
1 #ifndef MHO_DelayRate_HH__
2 #define MHO_DelayRate_HH__
3 
4 #include <cmath>
5 #include <complex>
6 
8 #include "MHO_TableContainer.hh"
9 
10 #include "MHO_BinaryOperator.hh"
11 #include "MHO_CyclicRotator.hh"
12 #include "MHO_EndZeroPadder.hh"
14 #include "MHO_SubSample.hh"
15 
16 #ifdef HOPS_USE_FFTW3
18 #endif
19 
20 namespace hops
21 {
22 
34 class MHO_DelayRate: public MHO_BinaryOperator< visibility_type, weight_type, sbd_type >
35 {
36  public:
37  MHO_DelayRate();
38  virtual ~MHO_DelayRate();
39 
45  void SetReferenceFrequency(double ref_freq) { fRefFreq = ref_freq; };
46 
52  int GetDelayRateSearchSpaceSize() const { return fDRSPSize; }
53 
60  unsigned int CalculateSearchSpaceSize(unsigned int input_size);
61 
62  protected:
66 
76  virtual bool InitializeImpl(const XArgType1* in1, const XArgType2* in2, XArgType3* out) override;
86  virtual bool ExecuteImpl(const XArgType1* in1, const XArgType2* in2, XArgType3* out) override;
87 
88  private:
89  std::size_t fInDims[VIS_NDIM];
90  std::size_t fOutDims[VIS_NDIM];
91 
98  void ApplyDataWeights(const XArgType2* in2, XArgType3* out);
106  void ConditionallyResizeOutput(const std::size_t* dims, std::size_t size, XArgType3* out);
107 
114  void ApplyInterpolation(const XArgType1* in1, XArgType3* out);
115 
116 #ifdef HOPS_USE_FFTW3
118 #else
120 #endif
121 
122  MHO_SubSample< sbd_type > fSubSampler;
123  MHO_CyclicRotator< sbd_type > fCyclicRotator;
124 
126  FFT_ENGINE_TYPE fFFTEngine;
127 
128  int fDRSPSize;
129  double fRefFreq;
130 
131  bool fInitialized;
132 };
133 
134 } // namespace hops
135 
136 #endif
#define VIS_NDIM
Definition: MHO_BaselineContainers.hh:43
Class MHO_BinaryOperator.
Definition: MHO_BinaryOperator.hh:24
Class MHO_CyclicRotator.
Definition: MHO_CyclicRotator.hh:29
Class MHO_DelayRate.
Definition: MHO_DelayRate.hh:35
void SetReferenceFrequency(double ref_freq)
Setter for reference frequency.
Definition: MHO_DelayRate.hh:45
virtual ~MHO_DelayRate()
Definition: MHO_DelayRate.cc:16
MHO_DelayRate()
Definition: MHO_DelayRate.cc:11
virtual bool ExecuteImpl(const XArgType1 *in1, const XArgType2 *in2, XArgType3 *out) override
Executes MHO_DelayRate operations: zero padding, FFT, cyclic rotation, and interpolation.
Definition: MHO_DelayRate.cc:79
virtual bool InitializeImpl(const XArgType1 *in1, const XArgType2 *in2, XArgType3 *out) override
Initializes MHO_DelayRate with input data and prepares for delay rate calculation.
Definition: MHO_DelayRate.cc:18
unsigned int CalculateSearchSpaceSize(unsigned int input_size)
Calculates the search space size based on input size.
Definition: MHO_DelayRate.cc:172
int GetDelayRateSearchSpaceSize() const
Getter for delay rate search space size.
Definition: MHO_DelayRate.hh:52
Class MHO_EndZeroPadder.
Definition: MHO_EndZeroPadder.hh:29
Class MHO_MultidimensionalFastFourierTransformFFTW.
Definition: MHO_MultidimensionalFastFourierTransformFFTW.hh:37
Class MHO_SubSample.
Definition: MHO_SubSample.hh:30
Definition: MHO_ChannelLabeler.hh:17
visibility_type sbd_type
Definition: MHO_BaselineContainers.hh:54
MHO_TableContainer< weight_element_type, baseline_axis_pack > weight_type
Definition: MHO_BaselineContainers.hh:53
MHO_TableContainer< visibility_element_type, baseline_axis_pack > visibility_type
Definition: MHO_BaselineContainers.hh:52