Learn to Take Sky Flats for Astrophotography

Flat frames are essential in astrophotography to correct optical issues like uneven illumination, vignetting, and dust particles on the optics. They are captured by photographing a uniformly lit source, such as a white screen or twilight sky. These reference images help remove imperfections during the processing workflow by dividing the original images by the flat frames, resulting in cleaner, more accurate final images. Flat frames are crucial calibration tools that enhance image quality, making astrophotography more visually appealing and accurate.

One of the fastest, cheapest, and easiest ways to capture flat frames is to simply use the sky. If you use N.I.N.A. (Nighttime Imaging ‘N” Astrophotography) to control your imaging rig, you can use the integrated processes to incorporate sky flats into your imaging sequence.

Twilight Sky Flats

N.I.N.A. includes an instruction that you can place within your imaging sequence called Twilight Sky Flats (Instruction – Flat Device – Twilight Sky Flats).

The instruction automates the sky flat capture for you based on the defined parameters:

  • Minimum and Maximum Exposure: These two parameters defines the boundary for your flat frame exposure duration. The defaults often work well, but you might need to modify the maximum exposure parameter based on your filters. When the flat frame instruction set starts, N.I.N.A. will capture a test image halfway between your min and max values and calculate the histogram mean value.
  • Histogram Mean Target and Mean Tolerance: These two parameters determines an acceptable brightness level for the image. The Mean Target is the brightness level goal (default of 50% works well), while the Mean Tolerance defines how far away from the target is acceptable.
  • Dither: Defines how many images should be captured before the telescope slightly adjusts location. This is often not needed with sky flats.
  • Amount: The number of flats to capture. Capture at least 25 images.
  • Filter: You need to create flat frames for each filter based on your captured light frames.
  • Binning: The binning parameters needs to be the same that you used to capture your light frames.
  • Gain and Offset: These parameters should be the same values you use to capture your light frames.

When the Twilight Sky Flat instruction runs,

  1. First, N.I.N.A. captures test images using an exposure time halfway between your minimum and maximum exposure values to calculate the histogram mean. If the mean is outside the acceptable range (defined by your target and tolerance), the exposure time is adjusted, and the test image is recaptured. This process continues until the histogram mean falls within the defined tolerance range.
  2. Once the histogram values are within the acceptable range, flat frames are captured based on your specified settings, such as the number of frames, filter, binning, gain, and offset.
  3. After each capture, the histogram mean is recalculated to ensure it remains within the desired tolerance. If the mean falls out of tolerance, new test images are taken to automatically adjust the exposure duration before restarting flat frame capture

The process of defining and using the histogram mean and tolerance values allows the instruction set to automatically adjust based on changing sky brightness levels.

Best Practices for Sky Flats

Here are a few tips to help you get the best results when taking sky flats:

  • Timing: Wait 20-30 minutes after sunrise before starting your sky flats. If you begin too early, you risk capturing stars in your flats. Additionally, the sky’s brightness changes rapidly at sunrise, which requires adjusting your exposure time accordingly.
  • Telescope Orientation: Point your telescope at the zenith, the point directly overhead. This position typically offers the best conditions for sky flats, providing more even lighting, less atmospheric distortion, and more consistent exposure times. Once your telescope is pointing at the meridian, make sure to stop tracking.
  • Frequency: It’s often recommended to take flats after each imaging session, especially if you set up and tear down your rig every night. However, if your setup is in a permanent location, you may only need to take flats every 1-2 months.
  • Mean Tolerance: Setting the mean tolerance value too low can lead to frequent exposure adjustments after every 1-2 captures. While this isn’t necessarily harmful, it can significantly increase the time required to capture all your flat frames. To save time, consider increasing the tolerance value to 25-40%. This will allow N.I.N.A. to capture more flat frames before needing to adjust exposures. When the flats are integrated into a master flat, any brightness variations will be averaged out.
  • Park and Wait: After completing your last deep-sky exposure (just before dawn) and before taking sky flats (20-30 minutes after sunrise), it’s best to park your telescope. If you simply stop tracking after the last deep-sky exposure, the telescope may end up pointing upward, making it prone to dew or frost buildup. Parking the telescope reduces the chances of this happening.
  • Meridian Flip: If your deep-sky imaging session involves a meridian flip, ensure that the flip is triggered by the target rather than being a global trigger in the sequence. If the meridian flip is set as a global trigger, the telescope may attempt to flip when it’s already pointed at the zenith during the sky flat sequence, which will fail as it won’t be able to find stars to track (since it’s already after sunrise).

These tips will help ensure that your sky flats are captured efficiently and accurately for the best calibration results.

NINA Sequence for Sky Flats

By incorporating all the best practices discussed, the following sequence provides a streamlined and efficient approach to capturing sky flats. This method ensures consistent results and minimizes the chances of errors, allowing you to make the most of your imaging sessions while maintaining accurate calibration.

When the sky flat capture sequence is complete, N.I.N.A. should move onto your Nightly Shutdown Sequence, which parks the telescope and warms the camera.