From da8adda281a61ec0964cdf41d42b9485ffb693a0 Mon Sep 17 00:00:00 2001 From: DvirYBria <74497787+DvirYBria@users.noreply.github.com> Date: Sun, 2 Feb 2025 11:35:57 +0200 Subject: [PATCH] Added seed go gen fill --- nodes/generative_fill_node.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/nodes/generative_fill_node.py b/nodes/generative_fill_node.py index b92221c..b30f005 100644 --- a/nodes/generative_fill_node.py +++ b/nodes/generative_fill_node.py @@ -17,6 +17,9 @@ class GenFillNode(): "prompt": ("STRING",), "api_key": ("STRING", {"default": "BRIA_API_TOKEN"}), # API Key input with a default value }, + "optional": { + "seed": ("INT", {"default": 123456}) + } } RETURN_TYPES = ("IMAGE",) @@ -28,7 +31,7 @@ class GenFillNode(): self.api_url = "https://engine.prod.bria-api.com/v1/gen_fill" # Eraser API URL # Define the execute method as expected by ComfyUI - def execute(self, image, mask, prompt, api_key): + def execute(self, image, mask, prompt, api_key, seed): if api_key.strip() == "" or api_key.strip() == "BRIA_API_TOKEN": raise Exception("Please insert a valid API key.") @@ -48,7 +51,8 @@ class GenFillNode(): "mask_file": f"{mask_base64}", "prompt": prompt, "negative_prompt": "blurry", - "sync": True + "sync": True, + "seed": seed, } headers = {