【超分辨率】超分辨率中的imresize函数(python, Matlab)

背景:

超分辨率挑战赛Super Resolution Challenges (e.g. NTIRE) 降采样(downscaling)- bicubic interpolation- 是利用Matlab的imresize()函数实现的。

Track info:
Track 1: bicubic uses the bicubic downscaling (Matlab imresize), one of the most common settings from the recent single-image super-resolution literature.

More info:
For obtaining the low res images we use the Matlab function “imresize” with default settings (bicubic interpolation) and the desired downscaling factors: 2, 3, and 4.

导致

由于目前主流的论文采用的都是Matlab的imresize函数,这也就导致了两个问题:

  1. 我们对训练集的构造需要利用Matlab的imresize去实现
  2. 参考的一些算法的预插值也是用的Matlab的imresize函数

Matlab中的实现方式:

一般来说,先对图像进行归一化至[0,1]之间,然后再进行resize,然后再进行计算PSNR。

im  = imread(['./Set5/' num2str(imglist(i).name)]);
im = modcrop(im, up_scale);
if size(im,3)>1
    im = rgb2ycbcr(im);
    im = im(:, :, 1);
end
im_gnd = im;
im_gnd = single(im_gnd)/255;

im_l = imresize(im_gnd, 1/up_scale, 'bicubic');
im_b = imresize(im_l, up_scale, 'bicubic');

im_gnd = shave(uint8(i
评论 2
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

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

余额充值