I was fighting thumbs problems for CR2 files for a while.
ANd yes, I gave up.
What I do is I run
ufraw-batch --embedded-image --out-path=./Thumbs ./*.CR2
It extract thumb embedded in RAW file to sub directory Thumbs. It substitutes solution but it run quickly and I am able to preview pictures and preselect them. I delete unwanted files. Then I run
ls ./Thumbs > z.pl #makes a file with list of pictures I want to process further
replace embedded.jpg CR2 <z.pl>z2.pl #prepare CR2 file list
rm ./Thumbs/* #wipe subfolder
cat z2.pl | xargs ufraw-batch --conf=MyConf --out-path=./PicsOK #generates jpg's from only selected CR2, put them to PicsOK
Notice --conf=MyConf - MyCOnf is a file with recipe how to process RAW files. You can change it according to specific conditions and pictures. What I do is I use interactive ufraw to find best parameters, just copy them to the file MyConf and voila.
Hope this can speed up you picture factory, as I did
Then I copy only CR2 that I want, and run
ufraw-batch --shrink=2 *.CR2
or rub interactive for files I want to make them better.
Since it is a quite a time, you probably find out. Ufraw is a command line but also interactive application for raw processing.
System: Host: Kernel: 5.4.0-66-generic x86_64 bits: 64 compiler: gcc v: 7.5.0
Desktop: Cinnamon 4.4.8 wm: muffin dm: LightDM Distro: Linux Mint 19.3 Tricia
base: Ubuntu 18.04 bionic