Pages: [1]   Go Down

Author Topic: Impeccable Lens Cast (Flat field) correction!  (Read 9051 times)

MichaelEzra

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 1146
    • https://www.michaelezra.com
Impeccable Lens Cast (Flat field) correction!
« on: February 05, 2011, 12:05:53 am »

I would like to share with everyone my limitless joy of using a new feature that has been recently added to RawTherapee (a powerful open source raw processor software www.rawtherapee.com).
As an owner of Mamiya ZD, I've had griefs over the lens cast issues, as, I am sure, many of the medium format users.

The Flat Field correction tool in RawTherapee allows to fully correct the lens cast issue for any of the currently supported cameras and for any, even misaligned lens.
Below are a few images illustrating the results of using this tool.
Correction is based on a reference Flat Field raw image - a defocused photograph of a uniformly lit uniformly colored and toned subject, such as a matte piece of white paper.
Flat field data is blurred during the correction process using a user-selectable blur radius.
The calculations are performed on linear raw image data; algorithm is smart to normalize the white balance of the raw image (in the spot of the automatically located projection of the optical center even for misaligned lens mounts).

This allows for the same flat field file to be reused for correction of images shot under varying lighting conditions.

Corrections are done on the fly, without intermediate steps involving copies of the original file; original raw file can be flat-field corrected during the RawTherapee development process itself.

Flat Fields are characterized by the Camera Make & Model, Lens, aperture and Date&Time of the image.
RawTherapee is able to automatically select a closest match from a collection of Flat Field raw files stored in a dedicated folder.

My sincere thanks to Emil Martinec, who wrote the flat field correction algorithm, Fabio Suprani for core of the the auto-selection algorithm and to the entire RawTherapee development team!
Logged

MichaelEzra

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 1146
    • https://www.michaelezra.com
Re: Impeccable Lens Cast (Flat field) correction!
« Reply #1 on: February 05, 2011, 12:06:53 am »

preferences panel showing the selection of the Flat Fields folder
Logged

fredjeang

  • Guest
Re: Impeccable Lens Cast (Flat field) correction!
« Reply #2 on: February 05, 2011, 05:38:52 am »

Hi Michael,

I went into the RT page. I see that you are using the Beta 3 version but the only downloadable that I see is the 2.4.1
Where did you get the 3 ?

Thanks
Logged

ErikKaffehr

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 11311
    • Echophoto
Re: Impeccable Lens Cast (Flat field) correction!
« Reply #3 on: February 05, 2011, 05:53:28 am »

Hi,

Right now I think you need to build it yourself from downloadable source code


Best regards
Erik


Hi Michael,

I went into the RT page. I see that you are using the Beta 3 version but the only downloadable that I see is the 2.4.1
Where did you get the 3 ?

Thanks
Logged
Erik Kaffehr
 

MichaelEzra

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 1146
    • https://www.michaelezra.com
Re: Impeccable Lens Cast (Flat field) correction!
« Reply #4 on: February 05, 2011, 08:11:27 am »

You can download the very latest Win32 build of the (not very) unstable branch from here:
http://www.mediafire.com/?eumwaeh64axdbtd
(2011/02/05 changeset 6d85fe5fe1ba)
No installation required - unzip and run rt.exe
« Last Edit: February 05, 2011, 08:19:25 am by MichaelEzra »
Logged

Doug Peterson

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 4210
    • http://www.doug-peterson.com
Re: Impeccable Lens Cast (Flat field) correction!
« Reply #5 on: February 05, 2011, 10:49:05 am »

Have you run a comparison against the Lens Cast Correction which has been fine-tuned for several years in Capture One Pro? In case you missed it they opened that tool up to all raw files (rather than just Phase One raw files) last year. It includes light fall off, color cast, and automatic dust removal.

Many Mamiya ZD users also use Capture One as their go-to raw processor after comparing the noise, color, and highlight/shadow recovery (particularly shadow color noise) between C1 and other raw processors.

Doug Peterson (e-mail Me)
__________________

Head of Technical Services, Capture Integration
Phase One Partner of the Year
Leaf, Leica, Cambo, Arca Swiss, Canon, Apple, Profoto, Broncolor, Eizo & More

National: 877.217.9870  |  Cell: 740.707.2183
Newsletter | RSS Feed
Buy Capture One 6 at 10% off

fredjeang

  • Guest
Re: Impeccable Lens Cast (Flat field) correction!
« Reply #6 on: February 05, 2011, 12:51:54 pm »

Thanks Michael.
Logged

archivue

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 417
Re: Impeccable Lens Cast (Flat field) correction!
« Reply #7 on: February 07, 2011, 03:43:43 am »

"Have you run a comparison against the Lens Cast Correction which has been fine-tuned for several years in Capture One Pro? In case you missed it they opened that tool up to all raw files (rather than just Phase One raw files) last year. It includes light fall off, color cast, and automatic dust removal..."

but with the current update it doesn't work for leaf back... grgrggrgr
Logged

yaya

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 1254
    • http://yayapro.com
Re: Impeccable Lens Cast (Flat field) correction!
« Reply #8 on: February 07, 2011, 05:26:04 am »

"Have you run a comparison against the Lens Cast Correction which has been fine-tuned for several years in Capture One Pro? In case you missed it they opened that tool up to all raw files (rather than just Phase One raw files) last year. It includes light fall off, color cast, and automatic dust removal..."

but with the current update it doesn't work for leaf back... grgrggrgr

Yes it does but the files need to be shot compressed with your Aptus back (or tethered with C1)

Yair
Logged
Yair Shahar | Product Manager | Phase One - Cultural Heritage
e: ysh@phaseone.com |

bjanes

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 3387
Re: Impeccable Lens Cast (Flat field) correction!
« Reply #9 on: February 07, 2011, 09:49:34 am »

Have you run a comparison against the Lens Cast Correction which has been fine-tuned for several years in Capture One Pro? In case you missed it they opened that tool up to all raw files (rather than just Phase One raw files) last year. It includes light fall off, color cast, and automatic dust removal.

Many Mamiya ZD users also use Capture One as their go-to raw processor after comparing the noise, color, and highlight/shadow recovery (particularly shadow color noise) between C1 and other raw processors.

Doug Peterson (e-mail Me)
__________________

Head of Technical Services, Capture Integration
Phase One Partner of the Year
Leaf, Leica, Cambo, Arca Swiss, Canon, Apple, Profoto, Broncolor, Eizo & More

National: 877.217.9870  |  Cell: 740.707.2183
Newsletter | RSS Feed
Buy Capture One 6 at 10% off
ect

Doug,

The effects of lens cast on color are unfamiliar to me. I use a full frame dSLR (Nikon D3) and my widest lenses are 20 and 24 mm and I have not noted a color cast but would think that oblique rays could well have effects in 35 mm as well as MFDBs. Dust removal and falloff and nonuniform illumination can be a problem in photo-microscopy and the latter can not be corrected with the Nikon software. Martin Evening discusses use of the Divide Blend Mode in Photoshop CS5 that can use a flat field image to correct for dust and uneven illumination, but he does not mention color casts.

How well would C1 help in dealing with these problems with microscopy and wide angle lenses in 35 mm? Evening's method is cumbersome.

Regards,

Bill Janes
Logged

ejmartin

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 575
Re: Impeccable Lens Cast (Flat field) correction!
« Reply #10 on: February 07, 2011, 10:17:19 am »

I think the issue with Evening's method is that the correction should be applied in linear gamma, rather than on gamma-corrected images.  PS is way too late in the workflow for this to be done accurately; it should be done in the converter.

As for color casts, one of the things that drove the solution in RawTherapee was the behavior of Michael's ZD system, where if the center is properly white balanced the edges show a decided greenish cast.  The flat field correction eliminates that completely.  It also corrects for the seam running down the middle of the ZD sensor (not really much of a worry; it's impossible to see without hugely cranking up the contrast).  Another potential use is to correct gain-based fixed pattern noise; RT can blur the flat field image by area, vertically, horizontally, or both vertically and horizontally.  I suspect for instance (though I haven't a camera to test) that the 7D might have columnwise gain variation that would benefit from the vertically blurred flat field subtraction.  The blur can also be set to zero, so that (at the cost of an increase of sqrt[2] in photon shot noise) one can compensate for dust spots and other sensor imperfections.
Logged
emil

Bart_van_der_Wolf

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 8914
Re: Impeccable Lens Cast (Flat field) correction!
« Reply #11 on: February 07, 2011, 10:57:27 am »

How well would C1 help in dealing with these problems with microscopy and wide angle lenses in 35 mm? Evening's method is cumbersome.

Hi Bill,

It does so quite well. The unlocking of that feature adds a huge amount of usability to version 6. It would be nice if they enabled dark frame subtraction, and a combination of the two.

I recently shot a bracketed series of images for HDR tonemapping. The tonemapping of local and microcontrast also enhanced the otherwise almost invisible dust bunnies. So one day after the event I shot an LCC file (hoping that the dust hadn't migrated), and all was well. It also corrected the very slight color cast and vignetting (things that can also be a pain when stitching with little overlap) as a bonus. I could now tonemap to my heart's content without enhancing the artifacts. It beats manual spot corrections, because it is faster, more accurate, and it finds spots in busy areas which may be smooth in other images (so it doesn't require going back an forth between images to find them all).

One just needs to make sure that for the LCC the same aperture value is used, and (approximately for deep DOF) the same focal distance is used to get the same shadowing / vignetting / light fall-off. I also prefer a diffuser plate instead of a "white wall" to produce the LCC, which is also easier to do in the field with the actual shooting conditions.

Cheers,
Bart
Logged
== If you do what you did, you'll get what you got. ==

ejmartin

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 575
Re: Impeccable Lens Cast (Flat field) correction!
« Reply #12 on: February 07, 2011, 11:53:48 am »

RT has darkframe subtraction; actually it had that first, and the flat field code was modeled on it.

Just one word of caution -- RT is a work in progress, not yet a finished product.  For instance I have found substantial improvements in image quality using floating point internals, but it will take some time to convert the code from its existing short integer representation.  The user interface is a bit of a mess and needs a rework.  And it is quite possible that sidecar files will evolve in ways not backward compatible with the current alpha code.  It will likely be some months before the code stabilizes to something that one would consider using as one's default converter; but those interested should please stay tuned...
Logged
emil

MichaelEzra

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 1146
    • https://www.michaelezra.com
Re: Impeccable Lens Cast (Flat field) correction!
« Reply #13 on: February 07, 2011, 12:22:50 pm »

Have you run a comparison against the Lens Cast Correction which has been fine-tuned for several years in Capture One Pro? In case you missed it they opened that tool up to all raw files (rather than just Phase One raw files) last year. It includes light fall off, color cast, and automatic dust removal.

The last time I tried Capture One it specifically refused to support Mamiya ZD for LCC...
I tried the latest version version now and LCC seems to work well on ZD files, but requires manual selection of a profile.

Adobe team was not able to implement this into ACR per my earlier request.

Considering that I need to correct all ZD images for lens cast, I find the flat field (and also the dark frame) auto selection capabilities in RT very useful. Once all the FF and DF reference frames are consolidated in folders, RT is able automatically do the flat field and/or dark frame correction without further user input being required. Auto-selection is performed based on photographic exif data of the reference frames also including the date & time.
Logged

Doug Peterson

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 4210
    • http://www.doug-peterson.com
Re: Impeccable Lens Cast (Flat field) correction!
« Reply #14 on: February 07, 2011, 01:56:08 pm »

The effects of lens cast on color are unfamiliar to me. I use a full frame dSLR (Nikon D3) and my widest lenses are 20 and 24 mm and I have not noted a color cast but would think that oblique rays could well have effects in 35 mm as well as MFDBs. Dust removal and falloff and nonuniform illumination can be a problem in photo-microscopy and the latter can not be corrected with the Nikon software. Martin Evening discusses use of the Divide Blend Mode in Photoshop CS5 that can use a flat field image to correct for dust and uneven illumination, but he does not mention color casts.

How well would C1 help in dealing with these problems with microscopy and wide angle lenses in 35 mm? Evening's method is cumbersome.

D3 will show little or no such color cast.

This issue is only now starting to crop up on dSLRs with wide angle tilt shift lenses and very small pixel sensors. The D3 has (relatively) large pixels and is not prone (AFAIK) to any lens-based color cast in normal photographic applications.
Pages: [1]   Go Up