@jmurphy thanks for the extensive response, I think that I still an open point to fully solve the puzzle (that probably exists only in my mind
)
Using noiseMRS on its own is not sufficient. The image (brightness) scale factor is crucial. If an image is scaled by a factor of 2, the measured noise will also increase by the same factor. Since the image weight is proportional to 1 / noise^2, an invalid scale factor will also have a very strong impact on the calculated weight. In NSG I have already applied the scale factor to the normalized images, so I don't need to include the scale factor in the equation (that would apply it twice).
This is exactly what I mean by using ImageIntegration's noise evaluation on the nsg-corrected images. Let me use a bit of simple math to clarify without ambiguity.
Let's call the initial frame noise
s, during the processing you subtract a 2D-spline background and, after the subtraction, you scale the entire image by a single scale factor of
k. This makes the noise of your image become
k*s, but to be more precise you don't use this scaling formula, you measure directly the noise after the correction, which we call
s'. Now, since subtracting the 2d-spline to the image could have an impact on the noise measurement (depending on the scale of the spine and the noise) let's assume that in general the identity
k*s = s' is only an approximation (maybe a very good one or a bad one depending on the case) and the correct noise is the one measured on the corrected/scaled image
s'.
The weights are then computed as
w = sr / s'
where
w is the FWEIGHT value as the ratio between the reference image noise
sr (which is constant for all frames) and the nsg-corrected frame noise
s'. (please confirm that I am not wrong here
)
Now, let's get to the core point of my question: when Image Integration measures the noise of a nsg-corrected frames it measures
s', which is the noise of the image "already scaled"; being already scaled we don't scale it anymore and the noise-based weight becomes
w' = 1 / s'
where
w' is the weight of the ImageIntegration noise-based method.
So, if I didn't commit any conceptual error and I didn't misinterpret the JS code and how the script works, I would conclude that
w = w' * sr
proving that the weights used by image integration and the weights stored in FWEIGHT should be proportional by a constant factor.
So, since using as weights [1 2 3 4 5] or any other weights given by n * [1 2 3 4 5] gives the same result, would conclude that the two weighting strategies should produce the same master file because the two weights are proportional each other (
n=sr).
I hope I was clear enough and sorry for maybe being tedious with such formalities but I am really interested in understanding this weighting strategy which looks great!
Robyx