Intel® Distribution of OpenVINO™ Toolkit
Community assistance about the Intel® Distribution of OpenVINO™ toolkit, OpenCV, and all aspects of computer vision-related on Intel® platforms.
6413 Discussions

openvino face_recognition demo is not working

chvenb
Beginner
677 Views

 

Im trying to run the demo using this cmd

 

 

openvino_env1) chvenb@ubuntu:~/open_model_zoo/demos/face_recognition_demo/python$
python3 face_recognition_demo.py \
-i "/home/chvenb/Downloads/trumptest.mp4" \
-m_fd "/home/chvenb/face_recognition_demo/python/intel/face-detection-retail-0004/FP16/face-detection-retail-0004.xml" \
-m_lm "/home/chvenb/face_recognition_demo/python/intel/landmarks-regression-retail-0009/FP16/landmarks-regression-retail-0009.xml" \
-m_reid "/home/chvenb/face_recognition_demo/python/intel/face-reidentification-retail-0095/FP16/face-reidentification-retail-0095.xml" \
-fg "/home/chvenb/Downloads/Face3" --loop -o trumpvidtest.avi --verbose

 

 

and ended up getting this error

 

Traceback (most recent call last):
File "/home/chvenb/open_model_zoo/demos/face_recognition_demo/python/face_recognition_demo.py", line 32, in <module>
from utils import crop
File "/home/chvenb/open_model_zoo/demos/face_recognition_demo/python/utils.py", line 19, in <module>
from model_api.models.utils import resize_image
ModuleNotFoundError: No module named 'model_api'

Note:

also i have install omz_dir/common/py.

please help me out

0 Kudos
5 Replies
Iffa_Intel
Moderator
633 Views

Hi, could you clarify:

  1. which OpenVINO version are you using?
  2. which method of installation did you installed the OpenVINO? (Runtime, PyPI, GitHub, etc)
  3. what Ubuntu version are you using?


Cordially,

Iffa


0 Kudos
chvenb
Beginner
560 Views

1. Im using 2023.2.0 version of openvino

2. PyPi

 

3. ubuntu versions is 22.04.3 LTS

0 Kudos
chvenb
Beginner
556 Views

--

0 Kudos
Iffa_Intel
Moderator
506 Views

I managed to run the face recogtion demo:

 

Iffa_Intel_0-1713316202647.png

 

Steps that I did:

1. Installed openvino-dev as instructed here

2. Get the OpenVINO OMZ from this repo

3. Install requirements.txt in the demo folder: pip install -r requirements.txt

4. Download 3 models (face-detection-retail-0004, landmarks-regression-retail-0009, face-reidentification-retail-0095): omz_downloader --name modelname

5.  Run the python demo: python face_recognition_demo.py -i <path_to_video>/input_video.mp4 -m_fd <path_to_model>/face-detection-retail-0004.xml -m_lm <path_to_model>/landmarks-regression-retail-0009.xml -m_reid <path_to_model>/face-reidentification-retail-0095.xml

Iffa_Intel_1-1713316675730.png

 

 

Note: add -fg "C:/face_gallery" if you have folder of faces that you want to be recognized.

Refer to this section to see supported models.

 

Cordially,

Iffa

 

0 Kudos
Iffa_Intel
Moderator
306 Views

Hi,


Intel will no longer monitor this thread since we have provided a solution. If you need any additional information from Intel, please submit a new question. 



Cordially,

Iffa


0 Kudos
Reply