mirror of
https://github.com/shirayu/whispering.git
synced 2024-06-12 18:29:21 +00:00
add download script
This commit is contained in:
parent
cc1099b46c
commit
7f77589138
|
@ -18,8 +18,8 @@ WORKDIR /app
|
|||
|
||||
RUN pip install .
|
||||
|
||||
# install whisper models
|
||||
RUN python3 -c 'import whisper\nfrom pathlib import Path\n\n[\n whisper._download(\n whisper._MODELS[m], str(Path("~/.cache/whisper").expanduser()), False\n )\n for m in ["tiny", "base", "small", "medium", "large"]\n]'
|
||||
COPY download_whisper_models.py .
|
||||
RUN python3 download_whisper_models.py
|
||||
|
||||
# open bash
|
||||
CMD ["/bin/bash"]
|
||||
|
|
8
download_whisper_models.py
Normal file
8
download_whisper_models.py
Normal file
|
@ -0,0 +1,8 @@
|
|||
from pathlib import Path
|
||||
|
||||
import whisper
|
||||
|
||||
download_path = str(Path("~/.cache/whisper").expanduser())
|
||||
|
||||
for m in ["tiny", "base", "small", "medium", "large"]:
|
||||
whisper._download(whisper._MODELS[m], download_path, False)
|
Loading…
Reference in a new issue