Upload folder using huggingface_hub
Browse files- README.md +1 -0
- app.py +9 -1
- core/pipelines/workflow_recipes/_partials/conditioning/lens.yaml +54 -0
- requirements.txt +1 -1
- yaml/file_list.yaml +14 -0
- yaml/image_gen_features.yaml +4 -0
- yaml/model_architectures.yaml +4 -0
- yaml/model_defaults.yaml +11 -0
- yaml/model_list.yaml +13 -0
README.md
CHANGED
|
@@ -40,6 +40,7 @@ models:
|
|
| 40 |
- Comfy-Org/HiDream-I1_ComfyUI
|
| 41 |
- Comfy-Org/HiDream-O1-Image
|
| 42 |
- Comfy-Org/HunyuanImage_2.1_ComfyUI
|
|
|
|
| 43 |
- Comfy-Org/LongCat-Image
|
| 44 |
- Comfy-Org/Lumina_Image_2.0_Repackaged
|
| 45 |
- Comfy-Org/NewBie-image-Exp0.1_repackaged
|
|
|
|
| 40 |
- Comfy-Org/HiDream-I1_ComfyUI
|
| 41 |
- Comfy-Org/HiDream-O1-Image
|
| 42 |
- Comfy-Org/HunyuanImage_2.1_ComfyUI
|
| 43 |
+
- Comfy-Org/Lens
|
| 44 |
- Comfy-Org/LongCat-Image
|
| 45 |
- Comfy-Org/Lumina_Image_2.0_Repackaged
|
| 46 |
- Comfy-Org/NewBie-image-Exp0.1_repackaged
|
app.py
CHANGED
|
@@ -3,6 +3,10 @@ import os
|
|
| 3 |
import sys
|
| 4 |
import site
|
| 5 |
|
|
|
|
|
|
|
|
|
|
|
|
|
| 6 |
APP_DIR = os.path.dirname(os.path.abspath(__file__))
|
| 7 |
if APP_DIR not in sys.path:
|
| 8 |
sys.path.insert(0, APP_DIR)
|
|
@@ -52,6 +56,10 @@ def main():
|
|
| 52 |
print("--- [Setup] Starting ComfyUI initialization ---")
|
| 53 |
setup_comfyui.initialize_comfyui()
|
| 54 |
|
|
|
|
|
|
|
|
|
|
|
|
|
| 55 |
print("--- [Setup] Reloading site-packages to detect newly installed packages... ---")
|
| 56 |
try:
|
| 57 |
site.main()
|
|
@@ -59,7 +67,7 @@ def main():
|
|
| 59 |
except Exception as e:
|
| 60 |
print(f"--- [Setup] ⚠️ Warning: Could not fully reload site-packages: {e} ---")
|
| 61 |
|
| 62 |
-
print("--- Initiating GPU Startup Check & SageAttention Patch ---")
|
| 63 |
try:
|
| 64 |
dummy_gpu_for_startup()
|
| 65 |
except Exception as e:
|
|
|
|
| 3 |
import sys
|
| 4 |
import site
|
| 5 |
|
| 6 |
+
if "--use-sage-attention" not in sys.argv:
|
| 7 |
+
sys.argv.append("--use-sage-attention")
|
| 8 |
+
print("🚀 [SageAttention] Injected '--use-sage-attention' into sys.argv.")
|
| 9 |
+
|
| 10 |
APP_DIR = os.path.dirname(os.path.abspath(__file__))
|
| 11 |
if APP_DIR not in sys.path:
|
| 12 |
sys.path.insert(0, APP_DIR)
|
|
|
|
| 56 |
print("--- [Setup] Starting ComfyUI initialization ---")
|
| 57 |
setup_comfyui.initialize_comfyui()
|
| 58 |
|
| 59 |
+
print("--- [Setup] Applying SageAttention Runtime Patch ---")
|
| 60 |
+
patch_result = apply_sage_attention_patch()
|
| 61 |
+
print(f"--- [Setup] {patch_result} ---")
|
| 62 |
+
|
| 63 |
print("--- [Setup] Reloading site-packages to detect newly installed packages... ---")
|
| 64 |
try:
|
| 65 |
site.main()
|
|
|
|
| 67 |
except Exception as e:
|
| 68 |
print(f"--- [Setup] ⚠️ Warning: Could not fully reload site-packages: {e} ---")
|
| 69 |
|
| 70 |
+
print("--- Initiating GPU Startup Check & SageAttention Patch Verification ---")
|
| 71 |
try:
|
| 72 |
dummy_gpu_for_startup()
|
| 73 |
except Exception as e:
|
core/pipelines/workflow_recipes/_partials/conditioning/lens.yaml
ADDED
|
@@ -0,0 +1,54 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
nodes:
|
| 2 |
+
unet_loader:
|
| 3 |
+
class_type: UNETLoader
|
| 4 |
+
title: "Load Diffusion Model"
|
| 5 |
+
params:
|
| 6 |
+
weight_dtype: "default"
|
| 7 |
+
clip_loader:
|
| 8 |
+
class_type: CLIPLoader
|
| 9 |
+
title: "Load CLIP"
|
| 10 |
+
params:
|
| 11 |
+
type: "lens"
|
| 12 |
+
device: "default"
|
| 13 |
+
vae_loader:
|
| 14 |
+
class_type: VAELoader
|
| 15 |
+
title: "Load VAE"
|
| 16 |
+
|
| 17 |
+
connections:
|
| 18 |
+
- from: "unet_loader:0"
|
| 19 |
+
to: "ksampler:model"
|
| 20 |
+
- from: "clip_loader:0"
|
| 21 |
+
to: "pos_prompt:clip"
|
| 22 |
+
- from: "clip_loader:0"
|
| 23 |
+
to: "neg_prompt:clip"
|
| 24 |
+
- from: "pos_prompt:0"
|
| 25 |
+
to: "ksampler:positive"
|
| 26 |
+
- from: "neg_prompt:0"
|
| 27 |
+
to: "ksampler:negative"
|
| 28 |
+
- from: "vae_loader:0"
|
| 29 |
+
to: "vae_decode:vae"
|
| 30 |
+
- from: "vae_loader:0"
|
| 31 |
+
to: "vae_encode:vae"
|
| 32 |
+
|
| 33 |
+
dynamic_lora_chains:
|
| 34 |
+
lora_chain:
|
| 35 |
+
template: "LoraLoader"
|
| 36 |
+
output_map:
|
| 37 |
+
"unet_loader:0": "model"
|
| 38 |
+
"clip_loader:0": "clip"
|
| 39 |
+
input_map:
|
| 40 |
+
"model": "model"
|
| 41 |
+
"clip": "clip"
|
| 42 |
+
end_input_map:
|
| 43 |
+
"model": ["ksampler:model"]
|
| 44 |
+
"clip": ["pos_prompt:clip", "neg_prompt:clip"]
|
| 45 |
+
|
| 46 |
+
dynamic_conditioning_chains:
|
| 47 |
+
conditioning_chain:
|
| 48 |
+
ksampler_node: "ksampler"
|
| 49 |
+
clip_source: "clip_loader:0"
|
| 50 |
+
|
| 51 |
+
ui_map:
|
| 52 |
+
unet_name: "unet_loader:unet_name"
|
| 53 |
+
clip_name: "clip_loader:clip_name"
|
| 54 |
+
vae_name: "vae_loader:vae_name"
|
requirements.txt
CHANGED
|
@@ -41,6 +41,6 @@ diffusers
|
|
| 41 |
protobuf
|
| 42 |
huggingface-hub
|
| 43 |
imageio
|
| 44 |
-
|
| 45 |
spaces
|
| 46 |
sageattention @ https://huggingface.co/RioShiina/Sage-Attention-ZeroGPU-Space-Build/resolve/main/sageattention-2.2.0-cp312-cp312-linux_x86_64.whl
|
|
|
|
| 41 |
protobuf
|
| 42 |
huggingface-hub
|
| 43 |
imageio
|
| 44 |
+
ninja
|
| 45 |
spaces
|
| 46 |
sageattention @ https://huggingface.co/RioShiina/Sage-Attention-ZeroGPU-Space-Build/resolve/main/sageattention-2.2.0-cp312-cp312-linux_x86_64.whl
|
yaml/file_list.yaml
CHANGED
|
@@ -403,6 +403,15 @@ file:
|
|
| 403 |
repo_id: "comfyanonymous/ControlNet-v1-1_fp16_safetensors"
|
| 404 |
repository_file_path: "control_v11u_sd15_tile_fp16.safetensors"
|
| 405 |
diffusion_models:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 406 |
# Anima
|
| 407 |
- filename: "waiANIMA_v10.safetensors"
|
| 408 |
source: "hf"
|
|
@@ -673,6 +682,11 @@ file:
|
|
| 673 |
repo_id: "alibaba-pai/Z-Image-Turbo-Fun-Controlnet-Union-2.1"
|
| 674 |
repository_file_path: "Z-Image-Turbo-Fun-Controlnet-Tile-2.1-8steps.safetensors"
|
| 675 |
text_encoders:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 676 |
# Anima
|
| 677 |
- filename: "qwen_3_06b_base.safetensors"
|
| 678 |
source: "hf"
|
|
|
|
| 403 |
repo_id: "comfyanonymous/ControlNet-v1-1_fp16_safetensors"
|
| 404 |
repository_file_path: "control_v11u_sd15_tile_fp16.safetensors"
|
| 405 |
diffusion_models:
|
| 406 |
+
# Lens
|
| 407 |
+
- filename: "lens_mxfp8.safetensors"
|
| 408 |
+
source: "hf"
|
| 409 |
+
repo_id: "Comfy-Org/Lens"
|
| 410 |
+
repository_file_path: "diffusion_models/lens_mxfp8.safetensors"
|
| 411 |
+
- filename: "lens_turbo_mxfp8.safetensors"
|
| 412 |
+
source: "hf"
|
| 413 |
+
repo_id: "Comfy-Org/Lens"
|
| 414 |
+
repository_file_path: "diffusion_models/lens_turbo_mxfp8.safetensors"
|
| 415 |
# Anima
|
| 416 |
- filename: "waiANIMA_v10.safetensors"
|
| 417 |
source: "hf"
|
|
|
|
| 682 |
repo_id: "alibaba-pai/Z-Image-Turbo-Fun-Controlnet-Union-2.1"
|
| 683 |
repository_file_path: "Z-Image-Turbo-Fun-Controlnet-Tile-2.1-8steps.safetensors"
|
| 684 |
text_encoders:
|
| 685 |
+
# Lens
|
| 686 |
+
- filename: "gpt_oss_20b_nvfp4.safetensors"
|
| 687 |
+
source: "hf"
|
| 688 |
+
repo_id: "Comfy-Org/Lens"
|
| 689 |
+
repository_file_path: "text_encoders/gpt_oss_20b_nvfp4.safetensors"
|
| 690 |
# Anima
|
| 691 |
- filename: "qwen_3_06b_base.safetensors"
|
| 692 |
source: "hf"
|
yaml/image_gen_features.yaml
CHANGED
|
@@ -7,6 +7,10 @@ default:
|
|
| 7 |
- style
|
| 8 |
- conditioning
|
| 9 |
|
|
|
|
|
|
|
|
|
|
|
|
|
| 10 |
ernie-image:
|
| 11 |
enabled_chains:
|
| 12 |
- lora
|
|
|
|
| 7 |
- style
|
| 8 |
- conditioning
|
| 9 |
|
| 10 |
+
lens:
|
| 11 |
+
enabled_chains:
|
| 12 |
+
- conditioning
|
| 13 |
+
|
| 14 |
ernie-image:
|
| 15 |
enabled_chains:
|
| 16 |
- lora
|
yaml/model_architectures.yaml
CHANGED
|
@@ -1,4 +1,5 @@
|
|
| 1 |
architecture_order:
|
|
|
|
| 2 |
- "FLUX.2-KV"
|
| 3 |
- "FLUX.2"
|
| 4 |
- "ERNIE-Image"
|
|
@@ -21,6 +22,9 @@ architecture_order:
|
|
| 21 |
- "SD1.5"
|
| 22 |
|
| 23 |
architectures:
|
|
|
|
|
|
|
|
|
|
| 24 |
"ERNIE-Image":
|
| 25 |
model_type: "ernie-image"
|
| 26 |
controlnet_key: "ERNIE-Image"
|
|
|
|
| 1 |
architecture_order:
|
| 2 |
+
- "Lens"
|
| 3 |
- "FLUX.2-KV"
|
| 4 |
- "FLUX.2"
|
| 5 |
- "ERNIE-Image"
|
|
|
|
| 22 |
- "SD1.5"
|
| 23 |
|
| 24 |
architectures:
|
| 25 |
+
"Lens":
|
| 26 |
+
model_type: "lens"
|
| 27 |
+
controlnet_key: "Lens"
|
| 28 |
"ERNIE-Image":
|
| 29 |
model_type: "ernie-image"
|
| 30 |
controlnet_key: "ERNIE-Image"
|
yaml/model_defaults.yaml
CHANGED
|
@@ -6,6 +6,17 @@ Default:
|
|
| 6 |
positive_prompt: ""
|
| 7 |
negative_prompt: ""
|
| 8 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 9 |
ERNIE-Image:
|
| 10 |
_defaults:
|
| 11 |
steps: 20
|
|
|
|
| 6 |
positive_prompt: ""
|
| 7 |
negative_prompt: ""
|
| 8 |
|
| 9 |
+
Lens:
|
| 10 |
+
_defaults:
|
| 11 |
+
steps: 20
|
| 12 |
+
cfg: 5.0
|
| 13 |
+
sampler_name: "euler"
|
| 14 |
+
scheduler: "simple"
|
| 15 |
+
total_pixels: 1048576
|
| 16 |
+
"Microsoft/Lens-Turbo":
|
| 17 |
+
steps: 4
|
| 18 |
+
cfg: 1.0
|
| 19 |
+
|
| 20 |
ERNIE-Image:
|
| 21 |
_defaults:
|
| 22 |
steps: 20
|
yaml/model_list.yaml
CHANGED
|
@@ -1,4 +1,17 @@
|
|
| 1 |
Checkpoint:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 2 |
FLUX.2-KV:
|
| 3 |
latent_type: flux2_latent
|
| 4 |
models:
|
|
|
|
| 1 |
Checkpoint:
|
| 2 |
+
Lens:
|
| 3 |
+
latent_type: flux2_latent
|
| 4 |
+
models:
|
| 5 |
+
- display_name: "Microsoft/Lens"
|
| 6 |
+
components:
|
| 7 |
+
unet: "lens_mxfp8.safetensors"
|
| 8 |
+
clip: "gpt_oss_20b_nvfp4.safetensors"
|
| 9 |
+
vae: "flux2-vae.safetensors"
|
| 10 |
+
- display_name: "Microsoft/Lens-Turbo"
|
| 11 |
+
components:
|
| 12 |
+
unet: "lens_turbo_mxfp8.safetensors"
|
| 13 |
+
clip: "gpt_oss_20b_nvfp4.safetensors"
|
| 14 |
+
vae: "flux2-vae.safetensors"
|
| 15 |
FLUX.2-KV:
|
| 16 |
latent_type: flux2_latent
|
| 17 |
models:
|