mirror of
https://github.com/serengil/deepface.git
synced 2025-06-06 19:45:21 +00:00
defualt --> default
This commit is contained in:
parent
4f0fa6ee22
commit
f9af73c1c7
@ -21,15 +21,15 @@ def test_standard_represent():
|
|||||||
|
|
||||||
def test_standard_represent_with_io_object():
|
def test_standard_represent_with_io_object():
|
||||||
img_path = "dataset/img1.jpg"
|
img_path = "dataset/img1.jpg"
|
||||||
defualt_embedding_objs = DeepFace.represent(img_path)
|
default_embedding_objs = DeepFace.represent(img_path)
|
||||||
io_embedding_objs = DeepFace.represent(open(img_path, 'rb'))
|
io_embedding_objs = DeepFace.represent(open(img_path, 'rb'))
|
||||||
assert defualt_embedding_objs == io_embedding_objs
|
assert default_embedding_objs == io_embedding_objs
|
||||||
|
|
||||||
# Confirm non-seekable io objects are handled properly
|
# Confirm non-seekable io objects are handled properly
|
||||||
io_obj = io.BytesIO(open(img_path, 'rb').read())
|
io_obj = io.BytesIO(open(img_path, 'rb').read())
|
||||||
io_obj.seek = None
|
io_obj.seek = None
|
||||||
no_seek_io_embedding_objs = DeepFace.represent(io_obj)
|
no_seek_io_embedding_objs = DeepFace.represent(io_obj)
|
||||||
assert defualt_embedding_objs == no_seek_io_embedding_objs
|
assert default_embedding_objs == no_seek_io_embedding_objs
|
||||||
|
|
||||||
logger.info("✅ test standard represent with io object function done")
|
logger.info("✅ test standard represent with io object function done")
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user