|
|
|
@ -236,6 +236,9 @@ def get_task():
|
|
|
|
|
if response.status_code == 200:
|
|
|
|
|
success = response.json()["success"]
|
|
|
|
|
if success == 1:
|
|
|
|
|
# 清理服务器显存
|
|
|
|
|
release_sd(webui_address, comfyui_address)
|
|
|
|
|
|
|
|
|
|
data = response.json()["data"]
|
|
|
|
|
# 任务编号
|
|
|
|
|
task_id = data['task_id']
|
|
|
|
@ -298,8 +301,6 @@ def get_task():
|
|
|
|
|
webui_convert(model_id=model_id, prompt_id=prompt_id, json_data=vjson_data,
|
|
|
|
|
input_image=input_image, target_folder=output_path)
|
|
|
|
|
|
|
|
|
|
# 清理服务器显存
|
|
|
|
|
release_sd(webui_address, comfyui_address)
|
|
|
|
|
|
|
|
|
|
return task_id
|
|
|
|
|
elif success == 0:
|
|
|
|
|