1
$\begingroup$

I have some images of a background, and of steam that I am subtracting to extract just the steam. Unfortunately, because the camera conditions are not perfect the differenced image is always a few pixels off generating sharp lines where features in the background don't match up pixel-by-pixel like so

Sharp lines and some noise

I'm interested in segmenting out the steam (foreground noise), from the background. I think if I can automatically remove the continuous lines from this image it would be sufficient for my purposes.

Unfortunately it's been almost ten years since my image analysis work and I don't remember what you do to detect continuous lines. What are some simple well preforming algorithms to do this?

$\endgroup$
1
$\begingroup$

I have two methods to suggest: 1. Use the erosion (morphological operator) (you can also use other operators like closing/opening). But i think it will destroy the steam data also... 2. A better solution is to detect the lines using hough transform. Google it and you'll find tons of info about it (if your'e using MATLAB, there is a guide how to do it in their website)

Have fun...

$\endgroup$
  • $\begingroup$ I don't see how a morphological operator would segment out continuous lines. If they were just vertical or horizontal I could use something, but they're tilted and curved so I need specifically continuous stuff. I've been looking at Hough transform a bit but am not sure I'm understanding how its useful for identifying continuous lines. $\endgroup$ – George Mauer Nov 25 '13 at 20:38
  • 1
    $\begingroup$ I used the code described here mathworks.com/help/images/ref/houghlines.html and got good (i did it QnD...). Any way, hough transform is mainly used to detect lines, the main problem with it that it cannot detect vertical lines so you need to rotate the image to detect these lines. $\endgroup$ – Muhammad Nov 25 '13 at 21:02
  • 1
    $\begingroup$ Well, i found a more detailed answer, take a look at it: stackoverflow.com/questions/2596722/… $\endgroup$ – Muhammad Nov 25 '13 at 21:07
1
$\begingroup$

One approach is find all contours in your source image and compute the area of each contour. And finally ignore the contours who have area greater than a threshold. You can refer this link to know more about contour processing.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.