From 05fb448bf48e31d723dfd9f4bbf3899ff65f0fba Mon Sep 17 00:00:00 2001 From: giuros01 Date: Tue, 26 Mar 2019 17:44:40 +0000 Subject: COMPMID-1963: Implement FFT (2D) on NEON Change-Id: I3b564be8d7949e00c6544071ef62dd51de838c96 Signed-off-by: giuros01 Reviewed-on: https://review.mlplatform.org/c/1048 Comments-Addressed: Arm Jenkins Tested-by: Arm Jenkins Reviewed-by: Georgios Pinitas --- arm_compute/runtime/NEON/functions/NEFFT1D.h | 19 ++++++++++++------- 1 file changed, 12 insertions(+), 7 deletions(-) (limited to 'arm_compute/runtime/NEON/functions/NEFFT1D.h') diff --git a/arm_compute/runtime/NEON/functions/NEFFT1D.h b/arm_compute/runtime/NEON/functions/NEFFT1D.h index 9b5ada746a..c706936f77 100644 --- a/arm_compute/runtime/NEON/functions/NEFFT1D.h +++ b/arm_compute/runtime/NEON/functions/NEFFT1D.h @@ -26,6 +26,7 @@ #include "arm_compute/core/NEON/kernels/NEFFTDigitReverseKernel.h" #include "arm_compute/core/NEON/kernels/NEFFTRadixStageKernel.h" +#include "arm_compute/core/NEON/kernels/NEFFTScaleKernel.h" #include "arm_compute/runtime/IFunction.h" #include "arm_compute/runtime/FunctionDescriptors.h" @@ -37,24 +38,25 @@ namespace arm_compute // Forward declaration class ITensor; -/** Basic function to execute one dimensional FFT. This function calls the following OpenCL kernels: +/** Basic function to execute one dimensional FFT. This function calls the following NEON kernels: * - * -# @ref CLFFTDigitReverseKernel Performs digit reverse + * -# @ref NEFFTDigitReverseKernel Performs digit reverse * -# @ref NEFFTRadixStageKernel A list of FFT kernels depending on the radix decomposition + * -# @ref NEFFTScaleKernel Performs output scaling in case of in inverse FFT */ class NEFFT1D : public IFunction { public: /** Default Constructor */ NEFFT1D(std::shared_ptr memory_manager = nullptr); - /** Initialise the function's source, destinations and border mode. + /** Initialise the function's source and destinations. * * @param[in] input Source tensor. Data types supported: F32. * @param[out] output Destination tensor. Data types and data layouts supported: Same as @p input. * @param[in] config FFT related configuration */ void configure(const ITensor *input, ITensor *output, const FFT1DInfo &config); - /** Static function to check if given info will lead to a valid configuration of @ref CLFFT1D. + /** Static function to check if given info will lead to a valid configuration of @ref NEFFT1D. * * @param[in] input Source tensor info. Data types supported: F32. * @param[in] output Destination tensor info. Data types and data layouts supported: Same as @p input. @@ -69,11 +71,14 @@ public: protected: MemoryGroup _memory_group; - Tensor _digit_reversed_input; - Tensor _digit_reverse_indices; NEFFTDigitReverseKernel _digit_reverse_kernel; std::vector _fft_kernels; - unsigned int _n_ffts; + NEFFTScaleKernel _scale_kernel; + Tensor _digit_reversed_input; + Tensor _digit_reverse_indices; + unsigned int _num_ffts; + unsigned int _axis; + bool _run_scale; }; } // namespace arm_compute #endif /*__ARM_COMPUTE_NEFFT1D_H__ */ -- cgit v1.2.1