The rotation is executed, it is just performed more slowly. If I rotate inside darkroom orientation -> rotate 90 everything is fine. I use demosaic -> RCD.
If I start darktable using a clean .config and ./cache and import a new raw file without corresponding XMP, then everything is fine.
My issue:
I do not seem to be able to reset my regular ./config or ./cache to get lighttable selected image -> rotate working again. My regular install has a lot of test pictures and styles I want to keep. My darktable install is somehow tainted and I can not clean it up. I start with a clean ./config and then put back:
darktablerc
data.db
library.db
shortcutsrc
styles
…
If I clean .cache and remove:
cached_kernels
And finally:
selected image -> trash
I remove XMP file
re-import a RAW file
And after the above, when I start darktable and import a new RAW the issue is back.
One thing I suspect is that my darktable openCL configuration is stuck somewhere. How can I force recompile of kernels? Removing cashed kernels is not enough.
I am open to any advice, in case,the root cause is somewhere else. Clearly a totally clean .config works, but I rather not remove all XMP files and re-import my files and define styles and presets again.
You seem to be restoring pretty much everything from your old config directory. Most of darktable’s configuration is stored in darktablerc, so if you restore that file, and it has some wrong setting, of course you will have the same problem.
If you run darktable with -d opencl, do you have any more info?
Have you tried resetting the openCL tuning params to none?
FYI:
data.db stores your presets, styles, locations and tags
library.db stores the processing settings for your currently imported images (film rolls, images, editing history, colour labels, which tags are applied to which images and so on).
styles/ is a directory with *.dtstyle files, I think they carry the same data as the styles table in data.db.
Yes, in various steps and permutations and orders, but still no luck.
I get same issue if I start darktable without darktablerc.
I have. If I start and then rotate a raw file in lighttable, then I get this (inside darkroom same rotation operation is fine):
./darktable -d opencl
0.2266 [dt_get_sysresource_level] switched to 1 as `default'
0.2266 total mem: 15941MB
0.2266 mipmap cache: 1992MB
0.2266 available mem: 7970MB
0.2266 singlebuff: 124MB
0.2266 OpenCL tune mem: OFF
0.2266 OpenCL pinned: OFF
[opencl_init] opencl related configuration options:
[opencl_init] opencl: ON
[opencl_init] opencl_scheduling_profile: 'very fast GPU'
[opencl_init] opencl_library: 'default path'
[opencl_init] opencl_device_priority: '*/!0,*/*/*/!0,*'
[opencl_init] opencl_mandatory_timeout: 400
[opencl_init] opencl library 'libOpenCL' found on your system and loaded
[opencl_init] found 1 platform
[opencl_init] found 1 device
[dt_opencl_device_init]
DEVICE: 0: 'Quadro RTX 4000'
PLATFORM NAME & VENDOR: NVIDIA CUDA, NVIDIA Corporation
CANONICAL NAME: nvidiacudaquadrortx4000
DRIVER VERSION: 470.182.03
DEVICE VERSION: OpenCL 3.0 CUDA, SM_20 SUPPORT
DEVICE_TYPE: GPU
GLOBAL MEM SIZE: 7982 MB
MAX MEM ALLOC: 1995 MB
MAX IMAGE SIZE: 32768 x 32768
MAX WORK GROUP SIZE: 1024
MAX WORK ITEM DIMENSIONS: 3
MAX WORK ITEM SIZES: [ 1024 1024 64 ]
ASYNC PIXELPIPE: NO
PINNED MEMORY TRANSFER: NO
MEMORY TUNING: NO
FORCED HEADROOM: 400
AVOID ATOMICS: NO
MICRO NAP: 250
ROUNDUP WIDTH: 16
ROUNDUP HEIGHT: 16
CHECK EVENT HANDLES: 128
PERFORMANCE: 8.655
TILING ADVANTAGE: 0.000
DEFAULT DEVICE: NO
KERNEL BUILD DIRECTORY: /home/magnus/usr/source/darktable/install/share/darktable/kernels
KERNEL DIRECTORY: /home/magnus/.cache/darktable/cached_v1_kernels_for_NVIDIACUDAQuadroRTX4000_47018203
CL COMPILER OPTION: -cl-fast-relaxed-math
KERNEL LOADING TIME: 0.0206 sec
[opencl_init] OpenCL successfully initialized. Internal numbers and names of available devices:
[opencl_init] 0 'NVIDIA CUDA Quadro RTX 4000'
[opencl_init] FINALLY: opencl is AVAILABLE and ENABLED.
[dt_opencl_update_priorities] these are your device priorities:
[dt_opencl_update_priorities] image preview export thumbs preview2
[dt_opencl_update_priorities] 0 0 0 0 0
[dt_opencl_update_priorities] show if opencl use is mandatory for a given pixelpipe:
[dt_opencl_update_priorities] image preview export thumbs preview2
[dt_opencl_update_priorities] 1 1 1 1 1
[opencl_synchronization_timeout] synchronization timeout set to 0
[dt_opencl_update_priorities] these are your device priorities:
[dt_opencl_update_priorities] image preview export thumbs preview2
[dt_opencl_update_priorities] 0 0 0 0 0
[dt_opencl_update_priorities] show if opencl use is mandatory for a given pixelpipe:
[dt_opencl_update_priorities] image preview export thumbs preview2
[dt_opencl_update_priorities] 1 1 1 1 1
[opencl_synchronization_timeout] synchronization timeout set to 0
9.6474 [dt_opencl_check_tuning] use 5182MB (tunemem=OFF, pinning=OFF) on device `NVIDIA CUDA Quadro RTX 4000' id=0
11.1731 [dt_interpolation_resample_cl] resampling plan cannot efficiently be run on the GPU - fall back to CPU.
11.1732 [dt_interpolation_resample_cl] couldn't enqueue kernel! DT_OPENCL_DEFAULT_ERROR
11.1753 [opencl_demosaic] rcd couldn't enqueue kernel! DT_OPENCL_DEFAULT_ERROR
11.1753 [opencl_pixelpipe] [thumbnail] could not run module `demosaic' on gpu. falling back to cpu path
14.8915 [dt_interpolation_resample_cl] resampling plan cannot efficiently be run on the GPU - fall back to CPU.
14.8915 [dt_interpolation_resample_cl] couldn't enqueue kernel! DT_OPENCL_DEFAULT_ERROR
14.8937 [opencl_demosaic] rcd couldn't enqueue kernel! DT_OPENCL_DEFAULT_ERROR
14.8937 [opencl_pixelpipe] [thumbnail] could not run module `demosaic' on gpu. falling back to cpu path
I also checked this:
I already have preferences → processing → tune openCL perfromance → none.
This has happened before. I rebuild git master almost daily and just keep doing cmake, make, make install on to the same installation. This sometimes gives me a non-standard install and state.
But I think you are pointing me in the right direction. I suspect this has something to do with by darktable openCL configuration. OpenCL as such is fine on my system.
I have the sources checked out to ~/darktable; I deploy to ~/darktable-master. git clean -d -f -x ensures all previous build artefacts are removed before starting the build. The renice and ionice are only there to let me browse undisturbed while the build is running.
Maybe you could try tuning for memory? My darktable resources setting is large, scheduling profile is default, tuning is for memory. I force all-GPU processing with opencl_device_priority=+0/+0/+0/+0/+0 , and I’ve raised opencl_mandatory_timeout=20000 (but what you get is not timeouts, but outright failures).
What size are your images? What’s your NVidia version? The last 470 upgrade broke my daughter’s games; I used to have troubles with some 520 or 525 version. I’m currently on 525.105.17.
This is Debian stable 11.7 current default driver for Nvidia non-free. It works for me. At this stage I do not think it is driver version is related, but I will keep an eye on it.
Thanks. I have tried to delete ./config.
This is what I see after scratching dt source and target install and starting all over with no previous .config or .cache:
If I import a raw file without a companion xmp-file then everything is fine. The operation selected image -> rotate in lighttable executes without issues.
If I import raw + xmp from previous install, then I get the error couldn't enqueue kernel! DT_OPENCL_DEFAULT_ERROR when selected image -> rotate is executed in lighttable.
It seems my issue is related to some other context or contents in xml file, with a combination of modules or parameters triggering this. But I do not know yet. I will have to continue and test.
Start darktable with a fresh ./config and ./cache (I deleted the old ones and let darktable create new ones when starting).
Start ./darktable and Import a new raw without associated xmp file.
The operation selected image -> rotate in lighttable executes without issues. i.e., no error messages in terminal window.
Select raw file and go to darkroom. Change demosaic -> method from default RCD to RCD + VNG.
Go back to lighttable and execute selected image -> rotate in lighttable. The error [dt_interpolation_resample_cl] couldn't enqueue kernel! DT_OPENCL_DEFAULT_ERROR will be displayed in the terminal window where ./darktable was executed.
Select SAME raw file and go back to darkroom. Change demosaic -> method from RCD + VNG back to RCD default.
Go back to lighttable and execute selected image -> rotate in lighttable. The error [dt_interpolation_resample_cl] couldn't enqueue kernel! DT_OPENCL_DEFAULT_ERROR will be displayed in the terminal window where ./darktable was executed.
In my standard install, I have a preset for demosaic module to set metod -> RCD + VNG. This will trigger the issue, even when going back to default metod -> RCD.
If I can find a more minimal set of steps to reproduce, then I will share it, but this is the best I can do at this stage.