Spaces:
Running
on
Zero
Running
on
Zero
Update app.py
Browse files
app.py
CHANGED
|
@@ -7,7 +7,7 @@ import tempfile
|
|
| 7 |
import spaces
|
| 8 |
from huggingface_hub import hf_hub_download
|
| 9 |
import numpy as np
|
| 10 |
-
|
| 11 |
import random
|
| 12 |
|
| 13 |
|
|
@@ -96,7 +96,7 @@ def update_prompt_from_mode(mode):
|
|
| 96 |
return MODE_PROMPTS.get(mode, "")
|
| 97 |
|
| 98 |
|
| 99 |
-
def prepare_video_and_mask_Ref2V( height: int, width: int, num_frames: int
|
| 100 |
frames = []
|
| 101 |
# Ideally, this should be 127.5 to match original code, but they perform computation on numpy arrays
|
| 102 |
# whereas we are passing PIL images. If you choose to pass numpy arrays, you can set it to 127.5 to
|
|
|
|
| 7 |
import spaces
|
| 8 |
from huggingface_hub import hf_hub_download
|
| 9 |
import numpy as np
|
| 10 |
+
import PIL.Image
|
| 11 |
import random
|
| 12 |
|
| 13 |
|
|
|
|
| 96 |
return MODE_PROMPTS.get(mode, "")
|
| 97 |
|
| 98 |
|
| 99 |
+
def prepare_video_and_mask_Ref2V( height: int, width: int, num_frames: int):
|
| 100 |
frames = []
|
| 101 |
# Ideally, this should be 127.5 to match original code, but they perform computation on numpy arrays
|
| 102 |
# whereas we are passing PIL images. If you choose to pass numpy arrays, you can set it to 127.5 to
|