24 #ifndef SKA_CHEETAH_RFIM_AMPP_RFIM_H 25 #define SKA_CHEETAH_RFIM_AMPP_RFIM_H 27 #include "cheetah/rfim/ampp/Config.h" 28 #include "cheetah/rfim/ampp/Spectrum.h" 29 #include "cheetah/rfim/PolicyInfo.h" 30 #include "cheetah/rfim/policy/Policy.h" 31 #include "cheetah/utils/Architectures.h" 32 #include "cheetah/data/TimeFrequency.h" 33 #include <boost/circular_buffer.hpp> 129 template<
typename RfimTraits>
132 typedef typename RfimTraits::NumericalRep NumericalRep;
133 typedef typename RfimTraits::Policy Policy;
134 typedef typename PolicyInfo<Policy>::AdapterType DataAdapter;
135 static_assert(!std::is_const<DataAdapter>::value,
"DataAdapter cannot be const");
139 typedef cheetah::Cpu Architecture;
142 Rfim(
Config const& config,
typename RfimTraits::BandPassHandler
const&);
168 unsigned _bad_spectra;
169 boost::circular_buffer<float> _mean_buffer, _rms_buffer;
170 float _replacement_sample_mean, _replacement_sample_rms;
171 float _rms_run_ave, _mean_run_ave;
172 float _mean_over_rms;
173 float _fraction_bad_channels;
174 unsigned _sample_counter;
175 unsigned _max_history;
177 int _use_mean_over_rms;
178 std::shared_ptr<Spectrum<NumericalRep>> _bandpass_data_ptr;
179 double _bandpass_rms;
181 std::vector<NumericalRep> _replacement_sample;
183 typename RfimTraits::BandPassHandler _bandpass_handler;
191 #include "detail/Rfim.cpp" 193 #endif // SKA_CHEETAH_RFIM_AMPP_RFIM_H std::conditional< std::is_same< void, AdapterDataReturnType >::value, DataArgumentType, AdapterDataReturnType >::type ReturnType
the data type the policy will return
Some limits and constants for FLDO.
ReturnType operator()(panda::PoolResource< Cpu > &thread, std::shared_ptr< data::TimeFrequency< Cpu, NumericalRep >> data)
task interface warpper around run
ReturnType run(data::TimeFrequency< Cpu, NumericalRep > &data)
perform rfi clipping on the data
Configuration Options for the ampp rfi clipping algorithm.
AMPP alogrithm CPU based on a dynamic bandfilter.
void set_max_history(unsigned length)
set the maximum history