• site home
  • blog home
  • galleries
  • contact
  • underwater
  • the bleeding edge

the last word

Photography meets digital computer technology. Photography wins -- most of the time.

You are here: Home / The Last Word / Sharpness testing, part 7

Sharpness testing, part 7

November 11, 2013 JimK 5 Comments

I haven’t posted anything on the sharpness testing for the past few days. It’s not because I’ve been busy with other things. On the contrary, I’ve been working way too hard on a problem I’ve discovered.

It all started when I looked critically at the results I was getting, and realized that, in some respects, they didn’t make sense. In particular, consider the aperture series in the last post. The results at the widest f-stops were too good to be true. I tried to convince myself that it was a focus shift issue, but something in the back of my mind kept telling me that probably wasn’t right.

I grew to suspect that my lighting compensation scheme wasn’t working. In particular, I suspected that I was overcompensating for light falloff, so that the wide aperture pictures, which suffered from vignetting, received unrealistic boosts in mean values and therefore in standard deviations. I decided to test it. I made two strobe-lit exposures under the same lighting conditions, deferring only in f-stop. One was f/11 and one was f/16. I figured there’d be some small diffraction differences, but that would be a second-order effect compared to what I was looking for. I brought both images into Lightroom and exported them as TIFFs. When I read them into Matlab and converted them to a linear representation, I noticed that the mean values weren’t a factor of two apart, as you’d expect. The ratio was 1.78. Not only that, the ratio of the standard deviations of the images as measured in Matlab, was 1.18. What was going on? Maybe the exposure was off, but the ratio of the means ought to be the same as the ratios of he standard deviations no matter what the difference in exposure was.

I redid the test, with the same results. Then I brought the f/11 image into Lightroom and dialed in -1 EV of Exposure adjustment. Matlab read those two images the same way as the two images that actually had two different exposures.

Well, then there had to be a programming error in my Matlab code, right? I went over it with a fine-tooth comb and tested it six ways from Sunday. It looked good, but I didn’t trust it anymore.

I fired up Rawdigger, and brought in the two images that were exposed a stop apart. The means were a factor of two apart, as were the standard deviations.

So the raw data looked as I would expect it to look, but the TIFFs from Lightroom looked wonky. I took the two raw files thru Iridient Developer. I got different answers than with Lightroom – a means ratio of 1.65, and a standard deviations ratio of 1.33 – but they were still wrong and still not anywhere near the same. I tried stripping all the processing I could find out of Iridient Developer. I even used the raw channel mixer to base all interpolations only on the two raw green channels (which prevents cross channel contamination). Every time I made a change, the means and standard deviations ratios would change, but they never got to anywhere near the right values.

I exported one of the green channels of both images from Rawdigger as TIFFs. When I read them into Matlab, the means and standard deviations were right.

Was something with the demosaicing screwing up the values? I didn’t think so, but I needed a raw converted that didn’t do any hidden processing.

I used dcraw to convert the two images, invoking it from the command line with the arcane test “dcraw -v -4 -w -j -T -o1 _D437350.NEF” looked at the sRGB TIFFs in Matlab. They were right.

I asked around on LuLa, but no one has explained what’s going on with Lightroom. Therefore, I’m now exporting the test images from Lightroom as renamed versions of the original raw files, and I’ve rewritten my Matlab code to call DCRAW for conversions.

All this makes a difference in the results. More soon.

The Last Word

← Sharpness testing, part 6 Sharpness testing, part 8 →

Comments

  1. Iliah Borg says

    November 20, 2013 at 3:51 pm

    What is going on is most probably default (hidden) S-shaped tone curve, which is not exactly gamma 2.2. If so, pairs of images taken a stop apart will render different ratio between them depending on the exposure of the first: say, 1/64 power to 1/32 should show the ratio different from 1/32 to 1/16.

    Reply
    • Jim says

      November 20, 2013 at 8:42 pm

      You’re right. Thanks to others, I now know how to get close to photogrammetric results from both Lightroom PV 2010 and Iridient developer. I will post the recipes soon.

      Jim

      Reply
      • Iliah Borg says

        November 22, 2013 at 3:24 pm

        Frankly, I would stick to tools for such experiments, not to full-blown raw converters. Those converters tend to do something under the hood, and it takes time to figure out; also changes between versions may interfere.
        But of course it is interesting to compare results from the tools to the results from the raw converters.

        Reply
        • Jim says

          November 22, 2013 at 3:32 pm

          Iliah, you’re right that there’s a lot going on under the hood of the commercial products that makes it hard to sort things out sometimes. The reason I was trying to use the common raw converters was to make it easier for others to duplicate my results. I realize that that’s somewhat misguided in this case, since the viewer would need some kind of programming skills to duplicate my Matlab work.

          There was a benefit for me to using DCRAW; I’d never used it before, and now it’s part of my bag of tricks.

          Thanks for your support on this and other projects,

          jim

          Reply
          • Iliah Borg says

            November 23, 2013 at 7:24 pm

            IMHO interfacing Matlab to libraw and libgphoto may offer some additional convenience for this kind of experimentation. As you are already calling dcraw from Matlab, maybe first to add gphoto2 to control the cameras remotely.

            Reply

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

May 2025
S M T W T F S
 123
45678910
11121314151617
18192021222324
25262728293031
« Apr    

Articles

  • About
    • Patents and papers about color
    • Who am I?
  • How to…
    • Backing up photographic images
    • How to change email providers
    • How to shoot slanted edge images for me
  • Lens screening testing
    • Equipment and Software
    • Examples
      • Bad and OK 200-600 at 600
      • Excellent 180-400 zoom
      • Fair 14-30mm zoom
      • Good 100-200 mm MF zoom
      • Good 100-400 zoom
      • Good 100mm lens on P1 P45+
      • Good 120mm MF lens
      • Good 18mm FF lens
      • Good 24-105 mm FF lens
      • Good 24-70 FF zoom
      • Good 35 mm FF lens
      • Good 35-70 MF lens
      • Good 60 mm lens on IQ3-100
      • Good 63 mm MF lens
      • Good 65 mm FF lens
      • Good 85 mm FF lens
      • Good and bad 25mm FF lenses
      • Good zoom at 24 mm
      • Marginal 18mm lens
      • Marginal 35mm FF lens
      • Mildly problematic 55 mm FF lens
      • OK 16-35mm zoom
      • OK 60mm lens on P1 P45+
      • OK Sony 600mm f/4
      • Pretty good 16-35 FF zoom
      • Pretty good 90mm FF lens
      • Problematic 400 mm FF lens
      • Tilted 20 mm f/1.8 FF lens
      • Tilted 30 mm MF lens
      • Tilted 50 mm FF lens
      • Two 15mm FF lenses
    • Found a problem – now what?
    • Goals for this test
    • Minimum target distances
      • MFT
      • APS-C
      • Full frame
      • Small medium format
    • Printable Siemens Star targets
    • Target size on sensor
      • MFT
      • APS-C
      • Full frame
      • Small medium format
    • Test instructions — postproduction
    • Test instructions — reading the images
    • Test instructions – capture
    • Theory of the test
    • What’s wrong with conventional lens screening?
  • Previsualization heresy
  • Privacy Policy
  • Recommended photographic web sites
  • Using in-camera histograms for ETTR
    • Acknowledgments
    • Why ETTR?
    • Normal in-camera histograms
    • Image processing for in-camera histograms
    • Making the in-camera histogram closely represent the raw histogram
    • Shortcuts to UniWB
    • Preparing for monitor-based UniWB
    • A one-step UniWB procedure
    • The math behind the one-step method
    • Iteration using Newton’s Method

Category List

Recent Comments

  • JimK on Goldilocks and the three flashes
  • DC Wedding Photographer on Goldilocks and the three flashes
  • Wedding Photographer in DC on The 16-Bit Fallacy: Why More Isn’t Always Better in Medium Format Cameras
  • JimK on Fujifilm GFX 100S II precision
  • Renjie Zhu on Fujifilm GFX 100S II precision
  • JimK on Fuji 20-35/4 landscape field curvature at 23mm vs 23/4 GF
  • Ivo de Man on Fuji 20-35/4 landscape field curvature at 23mm vs 23/4 GF
  • JimK on Fuji 20-35/4 landscape field curvature at 23mm vs 23/4 GF
  • JimK on Fuji 20-35/4 landscape field curvature at 23mm vs 23/4 GF
  • Ivo de Man on Fuji 20-35/4 landscape field curvature at 23mm vs 23/4 GF

Archives

Copyright © 2025 · Daily Dish Pro On Genesis Framework · WordPress · Log in

Unless otherwise noted, all images copyright Jim Kasson.