Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion agent_scheduler/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ def api_callback(callback_url: str, task_id: str, status: TaskStatus, images: li

return requests.post(
callback_url,
timeout=5,
timeout=60,
data={"task_id": task_id, "status": status.value},
files=files,
)
Expand Down
6 changes: 6 additions & 0 deletions agent_scheduler/task_helpers.py
Original file line number Diff line number Diff line change
Expand Up @@ -228,6 +228,12 @@ def map_controlnet_args_to_api_task_args(args: Dict):

for k, v in args.items():
if k == "image" and v is not None:
if isinstance(v, str):
if v.startswith("http://") or v.startswith("https://"):
args[k] = load_image_from_url(v)
else:
args[k] = v
continue
args[k] = {
"image": encode_image_to_base64(v["image"]),
"mask": encode_image_to_base64(v["mask"]) if v.get("mask", None) is not None else None,
Expand Down