Skip to content

Commit

Permalink
Add a node to block merge auraflow models.
Browse files Browse the repository at this point in the history
  • Loading branch information
comfyanonymous committed Nov 15, 2024
1 parent 122c9ca commit 5fb59c8
Showing 1 changed file with 29 additions and 0 deletions.
29 changes: 29 additions & 0 deletions comfy_extras/nodes_model_merging_model_specific.py
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,34 @@ def INPUT_TYPES(s):

return {"required": arg_dict}


class ModelMergeAuraflow(comfy_extras.nodes_model_merging.ModelMergeBlocks):
CATEGORY = "advanced/model_merging/model_specific"

@classmethod
def INPUT_TYPES(s):
arg_dict = { "model1": ("MODEL",),
"model2": ("MODEL",)}

argument = ("FLOAT", {"default": 1.0, "min": 0.0, "max": 1.0, "step": 0.01})

arg_dict["init_x_linear."] = argument
arg_dict["positional_encoding"] = argument
arg_dict["cond_seq_linear."] = argument
arg_dict["register_tokens"] = argument
arg_dict["t_embedder."] = argument

for i in range(4):
arg_dict["double_layers.{}.".format(i)] = argument

for i in range(32):
arg_dict["single_layers.{}.".format(i)] = argument

arg_dict["modF."] = argument
arg_dict["final_linear."] = argument

return {"required": arg_dict}

class ModelMergeFlux1(comfy_extras.nodes_model_merging.ModelMergeBlocks):
CATEGORY = "advanced/model_merging/model_specific"

Expand Down Expand Up @@ -151,6 +179,7 @@ def INPUT_TYPES(s):
"ModelMergeSD2": ModelMergeSD1, #SD1 and SD2 have the same blocks
"ModelMergeSDXL": ModelMergeSDXL,
"ModelMergeSD3_2B": ModelMergeSD3_2B,
"ModelMergeAuraflow": ModelMergeAuraflow,
"ModelMergeFlux1": ModelMergeFlux1,
"ModelMergeSD35_Large": ModelMergeSD35_Large,
"ModelMergeMochiPreview": ModelMergeMochiPreview,
Expand Down

0 comments on commit 5fb59c8

Please sign in to comment.