Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -7,6 +7,12 @@ from moviepy.editor import VideoFileClip
|
|
7 |
import json
|
8 |
import spaces
|
9 |
|
|
|
|
|
|
|
|
|
|
|
|
|
10 |
def truncate_video(video_file):
|
11 |
"""Truncates video to 15 seconds and saves it as a temporary file."""
|
12 |
clip = VideoFileClip(video_file)
|
|
|
7 |
import json
|
8 |
import spaces
|
9 |
|
10 |
+
torch.use_deterministic_algorithms(True)
|
11 |
+
torch.backends.cudnn.deterministic = True
|
12 |
+
torch.backends.cudnn.benchmark = False
|
13 |
+
torch.backends.cuda.matmul.allow_tf32 = False
|
14 |
+
torch.backends.cudnn.allow_tf32 = False
|
15 |
+
|
16 |
def truncate_video(video_file):
|
17 |
"""Truncates video to 15 seconds and saves it as a temporary file."""
|
18 |
clip = VideoFileClip(video_file)
|