Installation of the Dlib Library for Python (Anaconda) under Windows system

Source: Internet
Author: User

0. Introduction

Introduces the Windows 10 64-bit system and installs the Dlib library in Python using the Anaconda development environment;

Windows Dlib installation is very unfriendly, so here to share the installation process;

WINDOWS10 + Anaconda + pip + dlib;

(with Anaconda, do not need their own build and make source, CMake and boost here do not need, a lot of friendly operation)

1. Dlib's profile (official website: http://dlib.net/)

Dlib is a machine learning Open Source Toolkit (official website: http://dlib.net/), used in robotics, embedded devices, mobile phones and large-scale high-performance computing environment, learn from their own words, can be used to face detection and recognition;

Take a look at the Python examples on its official website to know what it might do (or see some of my previous blogs, with Dlib doing some face recognition and detection), here's the Demo on its website:

2. Installation Environment

Windows 10 64-bit operating system

anaconda:556361 Anaconda3-4.3.1-windows-x86_64.exe

Dlib:dlib-19.7.0-cp36-cp36m-win_amd64.whl

Pip:pip-9.0.1-py2.py3-none-any.whl

(at the end of the article)

2.1 Anaconda (https://www.anaconda.com/download/#windows)

Anaconda is an open source Python release that integrates many common libraries compared to native Python, and installs and uninstalls the management library much more easily;

Here choose Anaconda more important reason, use Anaconda install dlib very convenient;

Enter your website to download the Python version you need:

* Python 3.6 version

64-bit graphical Installer (537 MB) 32-bit graphical Installer (436 MB)

* Python 2.7 version

64-bit graphical Installer (523 MB) 32-bit graphical Installer (420 MB)

Anaconda Installation Steps:

Figure 1 Installation of Anaconda 1

Figure 2 Installation of Anaconda 2 (remember to tick add to system variable)

Figure 3 Installation of Anaconda 3

Figure 4 Installation of Anaconda 4

After the installation is completed in your Start menu, or the installation directory to find Anaconda promopt, is the Anaconda terminal;

Fig. 5 Anaconda Prompt

Installation of 2.2 Dlib

Use the CD command first to locate the path to the Dlib WHL file, and then use PIP to install the Dlib command:

Pip Install DLIB-19.7.0-CP36-CP36M-WIN_AMD64.WHL

Display successfully installed dlib-19.7.0 after installation;

Figure 6 Installation Complete Dlib

Enter Python and enter the Python,import dlib test to see if the Dlib library is working

1 (G:\\anaconda) E:\dlib>python 2 python 3.6.0 | Anaconda 4.3.1 (64-bit) | On Win32 3 Type ' help ', ' copyright ', ' credits ' or ' license ' for more information. 4 >>> import pip 5 >>> import dlib 6 >>> dlib.get_frontal_face_detector () 7 <dlib.dlib.fhog_ Object_detector object at 0x00000289f92318a0> 8 >>>_

Figure 7 Test installation Complete Dlib

This means that the Dlib library can be used normally;

If you use the Pycharm compiler, remember to specify Project interpreter as Anaconda Python.exe in Setting instead of the native Python;

Anaconda python and native python are not a thing, and packages are not common to each other;

Figure 8 Python named Project interpreter as Anaconda in Pycharm

If there is a problem in the installation process can leave a message or e-mail to me;

e-mail me (directly click to jump):

[Email protected]

# Please respect the work of others, reprint or use source code, please specify the source: Http://www.cnblogs.com/AdaminXie

# Pip and Dlib WHL files have been uploaded to my GitHub (Anaconda can go to the official website to download): Https://github.com/coneypo/Dlib_install


Installation of the Dlib Library for Python (Anaconda) under Windows system

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.