Hi again,
Here we go. There's no bug in ABE (at least not in the background subtraction routine).
This is a screen shot taken while working with Bitli's image:
http://forum-images.pixinsight.com/legacy/abe-bug-20090220/01.jpgTop-left (1): original image
Top-right (2): ABE background model
Bottom-left (3): ABE corrected image (by subtraction)
Bottom-right (4): Rescaled absolute difference between 1 and 3.
As you can see, the original image is quite flat. This can be seen also on the generated background model. Please note that
flat here doesn't mean that the image has a neutral background. Flatness refers here to the illumination distribution's profile.
When ABE subtracts a background model, it adds the original background to the corrected image. This is ABE's subtraction correction:
v' = v - b + M
where v' is a corrected pixel, v is the corresponding original pixel, b is the corresponding background model pixel, and M is the median of the original image.
Note that this is
correct in the sense that the original
mean background is preserved in the expression above. This means that after background subtraction, the image doesn't have to have a neutral background necessarily (unless all components of M are identical).
From the absolute difference image (4) you can see that the model is in fact applying a slight correction on the four corners of the image. It seems to be overcorrecting near the right border; this can be improved by tunning ABE parameters.
If you subtract the background model with a PixelMath expression, as we usually do with DBE models:
ngc_457_DSS_mean - ngc_457_DSS_mean_ABE_background
then the resulting image will have a nice neutral background, provided that the background model is accurate and the rescaling PixelMath option is enabled. This is probably what you were expecting from ABE. To reproduce ABE's subtraction behavior with PixelMath, apply this expression:
ngc_457_DSS_mean - ngc_457_DSS_mean_ABE_background + Med( ngc_457_DSS_mean )
with rescaling disabled.
Note that you can neutralize the background very easily with a PixelMath expression like this one:
$T - Med( $T )
applied with rescaling enabled. You can also add a small pedestal to prevent negative numbers, which allows you to apply the subtraction with rescaling disabled:
$T - Med( $T ) + 0.025
The constant above is just an example; its validity should be verified for each particular image.
Here is a screenshot showing what you have after background neutralization of your original image:
http://forum-images.pixinsight.com/legacy/abe-bug-20090220/02.jpgNote that if you want to stretch the image (and you want, of course
), then subtracting a good background model is mandatory. This is an easy target for ABE, but its parameters need to be tweaked.