Bin Module Use

Notes from users, documentation addendums.

Bin Module Use

Postby Guy » Wed Jan 25, 2017 11:23 am

Here are some notes relating to using this module. It is not the only way to use the module and experimentation is encouraged.
Please let me know if anyone sees any errors or has any additional advice they think helpful.
I will update this post as needed.
To easily access similar notes on the other StarTools modules see StarTools Main Window Use.

Bin Module

Purpose:
    - To reduce the resolution of the image and to improve the signal to noise ratio (SNR)
Description:
For a general overview see Bin: Trade Resolution for Noise Reduction.
The Bin algorithm trades off resolution for an improved Signal-to-Noise Ratio (SNR) - it doesn't just change the scale.
The algorithm yields correct results even at arbitrary sizes (not just powers of 2) by applying an anti-aliasing filter at the proper cutoff frequency corresponding to the new image size.

Useful Sources
There is a good general description of the Bin module here.
The Unofficial guide is also a good source of help. It relates to version 1.3.5 so there may have been some changes. The notes below relate to StarTools version 1.4.

When to use:
  • After initial global stretch (AutoDev).
  • When you want to improve the SNR - if the image is oversampled.
  • If the data is noisy you may want to bin to improve the SNR - even if the image is not oversampled and you will lose some detail.
Example Workflow:
AutoDev-{Band/Lens}-Bin-Crop-Wipe-AutoDev(or Develop)-{Decon/Sharp/Contrast/HDR/Flux/Life}-Color-{Filter}-Denoise-{Layer/Magic/Heal/Repair/Synth}
Key: {...} optional modules

Method:
This is a way of using the module which should give good results in most cases:
  1. Load the module - this automatically Bins the image by 50%.
  2. Zoom in on the image to see if the image is still oversampled. See the background notes on oversampling.
  3. Try different levels of binning until the smallest features occupy only a couple of pixels on their minor axis.
  4. Leave a bit of oversampling if you want to use the Decon module later.
  5. 'Keep' when finished.
What result to look for:
  • Is the image still oversampled? For a description of oversampling see below.
  • Zoom in and look at smallest stars when unbinned - are they spread over 3 or more pixels in any direction? - if they are the image is oversampled - the combination of the seeing, optics, focus and camera have lead to this spreading.
  • Zoom out - make sure the reduction in resolution hasn't caused the more prominent stars to lose their roundness and other detail in the brighter parts of the image to become angular and 'boxy'.
After Use:
  • You may want to use the Lens Module followed by the Crop module.
Description of Controls:
Presets
Define a preset amount of binning.
  • 25% - Reduce image resolution to 25% of what it was - Improve SNR by approx. 4x
  • 35% - Reduce image resolution to 35% of what it was - Improve SNR by approx. 2.9x
  • 50% - Reduce image resolution to 50% of what it was - Improve SNR by approx. 2x
  • 71% - Reduce image resolution to 71% of what it was - Improve SNR by approx. 1.7x
These SNR figures assume negligible read noise.

Scale
Scale sets the reduction in resolution (e.g. 25% - the number of pixels along one axis has been reduced to 25%)
  • Also shown is the corresponding noise reduction factor (1600.00%) and the bit depth improvement (+4.00 bits)
  • 100% = no reduction in scale, 0% noise reduction factor, 0 bit depth improvement
  • Default is (scale/noise reduction 50%)/(400.0%)/(+2.00 bits)
Background Notes
Oversampling
  • An image is oversampled if the image resolution is greater than the image detail available. The extra resolution doesn't contribute to improved detail.
  • For example, if you print a 2x oversampled image and print the same image after 2x binning (so it is not oversampled) enlarged to the same size - the detail visible will be the same in both.
  • As a general rule, if the smallest unsaturated star occupies 3 or more pixels in any direction you can bin the data some more without losing detail.
    • This rule applies to monochrome cameras and also for OSC/DLSR cameras where the image has been stacked with a sufficient number of sub-frames which have been dithered.
    • The rule needs to be adjusted for less good OSC/DSLR images. At the extreme, for a single OSC/DSLR sub-frame, a star will be spread across a minimum of 3 pixels by the debayering algorithm - so the rule in this case if a star occupied 3 pixels it would no longer be oversampled.
  • The major benefit of oversampling is that, using the right algorithm, you can bin it to improve the signal to noise ratio (SNR) of the image.
  • It can also be used by deconvolution routines - so it may be beneficial to leave a bit of oversampling for use by the Decon module.
  • If we assume we have perfect focus and optics then to get the best information from the seeing we need to have an image scale of about half the seeing.
  • Image scale (arcseconds per pixel) = 206 * camera pixel size (microns) / Focal length (mm)
    • For many DSLR camera and telescope combinations the image scale is around 1 arcsec/pixel or less.
      E.g. Canon 1100D (5.2um pixels) - with 200mm f5 reflector = 1.07 arcsec/pixel, with 80mm f6 refractor = 2.23 arcsec/pixel
  • Seeing:
    • An Average night at an average site - 4-5 arc seconds
    • A Good night at an average site - 2-3 arc seconds
    • The Best conditions at the best sites - 0.5-1 arc second
As a result, for many conditions we meet, stars can be spread over a number of pixels. Luckily we can take advantage of this wasted resolution for the conditions by binning and improving the SNR.

Bin vs Deconvolution
The Bin algorithm can take advantage of oversampling to improve signal to noise. The deconvolution algorithm used by the Decon module can take advantage of the oversampling to recover detail. So how should we decide the amount to bin? Should we leave some oversampling for deconvolution to use?
  • Binning more will improve the SNR and allow Decon to go "deeper" and successfully deconvolve features that are darker/buried. Other modules will also benefit from the improved SNR.
  • Binning less will accomplish the opposite (and the higher noise will impact other modules as well) but finer detail may be recovered and described (i.e. kept at higher resolution) in areas where signal is high.
So - it all depends - on whether you can get more detail using Decon that justifies the degradation of the results by not getting every last bit of SNR available.
  • For most noisy images binning to use all the oversampling will give best results.
  • For higher quality images leaving some oversampling may be beneficial. Initially probably the best way of deciding is to try it. See what results you can get when you go through the workflow (including Decon) when keeping some oversampling - as to what you can get using the same workflow by binning as much as you can.
  • Make sure that the overall image has a high enough resolution - with the prominent stars keeping their roundness and the prominent detail not artificially jagged and angular. High quality printed images are generally about 300 pixels per inch - although 240 pixels per inch may be sufficient.
Guy
 
Posts: 76
Joined: Thu Feb 19, 2015 8:35 am

Return to User Notes

Who is online

Users browsing this forum: No registered users and 1 guest

cron