darktable: can't open raw DNG files from film scanner (Epson V600)

My usual way of treating negative scans from the scanner is opening in RawTherapee and go from there.
However, today I wanted to give a shot to the negadoctor, but it seems darktable can’t load the DNG files from the Epson V600 scanner. I’m fairly sure that I was able to see these files in the past, because when I started scanning my own films, a few years ago, I also started using RawTherapee because darktable, my main raw tool, was not very good for this specific task (which suggest to my memory that I was developing these DNG files with darktable…).

Anyhow, when I try to import the DNG in darktable, the ‘skull’ icon appear, and if I double click to open the darkroom, this is what I get:

I’m using darktable 3.6 in Ubuntu 20.04, installed from OBS repos.

I can share an example file (it is pretty big, so I put here a download link, let me know if it doesn’t work):
29.dng
Licensed CC-BY-SA 4.0.

As said, in RawTherapee (5.8, AppImage) these files work as expected:

I’d really appreciate any help pointing me towards fixing my darktable/system, so I can give a shake to the negadoctor.

Cheers!

Can you scan the image to a tif file? I’m not sure what advantage scanning to dng provides. The problem with dng’s is that sometimes it’s a raw, sometimes it’s not, and the “standard” is not always standard.

Yes, I can, of course, but that wouldn’t solve it.
I couldn’t use negadoctor (in case I prefer it over RawTherape, for instance) on all my scanned films (~100 rolls in the past 4-5 years), which have all been scanned to DNG.

Since these come from a scanner, they are surely not raw :). It are just linear tif files with a dng extension.

Why darktable will not read them is a bit of a mistery to me though. It reads my linear rgb files from dxo photo lab just fine… But they have a camera model that IS supported in their metadata.

Maybe compression?

Or maybe - untested - the data can be written as a plain tif file with ImageMagick or something? “magick tiff:input.dng -compress none output.tif" maybe?

Are they scanned by VueScan? You can ‘scan from a raw file to raw’ in VueScan. Which means you can use the dng as input and then set your ‘raw’ output as tif. If you manage to tweak the right buttons you can do it even as batch (used it to convert plain ‘raw’ tif files to dng for NegativeLabPro once).

Notice how I always quote ‘raw’ since it has nothing to do with raw files from a photo camera.

To troubleshoot start darktable from a console, then import one of your dngs and see what errors it throws

Converted with Adobe DNG Converter, seems to work.

Did you know that if you rename the file to 29.tif darktable opens it just fine. The problem is that the extension is dng so darktable thinks it’s a raw file and tries to figure out the camera model so that it knows which color matrix, black and white point, etc to use.

1 Like

I tried this too. This is its size at 100%

I just looked at the dimensions. It’s pulling the embedded preview. I’m not sure how darktable tells the difference between a raw dng and a non-raw dng.

According to Wikipedia they are raw files even if the sensor producing them is not mounted on a camera rig, so no need for the quote marks :grin:
(nerdy remark from an image sensor designer: raw simply means, in usual spoken terms, the file content is “unprocessed”… ok this needs quoting, because the data from the sensors always needs some kind of processing… raw files are just “close” to the values generated by the sensor in the first place, without any rendering intent yet, e.g. normally they’re not demosaiced)

Regarding the scanning software, I don’t use VueScan, in part because it’s not free and in part because I try to do as much as possible in Linux. I use SilverFast, that came with the scanner. It does a great job of operating the scanner for negatives, better than the Epson one (which is good for the normal flat-bed). It is excellent in scanning, but not in developing, that’s why I scan to raw, then develop elsewhere. It is so good for scanning that I actually have Windows in dual boot just for that SW, basically.

Nit picking apart… I truly appreciate all your inputs, thanks.
However, it seems that simply changing the file name into .tif makes darktable load the embedded thumbnail as if it was the picture itself, nothing more, in my case.

Converting it into a tif works, I know and tried.

But I’d like to know if it’s possible to open, process and organize (for this I love darktable) photos from my current film library, without the need to convert every file in it first (a few k photos…).

dcraw can read 29.dng and the result looks reasonable, but libraw can’t.

I don’t know if darktable uses libraw. If it does, then that is probably the problem, and you might push the issue to the libraw people.

EDIT: Correction: the libraw tools can read 29.dng. The problem was in my understanding, not in libraw.

it does not, it uses the rawspeed library.

Okay, thanks. The next logical question is: can the rawspeed library read the file? I don’t know the answer.

No rawspeed doesn’t read the file. It thinks it’s a camera raw file and since it’s not it fails.

The problem with this file is in Rawspeed. The file contains a Makernote exif tag which is supposed to contain manufacturer proprietary data. Rawspeed appears to have some support for these tags from some manufacturers, but when it encounters this one it throws an error.

If I comment out this line in rawspeed so that it doesn’t call parseMakerNote and just ignores it, then Darktable does open the file successfully.

Looks like it’s already a known issue for Silverfast files:

1 Like

There is even a PR that sees no activity for a month? Maybe the devs are just busy with a PR backlog. I don’t want to point fingers without knowing anything.

But maybe a little ping there or asking who the correct reviewer is might help?

Maybe the issue is that they are afraid it will break something with all the currently working files… I don’t know if there is an automated test somewhere that runs through all user submitted samples or something.

@ OP: I guess you can always checkout the 3.6.1 release and then manually merge the pr into it and do a build.

@jorismak darktable doesn’t use libraw so pulling that patch for darktable won’t work.