Re: Regarding the Fit_Ellipse Program [message #59007 is a reply to message #58903] |
Thu, 28 February 2008 08:30   |
plim.dreaming
Messages: 22 Registered: February 2008
|
Junior Member |
|
|
> I don't think this is the right approach to the problem.
> What I would do is to get a regularly gridded array
> for rho first (for instance with trigrid, but there may
> be other possibilities).
> Once you have that, it is easy to produce an input array
> suitable for fit_ellipse (just set all points higher (or lower)
> than a threshold to 0, and the others to 1).
>
> Try something like:
>
> TRIANGULATE, x, y, Triangles
> Result = TRIGRID( x,y,rho, Triangles,[dx,dy],[minx,miny,maxx,maxy]] )
>
> where dx and dy is the spacing of the regular grid and minx etc. are
> the boundaries.
>
> Cheers,
> Paolo>
Hi Paolo,
I understand that it would be simpler to use a regular gridded array
but that is changing the whole situation.
Part of the study I am doing is based on the fact that it isn't a
regular gridded array with defined spacings dx and dy.
It seems we are straying from the problem which would be to fit an
ellipse to a contour and obtain its parameters given the x and y
positions of the contour. I'm getting amazed at how hard it is to fit
an ellipse to it!
I certainly don't understand why there isn't a fit_ellipse program
that works with the x,y array of the contour vertices instead of the
pixel indices of the image of a contour (I wish I knew how to make one
myself).
B
|
|
|