Machine Vision

cancel
Showing results for 
Search instead for 
Did you mean: 

Broken line(edge) detection from binary image

Hi,

I'm trying to mark(detect) 4 straight lines from a binary image and whether any of them are broken (not straith).
If there are any broken lines, i wish to mark(detect) these lines (edges) with a vertical line (which in this case(Test_Image) is located up in the right side corner).
I have created an application(VI) which seems to work well with the "raw" image, but when I extract the colorplane (blue) and try to detect the lines from the binary image (not the raw image), i can't seem to find anything. Maybe i'm using the wrong tools(VI's) or simply the wrong parameters(to much noise?).

Any suggestions? Smiley Happy

(It works when I use: "First Edge Rake" detection, but then I can only detect one horizontal line)

Example.JPG

Download All
0 Kudos
Message 1 of 4
(3,064 Views)

No one? Smiley Surprised

0 Kudos
Message 2 of 4
(3,004 Views)

Hey SinSch,

 

You are right in saying that there is quite a lot of noise in this image.I have had a play around with your image in Vision Assistant, I recommend you do the same to try and find the optimal settings for your image. 

 

It seems to work in the raw picture as you have your block that creates a solid edge for the vision application to reference. When you convert it to a binary image this edge is no longer as visible. You may benefit from improving the lighting in your image.

 

Hope this helps.

 

Best,

 

-Jelmer.

0 Kudos
Message 3 of 4
(2,964 Views)

After testing a few different values, I've found that "Minimum Edge Strength" must be below "1" to get satisfactory results (detect multiple lines).

I ended up with:

Line [Type: Hough Edge Rake | Iterations: 32 | Step size: 25]

Line (Edge) [Polarity: Falling Edges | Kernal: 9 | Width: 9 | Min edge strength: 1.0]

Edge [Polarity: All Edges | Kernal: 9 | Width: 45 | Min edge strength: 0.3]

Smiley Happy

Message 4 of 4
(2,923 Views)