rbarbera / PlanetarySystemStacker

Produce a sharp image of a planetary system object (moon, sun, planets) from many seeing-affected frames according to the "lucky imaging" technique.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

PlanetarySystemStacker

Produce a sharp image of a planetary system object (moon, sun, planets) from many seeing-affected frames using the "lucky imaging" technique.

The program is mainly targeted at extended objects (moon, sun), but it should work as well for the planet case. A full working prototype written in Python has been finished. Results obtained in tests show at least the same image quality as the established software AutoStakkert!3.

Input to the program can be either video files or a directories containing still images. The following algorithmic steps are performed:

  • First, all frames are ranked by their overall image quality.
  • On the best frame, a rectangular patch with the most pronounced structure in x and y is identified automatically.
  • Using this patch, all frames are registered relatively to each other.
  • A mean image is computed by averaging the best frames.
  • An alignment point mesh covering the object is constructed automatically. Points, where the image is too dim, or has too little contrast or structure, are discarded.
  • For each alignment point, all frames are ranked by their local contrast in a surrounding image patch.
  • The best frames up to a given number are selected for stacking. Note that this list can be different for different points.
  • For all frames, local shifts are computed at all alignment points.
  • Using those shifts, the alignment point patches of all contributing frames are stacked into a single average image patch.
  • Finally, all stacked patches are blended into a global image.
  • After stacking is completed, the stacked image can be postprocessed (sharpened) either in a final step of the stacking workflow, or in a separate postprocessing job.

Program execution is most efficient if the image data and all intermediate results can be keept in memory. This, however, requires much RAM space. Therefore, the level of buffering can be selected in the configuration dialog, ranging from 0 (no buffering) to 4 (maximum buffering).

The program is started by executing the main program in module "planetary_system_stacker.py".

The program uses array operations (OpenCV, numpy) wherever possible to speed up execution. Qt5 is used as the GUI toolkit.

A discussion platform for all issues concerning this software project has been created in the context of the German amateur astronomy forum Astronomie.de. Currently this forum is in German language only, but an English branch is in preparation.

About

Produce a sharp image of a planetary system object (moon, sun, planets) from many seeing-affected frames according to the "lucky imaging" technique.


Languages

Language:Python 85.1%Language:Rich Text Format 14.9%