How to install dlib on Raspberry Pi 4 or Linux

Поделиться
HTML-код
  • Опубликовано: 1 окт 2024
  • This Video show how to install dlib on Raspberry pi4 or any Linux machine in great detail.
    Terminal commands:
    ------------------------------------------------------------------------------
    --------------------------------------------------------------------------
    To update the System:
    ---------------------------------------------------------
    sudo apt get update
    -------------------------------------------------------
    To Upgrade the System:
    --------------------------------------------------------
    sudo apt get upgrade
    -------------------------------------------------------
    to install dev packages:
    ---------------------------------------------------------
    sudo apt-get install build-essential cmake pkg-config
    -----------------------------------------------------------------------------------------

Комментарии • 18

  • @castanog2
    @castanog2 3 года назад +1

    great video,
    Just a comment, if when trying to build and install the python script, you get an error "No module named setuptools" try installing those first using:
    First create and move into a folder to house the files new files that would be downloading and then issue the command:
    wget bootstrap.pypa.io/ez_setup.py -O - | sudo python

  • @hlt8811
    @hlt8811 3 года назад +1

    Thanks for sharing! This method worked well with my rasp4!

    • @AiPhile
      @AiPhile  3 года назад

      Thanks man, for sharing your experience with us

  • @jameshodds8800
    @jameshodds8800 2 года назад +1

    do you have a follow on video or a link on what to do next ??

    • @AiPhile
      @AiPhile  2 года назад

      You can create any kind of project, like face AR, eyes tracking, yawn detection, eyes 👁️ blinking detection etc.

  • @nesoacad738
    @nesoacad738 2 года назад

    Actually after 91% it is not building..I have tried more than 5 times. Every time I face the same issue..Can someone suggest me how to install dlib for my project..

    • @AiPhile
      @AiPhile  2 года назад

      Install mediapipe instead of dlib.

  • @RPILLAI1
    @RPILLAI1 3 года назад

    Can I use the same method for raspberry pi 3 B+ too?

    • @AiPhile
      @AiPhile  3 года назад

      yeah, Hopefully it would work.

  • @jeetkapadia5239
    @jeetkapadia5239 2 года назад

    i tried this but getting following error can someone help?
    running build
    Detected Python architecture: 64bit
    Detected platform: linux
    Removing build directory /home/pi/Downloads/dlib-19.7/./tools/python/build
    Configuring cmake ...
    /usr/lib/python3.9/subprocess.py:941: RuntimeWarning: line buffering (buffering=1) isn't supported in binary mode, the default buffer size will be used
    self.stdout = io.open(c2pread, 'rb', bufsize)
    Traceback (most recent call last):
    File "/home/pi/Downloads/dlib-19.7/setup.py", line 616, in
    setup(
    File "/usr/local/lib/python3.9/dist-packages/setuptools/__init__.py", line 87, in setup
    return distutils.core.setup(**attrs)
    File "/usr/local/lib/python3.9/dist-packages/setuptools/_distutils/core.py", line 148, in setup
    return run_commands(dist)
    File "/usr/local/lib/python3.9/dist-packages/setuptools/_distutils/core.py", line 163, in run_commands
    dist.run_commands()
    File "/usr/local/lib/python3.9/dist-packages/setuptools/_distutils/dist.py", line 967, in run_commands
    self.run_command(cmd)
    File "/usr/local/lib/python3.9/dist-packages/setuptools/dist.py", line 1214, in run_command
    super().run_command(command)
    File "/usr/local/lib/python3.9/dist-packages/setuptools/_distutils/dist.py", line 986, in run_command
    cmd_obj.run()
    File "/home/pi/Downloads/dlib-19.7/setup.py", line 410, in run
    self.build_dlib()
    File "/home/pi/Downloads/dlib-19.7/setup.py", line 567, in build_dlib
    if run_process(cmake_cmd):
    File "/home/pi/Downloads/dlib-19.7/setup.py", line 303, in run_process
    while t.isAlive():
    AttributeError: 'Thread' object has no attribute 'isAlive'

    • @AiPhile
      @AiPhile  2 года назад +2

      Use MediaPipe which is faster and easier.

  • @suhasl960
    @suhasl960 3 года назад

    Thank you . It went smooth :)

    • @AiPhile
      @AiPhile  3 года назад +2

      Thanks man for Appreciation and confirmation ♥️

  • @pordindrag
    @pordindrag 3 года назад

    THANK

    • @AiPhile
      @AiPhile  3 года назад

      You are welcome.

  • @jesusjask8
    @jesusjask8 3 года назад

    Hello, thanks for the video, everything worked ok during the installation, but after thar when i tried to import dlib y got this error
    >>> import dlib
    Traceback (most recent call last):
    File "", line 1, in
    File "/usr/local/lib/python3.7/dist-packages/dlib/__init__.py", line 19, in
    from _dlib_pybind11 import *
    ImportError: libatlas.so.3: cannot open shared object file: No such file or directory
    Can you please help me?

    • @AiPhile
      @AiPhile  3 года назад

      apologize, for late response have install required modules for Dlib before installation?

    • @venkatpr
      @venkatpr 2 года назад

      @@AiPhile which modules?