deepinsight / deepinsight/insightface

antelopev2 AssertionError:

Open
#2,766 2 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
29.7k
Forks
6.1k
PR merge metrics
No merged PRs in 30d

Description

---------------------------------------------------------------------------
AssertionError Traceback (most recent call last)
Cell In[30], [line 1](vscode-notebook-cell:?execution_count=30&line=1)
----> [1](vscode-notebook-cell:?execution_count=30&line=1) insightface_app = FaceAnalysis(name='antelopev2', providers=['CUDAExecutionProvider', 'CPUExecutionProvider'])
[2](vscode-notebook-cell:?execution_count=30&line=2) insightface_app.prepare(ctx_id=0, det_size=(640, 640))

File ~/anaconda3/envs/kqed_v2/lib/python3.10/site-packages/insightface/app/face_analysis.py:43, in FaceAnalysis.__init__(self, name, root, allowed_modules, **kwargs)
[41](https://vscode-remote+ssh-002dremote-002b34-002e224-002e65-002e62.vscode-resource.vscode-cdn.net/home/ubuntu/kqed_demo/udatya/~/anaconda3/envs/kqed_v2/lib/python3.10/site-packages/insightface/app/face_analysis.py:41) print('duplicated model task type, ignore:', onnx_file, model.taskname)
[42](https://vscode-remote+ssh-002dremote-002b34-002e224-002e65-002e62.vscode-resource.vscode-cdn.net/home/ubuntu/kqed_demo/udatya/~/anaconda3/envs/kqed_v2/lib/python3.10/site-packages/insightface/app/face_analysis.py:42) del model
---> [43](https://vscode-remote+ssh-002dremote-002b34-002e224-002e65-002e62.vscode-resource.vscode-cdn.net/home/ubuntu/kqed_demo/udatya/~/anaconda3/envs/kqed_v2/lib/python3.10/site-packages/insightface/app/face_analysis.py:43) assert 'detection' in self.models
[44](https://vscode-remote+ssh-002dremote-002b34-002e224-002e65-002e62.vscode-resource.vscode-cdn.net/home/ubuntu/kqed_demo/udatya/~/anaconda3/envs/kqed_v2/lib/python3.10/site-packages/insightface/app/face_analysis.py:44) self.det_model = self.models['detection']

AssertionError:

Steps to reproduce :-
insightface_app = FaceAnalysis(name='antelopev2', providers=['CUDAExecutionProvider', 'CPUExecutionProvider'])
insightface_app.prepare(ctx_id=0, det_size=(640, 640))

just run this in the notebook.

Help anyone?

Contributor guide

No contributing guide indexed for this repository

Research direction

Reproduce the two FaceAnalysis calls in the notebook, then inspect the installed insightface/app/face_analysis.py around line 43 and the antelopev2 model-loading inputs. Done means identifying why self.models lacks detection for this setup and recording a verified resolution or the missing environment/model details.

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.