Ask Your Question

Revision history [back]

Why does the foreground image from background subtraction look transparent?

Hello!

I've been working on background subtraction techniques to detect humans in a scene. Because I don't want the background to change, and just subtract the frames from the first reference frame, I've tried both the OpenCV MOG2(with learning parameter set to zero) and using the first frame and using the absdiff() to find the difference. But the foreground images I get from both techniques looks transparent as in, part of the background can be seen through the person as shown below:

Results with the absdiff() technique:

-Original Image:

image description

-Foreground Image:

image description

Results with the MOG2:

-Original Image:

image description

-Foreground Image:

image description

And this is the background(reference) image for both the methods:

image description

Does anyone know why this happens? I need to detect and track the people for which I find the blobs and because of the transparency the blobs are pretty much detected as two blobs which messes up everything else.

Thanks in advance!

Why does the foreground image from background subtraction look transparent?

Hello!

I've been working on background subtraction techniques to detect humans in a scene. Because I don't want the background to change, and just subtract the frames from the first reference frame, so I've tried both the OpenCV MOG2(with learning parameter set to zero) and using the first frame and using the absdiff() to find the difference. But the foreground images I get from both techniques looks transparent as in, part of the background can be seen through the person as shown below:

Results with the absdiff() technique:

-Original Image:

image description

-Foreground Image:

image description

Results with the MOG2:

-Original Image:

image description

-Foreground Image:

image description

And this is the background(reference) image for both the methods:

image description

Does anyone know why this happens? I need to detect and track the people for which I find the blobs and because of the transparency the blobs are pretty much detected as two blobs which messes up everything else.

Thanks in advance!

Why does the foreground image from background subtraction look transparent?

Hello!

I've been working on background subtraction techniques to detect and track humans in a scene. Because I don't want the background to change, and just subtract the frames from the first reference frame, so I've tried both the OpenCV MOG2(with learning parameter set to zero) and using the first frame and using the absdiff() to find the difference. But the foreground images I get from both techniques looks transparent as in, part of the background can be seen through the person as shown below:

Results with the absdiff() technique:

-Original Image:

image description

-Foreground Image:

image description

Results with the MOG2:

-Original Image:

image description

-Foreground Image:

image description

And this is the background(reference) image for both the methods:

image description

Does anyone know why this happens? I need to detect and track the people for which I find the blobs and because of the transparency the blobs are pretty much detected as two blobs which messes up everything else.

Thanks in advance!