Hi all,
I'm detecting circular objects in an image by first getting a binary map based on color deviation from the background and then getting the contours of the connected components (and then a bunch of other stuff). The thing is that there may be text written over the objects, which results in that the objects are split into several parts. The text can be small and just inside some connected component or it may be many times larger than the components. I can generate a mask for the text based on its color. I want to ignore the text somehow, but I'm not quite sure how.
I see three possible ways forward: -Deal with this when first getting the connected components -Merge contours which are connected by the text mask -Get contours which include the text and then modify the contours afterwards
Any help with this would be much appreciated! Maybe there is even some clever OpenCV function for this? Thanks!