Changed tensor location
Browse files
app.py
CHANGED
@@ -48,8 +48,8 @@ def get_audio(audio_path, duration=10, target_sr=16000):
|
|
48 |
|
49 |
def captioning(model,audio_path):
|
50 |
audio_tensor = get_audio(audio_path = audio_path)
|
51 |
-
if device is not None:
|
52 |
-
|
53 |
with torch.no_grad():
|
54 |
output = model.generate(
|
55 |
samples=audio_tensor,
|
|
|
48 |
|
49 |
def captioning(model,audio_path):
|
50 |
audio_tensor = get_audio(audio_path = audio_path)
|
51 |
+
# if device is not None:
|
52 |
+
# audio_tensor = audio_tensor.to(device)
|
53 |
with torch.no_grad():
|
54 |
output = model.generate(
|
55 |
samples=audio_tensor,
|