from scratch

This commit is contained in:
Sefik Ilkin Serengil 2020-03-06 08:51:45 +03:00 committed by GitHub
parent b3e9575273
commit b128ee10f9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -34,7 +34,7 @@ print("Is verified: ", result["verified"])
print("Distance: ", result["distance"]) print("Distance: ", result["distance"])
``` ```
Each call of verification function builds a face recognition model scratch and this is a costly operation. If you are going to verify multiple faces sequentially, then you should pass an array to verify function to speed the operation up. In this way, complex face recognition models will be built once. Each call of verification function builds a face recognition model from scratch and this is a costly operation. If you are going to verify multiple faces sequentially, then you should pass an array of faces to verification function to speed the operation up. In this way, complex face recognition models will be built once.
```python ```python
dataset = [ dataset = [
@ -42,6 +42,9 @@ dataset = [
['dataset/img5.jpg', 'dataset/img6.jpg'] ['dataset/img5.jpg', 'dataset/img6.jpg']
] ]
result = DeepFace.verify(dataset) result = DeepFace.verify(dataset)
for i in range(0, len(dataset)):
print(result[i]["verified"])
``` ```
## Face recognition models ## Face recognition models