Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -55,18 +55,20 @@ def add_extra_model_paths() -> None:
|
|
| 55 |
def import_custom_nodes() -> None:
|
| 56 |
import asyncio
|
| 57 |
import execution
|
| 58 |
-
from nodes import
|
| 59 |
import server
|
| 60 |
loop = asyncio.new_event_loop()
|
| 61 |
asyncio.set_event_loop(loop)
|
| 62 |
server_instance = server.PromptServer(loop)
|
| 63 |
execution.PromptQueue(server_instance)
|
| 64 |
-
|
| 65 |
|
| 66 |
# Setup ComfyUI and custom nodes
|
| 67 |
if not os.path.exists("ComfyUI"):
|
| 68 |
subprocess.run(["git", "clone", "https://github.com/comfyanonymous/ComfyUI.git"])
|
| 69 |
|
|
|
|
|
|
|
| 70 |
custom_node_path = "ComfyUI/custom_nodes/ComfyUI_UltimateSDUpscale"
|
| 71 |
if not os.path.exists(custom_node_path):
|
| 72 |
subprocess.run(["git", "clone", "https://github.com/ssitu/ComfyUI_UltimateSDUpscale.git", custom_node_path])
|
|
@@ -106,7 +108,7 @@ if not os.path.exists(esrgan_x4_path):
|
|
| 106 |
add_comfyui_directory_to_sys_path()
|
| 107 |
add_extra_model_paths()
|
| 108 |
from folder_paths import add_model_folder_path
|
| 109 |
-
add_model_folder_path("unet", find_path("
|
| 110 |
import_custom_nodes()
|
| 111 |
|
| 112 |
from nodes import NODE_CLASS_MAPPINGS
|
|
|
|
| 55 |
def import_custom_nodes() -> None:
|
| 56 |
import asyncio
|
| 57 |
import execution
|
| 58 |
+
from nodes import init_extra_nodes
|
| 59 |
import server
|
| 60 |
loop = asyncio.new_event_loop()
|
| 61 |
asyncio.set_event_loop(loop)
|
| 62 |
server_instance = server.PromptServer(loop)
|
| 63 |
execution.PromptQueue(server_instance)
|
| 64 |
+
init_extra_nodes()
|
| 65 |
|
| 66 |
# Setup ComfyUI and custom nodes
|
| 67 |
if not os.path.exists("ComfyUI"):
|
| 68 |
subprocess.run(["git", "clone", "https://github.com/comfyanonymous/ComfyUI.git"])
|
| 69 |
|
| 70 |
+
subprocess.run(["sh", "-c", "cd ComfyUI && git checkout `git rev-list -1 --before='2025-03-01' master`"])
|
| 71 |
+
|
| 72 |
custom_node_path = "ComfyUI/custom_nodes/ComfyUI_UltimateSDUpscale"
|
| 73 |
if not os.path.exists(custom_node_path):
|
| 74 |
subprocess.run(["git", "clone", "https://github.com/ssitu/ComfyUI_UltimateSDUpscale.git", custom_node_path])
|
|
|
|
| 108 |
add_comfyui_directory_to_sys_path()
|
| 109 |
add_extra_model_paths()
|
| 110 |
from folder_paths import add_model_folder_path
|
| 111 |
+
add_model_folder_path("unet", find_path("diffusion_models"))
|
| 112 |
import_custom_nodes()
|
| 113 |
|
| 114 |
from nodes import NODE_CLASS_MAPPINGS
|