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

ImportError: cannot import name 'pa_sfd_match' #65

Open
ncthong opened this issue Jun 22, 2020 · 6 comments
Open

ImportError: cannot import name 'pa_sfd_match' #65

ncthong opened this issue Jun 22, 2020 · 6 comments

Comments

@ncthong
Copy link

ncthong commented Jun 22, 2020

Hi Team,
I tried to follow your doc: https://github.com/Tencent/FaceDetection-DSFD
and when i run demo.py and got the following error:
Traceback (most recent call last):
File "demo.py", line 27, in
from face_ssd import build_ssd
File "D:\TRI TUE NHAN TAO AI\FaceDetection-DSFD-master\face_ssd.py", line 13, in
from layers import *
File "D:\TRI TUE NHAN TAO AI\FaceDetection-DSFD-master\layers_init_.py", line 2, in
from .modules import *
File "D:\TRI TUE NHAN TAO AI\FaceDetection-DSFD-master\layers\modules_init_.py", line 2, in
from .multibox_loss import MultiBoxLoss, focalLoss
File "D:\TRI TUE NHAN TAO AI\FaceDetection-DSFD-master\layers\modules\multibox_loss.py", line 13, in
from ..box_utils import (log_sum_exp, match, pa_sfd_match, refine_match,
ImportError: cannot import name 'pa_sfd_match'

I've installed torch

@anilrgukt
Copy link

I am also having the same issue. Please let me know if you figured it out.

@HMAA
Copy link

HMAA commented Jul 3, 2020

Hi all,
I am facing the same error. Could you please share a solution if you had an answer.

Thank you very much

@hypadr1v3
Copy link

hypadr1v3 commented Jul 4, 2020

I found the issue, go to multibox_loss where the library was imported and just remove the pa_sfd_match from the line from ..box_utils import (log_sum_exp, match, pa_sfd_match, refine_match, where it is imported because it does not seem to be used and does not exist in boxutils. Everything then works for me without error

@hypadr1v3
Copy link

This issue may be closed now as I believe the problem has been solved @ncthong

@ncthong
Copy link
Author

ncthong commented Jul 28, 2020

thanks guys, I have solved the problem in the way of @hypadr1v3.

@hypadr1v3
Copy link

You are very welcome. Although it is strange that this function is not called or mentioned anywhere else apart from the import statement.

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

4 participants