Spaces:
Paused
Paused
Commit
·
d720b81
1
Parent(s):
d3080a2
Fix CUDA generator error by moving pipeline to GPU
Browse filesAdd pipe.to("cuda") inside GPU-decorated function to ensure
pipeline is on CUDA before using CUDA generator
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
app.py
CHANGED
|
@@ -54,7 +54,10 @@ def generate_interpolation(
|
|
| 54 |
f"Parameters: frames={num_frames}, steps={num_inference_steps}, guidance={guidance_scale}"
|
| 55 |
)
|
| 56 |
|
| 57 |
-
#
|
|
|
|
|
|
|
|
|
|
| 58 |
generator = torch.Generator(device="cuda").manual_seed(seed)
|
| 59 |
|
| 60 |
video = pipe(
|
|
|
|
| 54 |
f"Parameters: frames={num_frames}, steps={num_inference_steps}, guidance={guidance_scale}"
|
| 55 |
)
|
| 56 |
|
| 57 |
+
# Move pipeline to CUDA within the GPU-decorated function
|
| 58 |
+
pipe.to("cuda")
|
| 59 |
+
|
| 60 |
+
# Generate video
|
| 61 |
generator = torch.Generator(device="cuda").manual_seed(seed)
|
| 62 |
|
| 63 |
video = pipe(
|