• 【图像去噪】基于空间光谱总变化减少高光谱图像的混合噪声(Matlab代码实现)


     👨‍🎓个人主页:研学社的博客 

    💥💥💞💞欢迎来到本博客❤️❤️💥💥

    🏆博主优势:🌞🌞🌞博客内容尽量做到思维缜密,逻辑清晰,为了方便读者。

    ⛳️座右铭:行百里者,半于九十。

    📋📋📋本文目录如下:🎁🎁🎁

    目录

    💥1 概述

    📚2 运行结果

    🎉3 参考文献

    🌈4 Matlab代码实现

    💥1 概述

    文献来源:

     本文介绍了一种基于时空总变化的高光谱去噪算法。去噪问题被表述为混合降噪问题。已经考虑了一种通用噪声模型,该模型不仅考虑了高斯噪声,还考虑了稀疏噪声。利用空间维度的二维总变化和光谱维度上的一维总变化,利用了高光谱图像的固有结构。去噪问题被表述为一个优化问题,其解决方案是使用分裂布雷格曼方法推导的。实验结果表明,所提算法能够显著降低真实噪声高光谱图像的噪声。所提出的算法已与现有的先进方法进行了比较。定量和定性结果表明,所提算法在峰值信噪比、结构相似性和视觉质量方面具有优越性。

    📚2 运行结果

    部分代码:

    %% Some initializations
    [m,n,dim]=size(noisy); mn=m*n;
    y=reshape(noisy,mn*dim,1); 
    b1=zeros(mn*dim,1); x=y;b2=b1; p=b1;q=b1; s=b1; 

    % Make total variation matrix
    Dh=TVmatrix(m,n,'H');
    Dv=TVmatrix(m,n,'V');
    D=opTV1(dim);D=D';
    D1=kron(D',Dh); D2=kron(D',Dv);
    %D1=KronProd({Dh,D'}); D2=KronProd({Dv,D'});
    %% Main iteration
     for i=1:maxiter
        
        %solve subproblem for x
        bigY=(y-s)+nu*D1'*(p-b1)+nu*D2'*(q-b2);        
        [x,~]=lsqr(@afun,bigY,1e-15,10,[],[],x);  
         
         p=SoftTh(D1*x+b1,mu/nu);
         q=SoftTh(D2*x+b2,mu/nu);
         s=SoftTh(y-x,lambda);
                   
         %Update B1,B2 and B3
         
         b1=b1+D1*x-p;
         b2=b2+D2*x-q;
         
        if rem(i,10)==0
            fprintf('%d iterations done of %d \n ',i,maxiter);
        end
     end
     denoised=reshape(x,m,n,dim); 
    %% This is a function handle used in LSQR
     function y = afun(x,str)
           tempval= nu*((D1'*(D1*x))+(D2'*(D2*x)))+ x;
                switch str
                    case 'transp'
                        y = tempval;
                    case 'notransp'
                        y = tempval;
                end
      end
     
    end
    %% Soft Thresholding
    function X=SoftTh(B,lambda)
          
           X=sign(B).*max(0,abs(B)-(lambda/2));
           
    end
    %%  Total Variation
    %This function will generate total variation operator for an image of size
    %mxn. Both horizontal and vertical total variation operators can be made
    %using this code.
    function opD=TVmatrix(m,n,str)

    if str=='H' % This will give matrix for Horizontal Gradient
        D = spdiags([-ones(n,1) ones(n,1)],[0 1],n,n);
        D(n,:) = 0;
        D = kron(D,speye(m));
       
    elseif str=='V' %This will give matrix for Verticle Gradient
       D = spdiags([-ones(m,1) ones(m,1)],[0 1],m,m);
       D(m,:) = 0;
       D = kron(speye(n),D);
    end
    opD=D;

    end
    %% This function will generate total variation operator for 1D signals
    function opD=opTV1(m)

    %Make two vectors of elements -1 and 1 of lengths (m-1)
    B=[ -1*ones(m-1,1),ones(m-1,1)]; 
    %Make sparse diagonal matrix D of size m-1 by m
    %with -1's on zeroth diagonal and 1's on 1st diagonal;
    D=spdiags(B,[0,1],m-1,m);

    🎉3 参考文献

    部分理论来源于网络,如有侵权请联系删除。

    [1]H. K. Aggarwal and A. Majumdar, "Hyperspectral Image Denoising Using Spatio-Spectral Total Variation," in IEEE Geoscience and Remote Sensing Letters, vol. 13, no. 3, pp. 442-446, March 2016, doi: 10.1109/LGRS.2016.2518218.

    🌈4 Matlab代码实现

  • 相关阅读:
    【python】Django——连接mysql数据库
    C语言 深入探究C语言中的文件操作
    go调用 c++中数组指针相关
    selenium的使用细节
    计算机组成原理期末复习第四章-1(唐朔飞)
    动画讲解TCP的3次握手,4次挥手,让你一次看明白
    产品经理基础--04流程图与结构图
    【前段工程化】经验总结03-ESNext到底是个啥?tsconfig.json配置文件中的ESNext, ESNext和ES6的关系
    [02] BLEMotion-Kit 基于QMI8658传感器使用加速度计进行倾斜检测
    乐趣国学—品读“富润屋,德润身。”中的智慧
  • 原文地址:https://blog.csdn.net/weixin_46039719/article/details/127875211