Spaces:
Sleeping
Sleeping
Update main.py
Browse files
main.py
CHANGED
|
@@ -94,11 +94,11 @@ class StableDiffusionEngine:
|
|
| 94 |
Stable Diffusion XL Engine (HF Spaces safe version)
|
| 95 |
"""
|
| 96 |
|
| 97 |
-
|
| 98 |
-
|
| 99 |
-
|
| 100 |
-
|
| 101 |
-
|
| 102 |
self.device = "cuda" if torch.cuda.is_available() else "cpu"
|
| 103 |
|
| 104 |
# ✅ Proper dtype assignment
|
|
|
|
| 94 |
Stable Diffusion XL Engine (HF Spaces safe version)
|
| 95 |
"""
|
| 96 |
|
| 97 |
+
def __init__(
|
| 98 |
+
self,
|
| 99 |
+
model_id="stabilityai/stable-diffusion-xl-base-1.0",
|
| 100 |
+
hf_token: str | None = None,
|
| 101 |
+
):
|
| 102 |
self.device = "cuda" if torch.cuda.is_available() else "cpu"
|
| 103 |
|
| 104 |
# ✅ Proper dtype assignment
|