200MB+ JPG files are failing to convert to JXL when I run batch convert. The files are either written as 0 bytes or don't write at all and XNView crashes to desktop. No error messages and I can't find any log files.
While attempting the conversion XnView was using over 12GB of memory at times. WTF?!
However, I can 'Save As' these large files individually.
An example JPG at 200MB+ - https://upload.wikimedia.org/wikipedia/ ... roject.jpg
EDIT - correction - 'Save As' only works sometimes. I have another JPG at 205MB and it crashes with a 0 byte JXL file written. XnViewer used up to 13,335MB while trying to convert this!! I have 'only' 16GB RAM.
EDIT - I tried running https://github.com/libjxl/libjxl against the 205MB JPG - it converted in a few seconds without problem.
EDIT - JXL Batch Converter - https://github.com/kampidh/jxl-batch-converter - also works perfectly for anyone who wants it.
Crashing on JPG to JXL for large files
Moderators: helmut, XnTriq, xnview, Dreamer
Re: Crashing on JPG to JXL for large files
I have 32 GB RAM and me take 26 GB before crash.rotbus19 wrote: Fri Feb 23, 2024 2:10 pm EDIT - correction - 'Save As' only works sometimes. I have another JPG at 205MB and it crashes with a 0 byte JXL file written. XnViewer used up to 13,335MB while trying to convert this!! I have 'only' 16GB RAM.
I think too — it's ridiculous.
I don't think so that it's XnView problem.rotbus19 wrote: Fri Feb 23, 2024 2:10 pm EDIT - I tried running https://github.com/libjxl/libjxl against the 205MB JPG - it converted in a few seconds without problem.
I don't know how You made jxl file via cjxl.exe (v 0.9.2) — me cjxl crash on start. And it's not only me crash on big file: www.reddit.com/r/jpegxl/comments/1aeg10 ... ng_to_jxl/
Re: Crashing on JPG to JXL for large files
Version 0.10 just released and that's what I used - default settings - '.\cjxl.exe input.jpg output.jxl'I don't know how You made jxl file via cjxl.exe (v 0.9.2)
However, a couple of JXLs produced with CJXL would not open in XnView or any other app (GIMP, Darktable). I think I fixed that by converting JPG -> TIFF -> JXL.
Re: Crashing on JPG to JXL for large files
Default settings make lossless transcoding jpg to jxl. If You want converting, use something that -> cjxl in.jpg out.jxl -q 96 -j 0rotbus19 wrote: Fri Feb 23, 2024 8:22 pmVersion 0.10 just released and that's what I used - default settings - '.\cjxl.exe input.jpg output.jxl'I don't know how You made jxl file via cjxl.exe (v 0.9.2)
However, a couple of JXLs produced with CJXL would not open in XnView or any other app (GIMP, Darktable). I think I fixed that by converting JPG -> TIFF -> JXL.
Your Van Gogh crash me on transcoding (memory issue) but make jxl file using coding parameters. And output file is not reading in XnView

BTW XnView using 0.8.2 library.
Re: Crashing on JPG to JXL for large files
Kadet wrote: Fri Feb 23, 2024 9:08 pm
Default settings make lossless transcoding jpg to jxl. If You want converting, use something that -> cjxl in.jpg out.jxl -q 96 -j 0
Your Van Gogh crash me on transcoding (memory issue) but make jxl file using coding parameters. And output file is not reading in XnView![]()
Thanks - I only installed XnView yesterday and had never used CJXL before, so it's been a learning curve (!). I also ditched the CLI version for the GUI (see last edit in first post), so I was trying conversion with that.
I spent a lot of time on this yesterday (thanks to the British weather!) - conclusions: LIBJXL not reliable (yet) for large images, XnView has badly implemented LIBJXL (or see below).
Is it? That jxl.dll is not the same size as libJPEGXL.dll. The XnView DLL has 2023/11/21 timestamp and doesn't seem to match any https://github.com/libjxl/libjxl/releases - and I've tried dropping in some but they don't work.BTW XnView using 0.8.2 library.
But if XnView is using an old one, maybe that is why it performed so poorly? A lot has changed in the last few months....
Re: Crashing on JPG to JXL for large files
XnView use library made by other devs (https://vcpkg.io/en/packages). They get stuck on 0.8.2 version. Sometimes it's good, as You see on version 0.10.0 (sometimes not compatibility output files). Waiting on version x.x.2 is good practice.rotbus19 wrote: Sat Feb 24, 2024 9:58 amIs it? That jxl.dll is not the same size as libJPEGXL.dll. The XnView DLL has 2023/11/21 timestamp and doesn't seem to match any https://github.com/libjxl/libjxl/releases - and I've tried dropping in some but they don't work.BTW XnView using 0.8.2 library.
But if XnView is using an old one, maybe that is why it performed so poorly? A lot has changed in the last few months....
Re: Crashing on JPG to JXL for large files
@Kadet
Good to know. Thanks.
Good to know. Thanks.
Re: Crashing on JPG to JXL for large files
...bug is still present in https://github.com/libjxl/libjxl/releases/tag/v0.10.1 (outputs a JXL but it cannot be opened).
Re: Crashing on JPG to JXL for large files
I'm not expert, but maybe in 0.10 used for large files some jxl trick which before not was coding in encoder and decoder compilation.rotbus19 wrote: Thu Feb 29, 2024 2:41 pm ...bug is still present in https://github.com/libjxl/libjxl/releases/tag/v0.10.1 (outputs a JXL but it cannot be opened).
djxl nice make png image.
We have to wait on XnView with 0.10 library.