Trying to understand algorithms

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

Trying to understand algorithms

Jolien Connor
Hi,  I've finally had some luck with segmentation on
my images (trying to pick out granular "stuff" from
monochrome pics).  I use the Subtract Background
feature from the Process menu and then the Maximum
Entropy thresholder.  Miraculously, my controls are
negative (even bright ones) and my high and low
density mutants reflect a close approximation of what
should ideally be selected.  

Now, I need to get more knowledge about what exactly
I'm doing and why it seems to be working well.  Could
anyone give me a detailed but straightforward
explanation of the rolling ball method for subtracting
background and the maximum entropy method of
thresholding?  I've got the papers from the mid to
late 80s that introduce the maximum entropy
thresholding method, but it's still not very clear why
it would be so good at picking out my clumpy brain
inclusions.  Thanks,

Jolien

Jolien Connor, Ph.D.
Microscopist/Associate Instrumentation Technologist
Waisman Center Rm T635B (scope room)
Rm 213/215 lab
Rm 217 office
(608) 263-9192 lab/office
(608) 265-9653 microscope room
[hidden email]
Reply | Threaded
Open this post in threaded view
|

Re: Trying to understand algorithms

Dimiter Prodanov
Hi,
what you do is quite obvious:
1) processing step, in this case the rolling-ball
2) segmentation step, in this case the max entropy

Most of the thresholding algorithms work on the histograms. So you can
compare the histograms of your samples to your controls.
It works because you are lucky to have similar brightness characteristics
of your objects.

Regards,

Dimiter Prodanov
Reply | Threaded
Open this post in threaded view
|

Getting Coordinates of Line Selection

Ryohei Thomas Nakano
Hi,
I'm writing plugin using Straight Line selection.
I want to get coordinate data or just an angle data is OK.
(x1, y1)  and (x2, y2), or the angel.
when rectangular selection was used, it greatly work,
but i have no idea when straight line selection.
I would be grateful for just a little help.

Sorry for so elementary question.
Thank you.

Thomas
Reply | Threaded
Open this post in threaded view
|

Re: Getting Coordinates of Line Selection

dscho
Hi,

On Wed, 18 Jul 2007, Ryohei Thomas Nakano wrote:

> I'm writing plugin using Straight Line selection.
> I want to get coordinate data or just an angle data is OK.
> (x1, y1)  and (x2, y2), or the angel.
> when rectangular selection was used, it greatly work,
> but i have no idea when straight line selection.
> I would be grateful for just a little help.

A straight line selection is of type ij.gui.Line.  The only method to get
at the coordinates that I know of, is the method "getPolygon()", which
returns a java.awt.Polygon.  If the width of the line selection is larger
than 1, then you will get a rectangle instead of a line.

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

Re: Getting Coordinates of Line Selection

Michael Schmid
On Wed, 18 Jul 2007, Ryohei Thomas Nakano wrote:

> I'm writing plugin using Straight Line selection.
> I want to get coordinate data or just an angle data is OK.
> (x1, y1)  and (x2, y2), or the angel.
> when rectangular selection was used, it greatly work,
> but i have no idea when straight line selection.
> I would be grateful for just a little help.

Hi,

in a macro you could also use
   if (selectionType() == 5) { //straight line selections only
     getSelectionCoordinates(xArray, yArray);
     startX = xArray[0];
     startY = yArray[0];
     endX = xArray[1];
     endY = yArray[1];
     //whatever you want to do here
   }

Michael