Spaces:
Paused
Paused
Update app.py
Browse files
app.py
CHANGED
@@ -1,5 +1,6 @@
|
|
1 |
import os
|
2 |
import sys
|
|
|
3 |
sys.path.insert(0, os.path.dirname(os.path.abspath(__file__)))
|
4 |
|
5 |
#import subprocess
|
@@ -31,7 +32,7 @@ ckpt_dir = snapshot_download(repo_id, local_dir_use_symlinks=False)
|
|
31 |
print(f"Using checkpoints from {ckpt_dir}")
|
32 |
|
33 |
# Load the model configuration
|
34 |
-
TASK_NAME = 'ti2v-5B'
|
35 |
cfg = WAN_CONFIGS[TASK_NAME]
|
36 |
FIXED_FPS = 24
|
37 |
MIN_FRAMES_MODEL = 8
|
@@ -41,6 +42,10 @@ MAX_FRAMES_MODEL = 121
|
|
41 |
print("Initializing WanTI2V pipeline...")
|
42 |
device = "cuda" if torch.cuda.is_available() else "cpu"
|
43 |
device_id = 0 if torch.cuda.is_available() else -1
|
|
|
|
|
|
|
|
|
44 |
pipeline = wan.WanTI2V(
|
45 |
config=cfg,
|
46 |
checkpoint_dir=ckpt_dir,
|
|
|
1 |
import os
|
2 |
import sys
|
3 |
+
from diffusers import WanImageToVideoPipeline, AutoencoderKLWan, ModularPi
|
4 |
sys.path.insert(0, os.path.dirname(os.path.abspath(__file__)))
|
5 |
|
6 |
#import subprocess
|
|
|
32 |
print(f"Using checkpoints from {ckpt_dir}")
|
33 |
|
34 |
# Load the model configuration
|
35 |
+
TASK_NAME = 'ti2v-5B-Diff'
|
36 |
cfg = WAN_CONFIGS[TASK_NAME]
|
37 |
FIXED_FPS = 24
|
38 |
MIN_FRAMES_MODEL = 8
|
|
|
42 |
print("Initializing WanTI2V pipeline...")
|
43 |
device = "cuda" if torch.cuda.is_available() else "cpu"
|
44 |
device_id = 0 if torch.cuda.is_available() else -1
|
45 |
+
|
46 |
+
|
47 |
+
|
48 |
+
|
49 |
pipeline = wan.WanTI2V(
|
50 |
config=cfg,
|
51 |
checkpoint_dir=ckpt_dir,
|