File size: 352 Bytes
0edd049
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
import pytest
from openface_model import OpenFaceModel


@pytest.fixture()
def model():
    return OpenFaceModel()

@pytest.mark.skip(reason="Not implemented")
def test_embed(model):
    image = open("../testdata/face_pic.jpeg", "rb").read()
    aligned_face = model.preprocess(image)
    rep = model.embed(aligned_face)
    assert rep.shape == (128,)