Spaces:
Running
on
L40S
Running
on
L40S
Disable SSR mode
Browse files
README.md
CHANGED
|
@@ -4,7 +4,7 @@ emoji: 🎞️
|
|
| 4 |
colorFrom: yellow
|
| 5 |
colorTo: gray
|
| 6 |
sdk: gradio
|
| 7 |
-
sdk_version: 5.
|
| 8 |
app_file: app.py
|
| 9 |
pinned: false
|
| 10 |
license: apache-2.0
|
|
|
|
| 4 |
colorFrom: yellow
|
| 5 |
colorTo: gray
|
| 6 |
sdk: gradio
|
| 7 |
+
sdk_version: 5.49.1
|
| 8 |
app_file: app.py
|
| 9 |
pinned: false
|
| 10 |
license: apache-2.0
|
app.py
CHANGED
|
@@ -124,20 +124,6 @@ examples = [list(x) for x in zip(prompts, motion_scores)]
|
|
| 124 |
if __name__ == "__main__":
|
| 125 |
args = parse_args()
|
| 126 |
|
| 127 |
-
import subprocess
|
| 128 |
-
import os
|
| 129 |
-
|
| 130 |
-
print("=== Environment Check ===")
|
| 131 |
-
print("CWD:", os.getcwd())
|
| 132 |
-
result = subprocess.run(["which", "node"], capture_output=True, text=True)
|
| 133 |
-
print("Which node:", result.stdout.strip())
|
| 134 |
-
|
| 135 |
-
result = subprocess.run(["node", "-v"], capture_output=True, text=True)
|
| 136 |
-
print("Node version:", result.stdout.strip())
|
| 137 |
-
|
| 138 |
-
result = subprocess.run(["which", "tsx"], capture_output=True, text=True)
|
| 139 |
-
print("Which tsx:", result.stdout.strip())
|
| 140 |
-
|
| 141 |
device = torch.device("cuda" if torch.cuda.is_available() else "cpu", args.device)
|
| 142 |
model_args = {"torch_dtype": getattr(torch, args.precision.lower()), "trust_remote_code": True}
|
| 143 |
pipe = URSAPipeline.from_pretrained(args.model, **model_args).to(device)
|
|
@@ -215,4 +201,4 @@ if __name__ == "__main__":
|
|
| 215 |
],
|
| 216 |
outputs=[result, seed],
|
| 217 |
)
|
| 218 |
-
app.__exit__(), app.launch(share=False)
|
|
|
|
| 124 |
if __name__ == "__main__":
|
| 125 |
args = parse_args()
|
| 126 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 127 |
device = torch.device("cuda" if torch.cuda.is_available() else "cpu", args.device)
|
| 128 |
model_args = {"torch_dtype": getattr(torch, args.precision.lower()), "trust_remote_code": True}
|
| 129 |
pipe = URSAPipeline.from_pretrained(args.model, **model_args).to(device)
|
|
|
|
| 201 |
],
|
| 202 |
outputs=[result, seed],
|
| 203 |
)
|
| 204 |
+
app.__exit__(), app.launch(share=False, ssr_mode=False)
|