2
votes

I am new to Matlab and I am trying to use the wavelet tool box in Matlab. I hope to use the undecimated wavelet transformation on an input image to create a series of images. But I am wondering how can I get the result of the wavelet transformation of each level?

The function I used in the program is

WTSource = ndwt2(Source, n, 'db1');

Where Source is the input image, n is the levels of the transformatino and 'db1', or haar transformation, is used to generate the images.

I had thought WTSource.dec is the result images, but I found that the size of the elements in WTSource.dec is different from the input image. And as n increases, the images became larger. So I am wondering how should I get the result images of the transformation for further use?

1

1 Answers

1
votes

If you look at the documentation
http://www.mathworks.nl/help/wavelet/ref/ndwt2.html
after your command:

 WTSource= ndwt2(Source,n,'db1');

the output WTSource is a record with a field dec that contains all those fields.

dec{ 1 }        approximation level n
dec{2 : 4}     detail level n-1 (channels LH, HL, HH)
dec{5 : 7}     detail level n-2 (channels LH, HL, HH)
 ...
dec{3n-1 : 3n+1} detail level 1  (channels LH, HL, HH)

Each element of dec is the same size as your input image.

See also:
http://www.mathworks.nl/products/wavelet/examples.html?file=/products/demos/shipping/wavelet/ndwtdemo.html