Canon Neural Network Image Processing tool files open source support?

I was a sucker and bought commercial Canon Neural Network Image Processing tool for one year. I needed to process some high ISO images and after short testing last year I found that this paid tool provided pretty good results.

This tool creates about 4x bigger CRN file from a Canon CR3 RAW file (for example 64MB CR3 → 311MB CRN). It is possible to process created CRN file with Canon Digital Photo Professional software which IMO sucks pretty hard compared to darktable.

Now when I have a RAW file I would like run through this commercial Canon tool I need to first do some basic development in DPP to it and then export TIF, which I need to import darktable for further processing.

I don’t know enough about RAW file formats to say would it be possible to add direct support for those CRN files to darktable or RawTherapee. So I have uploaded one CR3 file and CRN file created from it into my google drive (licensed CC-BY-NC). It would be great if some one who understand these RAW formats could look what Canon has done here and say if it would be possible to support this CRN file type directly with Open Source software.

Here’s a screenshot of what CR3 file looks like compared to CRN file in Canon DPP (zoomed 200%).

So, from the first few bytes it looks like this CRN is some variant of the CR3 file container, and these are the known facts:

  • RawSpeed doesn’t support CR3 yet, so this won’t be supported immediately either, but

  • LibRaw does support CR3 (used by darktable for CR3s only and by ART), but they have about one release per year, so it might still take a while until we see CRN support.

Is it possible to crop in this tool and provide a smaller CRN perhaps? Please upload it directly to (maybe even w/ the source CR3) for research and posterity.

Please also ping lclevy on github (and try the Python parsing tool): GitHub - lclevy/canon_cr3: Describing the Canon CR3 fileformat from Canon M50 / EOS R / SX70 HS / EOS RP...

Also, maybe @cytrinox will be keen to try it out for his DNGLab converter

1 Like

I’ve checked the provided files. Yes, the CRN image is bigger, but in fact it has the same MDAT box size as the original CR3. So I would say the image is the same for both files. dnglab can convert the CRN to DNG without problems but the resulting image looks very noisy in darktable an equal to to CR3 one.

There is a new obscure BMFF box with a very large content:

          "header": {
            "size": 1229531648,
            "typ": "\u0003\u0000\u0000\u0000",
            "uuid": null,
            "offset": 66184098,
            "header_len": 8

This box has an invalid length (larger than file) and points to a TIFF structure. Whatever this is, it seems to be f***ed up. Even the box type is unusal. Maybe this structure contains information how to modify the original embedded image, but I see no chance to implement this.

1 Like

It is not possible to crop in this tool. It takes RAW image and creates this huge CRN file from it.

Thank you very much for you time to look this. This was the answer I feared. Canon is probably protecting their IPR for this, so I feel it is too much to ask for anyone to try reverse engineering what this commercial tool is doing. I will generate TIFF with DPP from these CRN files and edit those in darktable also in the future.

Too bad. I don’t think @LebedevRI would be happy with such a big upload to RPU…

Upload the whole file to