I’ve mentioned in the past that I prefer to take spatial resolution measurements directly off the raw information in order to minimize often unknown subjective variables introduced by demosaicing and rendering algorithms unbeknownst to the operator, even when all relevant sliders are zeroed. In this post we discover that that is indeed the case for ACR/LR process 2010/2012 and for Capture NX-D – while DCRAW appears to be transparent and perform straight out demosaicing with no additional processing without the operator’s knowledge.
An easy way to demonstrate processing additional to straight demosaicing and rendering of a raw image is to take a close look at the profile of a sharp transition like a clean black and white edge when projected on a sensor. If we were to normalize the black to white transition with black around zero intensity and white near one and take readings across it (perpendicular to it), ideally we would read zeros in all the pixels to the left of the step and suddenly switch to ones in all the pixels to the right of it. But because of imperfections in the lenses and imaging system, the edge is in practice actually spread out over a few pixels as follows:
The blue line above is an actual edge intensity profile (Edge Spread Function, ESF) as measured by excellent open source MTF Mapper by Frans van den Bergh directly from unprocessed raw data. Because of super-sampling it is able to measure the intensity profile across an edge to a 1/8th of a pixel resolution.
An algorithm that performs demosaicing and rendering only – without additional processing – would track this curve relatively closely, without any of the overshoots, undershoots or ringing typical of subsequent sharpening shown in an earlier article. Open source DCRAW by David Coffin is often considered to be such a minimalist converter, so let’s see how the edges it creates compare to those from the raw data alone.
I used a 400×150 pixel area of the edge below the center of file DSC_7553.NEF, a D810+85mm:1.8G f/5.6 capture at base ISO by dpreview.com. This is what it looks like, just the raw data after CFA normalization (shown in the following graphs as WB Raw):The NEF was also white balanced and demosaiced to sRGB by dcraw with the AHD* and VNG algorithms, cropped as above and fed to MTF Mapper which produced the following intensity profiles (ESFs):
The edge profiles look pretty similar, with no signs of additional processing, squeezing or acutance stretching. This is what the top quadrant of that graph looks like up close:
The main differences around the bends are explainable by a number of standard adjustments required for rendering, including gamma and contrast. If not abused (as in a relatively neutral rendering), those tend not to degrade MTF performance much. It’s notable, however, that there are no tell tale signs of additional processing.
Next the NEF was white balanced and demosaiced to sRGB by ACR using both 2010 and 2012 process versions with the Adobe Standard profile and all sliders (including those below) set at zero – as well as by the 2012 process with everything at default:
I also threw in new-as-of-last-year Capture NX-D because the images it renders with all its relevant sliders at zero appear sharper to me than those produced by now-left-in-the-lurch Capture NX2 with the same setup, which did not use to perform any ‘subliminal’ processing. Here are their ESF’s, same crops as above:
And that’s what additional processing (‘sharpening’) looks like: overshoots (undershoots at the other end) and ringing. Sure enough, CNX-D is right in the thick of it, guilty as charged. And so is ACR even with all sliders at zero. This is not necessarily bad when rendering an image for display, but it does introduce a number of uncontrolled variables when attempting to measure different hardware performance.
ACR process 2012 with all its sliders at default supposedly sharpens the image by a blend of unsharp masking and deconvolution, the relative strength of the effects controlled by the detail slider, in this case at 25%. Even though often considered insufficient for capture sharpening by users, that’s quite a potent mix with sometime amusing results from online testing sites which use those settings to render the images they test. Especially noteworthy are those that show more line widths per picture height at MTF50 than the number of physical rows that a sensor has. With an AA! How many more phantom rows will the AAless version of that same sensor in the current generation’s body have, I wonder? I’ve noticed some of those results have been pulled since the last time I looked. Otus, Otus, why don’t they test you? I think I know.
But kidding aside and ignoring ACR at default for a moment, MTF50 readings from the algorithms with minimized sliders were fairly close, ranging from 0.284 to 0.301 cy/px for the edge at hand – with the highest score obtained by the unprocessed normalized raw file. This makes sense because demosaicing entails something akin to a low pass filtering function when data from neighbouring pixels is necessarily mixed in order to gather color information where there was none. Nevertheless I have seen in the past that good demosaicing algorithms are able to preserve linear spatial resolution information during the rendering process and come close to results from unprocessed raw data. Today dcraw AHD* came in a very close second, practically matching WB Raw. I am impressed:
The chart shows clearly what algorithms perform additional processing. DCraw’s renderings are well behaved, close to the raw-data benchmark. ACR 2012 with all sliders at zero holds up well up to MTF50 but loses steam above that, hovering on in the aliased upper frequencies. That’s probably due to some additional filtering somewhere in the chain (see also the same kink in the Default rendition), but not very desirable behavior – as far as retaining linear spatial resolution information either of the two Dcraw algorithms would appear to be preferable. On the other hand ACR 2012 at default hits MTF50 at a 1/3 higher amplitude than the others, 0.416 cycles per pixel – with the unwelcome side effect of also amplifying higher frequency false detail (aliasing), moiré and noise. Alas, the perfect sharpener has not been invented yet.
Most every other converter other than DCraw has its own secret sauce thrown in whether that be perceptual and/or physical. Some, like ACR/LR, are also known to use different parameters for different cameras. This variability is the reason that I prefer to stick to unprocessed, raw measurements when investigating the linear spatial resolution performance of different hardware. Fewer, better controlled variables make for a more even playing field and better results.
* Note that Jean Pierre suggests in the comments below that what is called AHD in DCraw is actually implemented by the LMMSE algorithm.