Eliminating lone pixels and connecting pixels

May i know if there is a plugin in Image J that makes it possible to eliminates stand-alone pixels in the background. Also, how can i connect pixels that are in close proximity to each other.

Hi @jubilee,

There is a very similar post regarding lines and here the same methods would work. So potentially you might want to have a look here: Getting rid of small lines in an image!

For single individual pixels you might run the Analyze Particles… and exclude the pixel “size” 1, e.g. use the parameter “2-Infinity”.

The other option would be to actually run >Process >Binary >Options... and set the count parameter to 8.

To connect objects you might give the EDM Binary Operations a trial by using its close funtion. For very thin objects that might change the object slightly.

cheers,
Jan

1 Like

Hello @jubilee,

If your images are grayscale, you can give a try to MorphoLibJ, especially the top-hat morphological filters.

ignacio

2 Likes

the classic method for “eliminating lone pixels” is the median operator but of course, methods will depend on what you exactly mean by “lone pixels”.

Best

Herbie

2 Likes

Great, i was able to eliminate the unwanted pixels using the remove outliers function ( process- Noise-Remove outliers)