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

人脸识别产线的demo数据是不是错误的,不能进行推理 #2548

Open
Barry-1212 opened this issue Nov 25, 2024 · 3 comments
Open
Assignees

Comments

@Barry-1212
Copy link

https://paddlepaddle.github.io/PaddleX/main/pipeline_usage/tutorials/cv_pipelines/face_recognition.html#222-python

from paddlex import create_pipeline

pipeline = create_pipeline(pipeline="face_recognition")

pipeline.build_index(data_root="face_demo_gallery", index_dir="face_gallery_index")

output = pipeline.predict("friends1.jpg", index_dir="face_gallery_index")
for res in output:
res.print()
res.save_to_img("./output/")

控制台打印:
Using official model (MobileFaceNet), the model files will be be automatically downloaded and saved in C:\Users\PC.paddlex\official_models.
Traceback (most recent call last):
File "D:\code\PaddleX\myUtils\face_test.py", line 5, in
pipeline.build_index(data_root="face_demo_gallery", index_dir="face_gallery_index")
TypeError: ShiTuV2Pipeline.build_index() missing 2 required positional arguments: 'gallery_imgs' and 'gallery_label'

@Barry-1212
Copy link
Author

文档的代码是不是也是错了

@leo-q8
Copy link
Collaborator

leo-q8 commented Nov 25, 2024

文档还没更新,最新的接口data_root变成了gallery_imgs, index_dir变成了gallery_label

@leo-q8
Copy link
Collaborator

leo-q8 commented Nov 26, 2024

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