Spaces:
Running
on
Zero
Running
on
Zero
Update whisper_cs_dev.py
Browse filesHardcoded torch utils for debugging
- whisper_cs_dev.py +4 -3
whisper_cs_dev.py
CHANGED
|
@@ -12,7 +12,8 @@ def get_settings():
|
|
| 12 |
|
| 13 |
if DEBUG_MODE: print(f"Entering get_settings function...")
|
| 14 |
|
| 15 |
-
|
|
|
|
| 16 |
if is_cuda_available:
|
| 17 |
device = "cuda"
|
| 18 |
compute_type = "float16"
|
|
@@ -109,8 +110,8 @@ def process_waveforms():
|
|
| 109 |
right_waveform, _ = format_audio(RIGHT_CHANNEL_TEMP_PATH)
|
| 110 |
|
| 111 |
# TODO should this be equal to compute_type?
|
| 112 |
-
left_waveform = left_waveform.numpy().astype("
|
| 113 |
-
right_waveform = right_waveform.numpy().astype("
|
| 114 |
|
| 115 |
if DEBUG_MODE: print(f"Exited process_waveforms function.")
|
| 116 |
|
|
|
|
| 12 |
|
| 13 |
if DEBUG_MODE: print(f"Entering get_settings function...")
|
| 14 |
|
| 15 |
+
# HACK hardcoding this to try
|
| 16 |
+
is_cuda_available = True #torch.cuda.is_available()
|
| 17 |
if is_cuda_available:
|
| 18 |
device = "cuda"
|
| 19 |
compute_type = "float16"
|
|
|
|
| 110 |
right_waveform, _ = format_audio(RIGHT_CHANNEL_TEMP_PATH)
|
| 111 |
|
| 112 |
# TODO should this be equal to compute_type?
|
| 113 |
+
left_waveform = left_waveform.numpy().astype("float16")
|
| 114 |
+
right_waveform = right_waveform.numpy().astype("float16")
|
| 115 |
|
| 116 |
if DEBUG_MODE: print(f"Exited process_waveforms function.")
|
| 117 |
|