Zooming and smoothing

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
23 messages Options
12
Reply | Threaded
Open this post in threaded view
|

Zooming and smoothing

flettster
My first post!

When I zoom on my image in imagej, it becomes highly pixelated. When i do the same on another program the image does not.

I presume that the other program is interpolating pixels or smoothing the image in some way.

I need ImageJ to do the same. The smooth function doesnt add more pixels which is what i need it to do.

Any ideas?

Many thanks
Reply | Threaded
Open this post in threaded view
|

Re: Zooming and smoothing

Volker Baecker
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Open Edit>Options>Appearance and check Interpolate Zoomed Images.
Volker

flettster a écrit :

> My first post!
>
> When I zoom on my image in imagej, it becomes highly pixelated. When i do
> the same on another program the image does not.
>
> I presume that the other program is interpolating pixels or smoothing the
> image in some way.
>
> I need ImageJ to do the same. The smooth function doesnt add more pixels
> which is what i need it to do.
>
> Any ideas?
>
> Many thanks
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFJt8HCxZKX7A/4oMERAhpGAKDCCk80R3OO25OjMRu1fe8/SDK1FwCgiqvc
jmLK/vJn6bAH/RX1qXpHbHU=
=STni
-----END PGP SIGNATURE-----

--
passerelle antivirus du campus CNRS de Montpellier
--
Reply | Threaded
Open this post in threaded view
|

Re: Zooming and smoothing

Zimmerman, Robert Edward,M.S.
In reply to this post by flettster
Edit/Options then check "Interpolate Zoomed Images"

Bob Z

-----Original Message-----
From: ImageJ Interest Group [mailto:[hidden email]] On Behalf Of flettster
Sent: Wednesday, March 11, 2009 9:20 AM
To: [hidden email]
Subject: Zooming and smoothing

My first post!

When I zoom on my image in imagej, it becomes highly pixelated. When i do
the same on another program the image does not.

I presume that the other program is interpolating pixels or smoothing the
image in some way.

I need ImageJ to do the same. The smooth function doesnt add more pixels
which is what i need it to do.

Any ideas?

Many thanks
--
View this message in context:
http://n2.nabble.com/Zooming-and-smoothing-tp2461280p2461280.html
Sent from the ImageJ mailing list archive at Nabble.com.


The information in this e-mail is intended only for the person to whom it is
addressed. If you believe this e-mail was sent to you in error and the e-mail
contains patient information, please contact the Partners Compliance HelpLine at
http://www.partners.org/complianceline . If the e-mail was sent to you in error
but does not contain patient information, please contact the sender and properly
dispose of the e-mail.
Reply | Threaded
Open this post in threaded view
|

Re: Zooming and smoothing

Gabriel Landini
In reply to this post by flettster
On Wednesday 11 March 2009 13:20:14 flettster wrote:
> When I zoom on my image in imagej, it becomes highly pixelated.
> When i do
> the same on another program the image does not.
> I presume that the other program is interpolating pixels or smoothing the
> image in some way.
> I need ImageJ to do the same. The smooth function doesnt add more pixels
> which is what i need it to do.

You can check the option:
Edit>Options>Appearance>Interpolate Zoomed Images

Or

Add this line to the AutoRun macro in /macros/StartupMacros:
run("Appearance...", "interpolate");

Cheers
G
Reply | Threaded
Open this post in threaded view
|

Re: Zooming and smoothing

flettster
It is amazing how easy something is when you know how!!

Thanks

Gabriel Landini wrote
On Wednesday 11 March 2009 13:20:14 flettster wrote:
> When I zoom on my image in imagej, it becomes highly pixelated.
> When i do
> the same on another program the image does not.
> I presume that the other program is interpolating pixels or smoothing the
> image in some way.
> I need ImageJ to do the same. The smooth function doesnt add more pixels
> which is what i need it to do.

You can check the option:
Edit>Options>Appearance>Interpolate Zoomed Images

Or

Add this line to the AutoRun macro in /macros/StartupMacros:
run("Appearance...", "interpolate");

Cheers
G
Reply | Threaded
Open this post in threaded view
|

Re: Zooming new problem

flettster

I have a new problem now. The image looks great - just what i needed

However, the selection tool and thresholding are still pixelated.

Is there a way of interpolating for these too?

Thanks


flettster wrote
It is amazing how easy something is when you know how!!

Thanks

Gabriel Landini wrote
On Wednesday 11 March 2009 13:20:14 flettster wrote:
> When I zoom on my image in imagej, it becomes highly pixelated.
> When i do
> the same on another program the image does not.
> I presume that the other program is interpolating pixels or smoothing the
> image in some way.
> I need ImageJ to do the same. The smooth function doesnt add more pixels
> which is what i need it to do.

You can check the option:
Edit>Options>Appearance>Interpolate Zoomed Images

Or

Add this line to the AutoRun macro in /macros/StartupMacros:
run("Appearance...", "interpolate");

Cheers
G
Reply | Threaded
Open this post in threaded view
|

Re: Zooming new problem

Gabriel Landini
On Wednesday 11 March 2009 15:00:09 flettster wrote:
> However, the selection tool and thresholding are still pixelated.
>
> Is there a way of interpolating for these too?

No, there isn't. You need to remember that you are working on a discrete
space.

G.
Reply | Threaded
Open this post in threaded view
|

Re: Zooming new problem

flettster
oh dear

This is difficult because i have a fairly rounded structure, then I draw a free hand selection and it creates a zigzag in pixels which makes it impossible to follow the round.  Likewise for the thresholding - the pixelation is very obvious.

Is there a way of cheating by creating a new image which includes the interpolated pixels?

I need my selections and thresholding to look nice as well as actually create measurements in order for people to buy in to the technique!

Thanks

Gabriel Landini wrote
On Wednesday 11 March 2009 15:00:09 flettster wrote:
> However, the selection tool and thresholding are still pixelated.
>
> Is there a way of interpolating for these too?

No, there isn't. You need to remember that you are working on a discrete
space.

G.
Reply | Threaded
Open this post in threaded view
|

Re: Zooming new problem

Gluender-2
Dear,

there might be a fundamental misunderstanding:

ImageJ is meant as a tool for scientific image analysis and not for
nice looking pictures and image cosmetics!

Best

Herbie

>oh dear
>
>This is difficult because i have a fairly rounded structure, then I draw a
>free hand selection and it creates a zigzag in pixels which makes it
>impossible to follow the round.  Likewise for the thresholding - the
>pixelation is very obvious.
>
>Is there a way of cheating by creating a new image which includes the
>interpolated pixels?
>
>I need my selections and thresholding to look nice as well as actually
>create measurements in order for people to buy in to the technique!
>
>Thanks
>
>Gabriel Landini wrote:
>>
>>  On Wednesday 11 March 2009 15:00:09 flettster wrote:
>>>  However, the selection tool and thresholding are still pixelated.
>>>
>>>  Is there a way of interpolating for these too?
>>
>>  No, there isn't. You need to remember that you are working on a discrete
>>  space.
>>
>  > G.
Reply | Threaded
Open this post in threaded view
|

Re: Zooming new problem

Volker Baecker
In reply to this post by flettster
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Keep in mind that however smooth it will look the zigzag thing is just
the reality and defines what you will measure.
I see two possibilities to make it look smoother:
1. scale up the image with the interpolation option selected (Image>Scale)
2. Have a look at the ObjectJ plugin (http://simon.bio.uva.nl/objectj/).
I think it can do what you want, but I'm not sure. Maybe someone else
can confirm this?
Volker
flettster a écrit :

> oh dear
>
> This is difficult because i have a fairly rounded structure, then I draw a
> free hand selection and it creates a zigzag in pixels which makes it
> impossible to follow the round.  Likewise for the thresholding - the
> pixelation is very obvious.
>
> Is there a way of cheating by creating a new image which includes the
> interpolated pixels?
>
> I need my selections and thresholding to look nice as well as actually
> create measurements in order for people to buy in to the technique!
>
> Thanks
>
>
> Gabriel Landini wrote:
>> On Wednesday 11 March 2009 15:00:09 flettster wrote:
>>> However, the selection tool and thresholding are still pixelated.
>>>
>>> Is there a way of interpolating for these too?
>> No, there isn't. You need to remember that you are working on a discrete
>> space.
>>
>> G.
>>
>>
>
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFJt93+xZKX7A/4oMERAn1aAKDsfZdBQ1T6oZA+9hMbzEwHhAp7swCg2bah
0OaPlht/Sqf11zutaAQLO4I=
=JR1J
-----END PGP SIGNATURE-----

--
passerelle antivirus du campus CNRS de Montpellier
--
Reply | Threaded
Open this post in threaded view
|

Antwort: Re: Zooming new problem

Joachim Wesner
In reply to this post by Gluender-2
ImageJ Interest Group <[hidden email]> schrieb am 11.03.2009 16:44:54:

> Dear,
>
> there might be a fundamental misunderstanding:
>
> ImageJ is meant as a tool for scientific image analysis and not for
> nice looking pictures and image cosmetics!
>

YES!


> >Is there a way of cheating by creating a new image which includes the
> >interpolated pixels?
> >


HOWEVER, some people talk about "superresolution" and "subpixels" for
scientific use....

What you can do, I do not know if it helps your case, also because I have
no experinece how good
ImageJs interpolation is, you can create a scaled up version of your
original image (Image/Scale...",
there is an "interpolation" option

JW


______________________________________________________________________
This email has been scanned by the MessageLabs Email Security System.
For more information please visit http://www.messagelabs.com/email 
______________________________________________________________________
Reply | Threaded
Open this post in threaded view
|

Re: Zooming new problem

flettster
In reply to this post by Gluender-2
I understand that it is to be used for making scientific measurements and that is what I need to use it for. The problem is that if those measurements dont look believable or robust to everyone else, they wont believe that the technique itself is believable or robust unless you spend an hour explaining why it is so. Sometimes, it is better to eliminate this step, if it makes no difference to the actual measurement - as in this case.

Thanks for your comment though.

Gluender-2 wrote
Dear,

there might be a fundamental misunderstanding:

ImageJ is meant as a tool for scientific image analysis and not for
nice looking pictures and image cosmetics!

Best

Herbie

>oh dear
>
>This is difficult because i have a fairly rounded structure, then I draw a
>free hand selection and it creates a zigzag in pixels which makes it
>impossible to follow the round.  Likewise for the thresholding - the
>pixelation is very obvious.
>
>Is there a way of cheating by creating a new image which includes the
>interpolated pixels?
>
>I need my selections and thresholding to look nice as well as actually
>create measurements in order for people to buy in to the technique!
>
>Thanks
>
>Gabriel Landini wrote:
>>
>>  On Wednesday 11 March 2009 15:00:09 flettster wrote:
>>>  However, the selection tool and thresholding are still pixelated.
>>>
>>>  Is there a way of interpolating for these too?
>>
>>  No, there isn't. You need to remember that you are working on a discrete
>>  space.
>>
>  > G.
Reply | Threaded
Open this post in threaded view
|

Re: Zooming new problem

flettster
The scaling option worked perfectly for what i need.

Thanks
Reply | Threaded
Open this post in threaded view
|

Re: Zooming new problem

Gabriel Landini
In reply to this post by flettster
On Wednesday 11 March 2009 15:59:31 flettster wrote:
> I understand that it is to be used for making scientific measurements and
> that is what I need to use it for. The problem is that if those
> measurements dont look believable or robust to everyone else, they wont
> believe that the technique itself is believable or robust unless you spend
> an hour explaining why it is so.
>
> Sometimes, it is better to eliminate this
> step, if it makes no difference to the actual measurement - as in this
> case.

Forget ImageJ, you need to read this, and urgently:

http://jcb.rupress.org/cgi/content/full/166/1/11

Cheers,

G
Reply | Threaded
Open this post in threaded view
|

Re: Zooming new problem

Gluender-2
In reply to this post by flettster
Sorry Sir,

but what you intend to do is invent pictorial information that is not
present in your original data (I won't discuss super-resolution here)
and you yourself used the term "cheating".

Why not show pixelated data if it represents the given image resolution?

Is an image at its original resolution not believable or robust?

I don't get the point from what you are saying.

Best wishes

Herbie


>I understand that it is to be used for making scientific measurements and
>that is what I need to use it for. The problem is that if those measurements
>dont look believable or robust to everyone else, they wont believe that the
>technique itself is believable or robust unless you spend an hour explaining
>why it is so. Sometimes, it is better to eliminate this step, if it makes no
>difference to the actual measurement - as in this case.
>
>Thanks for your comment though.
>
>
>Gluender-2 wrote:
>>
>>  Dear,
>>
>>  there might be a fundamental misunderstanding:
>>
>>  ImageJ is meant as a tool for scientific image analysis and not for
>>  nice looking pictures and image cosmetics!
>>
>>  Best
>>
>>  Herbie
>>
>>>oh dear
>>>
>>>This is difficult because i have a fairly rounded structure, then I draw a
>>>free hand selection and it creates a zigzag in pixels which makes it
>>>impossible to follow the round.  Likewise for the thresholding - the
>>>pixelation is very obvious.
>>>
>>>Is there a way of cheating by creating a new image which includes the
>>>interpolated pixels?
>>>
>>>I need my selections and thresholding to look nice as well as actually
>>>create measurements in order for people to buy in to the technique!
>>>
>>>Thanks
>>>
>>>Gabriel Landini wrote:
>>>>
>>>>   On Wednesday 11 March 2009 15:00:09 flettster wrote:
>>>>>   However, the selection tool and thresholding are still pixelated.
>>>>>
>>>>>   Is there a way of interpolating for these too?
>>>>
>>>>   No, there isn't. You need to remember that you are working on a
>>>>  discrete
>>>>   space.
>>>>
>  >>  > G.
Reply | Threaded
Open this post in threaded view
|

Re: Zooming new problem

flettster
All your points are well taken. I agree actually

I just need it to look smooth in this case.

Thanks

Andy


Gluender-2 wrote
Sorry Sir,

but what you intend to do is invent pictorial information that is not
present in your original data (I won't discuss super-resolution here)
and you yourself used the term "cheating".

Why not show pixelated data if it represents the given image resolution?

Is an image at its original resolution not believable or robust?

I don't get the point from what you are saying.

Best wishes

Herbie


>I understand that it is to be used for making scientific measurements and
>that is what I need to use it for. The problem is that if those measurements
>dont look believable or robust to everyone else, they wont believe that the
>technique itself is believable or robust unless you spend an hour explaining
>why it is so. Sometimes, it is better to eliminate this step, if it makes no
>difference to the actual measurement - as in this case.
>
>Thanks for your comment though.
>
>
>Gluender-2 wrote:
>>
>>  Dear,
>>
>>  there might be a fundamental misunderstanding:
>>
>>  ImageJ is meant as a tool for scientific image analysis and not for
>>  nice looking pictures and image cosmetics!
>>
>>  Best
>>
>>  Herbie
>>
>>>oh dear
>>>
>>>This is difficult because i have a fairly rounded structure, then I draw a
>>>free hand selection and it creates a zigzag in pixels which makes it
>>>impossible to follow the round.  Likewise for the thresholding - the
>>>pixelation is very obvious.
>>>
>>>Is there a way of cheating by creating a new image which includes the
>>>interpolated pixels?
>>>
>>>I need my selections and thresholding to look nice as well as actually
>>>create measurements in order for people to buy in to the technique!
>>>
>>>Thanks
>>>
>>>Gabriel Landini wrote:
>>>>
>>>>   On Wednesday 11 March 2009 15:00:09 flettster wrote:
>>>>>   However, the selection tool and thresholding are still pixelated.
>>>>>
>>>>>   Is there a way of interpolating for these too?
>>>>
>>>>   No, there isn't. You need to remember that you are working on a
>>>>  discrete
>>>>   space.
>>>>
>  >>  > G.
Reply | Threaded
Open this post in threaded view
|

Re: Zooming new problem

Robert Dougherty
In reply to this post by Gluender-2
Herbie, Gabriel, Volker, and everyone,

I prepare my acoustic images by computing them on a coarse grid  
(related to the phased array resolution) and then interpolating to a  
finer grid for presentation.  I found that the bilinear interpolation  
in ImageJ was not doing what I needed, so I wrote a bicubic  
interpolation code by extending the FloatProcessor class and  
overriding getInterpolatedPixel.  There are  other bicubic  
interpolation plugins available for ImageJ, including an example from  
the Burger and Burge book, but in each case the interpolation is part  
of something else, not a direct effort to extend ImageJ.  I posted my  
code on my web site last year in the hopes that someone would run with  
it by implementing the algorithm for the other image types and  
offering it to Wayne.  I was a little tentative because I was not sure  
that my somewhat invented algorithm would work out.  I've been using  
it a lot, and it seems to be perfect for my needs.  If it is time for  
ImageJ to go bicubic, here is a simple path for it.  I do not have  
time to do the coding right now.

Bob


Robert Dougherty, Ph.D.
President, OptiNav, Inc.
4176 148th Ave. NE
Redmond, WA 98052
(425)891-4883
FAX (425)467-1119
www.optinav.com
[hidden email]
Reply | Threaded
Open this post in threaded view
|

Re: Zooming new problem

Burger Wilhelm
Hi Bob,
 
as you mention, we have listed a number of different interpolation methods in the source section of our website (imagingbook.com), including cubic and other spline methods. I particularly recommend the Catmull-Rom formulation for good results. I can also send you code for a Lanczos interpolator, which has no visible advantage though.
 
All these methods are pretty standard and implemented by stand-alone code that could be copied directly into ImageProcessor's getInterpolatedPixel() method and selected using a suitable mode switch.
 
Wilhelm

________________________________

Von: ImageJ Interest Group im Auftrag von Robert Dougherty
Gesendet: Mi 11.03.2009 20:25
An: [hidden email]
Betreff: Re: Zooming new problem



Herbie, Gabriel, Volker, and everyone,

I prepare my acoustic images by computing them on a coarse grid
(related to the phased array resolution) and then interpolating to a
finer grid for presentation.  I found that the bilinear interpolation
in ImageJ was not doing what I needed, so I wrote a bicubic
interpolation code by extending the FloatProcessor class and
overriding getInterpolatedPixel.  There are  other bicubic
interpolation plugins available for ImageJ, including an example from
the Burger and Burge book, but in each case the interpolation is part
of something else, not a direct effort to extend ImageJ.  I posted my
code on my web site last year in the hopes that someone would run with
it by implementing the algorithm for the other image types and
offering it to Wayne.  I was a little tentative because I was not sure
that my somewhat invented algorithm would work out.  I've been using
it a lot, and it seems to be perfect for my needs.  If it is time for
ImageJ to go bicubic, here is a simple path for it.  I do not have
time to do the coding right now.

Bob


Robert Dougherty, Ph.D.
President, OptiNav, Inc.
4176 148th Ave. NE
Redmond, WA 98052
(425)891-4883
FAX (425)467-1119
www.optinav.com
[hidden email]
Reply | Threaded
Open this post in threaded view
|

Re: Zooming new problem

dscho
Hi,

On Wed, 11 Mar 2009, Burger Wilhelm wrote:

> as you mention, we have listed a number of different interpolation
> methods in the source section of our website (imagingbook.com),
> including cubic and other spline methods. I particularly recommend the
> Catmull-Rom formulation for good results. I can also send you code for a
> Lanczos interpolator, which has no visible advantage though.
>
> All these methods are pretty standard and implemented by stand-alone
> code that could be copied directly into ImageProcessor's
> getInterpolatedPixel() method and selected using a suitable mode switch.

Usually I would not say anything, but since we discussed clean design
earlier: I think it would not be appropriate to put this method into
ImageProcessor (think MVC), at least not with a global switch as to which
interpolation method is actually used.

Ciao,
Dscho
Reply | Threaded
Open this post in threaded view
|

Re: Zooming new problem

Burger Wilhelm
Oh sure, but this would be in line with the current implementation and would not break existing code. The switch would not be global but "private" to the individual ImageProcessor (with set-method etc.). Easy and clean enough for my taste.
 
Wilhelm


________________________________

Von: ImageJ Interest Group im Auftrag von Johannes Schindelin
Gesendet: Mi 11.03.2009 22:08
An: [hidden email]
Betreff: Re: Zooming new problem



Hi,

On Wed, 11 Mar 2009, Burger Wilhelm wrote:

> as you mention, we have listed a number of different interpolation
> methods in the source section of our website (imagingbook.com),
> including cubic and other spline methods. I particularly recommend the
> Catmull-Rom formulation for good results. I can also send you code for a
> Lanczos interpolator, which has no visible advantage though.
>
> All these methods are pretty standard and implemented by stand-alone
> code that could be copied directly into ImageProcessor's
> getInterpolatedPixel() method and selected using a suitable mode switch.

Usually I would not say anything, but since we discussed clean design
earlier: I think it would not be appropriate to put this method into
ImageProcessor (think MVC), at least not with a global switch as to which
interpolation method is actually used.

Ciao,
Dscho
12