pythonb超分辨成像_使用神经网络进行图像超分辨踩的坑

1、matlab的bicubic结果会有小于0或者大于255的情况出现。

Image interpolation wrong for pixel values exceeding vmax #8631

MATLABresize函数中也说明了:

% For bicubic interpolation, the output image may have some values

% slightly outside the range of pixel values in the input image. This

% may also occur for user-specified interpolation kernels.

%

2、神经网络训练出来的结果也会有小于0或者大于255的情况出现

Also remember that loss function is based on scaled images (pixel values between 0 and 1), so the predicted residual has to be scaled back by 255 before it is added to low resolution image. If some pixels become negative or go above 255, we return them to 0 and 255 respectively before saving.

解决方法:

make sure no pixels are outside [0, 255] interval

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值