%代码来源:https://github.com/xinntao/BasicSR
function generate_bicubic_img()
%% matlab code to genetate mod images, bicubic-downsampled images and
%% bicubic_upsampled images
%% set configurations
% comment the unnecessary lines
input_folder = 'D:/数据集/新建文件夹/image'; %输入文件路径
%save_mod_folder = '../../datasets/Set5/GTmod12';
save_lr_folder = 'D:/数据集/新建文件夹/LR_X4'; %下采样后保存路径
% save_bic_folder = '';
mod_scale = 12;
up_scale = 2; %下采样倍数
if exist('save_mod_folder', 'var')
if exist(save_mod_folder, 'dir')
disp(['It will cover ', save_mod_folder]);
else
mkdir(save_mod_folder);
end
end
if exist('save_lr_folder',
双三次差值下采样代码 matlab
最新推荐文章于 2023-03-20 23:09:50 发布