onnx / onnx/models

python3 ./arcface_inference.py cannot import name 'nms' from 'helper'

Open
#196 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Jupyter Notebook
Stars
9.8k
Forks
1.6k
PR merge metrics
No merged PRs in 30d

Description

Within the same directory I downloaded arface_service.py, mtcnn_detector.py, and the .py version of arface_inference.ipynb :

marco@pc:~/python3venvironments/mxnet/arcface$ ls -lah
total 368K
drwxrwxr-x 4 marco marco 4.0K Aug 14 22:51 .
drwxrwxr-x 3 marco marco 4.0K Aug 14 21:41 ..
drwxrwxr-x 2 marco marco 4.0K Aug 14 21:44 .ipynb_checkpoints
drwxrwxr-x 2 marco marco 4.0K Aug 14 22:47 __pycache__
-rw-rw-r-- 1 marco marco 307K Aug 14 21:37 arcface_inference.ipynb
-rw-rw-r-- 1 marco marco  10K Aug 14 21:51 arcface_inference.py
-rw-rw-r-- 1 marco marco 5.0K Oct 30  2018 arcface_service.py
-rw-rw-r-- 1 marco marco  24K Aug 14 22:47 mtcnn_detector.py

When trying to run arcface_inference.py :

marco@pc:~/python3venvironments/mxnet/arcface$ python3 ./arcface_inference.py
Traceback (most recent call last):
  File "./arcface_inference.py", line 54, in <module>
    from mtcnn_detector import MtcnnDetector
  File "/home/marco/python3venvironments/mxnet/arcface/mtcnn_detector.py", line 12, in 
<module>
    from helper import nms, adjust_input, detect_first_stage_warpper
ImportError: cannot import name 'nms' from 'helper' (/home/marco/anaconda3/lib/python3.7/site-
packages/helper/__init__.py)
marco@pc:~/python3venvironments/mxnet/arcface$ 

Python Version:

marco@pc:~/python3venvironments/mxnet/arcface$ python3 -V
Python 3.7.3

OS: Ubuntu 18.04.02 Server Edition

Looking forward to your kind help.
Marco

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with arcface_inference.py and mtcnn_detector.py, then inspect the helper import and the helper package path shown in the traceback. Re-run python3 ./arcface_inference.py after resolving the import mismatch; done means the reported ImportError no longer occurs.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
computer-vision, machine-learning
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.