I am getting the error Missing variable or function when I am trying to implement a code on 2 dimensional DWT on images in MATLAB 7. The code is given below.

4 visualizzazioni (ultimi 30 giorni)
f = imread('Region_of_interest.bmp');
imshow(f)
wname = 'sym4';
[CA,CH,CV,CD] = dwt2(X,wname,'mode','per');
subplot(211)
imagesc(CV); title('Vertical Detail Image');
subplot(212)
imagesc(CA); title('Lowpass Approximation');
Sir, kindly help me.
thanks and regards
Debarpita Chaudhuri.

Risposta accettata

Walter Roberson
Walter Roberson il 8 Mar 2016
dwt2() is part of the Wavelet toolbox. You would need to have that installed and licensed.
  2 Commenti
Debarpita Chaudhuri
Debarpita Chaudhuri il 9 Mar 2016
Modificato: Debarpita Chaudhuri il 16 Mar 2016
Sir, I do have wavelet toolbox. Is there any chance that the image variable X or f is not treated as a matrix right away. Do I need to add some code to change the the image variable into a 2-D Matrix so that dwt2() may give a proper output? thanks and regards Debarpita Chaudhuri.
Debarpita Chaudhuri
Debarpita Chaudhuri il 16 Mar 2016
Modificato: Debarpita Chaudhuri il 16 Mar 2016
Sir, my code is running now with the image of barbara. The code is given below
if true
% load woman;
wname = 'sym4';
[CA,CH,CV,CD] = dwt2(X, wname, 'mode', 'per');
subplot(211)
imagesc(CV); title('Vertical Detail Image');
colormap gray;
subplot(212)
imagesc(CA); title('Lowpass Approximation');
end
How do I edit this code to input a bmp image of my own, as for example the image given here.

Accedi per commentare.

Più risposte (0)

Categorie

Scopri di più su Denoising and Compression in Help Center e File Exchange

Tag

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by