[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
Re: [APML] median vs. average vs. sigma
Hi Bert and Tony,
Correct whole frames are not rejected by median combination. Median pixel
combinations do work on a pixel-by-pixel basis. It is done like this:
1) From each image in the set select the same pixel with respect to its x
and y coordinate and build a stack of pixels. For example, choose the top
left pixel from each image in the set and form a subset of pixel values.
This is called a pixel stack.
2) Using this subset of pixel values calculate their median value. This is
done by sorting all pixel values in the subset by increasing value then
assign the middle value in the sort order as the median value.
3) Set the corresponding pixel value in the combination image equal to the
median calcuated in step 2. So in the example, set the top left pixel of the
combination image equal to calculated median from step 2.
Now repeat the above process accross each row of the images on a
pixel-by-pixel basis.
So the top left pixel of a median combination may have come from image #1,
the next pixel to the right from image #2, and the 2nd pixel to the right
may have come from image 1# again. It all depends on the sorted order of
tthe pixel stack not the image stack.
Mike
----- Original Message -----
From: "Bert Katzung" <katzung1@comcast.net>
To: "Discussion of Film Astrophotography" <astro-photo@seds.org>
Sent: Friday, October 24, 2003 12:50 PM
Subject: Re: [APML] median vs. average vs. sigma
> Hi Tony:
> I hope one of the processing gurus can chime in, but I thought that median
> combine worked on a pixel-by-pixel basis. In other words, whole frames are
> not rejected but individual pixels within frames are rejected if they are
> not similar. So, for example, a frame with an airplane trail would still
be
> averaged into the final result where the airplane was not contributing,
but
> rejected in the area of the trail.
> Anybody else have information on this?
> Thanks,
> Bert
>
>
> ----- Original Message -----
> From: "Tony Hallas" <tonyhallas@foothill.net>
> To: "Discussion of Film Astrophotography" <astro-photo@seds.org>
> Sent: Friday, October 24, 2003 7:42 AM
> Subject: Re: [APML] median vs. average vs. sigma
>
>
> Brian,
>
> I'll make this quick since this is still a film site (anyone not
wanting
> to read this please hit "delete" now) ...
>
> Median combining has a dirty little secret about it ... if all your
> frames are not EXACTLY similar, median combining will actually reject some
> of the frames ... after all, it's looking for anything that is not exactly
> similar ... if you have some frames that aren't, they get the knife. The
bad
> thing about this ... you loose the "averaging" effect when you ditch
frames
> and your signal to noise is worse because of it. Signal to noise is
directly
> related to the square root of the number of frames that have been
averaged,
> so if you start loosing frames, the noise in your image will increase ...
> sometimes dramatically.
>
> Averaging, on the other hand, is locked in ... EVERY frame is
accounted
> for and all of them are combined so you end up with the smoothest image
> possible and the highest S/N ... this would be all you needed except for
one
> thing ... those pesky cosmic ray hits that appear in a RANDOM pattern all
> over your frames ... averaging does nothing to get rid of those. You have
> the smoothest background, but it is littered with the cosmic ray debris.
>
> Sigma processing is the best of both worlds ... although the exact
math
> is over my head, it essentially does a true average of the frames AND at
the
> same time rejects any "outliers" ... it is vital to set up the parameters
> correctly when doing a sigma combine ... Ray Graylak's site has a good
> explanation of it (I use Ray's Sigma 10 for my combining). I have run test
> after test and the sigma combine beat the median combine every time ... if
> you want the maximum S/N, it's the only way to fly.
>
> Tony
>
>
> --------------------------------------------------------------------------
--
> ----
>
>
> > _______________________________________________
> > Astro-Photo mailing list
> > Astro-Photo@seds.org
> > http://seds.org/mailman/listinfo/astro-photo
> >
>
>
> _______________________________________________
> Astro-Photo mailing list
> Astro-Photo@seds.org
> http://seds.org/mailman/listinfo/astro-photo
>
_______________________________________________
Astro-Photo mailing list
Astro-Photo@seds.org
http://seds.org/mailman/listinfo/astro-photo