提交 e6e9ed54 编写于 作者: T Tobias Mérinat 提交者: Adam Geitgey

rename parameter as per discussion

上级 60fe4e8c
......@@ -67,15 +67,15 @@ def face_distance(face_encodings, face_to_compare):
return np.linalg.norm(face_encodings - face_to_compare, axis=1)
def load_image_file(name, mode='RGB'):
def load_image_file(file, mode='RGB'):
"""
Loads an image file (.jpg, .png, etc) into a numpy array
:param name: image file name or file object to load
:param file: image file name or file object to load
:param mode: format to convert the image to. Only 'RGB' (8-bit RGB, 3 channels) and 'L' (black and white) are supported.
:return: image contents as numpy array
"""
return scipy.misc.imread(name, mode=mode)
return scipy.misc.imread(file, mode=mode)
def _raw_face_locations(img, number_of_times_to_upsample=1):
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册