Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

口罩检测模型报错 #609

Closed
zengqi0730 opened this issue May 18, 2020 · 2 comments
Closed

口罩检测模型报错 #609

zengqi0730 opened this issue May 18, 2020 · 2 comments

Comments

@zengqi0730
Copy link

paddlepaddle-gpu 1.7.0.post107
paddlehub:1.6.2
pyramidbox_lite_mobile_mask:1.3.0
paddleslim 1.0.1


import paddlehub as hub
import cv2

mask_detector = hub.Module(name="pyramidbox_lite_mobile_mask")
print(mask_detector.version)
img = cv2.imread('/home/edu/Desktop/1.jpg')
print(img.shape)
result = mask_detector.face_detection(images=[img],data=None)


[2020-05-18 11:35:10,849] [ INFO] - Installing pyramidbox_lite_mobile_mask module
[2020-05-18 11:35:10,913] [ INFO] - Module pyramidbox_lite_mobile_mask already installed in /home/edu/.paddlehub/modules/pyramidbox_lite_mobile_mask
[2020-05-18 11:35:10,913] [ INFO] - Installing pyramidbox_lite_mobile module
[2020-05-18 11:35:10,917] [ INFO] - Module pyramidbox_lite_mobile already installed in /home/edu/.paddlehub/modules/pyramidbox_lite_mobile
1.3.0
(667, 500, 3)
Traceback (most recent call last):
File "/home/edu/PycharmProjects/paddledemo/zengqi.py", line 300, in
result = mask_detector.face_detection(images=[img],data=None)
File "/home/edu/.paddlehub/modules/pyramidbox_lite_mobile_mask/module.py", line 127, in face_detection
images, paths, use_gpu, use_multi_scale):
File "/home/edu/.paddlehub/modules/pyramidbox_lite_mobile_mask/data_feed.py", line 202, in reader
confs_threshold=confs_threshold)
TypeError: call() missing 1 required positional argument: 'data'

Process finished with exit code 1

口罩模型起不来,请帮忙看下问题

@Steffy-zxf
Copy link
Contributor

你好!根据错误提示,应该是你的pyramidbox_lite_mobile_mask是旧版本,但是预测时候用的预测接口是新版本使用方式。解决方法:

hub install pyramidbox_lite_mobile_mask==1.3.0
hub install pyramidbox_lite_mobile==1.2.0

关于module的版本信息参见官网介绍:https://www.paddlepaddle.org.cn/hubdetail?name=pyramidbox_lite_mobile_mask&en_category=ObjectDetection

image

@haoyuying
Copy link
Contributor

Since you haven't replied for more than 3 months, we have closed this issue/pr.
If the problem is not solved or there is a follow-up one, please reopen it at any time and we will continue to follow up.
由于您超过三个月未回复,我们将关闭这个issue/pr。
若问题未解决或有后续问题,请随时重新打开,我们会继续跟进。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants