Bug 506063 - Faces not detected on JXL images
Summary: Faces not detected on JXL images
Status: RESOLVED FIXED
Alias: None
Product: digikam
Classification: Applications
Component: Faces-Detection (other bugs)
Version First Reported In: 8.6.0
Platform: openSUSE Linux
: NOR normal
Target Milestone: ---
Assignee: Digikam Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2025-06-23 17:18 UTC by vato
Modified: 2025-06-24 10:43 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed/Implemented In: 8.7.0
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description vato 2025-06-23 17:18:00 UTC
The faces on JXL images are not found, even when faces on the original NEF files or on identical JPG files are found.

STEPS TO REPRODUCE
Choose a folder with images with faces and run the face detection. 

OBSERVED RESULT
1. Faces on NEF or JPG files will be found.
2. Faces on JXL images will not be found.

EXPECTED RESULT
Faces on any image format are found.

SOFTWARE/OS VERSIONS
Operating System: openSUSE Tumbleweed 20250613
KDE Plasma Version: 6.3.5
KDE Frameworks Version: 6.14.0
Qt Version: 6.9.1
Kernel Version: 6.15.2-1-default (64-bit)
Graphics Platform: Wayland
Processors: 4 × Intel® Core™ i5-6400 CPU @ 2.70GHz
Memory: 23.2 GiB of RAM
Graphics Processor: Intel® HD Graphics 530
Comment 1 Maik Qualmann 2025-06-23 17:25:23 UTC
JXL images work flawlessly with my development version under openSUSE Tumbleweed. Can you display JXL images in digiKam? If not, you'll need to install the KImageFormat plugins.

Maik
Comment 2 vato 2025-06-23 18:07:42 UTC
(In reply to Maik Qualmann from comment #1)
> JXL images work flawlessly with my development version under openSUSE
> Tumbleweed. Can you display JXL images in digiKam? If not, you'll need to
> install the KImageFormat plugins.
> 
> Maik

I can display JXL images in digiKam and KImageFormat is installed as well as libjxl.
I just tested it again, digiKam finds images in JPG but not in the exact same JXL images.
Comment 3 Maik Qualmann 2025-06-23 18:09:20 UTC
Then we need the JXL image for testing, if not public to my email.

Maik
Comment 4 vato 2025-06-23 18:39:55 UTC
(In reply to Maik Qualmann from comment #3)
> Then we need the JXL image for testing, if not public to my email.
> 
> Maik

I just sent you an email.
Comment 5 Maik Qualmann 2025-06-23 20:24:07 UTC
Thanks for the JXL test image. Faces are detected here without any problems using the digiKam-8.7.0 pre-release version. However, the face thumbnails are not created correctly with this 16-bit JXL image; only a checkerboard thumbnail is created. Thumbnail creation from the icon view model process is fine (e.g., when manually changing the position), but not directly in the face detection process. I suspect a conversion issue from DImg to QImage. I'll look into that.

Maik
Comment 6 Maik Qualmann 2025-06-24 06:44:36 UTC
Git commit 17c5c09055f89dcd572f41890a3cb3015d1d64c5 by Maik Qualmann.
Committed on 24/06/2025 at 06:43.
Pushed by mqualmann into branch 'master'.

fix DImg memory overwrite by OpenCV

M  +4    -1    core/libs/qtopencvimg/qtopencvimg.cpp

https://invent.kde.org/graphics/digikam/-/commit/17c5c09055f89dcd572f41890a3cb3015d1d64c5
Comment 7 Maik Qualmann 2025-06-24 10:43:04 UTC
Git commit fb67733a7f7ab87303886661fee9f00b4871ca31 by Maik Qualmann.
Committed on 24/06/2025 at 10:42.
Pushed by mqualmann into branch 'master'.

better we make a deep copy of cv::Mat
FIXED-IN: 8.7.0

M  +1    -1    NEWS
M  +1    -4    core/libs/qtopencvimg/qtopencvimg.cpp

https://invent.kde.org/graphics/digikam/-/commit/fb67733a7f7ab87303886661fee9f00b4871ca31