how to write matlab code for third level DWT ?

9 Ansichten (letzte 30 Tage)
namita chandrakar
namita chandrakar am 22 Nov. 2014
Kommentiert: Asfaw Alem am 19 Feb. 2023
hello..im writing a code for getting an image and perform dwt for one level to get 4 sub bands, ,but i want to apply third level DWT for getting image of 3rd level decomposion, so kindly help me and correct my code for 3rd level DWT. the code i have written is shown below.
%Read Input Image
Input_Image=imread(‘rose.bmp’);
%Red Component of Colour Image
Red_Input_Image=Input_Image(:,:,1);
%Green Component of Colour Image
Green_Input_Image=Input_Image(:,:,2);
%Blue Component of Colour Image
Blue_Input_Image=Input_Image(:,:,3);
%Apply Two Dimensional Discrete Wavelet Transform
[LLr,LHr,HLr,HHr]=dwt2(Red_Input_Image,’haar’);
[LLg,LHg,HLg,HHg]=dwt2(Green_Input_Image,’haar’);
[LLb,LHb,HLb,HHb]=dwt2(Blue_Input_Image,’haar’);
First_Level_Decomposition(:,:,1)=[LLr,LHr;HLr,HHr];
First_Level_Decomposition(:,:,2)=[LLg,LHg;HLg,HHg];
First_Level_Decomposition(:,:,3)=[LLb,LHb;HLb,HHb];
First_Level_Decomposition=uint8(First_Level_Decomposition);
%Display Image
subplot(1,2,1);imshow(Input_Image);title(‘Input Image’);
subplot(1,2,2);imshow(First_Level_Decomposition,[]);title(‘First Level Decomposition’);

Antworten (1)

nadhir nouioua
nadhir nouioua am 2 Apr. 2020
Hello sir,
Here is a way of decomposition into third level, I think u can do the rest now, good luck.
[LLr1,LHr1,HLr1,HHr1]=dwt2(Red_Input_Image,’haar’);
[LLr2,LHr2,HLr2,HHr2]=dwt2(LLr1,’haar’);
[LLr3,LHr3,HLr3,HHr3]=dwt2(LLr2,’haar’);
  2 Kommentare
ghilani aya
ghilani aya am 29 Apr. 2021
how to create in imshow?
Asfaw Alem
Asfaw Alem am 19 Feb. 2023
for 1-D signal decomposition

Melden Sie sich an, um zu kommentieren.

Kategorien

Mehr zu Wavelet Toolbox finden Sie in Help Center und File Exchange

Produkte

Community Treasure Hunt

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

Start Hunting!

Translated by