Test: ran the code and checked for ffmpeg functionality
This commit is contained in:
+2
-4
@@ -102,14 +102,12 @@ class Transcriber:
|
||||
logger.exception("Failed to save transcript: %s", e)
|
||||
raise
|
||||
|
||||
def _clear_memory(self):
|
||||
@staticmethod
|
||||
def _clear_memory():
|
||||
"""
|
||||
Clear GPU memory.
|
||||
"""
|
||||
try:
|
||||
del self.transcription_model
|
||||
del self.alignment_model
|
||||
del self.metadata
|
||||
gc.collect()
|
||||
torch.cuda.empty_cache()
|
||||
except Exception as e:
|
||||
|
||||
Reference in New Issue
Block a user