I have a binary thresholed image of cart with ribs and some of them are cracked.
I need to use something like cv2.distanceTransform() to get markers for watershed algorithm, but I need to get rid of cracks. If I keep cracks, distance transform disconnects me the rib into several pieces
I tried closing of dilating, but it efects balls in between ribs and I don't get each rib separate
Of course I have tried different values of thresholding in distance transformed image, but when I filter balls by threshold, I split rib too.
Is there something like bay-removing algorithm? Or is there some better way?
Create a filter that looks for surrounding pixels (mostly vertical pixels) to decide what color the central pixel should be. ea