Spaces:
Running
Running
Update demo.py
Browse files
demo.py
CHANGED
@@ -47,8 +47,12 @@ def compare_face(image1, image2):
|
|
47 |
url = "http://127.0.0.1:8080/compare_face"
|
48 |
files = {'file1': img_bytes1, 'file2': img_bytes2}
|
49 |
result = requests.post(url=url, files=files)
|
|
|
|
|
50 |
if result.ok:
|
51 |
json_result = result.json()
|
|
|
|
|
52 |
if json_result.get("resultCode") != "Ok":
|
53 |
return [json_result.get("resultCode"), json_result]
|
54 |
|
|
|
47 |
url = "http://127.0.0.1:8080/compare_face"
|
48 |
files = {'file1': img_bytes1, 'file2': img_bytes2}
|
49 |
result = requests.post(url=url, files=files)
|
50 |
+
|
51 |
+
print(result)
|
52 |
if result.ok:
|
53 |
json_result = result.json()
|
54 |
+
printf("json_result", json_result)
|
55 |
+
|
56 |
if json_result.get("resultCode") != "Ok":
|
57 |
return [json_result.get("resultCode"), json_result]
|
58 |
|