Author Topic: Best subframe to select using SubframeSelector  (Read 1462 times)

Offline BobinBend

  • Member
  • *
  • Posts: 51
Best subframe to select using SubframeSelector
« on: 2019 March 13 16:16:01 »
It's generally recommended that we use the Blink process followed by the SubframeSelector script to 'weed out' any bad subframes before the Integration steps. In addition the SubframeSelector script can provide some idea of the 'best' subframe to use for reference in the BatchPreProcess script. My question is what is the best method to use to identify this 'reference' subframe? The lowest FWHM or the highest Weight or some other characteristic?

Thanks for you help!
Bob

Offline RickS

  • PTeam Member
  • PixInsight Jedi
  • *****
  • Posts: 1298
Re: Best subframe to select using SubframeSelector
« Reply #1 on: 2019 March 13 18:38:58 »
For the BPP registration reference I look for small, round stars: low FWHM combined with low Eccentricity.

Offline chris.bailey

  • PixInsight Addict
  • ***
  • Posts: 235
Re: Best subframe to select using SubframeSelector
« Reply #2 on: 2019 March 14 01:59:32 »
Lowest FWHM / Eccentricity for Star Alignment (BPP) but then highest S/N for Image Integration.

Offline RickS

  • PTeam Member
  • PixInsight Jedi
  • *****
  • Posts: 1298
Re: Best subframe to select using SubframeSelector
« Reply #3 on: 2019 March 14 02:49:34 »
Lowest FWHM / Eccentricity for Star Alignment (BPP) but then highest S/N for Image Integration.

For integration I look for a reference that looks clean wrt gradients from high clouds, etc. rather than best (estimated) SNR.

Offline Geoff

  • PixInsight Padawan
  • ****
  • Posts: 908
Re: Best subframe to select using SubframeSelector
« Reply #4 on: 2019 March 14 05:14:44 »
I know the replies of Chris and Rick are accepted wisdom, but has anybody done any tests to see how much difference the selection of a particular subframe actually makes to the final result?
Geoff
Don't panic! (Douglas Adams)
Astrobin page at http://www.astrobin.com/users/Geoff/
Webpage (under construction) http://geoffsastro.smugmug.com/

Offline mschuster

  • PTeam Member
  • PixInsight Jedi
  • *****
  • Posts: 1087
Re: Best subframe to select using SubframeSelector
« Reply #5 on: 2019 March 14 07:44:46 »
Geoff,

It appears to me that II applies a different linear transform to each frame and then averages the results. The linear transform depends on which reference is selected. I believe a linear transform does not affect SNR. This implies that the choice of reference has no effect on SNR. This also implies that II's process is no better than a simplistic averaging of all the frames. I know these are radical conclusions, maybe my analysis is flawed?

My motivation here is this: If though analysis we can find which reference is best, then it should be possible to choose it automatically. Also it should be possible to automatically determine which frames to reject from the integration, ones that are so bad as to only lower SNR if included (eg, an extreme case, adding a dark frame to an integration would be a mistake).

Mike

Offline BobinBend

  • Member
  • *
  • Posts: 51
Re: Best subframe to select using SubframeSelector
« Reply #6 on: 2019 March 14 13:07:55 »
Thanks for your input. Sounds like low FWHM and low Eccentricity are the most common parameters to monitor for the best registration reference.

Bob

Offline mschuster

  • PTeam Member
  • PixInsight Jedi
  • *****
  • Posts: 1087
Re: Best subframe to select using SubframeSelector
« Reply #7 on: 2019 March 14 17:29:15 »
Geoff,

A followup to my previous post.

I used II to integrate 8 frames three different ways. #1, simple averaging (no normalization, no weighting). #2, the recommended technique (additive with scaling, noise evaluation) using a reference frame that I thought was the "best". #3, the recommended technique (additive with scaling, noise evaluation) using a reference frame that I thought was the "worst". No rejection.

So #2 and #3 differ only by reference choice. According to my reading of II documentation, #2 and #3 are related by a linear transform. The plot below shows 2 pixel values versus #3 pixel values. The plot is a straight line with an offset, ie a linear transform. Since SNR is invariant under linear transform, #2 and #3 SNR are identical. So I conclude the choice of reference has no effect on SNR.



Now consider #1 and #3. My hope would be that #2 SNR is better than #1, simple averaging. But is it? The plot below again shows a linear relationship with a bit of scatter. The bit of scatter indicates the potential but not necessarily a guarantee of SNR differences. Given the amount of scatter (ie relatively small) I guess that SNR's are the same within 1%.



Mike

Offline BobinBend

  • Member
  • *
  • Posts: 51
Re: Best subframe to select using SubframeSelector
« Reply #8 on: 2019 March 15 07:40:35 »
Mike,

So based on your testing and graphs shown above, how might this impact the way we integrate our subframes? Is it important to select the ‘best’ subframe as a reference?
Bob

Offline mschuster

  • PTeam Member
  • PixInsight Jedi
  • *****
  • Posts: 1087
Re: Best subframe to select using SubframeSelector
« Reply #9 on: 2019 March 15 10:05:31 »
Bob,

My conclusions:

Reference choice affects the location (median) and scale (the selected II scale method) of the result. So in a sense the result "looks" more like the chosen reference in these two aspects (ie a similar background level and a similar contrast). This may be important to you.

It won't however affect SNR, FWHM, eccentricity, or any other quality metric invariant under linear transform. So with these types of quality metrics as a goal reference choice is not important.

Note however that PI processes that measure SNR, FWHM, eccenticity, the total number of stars detect, etc might in fact give slightly difference results with different references due to round-off error and thresholding. These processes may be slightly sensitive to the selected linear transform. But this is basically just noise sensitivity IMO.

Note also that the PI's noise evaluation method (used by several scripts and II) also employs thresholding. I am worried that it might in some cases be overly sensitive to linear transforms and report a false reference choice difference.

Mike

Offline Geoff

  • PixInsight Padawan
  • ****
  • Posts: 908
Re: Best subframe to select using SubframeSelector
« Reply #10 on: 2019 March 15 21:14:09 »
This is all very interesting Mike. Nice if Juan were to chip in here.
Geoff
Don't panic! (Douglas Adams)
Astrobin page at http://www.astrobin.com/users/Geoff/
Webpage (under construction) http://geoffsastro.smugmug.com/

Offline Juan Conejero

  • PTeam Member
  • PixInsight Jedi Grand Master
  • ********
  • Posts: 7111
    • http://pixinsight.com/
Re: Best subframe to select using SubframeSelector
« Reply #11 on: 2019 March 16 01:38:40 »
Of course, Mike's conclusion about reference frames in ImageIntegration is correct: The choice of a particular reference frame has no repercussion on the SNR improvement achieved in the final result, other than insignificant differences caused by roundoff errors. As Mike describes, this is because II applies only linear transformations to the data—it could not be otherwise, or linearity of the integrated image would be damaged. These conclusions can be drawn from the reference documentation for II, which (although now outdated) includes detailed descriptions of the algorithms and procedures implemented in the II process.

Quote
Reference choice affects the location (median) and scale (the selected II scale method) of the result. So in a sense the result "looks" more like the chosen reference in these two aspects (ie a similar background level and a similar contrast).

This is true and is actually a 'feature' of the ImageIntegration process. This is in fact the main reason one may have to choose a particular integration reference frame in a given data set. Here we must stress the important fact that, within reasonable limits, location and scale statistics should have no practical influence on the proportions of signal and noise in the final result.

Quote
Note also that the PI's noise evaluation method (used by several scripts and II) also employs thresholding. I am worried that it might in some cases be overly sensitive to linear transforms and report a false reference choice difference.

All relevant internal calculations in the ImageIntegration process and native PJSR routines are performed in 64-bit floating point format, and care has been taken in the algorithm implementations to prevent accumulation of roundoff errors as possible. Within the limits of reasonable procedures, I doubt this may become a practical problem. Of course, if insensate decisions and selections are made (including, for example, the use of a hugely bad frame as reference), bad results are definitely possible.
Juan Conejero
PixInsight Development Team
http://pixinsight.com/

Offline johnpane

  • PixInsight Enthusiast
  • **
  • Posts: 93
Re: Best subframe to select using SubframeSelector
« Reply #12 on: 2019 March 16 10:25:03 »
How does one specify a reference frame for II? Of course there is a reference frame for registration, but I thought that is all about image geometry, and thus would not seem to affect II except in how precisely the subframes are registered. Am I missing something?

Offline pfile

  • PTeam Member
  • PixInsight Jedi Grand Master
  • ********
  • Posts: 4729
Re: Best subframe to select using SubframeSelector
« Reply #13 on: 2019 March 16 12:12:48 »
first file in the list is the reference

rob

Offline msmythers

  • PTeam Member
  • PixInsight Jedi
  • *****
  • Posts: 1178
    • astrobin
Re: Best subframe to select using SubframeSelector
« Reply #14 on: 2019 March 16 12:47:11 »
John

Here it is in the documentation and in the tool. In the tool just select which image is your reference and click on the button. That image is then placed at the beginning of the list.


Mike