-
-
Notifications
You must be signed in to change notification settings - Fork 56.5k
Closed
Labels
Description
System Information
OpenCV 4.x ( 4d26e16 )
Operating System / Platform: Ubuntu 24.04
Compiler & compiler version: GCC 13.2.0
Detailed description
If EXR decoder is enabled, following tests are failed.
readWrite_32FC1
When using OpenEXR 3.x, getFileSize() return 440u instead of 396u.
Note: At ubuntu 24.11, system default(apt) OpenEXR is 3.1.5. it returns 439u.
[ RUN ] Imgcodecs_EXR.readWrite_32FC1
/home/kmtr/work/opencv4/modules/imgcodecs/test/test_exr.impl.hpp:38: Failure
Expected equality of these values:
396u
Which is: 396
getFileSize(filenameOutput)
Which is: 440
opencv/modules/imgcodecs/test/test_exr.impl.hpp
Lines 36 to 39 in 4d26e16
| ASSERT_TRUE(cv::imwrite(filenameOutput, img)); | |
| // Check generated file size to ensure that it's compressed with proper options | |
| ASSERT_EQ(396u, getFileSize(filenameOutput)); | |
| const Mat img2 = cv::imread(filenameOutput, IMREAD_UNCHANGED); |
read_YC_changeDepth
There are small diffenct between (1) IMREAD_COLOR_RGB (2) IMREAD_COLOR_BGR with swapping.
[ RUN ] Imgcodecs_EXR.read_YC_changeDepth
/home/kmtr/work/opencv4/modules/imgcodecs/test/test_exr.impl.hpp:202: Failure
Value of: cvtest::norm(img, img_rgb, NORM_INF) == 0
Actual: false
Expected: true
[ FAILED ] Imgcodecs_EXR.read_YC_changeDepth (12 ms)
opencv/modules/imgcodecs/test/test_exr.impl.hpp
Lines 195 to 202 in 4d26e16
| const Mat img_rgb = cv::imread(filenameInput, IMREAD_COLOR_RGB); | |
| ASSERT_FALSE(img_rgb.empty()); | |
| ASSERT_EQ(CV_8UC3, img_rgb.type()); | |
| cvtColor(img_rgb, img_rgb, COLOR_RGB2BGR); | |
| EXPECT_TRUE(cvtest::norm(img, img_rgb, NORM_INF) == 0); |
Steps to reproduce
I used system OpenEXR 3.1.5 from apt server (not OpenCV bundled).
sudo apt upgrade
sudo apt install libopenexr-dev
export OPENCV_IO_ENABLE_OPENEXR=1
git clone https://github.com/opencv/opencv.git opencv4
cmake -S opencv4 -B build4-main
cmake --build build4-main
cd build4-main
./bin/opencv_test_imgcodecs --gtest_filter="*EXR*"
Issue submission checklist
- I report the issue, it's not a question
- I checked the problem with documentation, FAQ, open issues, forum.opencv.org, Stack Overflow, etc and have not found any solution
- I updated to the latest OpenCV version and the issue is still there
- There is reproducer code and related data files (videos, images, onnx, etc)
Reactions are currently unavailable