ageitgey/face_recognition

Jetson Nano 4GB: Segmentation fault (core dumped) - dlib and face_recognition

VieiraJardel opened this issue · 1 comments

  • face_recognition version: 1.3.0
  • Python version: 3.6.9
  • Operating System: Linux4Tegra, based on Ubuntu 18.04

Description


I’m trying to build a facial recognition system, but I’m getting a Segmentation fault (core dumped) error.

Here are the software versions I’m using:

  • numpy 1.19.4
  • OpenCV 4.5.0 (Build)
  • Dlib 19.21
  • Jetpack 4.6
  • CUDA 10.2
  • cuDNN 8.2

I followed all the instructions from Simple accelerated face recognition - #19 by AastaLLL

My code is based on this tutorial: https://www.youtube.com/watch?v=eTf3UtnxMdw&list=PLGs0VKk2DiYxP-ElZ7-QXIERFFPkOuP4_&index=44
I triyed build dlib 19.17 19.21 19.22 19.23 and 19.24. I’m facing the same error.


I built OpenCV following the JetsonHacks tutorial. I followed the instructions provided in Simple accelerated face recognition - #19 by AastaLLL, but I encountered the same issue: “Segmentation fault (core dumped).”

Here are the versions of the software I’m using:

  • numpy 1.19.4
  • OpenCV 4.5.4 (built)
  • Dlib 19.21
  • Jetpack 4.6
  • CUDA 10.2
  • cuDNN 8.2


Now I uninstalled dlib and face recognition and reinstalled following Paul McWhorter’s instructions (without building):

sudo apt-get update
sudo apt-get install cmake libopenblas-dev liblapack-dev libjpeg-dev
sudo apt-get install python3-pip

Swap memory setup (if applicable)
wget http://dlib.net/files/dlib-19.17.tar.bz2
tar jxvf dlib-19.17.tar.bz2
gedit cudnn-dlibapi.cpp
sudo python3 setup.py install
sudo pip3 install face_recognition
However, even after these steps, I encountered the same issue: “Segmentation fault (core dumped).”

I tried this on another SD card without building OpenCV and dlib. I successfully completed the installation and achieved 13 FPS with the following configurations:

OpenCV 4.1.1
Dlib 19.24
My CPU usage ranged from 36% to 48%, and my GPU usage fluctuated between 40% and 100%.

Based on my experience, it seems that building OpenCV may not be necessary or could potentially cause conflicts when using the dlib and face_recognition libraries. Can anyone confirm this?

Hi @VieiraJardel ,

I have the same problem as you with the same error on my Jetson Nano.
What instructions did you follow to successfully get facial recognition working from a blank SD card (as you indicate in your last sentences) ?

Thank you,
Nicolas