Spaces:
Running on Zero
Running on Zero
Update app.py
Browse files
app.py
CHANGED
|
@@ -1,14 +1,3 @@
|
|
| 1 |
-
"""
|
| 2 |
-
Gradio Demo for Helios Video Generation (ZeroGPU / HF Spaces)
|
| 3 |
-
==============================================================
|
| 4 |
-
Pre-loads Helios-Distilled for fast inference on ZeroGPU.
|
| 5 |
-
Supports Text-to-Video (T2V), Image-to-Video (I2V), and Video-to-Video (V2V).
|
| 6 |
-
|
| 7 |
-
Usage:
|
| 8 |
-
pip install gradio torch diffusers transformers sentencepiece spaces
|
| 9 |
-
python app.py
|
| 10 |
-
"""
|
| 11 |
-
|
| 12 |
import os
|
| 13 |
import subprocess
|
| 14 |
import sys
|
|
@@ -22,8 +11,7 @@ import zipfile
|
|
| 22 |
_APP_DIR = os.path.dirname(os.path.abspath(__file__))
|
| 23 |
ZIP_PATH = os.path.join(_APP_DIR, "helios_diffusers.zip")
|
| 24 |
EXTRACT_DIR = os.path.join(_APP_DIR, "_helios_diffusers")
|
| 25 |
-
|
| 26 |
-
# diffusers-new-model-addition-helios-main/ (contains pyproject.toml / setup.py)
|
| 27 |
_PKG_ROOT = os.path.join(EXTRACT_DIR, "diffusers-new-model-addition-helios-helios")
|
| 28 |
|
| 29 |
if not os.path.isdir(_PKG_ROOT):
|
|
@@ -136,7 +124,7 @@ CSS = """
|
|
| 136 |
#header { text-align: center; margin-bottom: 0.5em; }
|
| 137 |
#header h1 { font-size: 2.2em; margin-bottom: 0; }
|
| 138 |
#header p { opacity: 0.7; margin-top: 0.2em; }
|
| 139 |
-
.contain { max-width:
|
| 140 |
"""
|
| 141 |
|
| 142 |
with gr.Blocks(css=CSS, title="Helios Video Generation", theme=gr.themes.Soft()) as demo:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
import os
|
| 2 |
import subprocess
|
| 3 |
import sys
|
|
|
|
| 11 |
_APP_DIR = os.path.dirname(os.path.abspath(__file__))
|
| 12 |
ZIP_PATH = os.path.join(_APP_DIR, "helios_diffusers.zip")
|
| 13 |
EXTRACT_DIR = os.path.join(_APP_DIR, "_helios_diffusers")
|
| 14 |
+
|
|
|
|
| 15 |
_PKG_ROOT = os.path.join(EXTRACT_DIR, "diffusers-new-model-addition-helios-helios")
|
| 16 |
|
| 17 |
if not os.path.isdir(_PKG_ROOT):
|
|
|
|
| 124 |
#header { text-align: center; margin-bottom: 0.5em; }
|
| 125 |
#header h1 { font-size: 2.2em; margin-bottom: 0; }
|
| 126 |
#header p { opacity: 0.7; margin-top: 0.2em; }
|
| 127 |
+
.contain { max-width: 1350px; margin: 0 auto !important; }
|
| 128 |
"""
|
| 129 |
|
| 130 |
with gr.Blocks(css=CSS, title="Helios Video Generation", theme=gr.themes.Soft()) as demo:
|