运行时报错FileNotFoundError: [Errno 2] No such file or directory: 'data/superpoint/superpoint_v1.pth'
错误出现的代码
f = open(f, 'rb')
elif (sys.version_info[0] == 3 and isinstance(f, pathlib.Path)):
new_fd = True
data文件夹结构 data/modle
/superpoint/superpoint_v1.pth
如何更改代码能让程序正常运行
代码不全,目录不全
解决方法
两种简单的方法:
1、文件名使用绝对路径
而不是相对路径
或者
2、将superpoint_v1.pth
文件复制拷贝到这个路径下的每一个路径
如有问题及时沟通
f这个变量
data/superpoint/superpoint_v1.pth
目录要直达盘符
完整路径
先查找superpoint_v1.pth文件在哪
找到后,右键属性,复制完整路径