Spaces:
Running
Running
Download app.py from STATICAI/Motion-Rig: direct link, hf CLI and curl.
- Browser
- Download file 1.04 kB
-
https://huggingface.co/spaces/STATICAI/Motion-Rig/resolve/main/app.py
- Command line
-
hf download hf://spaces/STATICAI/Motion-Rig/app.py
-
curl -L -o app.py https://huggingface.co/spaces/STATICAI/Motion-Rig/resolve/main/app.py
1.04 kB
| """Gradio ZeroGPU entry point for the existing Make-It-Animatable workflow.""" | |
| import os | |
| import subprocess | |
| import sys | |
| os.chdir(os.path.dirname(os.path.abspath(__file__))) | |
| subprocess.run(["bash", "install.sh"], check=True) | |
| import spaces | |
| import torch | |
| import torchvision | |
| import torch_cluster | |
| import pytorch3d | |
| import bpy | |
| import gradio | |
| print( | |
| "STARTUP_VERSIONS " | |
| f"python={sys.version.split()[0]} torch={torch.__version__} " | |
| f"torchvision={torchvision.__version__} cuda_wheel={torch.version.cuda} " | |
| f"torch_cluster={getattr(torch_cluster, '__version__', 'unknown')} " | |
| f"pytorch3d={pytorch3d.__version__} bpy={bpy.app.version_string} " | |
| f"gradio={gradio.__version__}", flush=True) | |
| assert torch.__version__.startswith("2.8.0"), "ZeroGPU build did not install Torch 2.8.0" | |
| from app.app import * | |
| init_models() | |
| demo = init_blocks() | |
| demo.launch(server_name="0.0.0.0", server_port=7860, | |
| allowed_paths=[".", "/data/app/data/Standard Run.fbx", "/data/app/output"], | |
| show_error=True, ssr_mode=False) | |