Open-source speech recognition toolkit for training, inference, streaming ASR, VAD, punctuation, speaker diarization pipelines, and OpenAI-compatible/MCP serving.
Python asraudiochineseemotion-recognitionfunasrmcp-servermultilingual-asropenai-compatible-apiparaformerpunctuationpytorchreal-time-asrspeaker-diarizationspeech-recognitionspeech-to-textstreaming-asrtranscriptionvllmvoice-activity-detectionwhisper-alternative
oom fix
游雁001a66bbfe80
diff --git a/funasr/bin/train.py b/funasr/bin/train.pyindex b2b1dcdb2..45e23a8c6 100644--- a/funasr/bin/train.py+++ b/funasr/bin/train.py@@ -221,10 +221,10 @@ def main(**kwargs):)trainer.start_step = 0- device = next(model.parameters()).device- if device.type == 'cuda':- with torch.cuda.device():- torch.cuda.empty_cache()+ # device = next(model.parameters()).device+ # if device.type == 'cuda':+ # with torch.cuda.device():+ # torch.cuda.empty_cache()time_escaped = (time.perf_counter() - time_slice_i) / 3600.0logging.info(diff --git a/funasr/bin/train_ds.py b/funasr/bin/train_ds.pyindex bfa1dff94..b28752ba8 100644--- a/funasr/bin/train_ds.py+++ b/funasr/bin/train_ds.py@@ -184,10 +184,10 @@ def main(**kwargs):)trainer.start_step = 0- device = next(model.parameters()).device- if device.type == 'cuda':- with torch.cuda.device():- torch.cuda.empty_cache()+ # device = next(model.parameters()).device+ # if device.type == 'cuda':+ # with torch.cuda.device():+ # torch.cuda.empty_cache()time_escaped = (time.perf_counter() - time_slice_i) / 3600.0logging.info(