Seperating connecting objects

Hey, I’m currently working on a project regarding fish object classification and detection. At the moment we have extracted the blobs from the original image, however in some of the images we are encountering an issue where some of the blobs are to close to each other, and therefor our program thinks its one object and not two.

So I’m looking for any kind of idea or solution to separate the object from each other, I have tried to erode and use different kind of combination of the morphology methods, but since the fins of the fish sometimes can be really thin, it seems to ruin that method.

I have provided an example image, where it can be seen on the left, that two blobs are connecting which the program then sees as one blob.

any help or direction to where i should look, will be appreciated.

Thanks in advance!
-MNejmann

old methods won’t produce decent results.

these days you should use neural networks for this. there are plenty of trained ones for semantic and instance segmentation.

1 Like

Okay, thats exactly what i was afraid of, since this is for our semester project where we try to compete against Deep learning and neural networks, and therefor wont use these methods.

Thanks for the response anyway :slight_smile:

oh well then you could mess around with morphology operations.

there’s also an article in the docs that uses watershed to separate a mask of coins that are touching.

your picture is already binarized. you should not accept that result as the starting point. look for fixes to the problem before binarization.

1 Like