I have two groups of dots that both contain noise between them:
The line that separates the two groups in the picture is diagonal in shape. I tried to use morphological filtering on this image to remove the noise between these two groups but failed.
This is the code that I tried to run on this image:
from skimage.morphology import opening, square new_image = opening(image, square(3))
It did remove a little bit of noise, but not enough for them to become two distinct groups.
I am using DBSCAN on the
new_image and DBSCAN still treats them as one group.
I would like to know whether I am giving the correct argument to the function opening. Or maybe there is some other way (better way) to remove the noise between the two groups?