evanarlian / whisper-torchscript

Robust Speech Recognition via Large-Scale Weak Supervision

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

whisper-torchscript

See original readme and repo. This repo modifies Whisper a little bit to enable TorchScript.

What's new?

  • TorchScript-able model.
  • kv_cache will be passed normally instead of using hooks.
  • Cannot use the existing wrapper library with this new model code.
  • Some modules will be duplicated in favor of using less if elses.

Same as before:

  • Original checkpoints are still valid.
  • Model architecture is the same as before.

Added files:

  • Scriptable model in model2.py
  • Comparison and tests in tests.ipynb
  • Prebuilt multilingual GPT2 tokenizer in whisper/assets/whisper_mult_gpt2/

About

Robust Speech Recognition via Large-Scale Weak Supervision

License:MIT License


Languages

Language:Jupyter Notebook 53.9%Language:Python 46.1%