Message Boards Message Boards

0
|
1715 Views
|
2 Replies
|
2 Total Likes
View groups...
Share
Share this post:

Equation from EdgeDetect function to determine straight or curved edges

Posted 1 year ago

Hello all,

Is there a way to extract what equation the EdgeDetect function used to identify edges in an image? I need to figure out whether the edges detected are straight lines or curved lines or something else

Thanks in advance for your help.
Sudip

2 Replies

Sudip,

the option Method -> ("StraightEdges" -> ...) and/or the command ImageLines[] might be helpful, e.g.:

img = Import["https://reference.wolfram.com/language/ref/Files/EdgeDetect.en/I_9.png"];
lineImg = EdgeDetect[img, Method -> ("StraightEdges" -> 0.3)];
lines = ImageLines[lineImg, .15];
HighlightImage[lineImg, lines]
POSTED BY: Henrik Schachner

Thanks Henrik. This is very helpful.

Do you know whether there is a way to detect curved lines - i.e. lines that can be represented with a 2nd degree polynomial equation?

Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard

Group Abstract Group Abstract