Curve detection

asked 2015-03-17 07:03:41 -0500

David_86 gravatar image

updated 2015-03-17 09:17:19 -0500

Hello, is there any chance of detecting the highlined green curve (or a close one) in an image like this?

I've worked on ellipse fitting in the past and i've had quite good result but the pool of points was A LOT smaller (getting even there wrong results sometimes).

So i'm wondering if this is a possible path before i even start to look for a Hough modification and implementation, because i will need to keep a certain degree of freedom in curve parameters (and this is making things even worse if possible)..

Thank you

image description

image description

edit retag flag offensive close merge delete

Comments

does your curve need to be "horizontal"?

thdrksdfthmn gravatar imagethdrksdfthmn ( 2015-03-17 07:05:55 -0500 )edit

Not necessarily, u can rotate the image and get a similar case..one constant is that the curve will be always perpendicular to the other lines in the image, but its shape could be a little different on the right edge (the left part will always be almost a straight line), so there's the degree of freedom in the parameters. Think of a cable that keeps together some other cables as an example: i'm trying to identify the enclosing cable, but can't use information on color or aspect because it looks like the other cables.

David_86 gravatar imageDavid_86 ( 2015-03-17 08:02:53 -0500 )edit

can you also supply the original image? It might help, to obtain a better perspective of the scene. The Canny output does not help that much to this.

theodore gravatar imagetheodore ( 2015-03-17 09:08:17 -0500 )edit

Attached the original image (had to use jpg format because of the size limits). Don't rely on this illumination, it could be different or i could set up a proper one.

David_86 gravatar imageDavid_86 ( 2015-03-17 09:18:14 -0500 )edit

NOTE: in this case is not very visible because of the light conditions, but it would be nice to detect also the last part of the curve on the right edge if properly illuminated (or with a lower threshold for Canny).

David_86 gravatar imageDavid_86 ( 2015-03-17 09:32:56 -0500 )edit
2

First, I think you should try to isolate the points belonging to the curve you want to detect. You can do it with a PCA analysis of the gradient distributions (the interesting area should show a strong horizontal component).

Then, you can try a curve-fitting method, with a least-squares method, for example (try to estimate F(p)=apĀ²+bp+c so that F(p)-p_observed is minimal).

kbarni gravatar imagekbarni ( 2015-03-17 10:23:37 -0500 )edit

Thanks for your suggestion kbarni, i'll give it a try

David_86 gravatar imageDavid_86 ( 2015-03-18 02:33:21 -0500 )edit

@David_86 i wonder did you find a solution?

sturkmen gravatar imagesturkmen ( 2015-10-04 15:13:16 -0500 )edit

@sturkmen not yet, but to be honest I did not spend enough time on that because I've been working on other tasks, so this one went in "stand-by". I will let you know if I get any result.

David_86 gravatar imageDavid_86 ( 2015-10-05 01:44:01 -0500 )edit