calculate phase angle from image and validate it, Diff b/w phase and phase spectrum?
    6 views (last 30 days)
  
       Show older comments
    
I am working on a acoustic microscope
What is the difference between phase and phase spectrum?
I have a 2d image 360x360 This image has been created using capturing amplitude of the reflected wave.
I want to calculate the phase angle of this image
My attempt(saw this Image reconstruction only by its phase or magnitude - MATLAB Answers - MATLAB Central (mathworks.com)):
image = rgb2gray(imread('coin.jpg')); 
F = fft2(double(image));
F_Mag = abs(F);
F_Phase = exp(1i*angle(F));
% reconstructin
I_Mag = ifft2(log(F_Mag+1));
I_Phase = ifft2(F_Phase);
% Calculate limits for plotting
I_Mag_min = min(min(abs(I_Mag)));
I_Mag_max = max(max(abs(I_Mag)));
I_Phase_min = min(min(abs(I_Phase)));
I_Phase_max = max(max(abs(I_Phase)));
% Display reconstructed images
subplot(121),imagesc(abs(I_Mag),[I_Mag_min I_Mag_max]), colormap gray 
title('reconstructed image only by Magnitude');
subplot(122),imagesc(abs(I_Phase),[I_Phase_min I_Phase_max]), colormap gray 
title('reconstructed image only by Phase');
phase=rad2deg(angle(I_Phase));
But I'm not sure this I'm getting is phase or not?
How to validate this?



0 Comments
Answers (0)
See Also
Categories
				Find more on Image Filtering and Enhancement in Help Center and File Exchange
			
	Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!