k2-fsa / sherpa

Speech-to-text server framework with next-gen Kaldi
https://k2-fsa.github.io/sherpa
Apache License 2.0
474 stars 97 forks source link

Use InferenceMode to replace NoGradMode. #535

Closed csukuangfj closed 5 months ago

csukuangfj commented 5 months ago

See also https://pytorch.org/cppdocs/notes/inference_mode.html

InferenceMode is available since torch >= 1.9.0 (see here)