Commit 4a7d441b authored by Alexander Alekhin's avatar Alexander Alekhin

test: fix cuda build

parent 2c03c8d7
...@@ -46,6 +46,8 @@ using namespace std; ...@@ -46,6 +46,8 @@ using namespace std;
using namespace testing; using namespace testing;
using namespace perf; using namespace perf;
namespace { // workaround conflict with DftFlags
////////////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////////////
// GEMM // GEMM
...@@ -252,3 +254,5 @@ PERF_TEST_P(Sz_KernelSz_Ccorr, Convolve, ...@@ -252,3 +254,5 @@ PERF_TEST_P(Sz_KernelSz_Ccorr, Convolve,
CPU_SANITY_CHECK(dst); CPU_SANITY_CHECK(dst);
} }
} }
} // namespace
...@@ -46,6 +46,8 @@ ...@@ -46,6 +46,8 @@
using namespace cvtest; using namespace cvtest;
namespace {
//////////////////////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////////////////
// Merge // Merge
...@@ -416,4 +418,6 @@ INSTANTIATE_TEST_CASE_P(CUDA_Arithm, CopyMakeBorder, testing::Combine( ...@@ -416,4 +418,6 @@ INSTANTIATE_TEST_CASE_P(CUDA_Arithm, CopyMakeBorder, testing::Combine(
ALL_BORDER_TYPES, ALL_BORDER_TYPES,
WHOLE_SUBMAT)); WHOLE_SUBMAT));
} //namespace
#endif // HAVE_CUDA #endif // HAVE_CUDA
...@@ -55,6 +55,8 @@ namespace ...@@ -55,6 +55,8 @@ namespace
IMPLEMENT_PARAM_CLASS(FAST_NonmaxSuppression, bool) IMPLEMENT_PARAM_CLASS(FAST_NonmaxSuppression, bool)
} }
namespace {
PARAM_TEST_CASE(FAST, cv::cuda::DeviceInfo, FAST_Threshold, FAST_NonmaxSuppression) PARAM_TEST_CASE(FAST, cv::cuda::DeviceInfo, FAST_Threshold, FAST_NonmaxSuppression)
{ {
cv::cuda::DeviceInfo devInfo; cv::cuda::DeviceInfo devInfo;
...@@ -708,4 +710,6 @@ INSTANTIATE_TEST_CASE_P(CUDA_Features2D, BruteForceMatcher, testing::Combine( ...@@ -708,4 +710,6 @@ INSTANTIATE_TEST_CASE_P(CUDA_Features2D, BruteForceMatcher, testing::Combine(
testing::Values(DescriptorSize(57), DescriptorSize(64), DescriptorSize(83), DescriptorSize(128), DescriptorSize(179), DescriptorSize(256), DescriptorSize(304)), testing::Values(DescriptorSize(57), DescriptorSize(64), DescriptorSize(83), DescriptorSize(128), DescriptorSize(179), DescriptorSize(256), DescriptorSize(304)),
testing::Values(UseMask(false), UseMask(true)))); testing::Values(UseMask(false), UseMask(true))));
} // namespace
#endif // HAVE_CUDA #endif // HAVE_CUDA
...@@ -68,6 +68,8 @@ namespace ...@@ -68,6 +68,8 @@ namespace
} }
} }
namespace {
///////////////////////////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////////////////////////
// Blur // Blur
...@@ -708,4 +710,6 @@ INSTANTIATE_TEST_CASE_P(CUDA_Filters, Median, testing::Combine( ...@@ -708,4 +710,6 @@ INSTANTIATE_TEST_CASE_P(CUDA_Filters, Median, testing::Combine(
WHOLE_SUBMAT) WHOLE_SUBMAT)
); );
} //namespace
#endif // HAVE_CUDA #endif // HAVE_CUDA
...@@ -55,6 +55,8 @@ namespace ...@@ -55,6 +55,8 @@ namespace
IMPLEMENT_PARAM_CLASS(L2gradient, bool) IMPLEMENT_PARAM_CLASS(L2gradient, bool)
} }
namespace {
PARAM_TEST_CASE(Canny, cv::cuda::DeviceInfo, AppertureSize, L2gradient, UseRoi) PARAM_TEST_CASE(Canny, cv::cuda::DeviceInfo, AppertureSize, L2gradient, UseRoi)
{ {
cv::cuda::DeviceInfo devInfo; cv::cuda::DeviceInfo devInfo;
...@@ -98,4 +100,6 @@ INSTANTIATE_TEST_CASE_P(CUDA_ImgProc, Canny, testing::Combine( ...@@ -98,4 +100,6 @@ INSTANTIATE_TEST_CASE_P(CUDA_ImgProc, Canny, testing::Combine(
testing::Values(L2gradient(false), L2gradient(true)), testing::Values(L2gradient(false), L2gradient(true)),
WHOLE_SUBMAT)); WHOLE_SUBMAT));
} // namespace
#endif // HAVE_CUDA #endif // HAVE_CUDA
...@@ -46,6 +46,8 @@ ...@@ -46,6 +46,8 @@
using namespace cvtest; using namespace cvtest;
namespace {
/////////////////////////////////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////////////////////////////
// HistEven // HistEven
...@@ -212,4 +214,6 @@ INSTANTIATE_TEST_CASE_P(CUDA_ImgProc, CLAHE, testing::Combine( ...@@ -212,4 +214,6 @@ INSTANTIATE_TEST_CASE_P(CUDA_ImgProc, CLAHE, testing::Combine(
DIFFERENT_SIZES, DIFFERENT_SIZES,
testing::Values(0.0, 40.0))); testing::Values(0.0, 40.0)));
} // namespace
#endif // HAVE_CUDA #endif // HAVE_CUDA
...@@ -46,6 +46,8 @@ ...@@ -46,6 +46,8 @@
using namespace cvtest; using namespace cvtest;
namespace {
/////////////////////////////////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////////////////////////////
// HoughLines // HoughLines
...@@ -256,4 +258,6 @@ INSTANTIATE_TEST_CASE_P(CUDA_ImgProc, GeneralizedHough, testing::Combine( ...@@ -256,4 +258,6 @@ INSTANTIATE_TEST_CASE_P(CUDA_ImgProc, GeneralizedHough, testing::Combine(
ALL_DEVICES, ALL_DEVICES,
WHOLE_SUBMAT)); WHOLE_SUBMAT));
} // namespace
#endif // HAVE_CUDA #endif // HAVE_CUDA
...@@ -46,6 +46,8 @@ ...@@ -46,6 +46,8 @@
using namespace cvtest; using namespace cvtest;
namespace {
//#define DUMP //#define DUMP
struct HOG : testing::TestWithParam<cv::cuda::DeviceInfo> struct HOG : testing::TestWithParam<cv::cuda::DeviceInfo>
...@@ -558,4 +560,6 @@ CUDA_TEST_P(LBP_classify, Accuracy) ...@@ -558,4 +560,6 @@ CUDA_TEST_P(LBP_classify, Accuracy)
INSTANTIATE_TEST_CASE_P(CUDA_ObjDetect, LBP_classify, INSTANTIATE_TEST_CASE_P(CUDA_ObjDetect, LBP_classify,
testing::Combine(ALL_DEVICES, testing::Values<int>(0))); testing::Combine(ALL_DEVICES, testing::Values<int>(0)));
} // namespace
#endif // HAVE_CUDA #endif // HAVE_CUDA
...@@ -46,6 +46,8 @@ ...@@ -46,6 +46,8 @@
using namespace cvtest; using namespace cvtest;
namespace {
////////////////////////////////////////////////////// //////////////////////////////////////////////////////
// BroxOpticalFlow // BroxOpticalFlow
...@@ -401,4 +403,6 @@ INSTANTIATE_TEST_CASE_P(CUDA_OptFlow, OpticalFlowDual_TVL1, testing::Combine( ...@@ -401,4 +403,6 @@ INSTANTIATE_TEST_CASE_P(CUDA_OptFlow, OpticalFlowDual_TVL1, testing::Combine(
ALL_DEVICES, ALL_DEVICES,
testing::Values(Gamma(0.0), Gamma(1.0)))); testing::Values(Gamma(0.0), Gamma(1.0))));
#endif // HAVE_CUDA } // namespace
\ No newline at end of file
#endif // HAVE_CUDA
...@@ -46,6 +46,8 @@ ...@@ -46,6 +46,8 @@
using namespace cvtest; using namespace cvtest;
namespace {
////////////////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////////////////
// StereoBM // StereoBM
...@@ -209,4 +211,6 @@ INSTANTIATE_TEST_CASE_P(CUDA_Stereo, ReprojectImageTo3D, testing::Combine( ...@@ -209,4 +211,6 @@ INSTANTIATE_TEST_CASE_P(CUDA_Stereo, ReprojectImageTo3D, testing::Combine(
testing::Values(MatDepth(CV_8U), MatDepth(CV_16S)), testing::Values(MatDepth(CV_8U), MatDepth(CV_16S)),
WHOLE_SUBMAT)); WHOLE_SUBMAT));
} // namespace
#endif // HAVE_CUDA #endif // HAVE_CUDA
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment