|
|
Subtracting background from an image
Hi,
In Matlab, I am trying to subtract a background image ([url=http://www.freeimagehosting.net/image.php?52da94ec0d.jpg][img]http://www.freeimagehosting.net/uploads/th.52da94ec0d.jpg[/img][/url]) from an original image ([url=http://www.freeimagehosting.net/image.php?1888ec1fef.jpg][img]http://www.freeimagehosting.net/uploads/th.1888ec1fef.jpg[/img][/url]) that I have. From the short code I have written, the background image is removed from the original image but there is a dark shade on the side of the image ([url=http://www.freeimagehosting.net/image.php?eca45fbcf6.jpg][img]http://www.freeimagehosting.net/uploads/th.eca45fbcf6.jpg[/img][/url]) that I have been trying to get rid of but don't know how. I was wondering if there was a way to get rid of the dark shade or another way to remove the background image from the original image?
Code:
B=imread('25x_prepared.jpg');
figure;imshow(B);
background=imread('25x_prepared_bckgnd.jpg');
figure;imshow(background);
B1=B-background;
figure;imshow(B1);
-Courtney
|
|
0
|
|
|
|
Reply
|
Courtney
|
9/18/2010 9:46:06 AM |
|
Courtney:
Well there's two reasons that I would guess:
1. Your background image is not really a background image. It looks
like it has already been flattened. It does not have the same overall
shape (profile) as the sample image.
2. You're subtracting the background. People often incorrectly talk
about background subtraction as if that's the mathematically accurate
and appropriate thing you want to do. Unless you're doing radiology,
which it doesn't look like you are, you don't want to do background
subtraction. It looks like you're doing microscopy of thin samples.
You'd have much better results doing a background division. Why?
Well if you have 90% as much light coming in at the corner as you do
at the middle, don't you think you'd need to divide by .9 out there?
You can try that once you get a valid background (not one already
flattened).
Good luck,
ImageAnalyst
|
|
0
|
|
|
|
Reply
|
ImageAnalyst
|
9/18/2010 12:28:11 PM
|
|
|
1 Replies
527 Views
(page loaded in 0.052 seconds)
Similiar Articles: the background subtraction - comp.soft-sys.matlabhi all, plz if any one could help me as i want to remove the background of sign language image. Regards ... periodic noise removal - comp.soft-sys.matlabI'm taking a background image (with no object) then taking another image within a few seconds with the object. I then subtract the background from the foreground image as ... Remove foreground. - comp.soft-sys.matlabHow to remove background on picture! - comp.graphics.apps ... How can I remove on a picture, for ... subtract the background from the foreground image as the first ... Spectral Subtraction Technique in Noise Reduction of Audio File ...need algorithm to remove mixed noise from image - comp.soft-sys ... Spectral Subtraction Technique ... the background subtraction - comp.soft-sys.matlab Spectral Subtraction ... Selecting a background frame for a moving object differentiation ...the background subtraction - comp.soft-sys.matlab how to make camera on the moving object ... Stretch, moving slow in Cadence 6 - comp.cad.cadence... an image from a ... correcting background non_uniform illumination - comp.soft-sys ...> I have a image with non-uniform background illumination, one side is darker, the other ... the background subtraction - comp.soft-sys.matlab correcting background non ... real-time object tracking using optical flow / XY coordinates ...Standart method for such task is to subtract static background. First make phot of empty ... algorithm in the Matlab -> start -> demos -> blocksets -> video and image ... What software to render a bead or tile pattern from a scan? - comp ...Open a working copy of a scanned > image. Promote the background layer and increase the canvas ... eye coordinate is (X1, Y1), compute how many bead sizes you can subtract ... remove backgroud using global threshold - comp.soft-sys.matlab ...the background subtraction - comp.soft-sys.matlab hi all, plz if any one could help ... If you're scanning black or dark text on a light background, I ... the image the black ... color detection in matlab - comp.soft-sys.matlabfor example when image has red color only it set a value to an integer which ... the background subtraction - comp.soft-sys.matlab This is demonstrated in my simple color ... How to Do Background Subtraction | eHow.comAn example of this would be when you want to remove the background of an image, leaving only the people or objects in the foreground. When you subtract the background ... Background Subtraction - Molecular Expressions: Images from the ...Interactive Java Tutorials Background Subtraction. Application of a suitable background subtraction algorithm is a useful technique for correcting image defects that ... 7/22/2012 1:51:59 PM
|
|
|
|
|
|
|
|
|