Why are DNGs so much larger than the raw files?

I’m using PureRaw as a stand-alone processor before importing into Lightroom.
The results are great, but the size of the DNG files is ridiculous. My raw files are 24 meg to 30 meg in size, whereas the DNGs are 80 meg or thereabouts.
Is there a reason for this, and is there a way to get the DNGs smaller?
I was originally told that DNGs didn’t have to be that much bigger than the raws, if at all. so this puzzles me.

It’s because they are Linear DNGs. See here for more: Output File Size

Simplyfied explanation: Each pixel in a RAW file is either red, green or blue. PureRAW writes DNG files, in which every pixel is red, green and blue. Instead of r,g,b, you get rgb,rgb,rgb, which leads to about three times the file size.


People don’t always realize that if a sensor ia described as 24 megapixels, that means 24 MONOCHROME megapixels .

You then get color in a picture because those pixels have filters in front of them to either let through red, OR green OR blue.

In case of a Bayer pattern , you could describe that as 24 megapixels actually being 6 megapixels red, 2x6 megapixels green and finally 6 megapixels blue. Making the total of 24 megapixels.

So what a raw processor sort of does , is upscaling those four 6megapixels images of a single color , into one whole image of 24 megapixels with all colors combined. That is called demosaicing. And that basically means that you now have more data.

24 megapixels means 24 million measurements, so 24 million numbers to write. If the color data is demosaiced, you get three measurements (r,g,b) per pixel. So you get 24 x 3 million numbers to write. This is why the files are larger .

If you convert a raw file to a DNG without doing the demosaicing step, you still write 24 million numbers so the filesize doesnt has to increase .

DxO’s demosaicing , rendering and noise reduction (and more i guess) are all tied together. So you can’t have one without the other , meaning it always does the demosaicing step, and thus always increases the filesize.

The compression in the DNG format can sometimes help a bit with the filesize. But it’s still an increase. Since they are ‘intermediate’ files to me , i don’t care . After the edit and the export, it gets thrown out again .

For me at least.

Just as a sidenote: DCRAW has a development mode, which is superfast, because it merges four sensor pixel into one output pixel. In case of a 24 mp input file, you get a 6 mp output file without any demosaicing artefacts…but the file is still big, specially when 16 bit TIFF is used for output :grin:

The image will have as many pixels as there are sensels. Or nearly, the outer columns and rows are excluded for they miss a neighbour. So I don’t know what DCRAW is doing, but it is not right as you mention it.


Check out DCRAW option “-h” here: man dcraw (1): command-line decoder for raw digital photos

I didn’t know. But that is only meant for a fast preview. Not for serious photography.


Photography, serious or not, is more about what’s in the image, rather than how big it is :wink:

Other than that, DCRAW can deliver refreshing views of our images and on how much other apps tweak our images before we even know it…

I know DCRAW is a powerfull and often used demosaicing tool. I never played with it.
But your example deals with a kind of compression resulting in smaller output files. I don’t think that was the question in this topic.


to really return to the original topic, this isn’t about DNG pros and cons. It’s about the noise reduction (excellent) that DxO offers. The downside is having to keep the DNGs as my raw images, but having them so huge and taking up so much disc space.
I was hoping that after the noise reduction, I could get a more reasonable sized output file.
after my trial with this software, I might have to go to DeNoise AI.
I like the DxO software more, but I can’t deal with the huge output file.

The beauty of RAW processing is, that you can always redo what you did. You don’t need to keep intermediate copies (like DNGs)… Final output is often a JPEG, so wha keep the DNG?

1 Like

Because from time to time, I go back and reedit a photo for some reason, and I’d like to be able to keep my edits and not have to start all over.


That would be easier with PL5. Then the savings are parametric. I never understood the meaning of an external noise reducer that works on the raw file and exports as a RGB file, which a DNG in this case is.


I do that all the time. All I need is RAW, but no DNG (except the camera uses that as native RAW). And your attempt to interpret a very clear and definitive question to the efforts of noise reduction

simply fails. Read your original topic, you were asking why DNGs are so much larger, that inevitably leads to pros and cons (and I don’t see many pros). Noise reduction in PL5 is for all supported RAW formats and works fine. No one needs Adobe’s blown up file formats just to benefit of another company’s noise reduction.

An ironic twist is that jpg files converted from linear DNG are generally much smaller than their RAW>JPG counterparts. I noticed this when I was starting to use PureRaw. After a series of test shots I realized noise adds a lot of size to the image. When that gets taken out in PureRaw, the file sizes decrease materially upon conversion to JPG. Depth of Field also impacts file size, and for the same reason - more information to store.

Interesting thread. I don’t use PureRaw, but instead LR. Why does a 42mb RAW file out of my Sony aR7iii camera shrink into a ~28mb DNG file when converted in LR? Is that because the PureRaw de-noising sw “multiplies” the pixel info as decribed above (sorry for the probably inaccurate characterization - I didn’t study the actual description in much depth as I don’t use PureRaw).

This is a digression, but interesting IMO. For those that don’t know, sensels are photo sites and pixels are what are created from them in an image file. As you explained, the ratio of sensels to pixels is most often near 1:1 but one notable exception is found on Canon’s sensors with DPAF, where each pixel has two “sub-pixels”, each of which is a sensel. So on Canon DPAF sensors, the ratio is close to 2:1. One would think that there would be some IQ advantage to this but, if there is, it isn’t enough to make Canon sensors the IQ leaders.

pixel: picture elements.
sensel: sensor elements.
dpaf:dual pixel auto focus.
Yes, I was thinking of the classic Bayer arrays.
I didn’t know about dpaf so I did a search. It’s a way to get autofocus directly based on the sensor info. https://www.usa.canon.com/internet/portal/us/home/learn/education/topics/article/2018/July/Intro-to-Dual-Pixel-Autofocus-(DPAF)/Intro-to-Dual-Pixel-Autofocus-(DPAF)


Lightroom stores compressed raw info in its DNG files, while pureRAW stores demosaiced info.

  • RAW 2x2 sensel colour pattern: r, g, g, b, etc
  • Demosaiced 2x2 pixel pattern: rgb, rgb, rgb, rgb, etc.