•

# Flat Frames - what is the ideal ADU value?

28 replies to this topic

### #1 WConde

WConde

Vostok 1

• topic starter
• Posts: 159
• Joined: 04 Oct 2014

Posted 04 June 2017 - 06:54 AM

I am trying to determine what is the exposure time that will yield the ideal ADU value  for my ZWO ASI 1600MM.  The camera is 12bit, therefore the maximum ADU is 4096  (2^12) and the flat frames  should be 45% of that value (approximately 1800).  I use Maxim DL which does not calculate the ADU. Therefore, I am using the mean value under the Statistics process menu on PixInsight.

Yesterday I took two flat frames  with the Luminance filter:

A 0.03 secs frame which yields a mean value of 2236
A 0.025 secs frame which yields a mean value of 1868

When I inspect them visually I think the 0.025 secs frame is a bit too dark. I am more inclined to use the 0.03 secs exposure even though the median value is a bit over 50% of the 4096 max ADU. Here is the link to the dropbox with the two frames. https://www.dropbox.....2gyk9XqUa?dl=0

If I have to choose, should I go strictly by the numbers, or should I also take into account the brightness of the frame?

• Mondeclerk likes this

### #2 bobzeq25

bobzeq25

ISS

• Posts: 21,352
• Joined: 27 Oct 2014

Posted 04 June 2017 - 07:37 AM

The most important thing.   There is little or no value in getting them "perfect".  It will not make any difference to the final image.

Difficulties arise when any area (pixel?) is out of the "linear" range, either too bright or too dim (especially possible in the dark corners of some setups).

In order to avoid those, you put the peak somewhere near the middle.  Somewhere near will work.

Want to prove the first statement?  Try two different exposures that still are reasonable, see if you can see a difference in the final image.  I'm betting you can't.

Example.  A flat of mine in a 16 bit camera.  The average is about 29000 (max 64000).  Min is 26500, max is 36000.  (I find it surprising that no hot/cold pixels are indicated).  That's fine.  Half the exposure would still be fine, there's not much vignetting.

You actually can't really examine a linear flat frame, your eyes are not adequate.  You have to stretch it, and your perception of the frame will depend heavily on the stretch.  When I visualize the above flat with ScreenTransferFunction, the corners look very dark.

Edited by bobzeq25, 04 June 2017 - 08:01 AM.

• PirateMike and Michael Covington like this

Fly Me to the Moon

• Posts: 6,111
• Joined: 24 Feb 2007
• Loc: Ellensburg, WA

Posted 04 June 2017 - 07:38 AM

The ideal ADU value for flats varies by camera.  You want about the highest ADU value that you can get before pixels either saturate or, in the case of the ASI1600 or any anti-blooming camera, you want to be just below where the pixel response goes non-linear.

You can find this yourself by taking increasingly longer exposures and graphing the number of ADUs per exposure length.  The graph should be an increasing diagonal line that starts straight, but eventually levels off.  The ideal ADU value is just before the line levels off.

Regarding using the ASI1600 with MaxIm/DL, it definitely does report the ADU.  What may be confusing is that the data is scaled to 16 bit, so MaxIm will report values much larger 4096 (basically the raw value from the camera sensor is multiplied by 16 when displayed in MaxIm).

I've not actually done the graphing exercise yet with my ASI1600, but I've had good results by taking flats to 30,000 ADU (as reported by MaxIm).  I tried 40,000, but found that to be a bit too much.  To make that determination, I used another technique that you can use to verify that the flat is good.  Specifically, I looked at the histogram.  With a 30,000 ADU target, the histogram has the right shape and is symmetrical around 30,000 ADU.  With a 40,000 ADU target, the histgram was not symmetrical and was a bit flattened above the 40,000 ADU peak.

I hope that this helps,

• wes, Merc, PirateMike and 5 others like this

### #4 Jon Rista

Jon Rista

ISS

• Posts: 24,340
• Joined: 10 Jan 2014

Posted 04 June 2017 - 01:31 PM

Generally speaking, flats with a histogram peak between 1/3 and 1/2 the maximum ADU range of the camera are ideal. Note that this is the ADU range of the camera...not every camera supports 65535 ADU (i.e. the QSI6120 caps out at ~50000 ADU in it's high gain mode, and only ~32000 ADU in low gain mode! You would want 1/3 to 1/2 THAT range, not 1/3 to 1/2 of 65535!)

To be more specific. With flats, you want the entire range of the signal to fit within the linear range of the sensor. That means the darkest pixels should be well above the read noise floor, while the brightest pixels are well below the max ADU, ideally below the point where the sensor starts to go non-linear. It seems the linearity of the ASI1600 is actually quite good, so you don't have to worry too much about it.

With the ASI1600MM-C I've found that 20-25k work quite well. Because the read noise is so low, you don't really need to push the flats out beyond the 50% ADU count level, and should generally avoid it.

One thing regarding the ASI1600 cameras. They seem to have some strange behavior with the bias level with very short exposures. I recently tested and plotted various short exposures:

I have found that ideal performance generally starts at 0.2 second exposures...below that, and things tend to fluctuate a lot, and there is a drop in median level for some reason. I recommend avoiding exposures shorter than 0.2 seconds for anything...bias and flat frames included.

• happylimpet, xb39, SnowSailor and 1 other like this

### #5 vdb

vdb

Surveyor 1

• Posts: 1,567
• Joined: 08 Dec 2009

Posted 05 June 2017 - 04:06 AM

Generally speaking, flats with a histogram peak between 1/3 and 1/2 the maximum ADU range of the camera are ideal. Note that this is the ADU range of the camera...not every camera supports 65535 ADU (i.e. the QSI6120 caps out at ~50000 ADU in it's high gain mode, and only ~32000 ADU in low gain mode! You would want 1/3 to 1/2 THAT range, not 1/3 to 1/2 of 65535!)

To be more specific. With flats, you want the entire range of the signal to fit within the linear range of the sensor. That means the darkest pixels should be well above the read noise floor, while the brightest pixels are well below the max ADU, ideally below the point where the sensor starts to go non-linear. It seems the linearity of the ASI1600 is actually quite good, so you don't have to worry too much about it.

With the ASI1600MM-C I've found that 20-25k work quite well. Because the read noise is so low, you don't really need to push the flats out beyond the 50% ADU count level, and should generally avoid it.

One thing regarding the ASI1600 cameras. They seem to have some strange behavior with the bias level with very short exposures. I recently tested and plotted various short exposures:

I have found that ideal performance generally starts at 0.2 second exposures...below that, and things tend to fluctuate a lot, and there is a drop in median level for some reason. I recommend avoiding exposures shorter than 0.2 seconds for anything...bias and flat frames included.

This is even noted in de QHY163 manual, one need to take "longer" bias frames, I settled for 0.5.

On another note, can you take flats with other gain settings and calibrate these and use the master flat for other gain settings used for Lights?

/Yves

Edited by vdb, 05 June 2017 - 06:19 AM.

### #6 Nocturnal

Nocturnal

Surveyor 1

• Posts: 1,850
• Joined: 14 Sep 2005
• Loc: CT, USA

Posted 05 June 2017 - 01:57 PM

Yes you can re-use a master flat like that. A master flat is no longer related to gain and or offset because it is normalized. As long as your flat is 'good' it applies. A good flat is high SNR (lots of subs and lots of signal in each sub) and is based on linear subs. Both points are equally important. All the noise in your flat is added to your image squared and what is worse is that where you really need your flat  in the dim outer edges you are dividing the noisiest area of the image with the noisiest area of the flat. If your subs aren't linear then you will 'bend' your image and it will not look flattened in severe cases. In subtle cases it will end up distorting the brightness relations between different areas of your image and this may show during processing.

Anyway, I don't think there is much need to mess with gain once you've decided on a setting that works for you. But if you do fiddle with gain a lot then you do not need to redo your flats each time. Either use the master flat or keep the correct dark flats with your flats.

• 42itous1 likes this

### #7 Nocturnal

Nocturnal

Surveyor 1

• Posts: 1,850
• Joined: 14 Sep 2005
• Loc: CT, USA

Posted 05 June 2017 - 01:58 PM

Generally speaking, flats with a histogram peak between 1/3 and 1/2 the maximum ADU range of the camera are ideal. Note that this is the ADU range of the camera...not every camera supports 65535 ADU (i.e. the QSI6120 caps out at ~50000 ADU in it's high gain mode, and only ~32000 ADU in low gain mode! You would want 1/3 to 1/2 THAT range, not 1/3 to 1/2 of 65535!)

To be more specific. With flats, you want the entire range of the signal to fit within the linear range of the sensor. That means the darkest pixels should be well above the read noise floor, while the brightest pixels are well below the max ADU, ideally below the point where the sensor starts to go non-linear. It seems the linearity of the ASI1600 is actually quite good, so you don't have to worry too much about it.

With the ASI1600MM-C I've found that 20-25k work quite well. Because the read noise is so low, you don't really need to push the flats out beyond the 50% ADU count level, and should generally avoid it.

One thing regarding the ASI1600 cameras. They seem to have some strange behavior with the bias level with very short exposures. I recently tested and plotted various short exposures:

I have found that ideal performance generally starts at 0.2 second exposures...below that, and things tend to fluctuate a lot, and there is a drop in median level for some reason. I recommend avoiding exposures shorter than 0.2 seconds for anything...bias and flat frames included.

Yes I'm pretty sure I posted a chart like this some time back. Very odd behavior indeed.

### #8 Jon Rista

Jon Rista

ISS

• Posts: 24,340
• Joined: 10 Jan 2014

Posted 05 June 2017 - 02:03 PM

I thought it was a fluke at first, then I ran the tests a couple dozen times and the median issue was quite consistent. The mean varies a bit, but for the most part both seem to flatten out at 0.2s. The truly curious thing is the spike in mean and median level at minimum exposure...I really don't understand that.

### #9 PirateMike

PirateMike

Gemini

• Posts: 3,049
• Joined: 27 Sep 2013
• Loc: A Green Dot On A Blue Sea

Posted 05 June 2017 - 03:54 PM

All this information is good to know.

Everyone with a 1600MM on CN should be thankful for all the work and sharing that you guys have done.

I know that I am very grateful.

Edited by PirateMike, 05 June 2017 - 03:54 PM.

• NMCN, okiedrifter, rkayakr and 4 others like this

### #10 astrnmr

astrnmr

Lift Off

• Posts: 11
• Joined: 22 Mar 2012
• Loc: Duenweg MO

Posted 08 June 2017 - 12:56 PM

Hey folks. I've been working on flats for the QHY163M (ASI1600) and have found that the camera has a full well capacity of 18-20,000. At 0 gain it has an e-/ADU value of 0.26. When using the CCD flats calculator found at http://www.telescope...atfieldcalc.htm I get a read value of 26,215 as the recommended flat value. Regardless of which gain setting I use, it still shows the same value of 26,215 as long as the e-/ADU value is adjusted correctly.

Not sure if that will help but it's what I have found.

• josephuy0420 likes this

### #11 steven_usa

steven_usa

Viking 1

• Posts: 960
• Joined: 06 May 2014
• Loc: Texas

Posted 09 July 2017 - 12:31 PM

Hey folks. I've been working on flats for the QHY163M (ASI1600) and have found that the camera has a full well capacity of 18-20,000. At 0 gain it has an e-/ADU value of 0.26.

In the ASI1600 manual ( https://astronomy-im...1600 Manual.pdf )  Page 9 has this Gain chart (and other charts).

With my own ASI1600MC-C (note: OSC/color version, not the MM), I can match most of their charts....

At 0 Gain/10 Offset, using BasicCCDParameters in PI, I get the following:  (there are ranges since it is for each of GRBG channels)

full well (19742-20291 e)                          ASI manual = 20k  e-
gain      (4.821-4.955  e/ADU)                   ASI manual = 5   e-/ADU
DR        (5711-5981 steps)                       ASI manual = 12.5 steps
read noise  (3.311-3.553 e)                       ASI manual = 3.6 e- rms

(left values from PixInsight BasicCCDParameters)

So my questions are:

1) is there a units difference in Dynamic Range between PI and the ASI manual?  re:  ~5800 vs 12.5 steps   (DR does mean Dynamic Range, right?)

2) @astrnmr:   why is your 0 gain e-/ADU number 0.26, while I'm showing ~5 ?  (I assume some kind of units difference also?)

Edited by steven_usa, 09 July 2017 - 01:56 PM.

### #12 steven_usa

steven_usa

Viking 1

• Posts: 960
• Joined: 06 May 2014
• Loc: Texas

Posted 09 July 2017 - 12:44 PM

...
I have found that ideal performance generally starts at 0.2 second exposures...below that, and things tend to fluctuate a lot, and there is a drop in median level for some reason. I recommend avoiding exposures shorter than 0.2 seconds for anything...bias and flat frames included.

Oh, even for bias frames?   So ASI claims fastest exposure is 32usec (microseconds, or 0.000032 seconds), right?  You're chart is only going down to 0.001 (I'm assuming seconds?).   But anyhow, really, some folks are trying 0.2 sec exposures as bias frames (for the ASI1600)?  Hmm, I'll give it a try.

### #13 PirateMike

PirateMike

Gemini

• Posts: 3,049
• Joined: 27 Sep 2013
• Loc: A Green Dot On A Blue Sea

Posted 09 July 2017 - 01:10 PM

I have been using 0.3 seconds without any issues that I can see.

• 42itous1 likes this

### #14 PirateMike

PirateMike

Gemini

• Posts: 3,049
• Joined: 27 Sep 2013
• Loc: A Green Dot On A Blue Sea

Posted 09 July 2017 - 01:12 PM

Here are results that I have gotten from 0.3 seconds Bias and 30,000 ADU Flats.

• steven_usa, 42itous1 and josephuy0420 like this

### #15 Jon Rista

Jon Rista

ISS

• Posts: 24,340
• Joined: 10 Jan 2014

Posted 09 July 2017 - 01:52 PM

Hey folks. I've been working on flats for the QHY163M (ASI1600) and have found that the camera has a full well capacity of 18-20,000. At 0 gain it has an e-/ADU value of 0.26.

In the ASI1600 manual ( https://astronomy-im...1600 Manual.pdf )  Page 9 has this Gain chart (and other charts).

With my own ASI1600MC-C (note: OSC/color version, not the MM), I can match most of their charts.... At 0 Gain/10 Offset, using BasicCCDParameters in PI, I get the following:  (there are ranges since it is for each of GRBG channels)

(PixInsight BasicCCDParameters)

full well (19742-20291 e)                          ASI manual = 20k  e-
gain      (4.821-4.955  e/ADU)                   ASI manual = 5   e-/ADU
DR        (5711-5981 steps)                       ASI manual = 12.5 steps
read noise  (3.311-3.553 e)                       ASI manual = 3.6 e- rms

So my questions are:

1) is there a units difference in Dynamic Range between PI and the ASI manual?  re:  ~5800 vs 12.5 steps   (DR does mean Dynamic Range, right?)

2) @astrnmr:   why is your 0 gain e-/ADU number 0.26, while I'm showing ~5 ?  (I assume some kind of units difference also?)

1) The manual says 12.5 stops, which is different than steps. To get 12.5 stops you need about 5623 steps.

2) He was measuring in 16-bit, rather than 12-bit.

### #16 Jon Rista

Jon Rista

ISS

• Posts: 24,340
• Joined: 10 Jan 2014

Posted 09 July 2017 - 01:53 PM

...
I have found that ideal performance generally starts at 0.2 second exposures...below that, and things tend to fluctuate a lot, and there is a drop in median level for some reason. I recommend avoiding exposures shorter than 0.2 seconds for anything...bias and flat frames included.

Oh, even for bias frames?   So ASI claims fastest exposure is 32usec (microseconds, or 0.000032 seconds), right?  You're chart is only going down to 0.001 (I'm assuming seconds?).   But anyhow, really, some folks are trying 0.2 sec exposures as bias frames (for the ASI1600)?  Hmm, I'll give it a try.

Yes, for bias I recommend an exposure of 0.2s. This is due to inconsistent behavior in the biases with shorter exposures.

### #17 steven_usa

steven_usa

Viking 1

• Posts: 960
• Joined: 06 May 2014
• Loc: Texas

Posted 09 July 2017 - 02:12 PM

Here are results that I have gotten from 0.3 seconds Bias and 30,000 ADU Flats.

@PirateMike:  can you explain your 12 and 16 bit RN columns?  They reverse in scale from the "original" RN column that is in e-.

Also, to me "30,000 ADU" is confusing.  Like the OP states, 12-bit ASI1600 has native "range' of 0-4095.  I suppose then it should be obvious when you say "30,000 ADU" you mean viewed from a 16-bit scale? (I mean, it's just implied since the ASI output is scaled to 16-bit FITS file?).   Also, "30,000 ADU Flat" implicitly means peak/max, or is it average?

@Jon Rista:  Thanks for those clarifications!   I totally misread "stops"   And gotcha on the bit-scale (I re-ran BasicCCDParameter with 16 bit instead, and yeah my ~5 ADU/e- drops to ~0.3).  So, we have to keep in mind of the scale in whatever application(s) we're using (like the "Integer Range" in PixInsight when we pop open a .FIT flats and values).

Edited by steven_usa, 09 July 2017 - 02:15 PM.

• PirateMike likes this

### #18 PirateMike

PirateMike

Gemini

• Posts: 3,049
• Joined: 27 Sep 2013
• Loc: A Green Dot On A Blue Sea

Posted 09 July 2017 - 11:30 PM

The 12 and 16 bit columns would be my target for minimum median exposure which would be 20xRN. I have it in 12bit because I like that scale, I converted the 12bit to 16bit because that is the readout scale for SGP.

30,000 ADU Flats are in 16bit because that is what SGP outputs. Is it max or average? Not sure, I would have to check SGP.

https://www.cloudyni...-exposed-right/

• mellowamoya likes this

### #19 PhotonHunter1

PhotonHunter1

Viking 1

• Posts: 855
• Joined: 19 Mar 2015
• Loc: Northwest Suburbs of Chicago

Posted 29 September 2017 - 08:57 AM

Generally speaking, flats with a histogram peak between 1/3 and 1/2 the maximum ADU range of the camera are ideal. Note that this is the ADU range of the camera...not every camera supports 65535 ADU (i.e. the QSI6120 caps out at ~50000 ADU in it's high gain mode, and only ~32000 ADU in low gain mode! You would want 1/3 to 1/2 THAT range, not 1/3 to 1/2 of 65535!)

To be more specific. With flats, you want the entire range of the signal to fit within the linear range of the sensor. That means the darkest pixels should be well above the read noise floor, while the brightest pixels are well below the max ADU, ideally below the point where the sensor starts to go non-linear. It seems the linearity of the ASI1600 is actually quite good, so you don't have to worry too much about it.

With the ASI1600MM-C I've found that 20-25k work quite well. Because the read noise is so low, you don't really need to push the flats out beyond the 50% ADU count level, and should generally avoid it.

One thing regarding the ASI1600 cameras. They seem to have some strange behavior with the bias level with very short exposures. I recently tested and plotted various short exposures:

I have found that ideal performance generally starts at 0.2 second exposures...below that, and things tend to fluctuate a lot, and there is a drop in median level for some reason. I recommend avoiding exposures shorter than 0.2 seconds for anything...bias and flat frames included.

Is the Flats Mean value in SGP displayed in 12bit or 16bit? I thought I read somewhere that for Flats it was 12bit but lights were 16bit. The reason I ask is when I shoot my lights with a Mean value of 1500 (assuming this is a 12bit value) they appear consistent to the edges. If I aim for 21000-24000 Mean value, I get concentric rings in the corners.

### #20 Stelios

Stelios

Voyager 1

• Posts: 10,218
• Joined: 04 Oct 2003
• Loc: West Hills, CA

Posted 29 September 2017 - 10:53 AM

It is displayed in 16-bit. To verify, expose for a few seconds--you'll get values close to 65,535

### #21 Jon Rista

Jon Rista

ISS

• Posts: 24,340
• Joined: 10 Jan 2014

Posted 29 September 2017 - 11:58 AM

SGP always reads 16-bit. So for ASI1600 flats, you want something in the 18-30k range. If you were measuring 1500, then those were very under-exposed flats.

### #22 PhotonHunter1

PhotonHunter1

Viking 1

• Posts: 855
• Joined: 19 Mar 2015
• Loc: Northwest Suburbs of Chicago

Posted 01 October 2017 - 12:25 PM

SGP always reads 16-bit. So for ASI1600 flats, you want something in the 18-30k range. If you were measuring 1500, then those were very under-exposed flats.

Here is a screen shot of the FITS header for my Blue Flat in PI. Is the BZERO figure the ADU number (32768)? If not, is there a way to determine the ADU number in PI?

### #23 Jon Rista

Jon Rista

ISS

• Posts: 24,340
• Joined: 10 Jan 2014

Posted 01 October 2017 - 12:42 PM

SGP always reads 16-bit. So for ASI1600 flats, you want something in the 18-30k range. If you were measuring 1500, then those were very under-exposed flats.

Here is a screen shot of the FITS header for my Blue Flat in PI. Is the BZERO figure the ADU number (32768)? If not, is there a way to determine the ADU number in PI?

BZERO is something different. It identifies the black point for the data, and when it is offset to 32k, it's done sort of like a pedestal to allow for negative values. In scientific contexts, BZERO may also allow for special pixel values, markers for certain kinds of things..say dust motes, etc.

I'm surprised BZERO is 32k in your FITS. I wonder why SGP is doing that....it is not necessary, for sure.

### #24 PhotonHunter1

PhotonHunter1

Viking 1

• Posts: 855
• Joined: 19 Mar 2015
• Loc: Northwest Suburbs of Chicago

Posted 01 October 2017 - 04:41 PM

SGP always reads 16-bit. So for ASI1600 flats, you want something in the 18-30k range. If you were measuring 1500, then those were very under-exposed flats.

Here is a screen shot of the FITS header for my Blue Flat in PI. Is the BZERO figure the ADU number (32768)? If not, is there a way to determine the ADU number in PI?

BZERO is something different. It identifies the black point for the data, and when it is offset to 32k, it's done sort of like a pedestal to allow for negative values. In scientific contexts, BZERO may also allow for special pixel values, markers for certain kinds of things..say dust motes, etc.

I'm surprised BZERO is 32k in your FITS. I wonder why SGP is doing that....it is not necessary, for sure.

Is there a setting in SGP that needs to be changed?

### #25 Jon Rista

Jon Rista

ISS

• Posts: 24,340
• Joined: 10 Jan 2014

Posted 01 October 2017 - 04:50 PM

SGP always reads 16-bit. So for ASI1600 flats, you want something in the 18-30k range. If you were measuring 1500, then those were very under-exposed flats.

Here is a screen shot of the FITS header for my Blue Flat in PI. Is the BZERO figure the ADU number (32768)? If not, is there a way to determine the ADU number in PI?

BZERO is something different. It identifies the black point for the data, and when it is offset to 32k, it's done sort of like a pedestal to allow for negative values. In scientific contexts, BZERO may also allow for special pixel values, markers for certain kinds of things..say dust motes, etc.

I'm surprised BZERO is 32k in your FITS. I wonder why SGP is doing that....it is not necessary, for sure.

Is there a setting in SGP that needs to be changed?

I dunno. As long as the subs look ok in PI, i wouldn't worry about it. Ignore BZERO unless you end up with very bright subs in PI (without stretching).

• PhotonHunter1 likes this

## Recent Topics

 Cloudy Nights LLC Cloudy Nights Sponsor: Astronomics