# 需要導入模塊: import torch [as 別名]# 或者: from torch importprod[as 別名]defms_ssim(self, img1, img2, levels=5):weight = Variable(torch.Tensor([0.0448,0.2856,0.3001,0.2363,0.1333]).cuda()) msssim = Variable(torch.Tensor(levels,).cuda()) mcs = Variable(torch.Tensor(levels,).cuda...
# 需要导入模块: import torch [as 别名]# 或者: from torch importprod[as 别名]defms_ssim(self, img1, img2, levels=5):weight = Variable(torch.Tensor([0.0448,0.2856,0.3001,0.2363,0.1333]).cuda()) msssim = Variable(torch.Tensor(levels,).cuda()) mcs = Variable(torch.Tensor(levels,).cuda...
metrics['val.generated_score'].append(generated_score.item()) metrics['val.ssim'].append(ssim(cover, generated).item()) metrics['val.psnr'].append(10* torch.log10(4/ encoder_mse).item()) metrics['val.bpp'].append(self.data_depth * (2* decoder_acc.item() -1)) 开发者ID:DAI-Lab...
(aamddiedeccdrreleeaa)s.seeTihinnetthmheeonsnutumpmrbobenerroouofnfcccoeoldloonaninieetssimiissiocorbbossbeeirarvvleeeddf.f.eFFcootrroccfhhteehrrerriiepessla,, stthmheeattrtreoearatctmhmeetnrnettaddtmuurreaantttiiooins odoffet11e55ctssehdhaafssoara bnnleeuggellibiggeiribbrlieleees,feffwefce...