See attached photos for reference.

raw photo Parts I want removed

I tried watershedding, it breaks apart the main body and doesnt even touch the part I want disconnected!

morphology is no good, the holes in the main body easily break in two before the edges I want disconnected come off.

imfill doesn't solve this, it fills the hole between the two trouble areas as well as the holes in the main body.

I have thousands of similar photos, so I need to come up with something robust.

I'd appreciate any help I could get!

  • 2
    $\begingroup$ By what criteria do you judge the circled areas to be "weak"? Edge strength typically refers to a gradient in a grayscale image. What you've circled looks more like concavities at the borders of connected regions. $\endgroup$
    – Rethunk
    Jul 12 '17 at 1:44

When you are dealing with a binary image (black and white with 1 bit per pixel intensity) you loose all the continuous gradient information, and therefore cannot make use of edge detection (or removal) algortihms that rely on it.

Instead you can return to geometric features such as line length, edge thickness (indeed line thikness), surface area etc to classify features found in the image.

A weak edge should have a corresponding definition in terms of feature geometries so that it can be detected and removed (replaced) if necessary.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.