Spaces:
Paused
Paused
Update app.py
Browse files
app.py
CHANGED
|
@@ -87,7 +87,8 @@ def infer(image, prompt, steps=50, cfg_scale=7.5, eta=1.0, fs=3, seed=123):
|
|
| 87 |
cond = {"c_crossattn": [imtext_cond], "fs": fs, "c_concat": [img_tensor_repeat]}
|
| 88 |
|
| 89 |
## inference
|
| 90 |
-
|
|
|
|
| 91 |
## b,samples,c,t,h,w
|
| 92 |
|
| 93 |
video_path = './output.mp4'
|
|
|
|
| 87 |
cond = {"c_crossattn": [imtext_cond], "fs": fs, "c_concat": [img_tensor_repeat]}
|
| 88 |
|
| 89 |
## inference
|
| 90 |
+
with torch.no_grad(), torch.cuda.amp.autocast():
|
| 91 |
+
batch_samples = batch_ddim_sampling(model, cond, noise_shape, n_samples=1, ddim_steps=steps, ddim_eta=eta, cfg_scale=cfg_scale)
|
| 92 |
## b,samples,c,t,h,w
|
| 93 |
|
| 94 |
video_path = './output.mp4'
|