wrong path
Browse files
utils.py
CHANGED
|
@@ -95,15 +95,9 @@ def postprocess_image(result: torch.Tensor, im_size: list) -> np.ndarray:
|
|
| 95 |
|
| 96 |
|
| 97 |
def downloadModels():
|
| 98 |
-
MODEL_PATH =
|
| 99 |
-
repo_id="RunDiffusion/Juggernaut-XL-v6",
|
| 100 |
-
filename="juggernautXL_version6Rundiffusion.safetensors",
|
| 101 |
)
|
| 102 |
-
# MODEL_PATH = hf_hub_download(
|
| 103 |
-
# repo_id="lllyasviel/fav_models",
|
| 104 |
-
# subfolder="fav",
|
| 105 |
-
# filename="juggernautXL_v8Rundiffusion.safetensors",
|
| 106 |
-
# )
|
| 107 |
LAYERS_PATH = snapshot_download(
|
| 108 |
repo_id="LayerDiffusion/layerdiffusion-v1", allow_patterns="*.safetensors"
|
| 109 |
)
|
|
@@ -111,12 +105,10 @@ def downloadModels():
|
|
| 111 |
target_path = Path(f"./ComfyUI/models/layer_model/{file.name}")
|
| 112 |
if not target_path.exists():
|
| 113 |
os.symlink(file, target_path)
|
| 114 |
-
|
| 115 |
-
|
| 116 |
-
|
| 117 |
-
|
| 118 |
-
if not model_target_path.exists():
|
| 119 |
-
os.symlink(MODEL_PATH, model_target_path)
|
| 120 |
|
| 121 |
|
| 122 |
examples = [
|
|
|
|
| 95 |
|
| 96 |
|
| 97 |
def downloadModels():
|
| 98 |
+
MODEL_PATH = snapshot_download(
|
| 99 |
+
repo_id="RunDiffusion/Juggernaut-XL-v6", allow_patterns="*.safetensors"
|
|
|
|
| 100 |
)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 101 |
LAYERS_PATH = snapshot_download(
|
| 102 |
repo_id="LayerDiffusion/layerdiffusion-v1", allow_patterns="*.safetensors"
|
| 103 |
)
|
|
|
|
| 105 |
target_path = Path(f"./ComfyUI/models/layer_model/{file.name}")
|
| 106 |
if not target_path.exists():
|
| 107 |
os.symlink(file, target_path)
|
| 108 |
+
for model in Path(MODEL_PATH).glob("*.safetensors"):
|
| 109 |
+
model_target_path = Path(f"./ComfyUI/models/checkpoints/{model.name}")
|
| 110 |
+
if not model_target_path.exists():
|
| 111 |
+
os.symlink(model, model_target_path)
|
|
|
|
|
|
|
| 112 |
|
| 113 |
|
| 114 |
examples = [
|