Velocity Reviews

Velocity Reviews (http://www.velocityreviews.com/forums/index.php)
-   Digital Photography (http://www.velocityreviews.com/forums/f37-digital-photography.html)
-   -   Down sampling and Nyquist limits (http://www.velocityreviews.com/forums/t430228-down-sampling-and-nyquist-limits.html)

Scott W 11-01-2006 06:17 PM

Down sampling and Nyquist limits
 

But pretty much the discussions of late have been all talk and no one
showing the effects of their preferred way to limit the higher
frequencies when down sampling.

So I have put up an image that if not down sampled well will look like
crap i.e. nearest neighbor shows huge amounts of moiré in the roof and
bricks.

There is also in the bottom part of the image a sin wave at 7.69 pixels
/ cycle. This image is meant to test down sampling to 25%, which puts
the sin wave just past the Nyquist limit. If there were no aliasing in
the down sampling the sin wave area would turn gray.

Here is the test file to be down sampled, it is 3200 x 2000 pixel and
the test is to resize it to 800 x 500 pixels.
http://www.pbase.com/konascott/image/69543104/original

This is how I would normally down sample, bicubic followed but USM of r
R=0.3 and 100%
http://www.pbase.com/konascott/image/69546848/original
you can see from my sin wave that I have a lot of aliasing right above
Nyquist but the image look pretty good over all.

Now clearly some filtering of the higher frequencies is needed or you
end up with this.
http://www.pbase.com/konascott/image/69547582/original

I don't believe you can get a sharp looking photo if you do not allow
some alaising at just above Nyquist, but I will be interested in what
other come up with.

Scott


=?iso-8859-1?Q?M=E5ns_Rullg=E5rd?= 11-01-2006 07:33 PM

Re: Down sampling and Nyquist limits
 
"Scott W" <biphoto@hotmail.com> writes:

> But pretty much the discussions of late have been all talk and no one
> showing the effects of their preferred way to limit the higher
> frequencies when down sampling.
>
> So I have put up an image that if not down sampled well will look like
> crap i.e. nearest neighbor shows huge amounts of moiré in the roof and
> bricks.
>
> There is also in the bottom part of the image a sin wave at 7.69 pixels
> / cycle. This image is meant to test down sampling to 25%, which puts
> the sin wave just past the Nyquist limit. If there were no aliasing in
> the down sampling the sin wave area would turn gray.
>
> Here is the test file to be down sampled, it is 3200 x 2000 pixel and
> the test is to resize it to 800 x 500 pixels.
> http://www.pbase.com/konascott/image/69543104/original
>
> This is how I would normally down sample, bicubic followed but USM of r
> R=0.3 and 100%
> http://www.pbase.com/konascott/image/69546848/original
> you can see from my sin wave that I have a lot of aliasing right above
> Nyquist but the image look pretty good over all.
>
> Now clearly some filtering of the higher frequencies is needed or you
> end up with this.
> http://www.pbase.com/konascott/image/69547582/original
>
> I don't believe you can get a sharp looking photo if you do not allow
> some alaising at just above Nyquist, but I will be interested in what
> other come up with.


I believe you swapped the URLs to the scaled images. How did you
produce those scaled versions?

--
Måns Rullgård
mru@inprovide.com

=?iso-8859-1?Q?M=E5ns_Rullg=E5rd?= 11-01-2006 07:35 PM

Re: Down sampling and Nyquist limits
 
Måns Rullgård <mru@inprovide.com> writes:

> "Scott W" <biphoto@hotmail.com> writes:
>
>> But pretty much the discussions of late have been all talk and no one
>> showing the effects of their preferred way to limit the higher
>> frequencies when down sampling.
>>
>> So I have put up an image that if not down sampled well will look like
>> crap i.e. nearest neighbor shows huge amounts of moiré in the roof and
>> bricks.
>>
>> There is also in the bottom part of the image a sin wave at 7.69 pixels
>> / cycle. This image is meant to test down sampling to 25%, which puts
>> the sin wave just past the Nyquist limit. If there were no aliasing in
>> the down sampling the sin wave area would turn gray.
>>
>> Here is the test file to be down sampled, it is 3200 x 2000 pixel and
>> the test is to resize it to 800 x 500 pixels.
>> http://www.pbase.com/konascott/image/69543104/original
>>
>> This is how I would normally down sample, bicubic followed but USM of r
>> R=0.3 and 100%
>> http://www.pbase.com/konascott/image/69546848/original
>> you can see from my sin wave that I have a lot of aliasing right above
>> Nyquist but the image look pretty good over all.
>>
>> Now clearly some filtering of the higher frequencies is needed or you
>> end up with this.
>> http://www.pbase.com/konascott/image/69547582/original
>>
>> I don't believe you can get a sharp looking photo if you do not allow
>> some alaising at just above Nyquist, but I will be interested in what
>> other come up with.

>
> I believe you swapped the URLs to the scaled images.


No, you didn't. It was me confusing browser windows.

--
Måns Rullgård
mru@inprovide.com

=?iso-8859-1?Q?M=E5ns_Rullg=E5rd?= 11-01-2006 07:37 PM

Re: Down sampling and Nyquist limits
 
"Scott W" <biphoto@hotmail.com> writes:

> But pretty much the discussions of late have been all talk and no one
> showing the effects of their preferred way to limit the higher
> frequencies when down sampling.
>
> So I have put up an image that if not down sampled well will look like
> crap i.e. nearest neighbor shows huge amounts of moiré in the roof and
> bricks.
>
> There is also in the bottom part of the image a sin wave at 7.69 pixels
> / cycle. This image is meant to test down sampling to 25%, which puts
> the sin wave just past the Nyquist limit. If there were no aliasing in
> the down sampling the sin wave area would turn gray.
>
> Here is the test file to be down sampled, it is 3200 x 2000 pixel and
> the test is to resize it to 800 x 500 pixels.
> http://www.pbase.com/konascott/image/69543104/original
>
> This is how I would normally down sample, bicubic followed but USM of r
> R=0.3 and 100%
> http://www.pbase.com/konascott/image/69546848/original
> you can see from my sin wave that I have a lot of aliasing right above
> Nyquist but the image look pretty good over all.
>
> Now clearly some filtering of the higher frequencies is needed or you
> end up with this.
> http://www.pbase.com/konascott/image/69547582/original
>
> I don't believe you can get a sharp looking photo if you do not allow
> some alaising at just above Nyquist, but I will be interested in what
> other come up with.


IMHO ImageMagick with a sinc or lanczos filter does a slightly better
job.

--
Måns Rullgård
mru@inprovide.com

Alfred Molon 11-01-2006 09:37 PM

Re: Down sampling and Nyquist limits
 
Here is what I get:

Lanczos (Irfanview) + USM 50% radius 0.3:
http://www.ddde.de/test/Lanczos_USM50_0.3.jpg

Gaussian blur radius 0.7, bilinear downsampling, USM 50% radius 0.3:
http://www.ddde.de/test/gaussblur0.7..._USM0.3_50.jpg

Not too much difference, although the Gaussian blur step helps and makes
the image more pleasant for the eye. By the way, if you think that I'm
violating your copyright, simply let me know and I'll remove the images.
--

Alfred Molon
------------------------------
Olympus 50X0, 7070, 8080, E300, E330, E400 and E500 forum at
http://tech.groups.yahoo.com/group/MyOlympus/
Olympus E330 resource - http://myolympus.org/E330/

Scott W 11-01-2006 09:44 PM

Re: Down sampling and Nyquist limits
 
Alfred Molon wrote:
> Here is what I get:
>
> Lanczos (Irfanview) + USM 50% radius 0.3:
> http://www.ddde.de/test/Lanczos_USM50_0.3.jpg
>
> Gaussian blur radius 0.7, bilinear downsampling, USM 50% radius 0.3:
> http://www.ddde.de/test/gaussblur0.7..._USM0.3_50.jpg
>
> Not too much difference, although the Gaussian blur step helps and makes
> the image more pleasant for the eye. By the way, if you think that I'm
> violating your copyright, simply let me know and I'll remove the images.


Naw, I am not worried at all about any copy rights on this image, not
the kind of image I would imagine ever making money on. It is the side
of my brother in laws house BTW.

You links however don't seem to be working.

Scott


Scott W 11-01-2006 09:50 PM

Re: Down sampling and Nyquist limits
 

Scott W wrote:
> Alfred Molon wrote:
> > Here is what I get:
> >
> > Lanczos (Irfanview) + USM 50% radius 0.3:
> > http://www.ddde.de/test/Lanczos_USM50_0.3.jpg
> >
> > Gaussian blur radius 0.7, bilinear downsampling, USM 50% radius 0.3:
> > http://www.ddde.de/test/gaussblur0.7..._USM0.3_50.jpg
> >
> > Not too much difference, although the Gaussian blur step helps and makes
> > the image more pleasant for the eye. By the way, if you think that I'm
> > violating your copyright, simply let me know and I'll remove the images.

>
> Naw, I am not worried at all about any copy rights on this image, not
> the kind of image I would imagine ever making money on. It is the side
> of my brother in laws house BTW.
>
> You links however don't seem to be working.
>
> Scott

Hmm... maybe it is my browser, when I cut and paste you links they work
fine.

Your down sampling looks good, to my eye, but like mine it shows a lot
of aliasing just above Nyquist. For me I don't think this is a
problem, but there are a number of people who claim you need to remove
the frequencies above the Nyquist limit, I believe if you do this the
down sampled image will either look soft or have a lot of halos
(ringing ).

Scott


Paul Rubin 11-01-2006 11:46 PM

Re: Down sampling and Nyquist limits
 
Alfred Molon <alfredDELETE_molon@yahoo.com> writes:
> Lanczos (Irfanview) + USM 50% radius 0.3:
> http://www.ddde.de/test/Lanczos_USM50_0.3.jpg
>
> Gaussian blur radius 0.7, bilinear downsampling, USM 50% radius 0.3:
> http://www.ddde.de/test/gaussblur0.7..._USM0.3_50.jpg
>
> Not too much difference,


The Lanczos one has really blatant moire in the house shingles.

Bill Tuthill 11-02-2006 12:53 AM

Re: Down sampling and Nyquist limits
 
Måns Rullgård <mru@inprovide.com> wrote:
>
> IMHO ImageMagick with a sinc or lanczos filter does a slightly better job.


I didn't try Sinc, but Lanczos had to be tweaked with sharpening (-unsharp)
to come close.

Downsampling 25% is not a particularly good test, because many algorithms
produce identical results at that value.


Paul J Gans 11-02-2006 03:03 AM

Re: Down sampling and Nyquist limits
 
Paul Rubin <http://phr.cx@nospam.invalid> wrote:
>Alfred Molon <alfredDELETE_molon@yahoo.com> writes:
>> Lanczos (Irfanview) + USM 50% radius 0.3:
>> http://www.ddde.de/test/Lanczos_USM50_0.3.jpg
>>
>> Gaussian blur radius 0.7, bilinear downsampling, USM 50% radius 0.3:
>> http://www.ddde.de/test/gaussblur0.7..._USM0.3_50.jpg
>>
>> Not too much difference,


>The Lanczos one has really blatant moire in the house shingles.


I think we have a browser problem. I see no moire there at all
in Firefox. But I see plenty in the white fence in both images.

---- Paul J. Gans


All times are GMT. The time now is 09:14 PM.

Powered by vBulletin®. Copyright ©2000 - 2014, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.