455db0215475f49b2ad908f94b9d589a0ba80ef5
PDlib - A PHP extension for Dlib
A PHP extension
Requirements
- Dlib 19.13+
- PHP 7.0+
- C++ 11
Dependence
Dlib
Install Dlib as share library
git clone git@github.com:davisking/dlib.git
cd dlib/dlib
mkdir build
cd build
cmake -DBUILD_SHARED_LIBS=ON ..
make
sudo make install
Installation
git clone https://github.com/goodspb/pdlib.git
cd pdlib
phpize
./configure --enable-debug
make
sudo make install
Configure
vim youpath/php.ini
Write the below content into php.ini
[pdlib]
extension="pdlib.so"
Usage
face detection
<?php
// face detection
$faceCount = dlib_face_detection("~/a.jpg");
// how mary face in the picture.
var_dump($faceCount);
face landmark detection
<?php
// face landmark detection
$landmarks = dlib_face_landmark_detection("~/a.jpg");
var_dump($landmarks);
Features
- 1.Face Detection
- 2.Face Landmark Detection
- 3.Deep Face Recognition
- 4.Deep Learning Face Detection
Description
Languages
C++
68.1%
PHP
18.8%
C
7.7%
M4
3.8%
CMake
1%
Other
0.6%