make execute async function

This commit is contained in:
Andrewmatilde
2025-08-06 12:57:45 +08:00
parent e0de88df3a
commit 0f5c8ac35b
7 changed files with 13 additions and 13 deletions
+2 -2
View File
@@ -97,7 +97,7 @@ class FluxDevNode:
CATEGORY = "UCLOUD_MODELVERSE"
FUNCTION = "execute"
def execute(self,
async def execute(self,
client,
prompt,
width=864,
@@ -129,7 +129,7 @@ class FluxDevNode:
))
for i in range(num_requests)]
image_urls = asyncio.run(client.run_tasks(tasks))
image_urls = await client.run_tasks(tasks)
output_images_list = []
for image_url in image_urls:
+2 -2
View File
@@ -59,7 +59,7 @@ class FluxKontextMaxNode:
CATEGORY = "UCLOUD_MODELVERSE"
FUNCTION = "execute"
def execute(self,
async def execute(self,
client,
prompt,
images,
@@ -100,7 +100,7 @@ class FluxKontextMaxNode:
))
for i in range(num_requests)]
image_urls = asyncio.run(client.run_tasks(tasks))
image_urls = await client.run_tasks(tasks)
output_images_list = []
for image_url in image_urls:
+2 -2
View File
@@ -63,7 +63,7 @@ class FluxKontextMaxT2INode:
CATEGORY = "UCLOUD_MODELVERSE"
FUNCTION = "execute"
def execute(self,
async def execute(self,
client,
prompt,
num_images=1,
@@ -88,7 +88,7 @@ class FluxKontextMaxT2INode:
))
for i in range(num_requests)]
image_urls = asyncio.run(client.run_tasks(tasks))
image_urls = await client.run_tasks(tasks)
output_images_list = []
for image_url in image_urls:
+2 -2
View File
@@ -59,7 +59,7 @@ class FluxKontextProNode:
CATEGORY = "UCLOUD_MODELVERSE"
FUNCTION = "execute"
def execute(self,
async def execute(self,
client,
prompt,
images,
@@ -100,7 +100,7 @@ class FluxKontextProNode:
))
for i in range(num_requests)]
image_urls = asyncio.run(client.run_tasks(tasks))
image_urls = await client.run_tasks(tasks)
output_images_list = []
for image_url in image_urls:
+2 -2
View File
@@ -63,7 +63,7 @@ class FluxKontextProT2INode:
CATEGORY = "UCLOUD_MODELVERSE"
FUNCTION = "execute"
def execute(self,
async def execute(self,
client,
prompt,
num_images=1,
@@ -88,7 +88,7 @@ class FluxKontextProT2INode:
))
for i in range(num_requests)]
image_urls = asyncio.run(client.run_tasks(tasks))
image_urls = await client.run_tasks(tasks)
output_images_list = []
for image_url in image_urls:
+2 -2
View File
@@ -60,7 +60,7 @@ class Step1xEditNode:
CATEGORY = "UCLOUD_MODELVERSE"
FUNCTION = "execute"
def execute(self,
async def execute(self,
client,
prompt,
image,
@@ -89,7 +89,7 @@ class Step1xEditNode:
))
for i in range(num_requests)]
image_urls = asyncio.run(client.run_tasks(tasks))
image_urls = await client.run_tasks(tasks)
output_images_list = []
for image_url in image_urls:
+1 -1
View File
@@ -1,2 +1,2 @@
requests >= 3.32.4
requests >= 2.32.4
pillow >= 11