【基于块分类和字典优化的K-SVD图像去噪研究(MATLAB)】

基于块分类和字典优化的K-SVD图像去噪研究(MATLAB)


前言

(1) 输入原图像,添加泊松噪声,
(2) 采用二维变分模态分解进行预处理;将含噪图像分为高频图像和低频图像;
(3) 采用K-SVD算法训练高频图像对应的字典和低频图像对应的字典,训练完成的字典采用Bartlett检验法优化,最后用优化后的字典分别对高频和低频图像去噪;
(4) 最后将去噪的高频图像和低频图像进行融合,得到最终的去噪图像;

在这里插入图片描述

一、K-SVD算法介绍

K-SVD算法参考文献(基于块分类和字典优化的K-SVD图像去噪研究)

二、主要代码展示

MATLAB APP实现的代码

function varargout = Task1(varargin)
% Task2 M-file for Task2.fig
%      Task2, by itself, creates a new Task2 or raises the existing
%      singleton*.
%
%      H = Task2 returns the handle to a new Task2 or the handle to
%      the existing singleton*.
%
%      Task2('CALLBACK',hObject,eventData,handles,...) calls the local
%      function named CALLBACK in Task2.M with the given input arguments.
%
%      Task2('Property','Value',...) creates a new Task2 or raises the
%      existing singleton*.  Starting from the left, property value pairs are
%      applied to the GUI before Task2_OpeningFcn gets called.  An
%      unrecognized property name or invalid value makes property application
%      stop.  All inputs are passed to Task2_OpeningFcn via varargin.
%
%      *See GUI Options on GUIDE's Tools menu.  Choose "GUI allows only one
%      instance to run (singleton)".
%
% See also: GUIDE, GUIDATA, GUIHANDLES

% Edit the above text to modify the response to help Task2

% Last Modified by GUIDE v2.5 08-Jan-2023 16:13:54

% Begin initialization code - DO NOT EDIT
gui_Singleton = 1;
gui_State = struct('gui_Name',       mfilename, ...
                   'gui_Singleton',  gui_Singleton, ...
                   'gui_OpeningFcn', @Task2_OpeningFcn, ...
                   'gui_OutputFcn',  @Task2_OutputFcn, ...
                   'gui_LayoutFcn',  [] , ...
                   'gui_Callback',   []);
if nargin && ischar(varargin{
   1})
    gui_State.gui_Callback = str2func(varargin{
   1});
end

if nargout
    [varargout{
   1:nargout}] = gui_mainfcn(gui_State, varargin{
   :});
else
    gui_mainfcn(gui_State, varargin{
   :});
end
% End initialization code - DO NOT EDIT


% --- Executes just before Task2 is made visible.
function Task2_OpeningFcn(hObject, eventdata, handles, varargin)
% This function has no output args, see OutputFcn.
% hObject    handle to figure
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
% varargin   command line arguments to Task2 (see VARARGIN)

% Choose default command line output for Task2
% 初始化界面图像显示的Figure
a = ones(8,8);
imshow(a, 'Parent', handles.axes1);
imshow(a, 'Parent', handles.axes2);
imshow(a, 'Parent', handles.axes3);
imshow(a, 'Parent', handles.axes4);
imshow(a, 'Parent', handles.axes5);
imshow(a, 'Parent', handles.axes6);
imshow(a, 'Parent', handles.axes7);

guidata(hObject, handles);

% UIWAIT makes Task2 wait for user response (see UIRESUME)
% uiwait(handles.figure1);


% --- Outputs from this function are returned to the command line.
function varargout = Task2_OutputFcn(hObject, eventdata, handles) 
% varargout  cell array for returning output args (see VARARGOUT);
% hObject    handle to figure
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)

% Get default command line output from handles structure
% varargout{1} = handles.output;


% --- Executes during object creation, after setting all properties.
function edit4_CreateFcn(hObject, eventdata, handles)
% hObject    handle to edit2 (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    empty - handles not created until after all CreateFcns called

% Hint: edit controls usually have a white background on Windows.
%       See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get
  • 0
    点赞
  • 5
    收藏
    觉得还不错? 一键收藏
  • 打赏
    打赏
  • 1
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

20230330

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值