Update app.py
Browse files
app.py
CHANGED
|
@@ -15,11 +15,7 @@ LTX_REPO_DIR = os.path.join(os.path.dirname(os.path.abspath(__file__)), "LTX-2")
|
|
| 15 |
|
| 16 |
if not os.path.exists(LTX_REPO_DIR):
|
| 17 |
print(f"Cloning {LTX_REPO_URL}...")
|
| 18 |
-
subprocess.run(["git", "clone", LTX_REPO_URL, LTX_REPO_DIR], check=True)
|
| 19 |
-
|
| 20 |
-
# 🔒 Pin to last known working commit (UPDATE THIS if needed)
|
| 21 |
-
WORKING_COMMIT = "c0b9c6d" # example commit — replace with your known working one
|
| 22 |
-
subprocess.run(["git", "-C", LTX_REPO_DIR, "checkout", WORKING_COMMIT], check=True)
|
| 23 |
|
| 24 |
print("Installing ltx-core and ltx-pipelines from cloned repo...")
|
| 25 |
subprocess.run(
|
|
@@ -52,7 +48,8 @@ from ltx_core.components.diffusion_steps import EulerDiffusionStep
|
|
| 52 |
from ltx_core.components.noisers import GaussianNoiser
|
| 53 |
from ltx_core.model.audio_vae import encode_audio as vae_encode_audio
|
| 54 |
from ltx_core.model.upsampler import upsample_video
|
| 55 |
-
from ltx_core.model.video_vae import TilingConfig, get_video_chunks_number
|
|
|
|
| 56 |
from ltx_core.quantization import QuantizationPolicy
|
| 57 |
from ltx_core.types import Audio, AudioLatentShape, VideoPixelShape
|
| 58 |
from ltx_pipelines.distilled import DistilledPipeline
|
|
|
|
| 15 |
|
| 16 |
if not os.path.exists(LTX_REPO_DIR):
|
| 17 |
print(f"Cloning {LTX_REPO_URL}...")
|
| 18 |
+
subprocess.run(["git", "clone", "--depth", "1", LTX_REPO_URL, LTX_REPO_DIR], check=True)
|
|
|
|
|
|
|
|
|
|
|
|
|
| 19 |
|
| 20 |
print("Installing ltx-core and ltx-pipelines from cloned repo...")
|
| 21 |
subprocess.run(
|
|
|
|
| 48 |
from ltx_core.components.noisers import GaussianNoiser
|
| 49 |
from ltx_core.model.audio_vae import encode_audio as vae_encode_audio
|
| 50 |
from ltx_core.model.upsampler import upsample_video
|
| 51 |
+
from ltx_core.model.video_vae import TilingConfig, get_video_chunks_number
|
| 52 |
+
from ltx_core.model.video_vae.video_vae import decode_video as vae_decode_video
|
| 53 |
from ltx_core.quantization import QuantizationPolicy
|
| 54 |
from ltx_core.types import Audio, AudioLatentShape, VideoPixelShape
|
| 55 |
from ltx_pipelines.distilled import DistilledPipeline
|