Ask Your Question

Remove white noise between white horizontal line

asked 2019-02-20 08:39:06 -0500

updated 2019-02-20 08:58:31 -0500

I currently have an image with white horizontal lines. between those lines, there is some noise that I would like to remove. I've already done Morphological Opening on the original image and the current one.

image description

Does someone have an idea on how I could remove some of this noise between the lines?

original image: image description


edit retag flag offensive close merge delete


If you have threshold. Then increasing value between 50 to 127. Then another one is dilate and erode.If you could post orignal image.

supra56 gravatar imagesupra56 ( 2019-02-20 08:46:52 -0500 )edit

The current image uses dilate en erode and it does work as you could see the noise isn't that bad between the lines, I'm wondering if there is a way so I could remove the remaining noise between the lines

Tom_ColdenhoffVMT gravatar imageTom_ColdenhoffVMT ( 2019-02-20 08:51:06 -0500 )edit

1 answer

Sort by ยป oldest newest most voted

answered 2019-02-20 08:55:29 -0500

kbarni gravatar image

updated 2019-02-20 09:01:27 -0500

Well, that's an ugly image!

I suggest to clean up the original (RGB) image, it's much easier than the binary image.

Try also to improve the binarization (e.g. work on HSV or LAB color space, use several channels, combine the RGB channels) to get a cleaner result. If you post the original image, you could get better ideas.

If you must work with the binary image, a directional diffusion (Perona&Malik method, ~~not part of OpenCV~~ correction: see below) could be a solution.

[EDIT] I was wrong, Perona-Malik is part of the Extended image processing module: cv::ximgproc::anisotropicDiffusion

edit flag offensive delete link more


Thank you for your reaction. I've also add the original image right now. I've to make the edges between the items on the stack clearer so that the edge recognition is able to see them better

Tom_ColdenhoffVMT gravatar imageTom_ColdenhoffVMT ( 2019-02-20 08:59:46 -0500 )edit
Login/Signup to Answer

Question Tools

1 follower


Asked: 2019-02-20 08:39:06 -0500

Seen: 24 times

Last updated: Feb 20