首页 PaddleHub 帖子详情
使用MiDaS_Small预训练模型,加载时报错没有该模型
收藏
快速回复
PaddleHub 问答预训练模型 685 1
使用MiDaS_Small预训练模型,加载时报错没有该模型
收藏
快速回复
PaddleHub 问答预训练模型 685 1

在下载完与训练模型之后进行简单的调用测试报错:

import imp
[2021-09-10 11:53:54,766] [ WARNING] - An error was encountered while loading MiDaS_Small. Detailed error information can be found in the C:\Users\Administrator\.paddlehub\log\20210910.log.
[2021-09-10 11:53:54,768] [ WARNING] - An error was encountered while loading MiDaS_Small. Detailed error information can be found in the C:\Users\Administrator\.paddlehub\log\20210910.log.
Download https://bj.bcebos.com/paddlehub/paddlehub_dev/MiDaS_Small.tar.gz
[######################################### ] 83.13%
[2021-09-10 11:54:22,184] [ WARNING] - An error was encountered while loading MiDaS_Small. Detailed error information can be found in the C:\Users\Administrator\.paddlehub\log\20210910.log.
[2021-09-10 11:54:22,197] [ WARNING] - An error was encountered while loading MiDaS_Small. Detailed error information can be found in the C:\Users\Administrator\.paddlehub\log\20210910.log.

 

错误日志内容为:

Record at 2021-09-10 11:40:55
==================================================
Traceback (most recent call last):
File "D:\tool\Miniconda3\envs\py36\lib\site-packages\paddlehub\module\manager.py", line 224, in search
module = self._local_modules[name] = HubModule.load(module_dir)
File "D:\tool\Miniconda3\envs\py36\lib\site-packages\paddlehub\module\module.py", line 418, in load
py_module = utils.load_py_module(dirname, '{}.module'.format(basename))
File "D:\tool\Miniconda3\envs\py36\lib\site-packages\paddlehub\utils\utils.py", line 248, in load_py_module
py_module = importlib.import_module(py_module_name)
File "D:\tool\Miniconda3\envs\py36\lib\importlib\__init__.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "", line 978, in _gcd_import
File "", line 961, in _find_and_load
File "", line 945, in _find_and_load_unlocked
ModuleNotFoundError: No module named 'MiDaS_Small.module'; 'MiDaS_Small' is not a package

已经确认过paddle版本和paddlehub版本满足要求

求问原因,谢谢大佬们

0
收藏
回复
全部评论(1)
时间顺序
FutureSI
#2 回复于2021-09

报错没找到 MiDaS_Small.module 这个模块,用 hub install 重新安装下试试

0
回复
需求/bug反馈?一键提issue告诉我们
发现bug?如果您知道修复办法,欢迎提pr直接参与建设飞桨~
在@后输入用户全名并按空格结束,可艾特全站任一用户