Skip to content

Commit f4be2ce

Browse files
update readme
1 parent d5de3f5 commit f4be2ce

File tree

1 file changed

+7
-12
lines changed

1 file changed

+7
-12
lines changed

README.md

Lines changed: 7 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,8 @@ Table of Contents:
4343

4444
### Face Landmarks
4545

46-
![preview_face_landmarks_boxes](https://user-images.githubusercontent.com/31125521/41507933-65f9b642-723c-11e8-8f4e-aab13303e7ff.jpg)
46+
![face_landmarks_boxes_1](https://user-images.githubusercontent.com/31125521/46063403-fff9f480-c16c-11e8-900f-e4b7a3828d1d.jpg)
47+
![face_landmarks_boxes_2](https://user-images.githubusercontent.com/31125521/46063404-00928b00-c16d-11e8-8f29-e9c50afd2bc8.jpg)
4748

4849
![preview_face_landmarks](https://user-images.githubusercontent.com/31125521/41507950-e121b05e-723c-11e8-89f2-d8f9348a8e86.png)
4950

@@ -57,10 +58,6 @@ Table of Contents:
5758

5859
![mtcnn-preview](https://user-images.githubusercontent.com/31125521/42756818-0a41edaa-88fe-11e8-9033-8cd141b0fa09.gif)
5960

60-
### Face Alignment
61-
62-
![preview_face_alignment](https://user-images.githubusercontent.com/31125521/41526994-1a690818-72e6-11e8-8f3c-d2cf31fe517b.jpg)
63-
6461
<a name="running-the-examples"></a>
6562

6663
## Running the Examples
@@ -89,7 +86,7 @@ The face detection model has been trained on the [WIDERFACE dataset](http://mmla
8986

9087
### Face Detection - Tiny Yolo v2
9188

92-
The Tiny Yolo v2 implementation is a very performant face detector, which can easily adapt to different input image sizes, thus can be used as an alternative to SSD Mobilenet v1 to trade off accuracy for performance (inference time). In general the models ability to locate smaller face bounding boxes is not as accurate as SSD Mobilenet v1.
89+
The Tiny Yolo v2 implementation is a very performant face detector, which can easily adapt to different input image sizes, thus can be used as an alternative to SSD Mobilenet v1 to trade off accuracy for performance (inference time). In general the models ability to locate smaller face bounding boxes is not as accurate as SSD Mobilenet v1.
9390

9491
The face detector has been trained on a custom dataset of ~10K images labeled with bounding boxes and uses depthwise separable convolutions instead of regular convolutions, which ensures very fast inference and allows to have a quantized model size of only 1.7MB making the model extremely mobile and web friendly. Thus, the Tiny Yolo v2 face detector should be your GO-TO face detector on mobile devices.
9592

@@ -113,9 +110,7 @@ The neural net is equivalent to the **FaceRecognizerNet** used in [face-recognit
113110

114111
### 68 Point Face Landmark Detection
115112

116-
This package implements a CNN to detect the 68 point face landmarks for a given face image.
117-
118-
The model has been trained on a variety of public datasets and the model weights are provided by [yinguobing](https://github.com/yinguobing) in [this](https://github.com/yinguobing/head-pose-estimation) repo.
113+
This package implements a very lightweight and fast, yet accurate 68 point face landmark detector. The default model has a size of only 350kb and the tiny model is only 80kb. Both models employ the idea of depthwise separable convolutions as well as densely connected blocks. The models have been trained on a dataset of ~35k face images labeled with 68 face landmark points.
119114

120115
<a name="usage"></a>
121116

@@ -145,6 +140,7 @@ Assuming the models reside in **public/models**:
145140
await faceapi.loadFaceDetectionModel('/models')
146141
// accordingly for the other models:
147142
// await faceapi.loadFaceLandmarkModel('/models')
143+
// await faceapi.loadFaceLandmarkTinyModel('/models')
148144
// await faceapi.loadFaceRecognitionModel('/models')
149145
// await faceapi.loadMtcnnModel('/models')
150146
// await faceapi.loadTinyYolov2Model('/models')
@@ -156,18 +152,17 @@ As an alternative, you can also create instance of the neural nets:
156152
const net = new faceapi.FaceDetectionNet()
157153
// accordingly for the other models:
158154
// const net = new faceapi.FaceLandmarkNet()
155+
// const net = new faceapi.FaceLandmarkTinyNet()
159156
// const net = new faceapi.FaceRecognitionNet()
160157
// const net = new faceapi.Mtcnn()
161158
// const net = new faceapi.TinyYolov2()
162159

163160
await net.load('/models/face_detection_model-weights_manifest.json')
164161
// await net.load('/models/face_landmark_68_model-weights_manifest.json')
162+
// await net.load('/models/face_landmark_68_tiny_model-weights_manifest.json')
165163
// await net.load('/models/face_recognition_model-weights_manifest.json')
166164
// await net.load('/models/mtcnn_model-weights_manifest.json')
167165
// await net.load('/models/tiny_yolov2_separable_conv_model-weights_manifest.json')
168-
169-
// or simply load all models
170-
await net.load('/models')
171166
```
172167

173168
Using instances, you can also load the weights as a Float32Array (in case you want to use the uncompressed models):

0 commit comments

Comments
 (0)