CufftErrorCheck(cufftExecR2C(plan_f_all_scales, reinterpret_cast<cufftReal *>(real_input_arr),
complex_result.get_p_data()));
} else {
-#pragma omp critical
+NORMAL_OMP_CRITICAL
{
CufftErrorCheck(cufftSetStream(plan_f, stream));
CufftErrorCheck(
cv::Mat in_roi(fw_all, cv::Rect(0, int(i * m_height), int(m_width), int(m_height)));
in_roi = patch_feats[i].mul(m_window);
}
-#pragma omp critical
+NORMAL_OMP_CRITICAL
{
CufftErrorCheck(cufftSetStream(plan_fw, stream));
CufftErrorCheck(
cufftComplex *in = reinterpret_cast<cufftComplex *>(complex_input.get_p_data());
if (n_channels == 1) {
-#pragma omp critical
+NORMAL_OMP_CRITICAL
{
CufftErrorCheck(cufftSetStream(plan_i_1ch, stream));
CufftErrorCheck(cufftExecC2R(plan_i_1ch, in, reinterpret_cast<cufftReal *>(real_result_arr)));
CufftErrorCheck(cufftExecC2R(plan_i_features_all_scales, in, reinterpret_cast<cufftReal *>(real_result_arr)));
return;
}
-#pragma omp critical
+NORMAL_OMP_CRITICAL
{
CufftErrorCheck(cufftSetStream(plan_i_features, stream));
CufftErrorCheck(cufftExecC2R(plan_i_features, in, reinterpret_cast<cufftReal *>(real_result_arr)));
#if defined(OPENMP) && !defined(BIG_BATCH)
- cudaStreamSynchronize(stream);
+ CudaSafeCall(cudaStreamSynchronize(stream));
#endif
}
return;
#include "fft.h"
#include "cuda/cuda_error_check.cuh"
+#include "pragmas.h"
#if CV_MAJOR_VERSION == 2
#include <opencv2/gpu/gpu.hpp>
#include <cufft.h>
#include <cuda_runtime.h>
-struct Scale_vars;
+struct ThreadCtx;
class cuFFT : public Fft
{