selfitcamera
commited on
Commit
•
d0731a1
1
Parent(s):
39d63a2
update
Browse files
app.py
CHANGED
@@ -54,7 +54,7 @@ def onClick(cloth_id, pose_image, pose_id, size, request: gr.Request):
|
|
54 |
if len(faces)==0:
|
55 |
client_ip = request.client.host
|
56 |
print(client_ip, 'faces num is 0! ', flush=True)
|
57 |
-
return None, "
|
58 |
|
59 |
timeId = int( str(time.time()).replace(".", "") )+random.randint(1000, 9999)
|
60 |
isUpload = upload_pose_img(ApiUrl, OpenId, ApiKey, client_ip, timeId, pose_image)
|
|
|
54 |
if len(faces)==0:
|
55 |
client_ip = request.client.host
|
56 |
print(client_ip, 'faces num is 0! ', flush=True)
|
57 |
+
return None, "Fatal Error !!! No face detected !!! You must upload a human photo!!! Not clothing photo!!!", ""
|
58 |
|
59 |
timeId = int( str(time.time()).replace(".", "") )+random.randint(1000, 9999)
|
60 |
isUpload = upload_pose_img(ApiUrl, OpenId, ApiKey, client_ip, timeId, pose_image)
|