Bin Module Use
Posted: 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:
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 Official StarTools English Manual (pdf) gives a good description of all the modules. It relates to StarTools version 1.6+.
The Unofficial StarTools English Manual (pdf) is a good general source of help. There are versions that relate to StarTools version 1.6 and
version 1.7
The processing video 'StarTools complex LLRGB composite processing in 9 minutes real-time, with the Compose module' shows the use of the Bin module. This shows v1.5 but is still relevant for this module.
The notes below relate to StarTools version 1.5+
When to use:
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
Example Workflow (v1.6):
AutoDev-{Band/Lens}-Bin-Crop-Wipe-AutoDev (or Develop)-{Contrast/HDR/Sharp/Decon/Flux/Life}-Color-{Entropy/Filter}-Denoise (or Denoise 2)-{Layer/Shrink/Heal/Repair/Synth/Stereo 3D}
Key: {...} optional modules
Example Workflow (v1.7):
{Compose}-AutoDev-{Lens}-Bin-Crop-Wipe-AutoDev (or FilmDev)-{Contrast/HDR/Sharp/Decon/Flux}-Color-{Shrink/Filter/Entropy/SuperStr}-Track/NR-{Layer/Heal/Repair/Synth/Stereo 3D}
Key: {...} optional modules
Example Workflow (v1.8):
{Compose}-AutoDev-{Lens}-Bin-Crop-Wipe-AutoDev (or FilmDev)-{Contrast/HDR/Sharp/SVDecon}-Color-{Shrink/Filter/Entropy/SuperStr/NBAccent/}-Track/NR(Unified-Denoise)-{Flux/Repair/Heal/Layer/Synth/Stereo 3D}
Key: {...} optional modules
Method:
This is a way of using the module which should give good results in most cases:
Presets
Define a preset amount of binning.
Scale
Scale sets the reduction in resolution (e.g. 25% - the number of pixels along one axis has been reduced to 25%)
Oversampling
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?
Hardware binning
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)
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 Official StarTools English Manual (pdf) gives a good description of all the modules. It relates to StarTools version 1.6+.
The Unofficial StarTools English Manual (pdf) is a good general source of help. There are versions that relate to StarTools version 1.6 and
version 1.7
The processing video 'StarTools complex LLRGB composite processing in 9 minutes real-time, with the Compose module' shows the use of the Bin module. This shows v1.5 but is still relevant for this module.
The notes below relate to StarTools version 1.5+
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.
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
Example Workflow (v1.6):
AutoDev-{Band/Lens}-Bin-Crop-Wipe-AutoDev (or Develop)-{Contrast/HDR/Sharp/Decon/Flux/Life}-Color-{Entropy/Filter}-Denoise (or Denoise 2)-{Layer/Shrink/Heal/Repair/Synth/Stereo 3D}
Key: {...} optional modules
Example Workflow (v1.7):
{Compose}-AutoDev-{Lens}-Bin-Crop-Wipe-AutoDev (or FilmDev)-{Contrast/HDR/Sharp/Decon/Flux}-Color-{Shrink/Filter/Entropy/SuperStr}-Track/NR-{Layer/Heal/Repair/Synth/Stereo 3D}
Key: {...} optional modules
Example Workflow (v1.8):
{Compose}-AutoDev-{Lens}-Bin-Crop-Wipe-AutoDev (or FilmDev)-{Contrast/HDR/Sharp/SVDecon}-Color-{Shrink/Filter/Entropy/SuperStr/NBAccent/}-Track/NR(Unified-Denoise)-{Flux/Repair/Heal/Layer/Synth/Stereo 3D}
Key: {...} optional modules
Method:
This is a way of using the module which should give good results in most cases:
- Load the module - this automatically Bins the image by 50%.
- Zoom in on the image to see if the image is still oversampled. See the background notes on oversampling.
- Try different levels of binning until the smallest features occupy only a couple of pixels on their minor axis.
- Leave a bit of oversampling if you want to use the Decon module later.
- 'Keep' when finished.
- 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'.
- You may want to use the Lens Module followed by the Crop module.
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
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)
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
- For many DSLR camera and telescope combinations the image scale is around 1 arcsec/pixel or less.
- 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
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.
- 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.
Hardware binning
- Reduces noise by reducing the amount of read noise e.g. 2x2 binning means 4 pixels are read at once - so a quarter of the read noise
- It is fixed at capture time - there is no way of reducing it later.
- May give better results where read noise is dominant over shot noise - such as with very faint objects under really dark skies.
- Read noise is the unchanged because the pixels are read individually
- Shot Noise is reduced - Example: 2x2 binning - signal increases by 4x but noise increases by sqrt(4)=2 so SNR increases by 2 - assuming read noise is negligible
- Allows fractional binning (e.g. 2.1x2.1)
- Allows experimentation after capture
- Better results when there is skyglow or light pollution (i.e. shot & other noise is dominant over read noise)
- If in doubt - use StarTools binning unless target is a faint object under a really dark sky.