Jump to content

  •  

CNers have asked about a donation box for Cloudy Nights over the years, so here you go. Donation is not required by any means, so please enjoy your stay.

Photo

Pre-demosaic Median stack and render to new raw file.

  • Please log in to reply
1 reply to this topic

#1 Waveluke

Waveluke

    Lift Off

  • -----
  • topic starter
  • Posts: 1
  • Joined: 10 Nov 2018

Posted 10 November 2018 - 01:02 PM

Hello, I would like to see if anyone has any idea of how to median stack raw files before demosaicing, and render a new raw file, preferably higher in bit depth, yet reads like the original file by raw processors.

 

To explain the intended use, I have cameras, that have a mix of fixed pattern noise (line noise and amp glow) as well as random noise in the deep shadows. I know Rawtherapee (my raw processor of choice) has a dark frame noise subtraction feature, and know how to use it, but it is more useful for hot pixels for low ISO long exposure than high ISO with fixed pattern noise. This is because if there is enough random noise that if I were to use a single dark frame, it would cancel out the fixed pattern noise, but increase the variance of the random noise, thereby making the signal to noise ratio poorer. The solution to this is to mean/median the dark frames, but if the subtraction is done after the raw develop, then it potentially raises issues with the log transform, color matrix and other non-linearities that make the subtraction less accurate. Higher bit depth of the new raw file might be needed, as the extreme shadows information that I am trying to make use of is likely between the steps of the linear 12 bit file, but is dithered by the random noise, but I am not sure this will be 100% needed.

 

Since this would be used for cinema raw videography with the BMPCC, with thousands of light frames to render, doing the median of multiple dark frames for each raw light frame would be excessively computationally intensive, and would prefer to create a master raw dark frame that was born out of the mean/median of multiple dark frame, that I could use to subtract from each video frame.



#2 whwang

whwang

    Gemini

  • *****
  • Posts: 3,134
  • Joined: 20 Mar 2013

Posted 11 November 2018 - 09:14 AM

You can definitely stack dark frames without debayerizing them. That’s very standard in stacking programs.

The problem is to save the dark-subtracted image to raw format so you can trick whatever post-processing program you use. I think the best hope is the DNG format. I don’t know any program that can save an astro-calibrated image into NEF or CR2 or PEF. These are all proprietary formats. But DNG is an open format and it’s perfectly raw.

So, the question becomes, which program can save an image as DNG? Unfortunately, I don’t know.

Cheers,
Wei-Hao


CNers have asked about a donation box for Cloudy Nights over the years, so here you go. Donation is not required by any means, so please enjoy your stay.


Recent Topics






Cloudy Nights LLC
Cloudy Nights Sponsor: Astronomics