Skip to content

Commit

Permalink
drop convertFp16 in favor of cv::Mat::convertTo.
Browse files Browse the repository at this point in the history
  • Loading branch information
asmorkalov committed Oct 18, 2024
1 parent 3cc5923 commit e28d224
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions modules/cudev/test/test_cvt.cu
Original file line number Diff line number Diff line change
Expand Up @@ -102,10 +102,10 @@ public:

// Fp32 -> Fp16
cv::cuda::convertFp16(g_src, g_dst);
cv::convertFp16(src, dst);
src.convertTo(dst, CV_16F);
// Fp16 -> Fp32
cv::cuda::convertFp16(g_dst.clone(), g_dst);
cv::convertFp16(dst, ref);
dst.convertTo(ref, CV_32F);

g_dst.download(dst);
EXPECT_MAT_NEAR(dst, ref, 0.0);
Expand Down

0 comments on commit e28d224

Please sign in to comment.