zoukankan      html  css  js  c++  java
  • 多尺度二维离散小波分解wavedec2

    对X进行N尺度小波分解 [C,S]=wavedec2(X,N,'wname');
    clc,clear all,close all;
    load woman;
    [c,s]=wavedec2(X,2,'db1');%进行2尺度二维离散小波分解。分解小波函数-db1
    [cH1,cV1,cD1]=detcoef2('all',c,s,1);%尺度1的所有方向的高频系数
    [cH2,cV2,cD2]=detcoef2('all',c,s,2);%尺度2的所有方向的高频系数
    cA1=appcoef2(c,s,'db1',1);%尺度1的低频系数
    cA2=appcoef2(c,s,'db1',2);%尺度2的低频系数
    figure,imshow(X,map);title('原图');
    figure;
    subplot(1,2,1),imshow(uint8(cA1));axis off;title('尺度1的低频系数图像');
    subplot(1,2,2),imshow(uint8(cA2));axis off;title('尺度2的低频系数图像');
    figure;
    subplot(2,3,1),imshow(uint8(cH1));axis off;title('尺度1水平方向高频系数');
    subplot(2,3,2),imshow(uint8(cV1));axis off;title('尺度1垂直方向高频系数');
    subplot(2,3,3),imshow(uint8(cD1));axis off;title('尺度1斜线方向高频系数');
    subplot(2,3,4),imshow(uint8(cH2));axis off;title('尺度2水平方向高频系数');
    subplot(2,3,5),imshow(uint8(cV2));axis off;title('尺度2垂直方向高频系数');
    subplot(2,3,6),imshow(uint8(cD2));axis off;title('尺度2斜线方向高频系数');
    

      

  • 相关阅读:
    D
    NOI 1.7编程基础之字符串(35题)
    HYSBZ 2145 悄悄话
    POJ 2406 Power Strings
    POJ 3461 Oulipo[附KMP算法详细流程讲解]
    POJ 3974 Palindrome
    POJ 1002 487-3279
    POJ 1182 食物链
    POJ 2524 Ubiquitous Religions
    HDU 1251 统计难题
  • 原文地址:https://www.cnblogs.com/xixixing/p/5827157.html
Copyright © 2011-2022 走看看