ForewordFirst, I must thank Mike Schuster for the original version of this fantastic PixInsight Script. Second, of course, the PixInsight team and their continuing open-source initiative, without which this Module would be near impossible to complete. The recent release of 1.8.5 is also worth mentioning because two very important inclusions made this Module significantly easier to make.
I'm sure that most users love the SubframeSelector. It seemed such a worthy item in the pre-processing toolkit that I believed it deserved a more 'standard' method of use that fits inside PixInsight. My primary motivator for this was that Scripts 'block' PixInsight from other tasks. With nearly every use, I singled out a few frames to check out; why are the statistics so different for this frame, and how 'bad' is my worst 'statistically significant' frame? This involved remembering the file name, finding it in a file explorer, and checking it out in another image editor. My secondary motivator was speed. By far this is the slowest part of my pre-processing workflow. Less importantly, I prefer prefixes and this Script only supported postfixes.
Initial Release NotesThis Module has become stable and includes nearly every feature as the SubframeSelector Script. I work in Linux, and while I've provided a Windows build, I've only opened it in Windows to ensure that it loads fine. I do not currently plan on including more features, but I am absolutely welcome to feedback and will continue to develop this as needs arise.
Notable DifferencesOf course, this is a native PCL Module instead of a PJSR Script. That alone offers many conveniences, including a huge performance boost. With the addition of threading for the measurement stage, this Module ran 12 frames in the time it takes the original Script to run 2.
The Output Files section is based off the common section between many other PixInsight Modules.
I've ported the recent PJSR StarDetector library to PCL and am using that exclusively instead of the StarAlignment tool. Some of the Star Detector parameters are slightly different because of this.
I've ripped the PSF Fitting portion of DynamicPSF. This plus my port of the StarDetector means this Module is more self-contained and does not call on any other PixInsight Modules or Scripts.
For most measurements, I'm using the Median and Mean Deviation from the Median for dispersion calculations. Star-related paramters, such as FWHM, are now a weighted average of the best-fit stars instead of a simple image-wide average.
The Approval and Weighting expressions are mostly the same, but behind-the-scenes are completely different. I've renamed a few parameters, so be sure to check them if you're copying your existing expressions. These expressions are now run as JavaScript code in the PJSR, thanks to recent updates. This vastly simplified the work involved for parsing expressions. Although I've limited the allowed characters, there are more possibilities with expressions. For example, you can use standard JavaScript functions like 'Math.abs()'.
The Graphs are now a WebView which utilizes the Dygraphs JS library also recently introduced. They are a little more interactive now, and display more information. In lieu of the extra line items in the Measurement Table, the Median and Mean Deviation are displayed on the graph and in tooltips that appear as you hover over points. Subframe Weights are a secondary axis, and the dispersion is displayed with a gradation. Clicking frames still toggles the Approved status, and shift-clicking unlocks the frame.
An additional Graph is also included which shows a histogram of the selected property with a line representing the Empirical Distribution Function. While this graph is not as interactive as the previous, it helps to identify ranges within your distribution of data that are best to include or exclude.
A few items are now placed in a 'Routines' dropdown: Measurement, Output, and Star Detector Preview. First, you must add your frames and measure them. Then, you can use the Output Routine. The Star Detector Routine runs only the Star Detector on the first frame that's supplied, and outputs relevant images for this process and the final structure map used to fit stars against. This helps you when tweaking Star Detector parameters.
To-Do- Live Monitoring
- Support for DATE-OBS keywords
- Map Outputs (currently, only the Star Detector preview is available)
Release InformationMy code is available in my forked branch of the PCL repository:
https://github.com/cameronleger/PCL/tree/SubframeSelectorYou can download a Linux and Windows build at this releases page of the repository:
https://github.com/cameronleger/PCL/releases/tag/01.04.01.0001OS X 10.12 build provided by Rob:
https://drive.google.com/file/d/1xWKzGr4YKXbNaaeui5nH8RZR7olD1bIj/view?usp=sharingI welcome any and all feedback. Thank you and enjoy!