admin管理员组

文章数量:1567522

module ‘kornia’ has no attribute ‘warp_perspective’

安装了kornia版本为0.6.13
但直接使用import调用kornia,无法使用warp_perspective()函数,出现标题中的报错。

解决方法

使用from直接指示调用,并将代码中kornia.warp_perspective改为warp_perspective。

# import kornia
from kornia.geometry.transform import warp_perspective

本文标签: korniaModulewarpperspectiveattribute