Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add large-v3 #7

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions predict.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ class Predictor(BasePredictor):
def setup(self):
"""Loads whisper models into memory to make running multiple predictions efficient"""

with open(f"./weights/large-v2.pt", "rb") as fp:
with open(f"./weights/large-v3.pt", "rb") as fp:
checkpoint = torch.load(fp, map_location="cpu")
dims = ModelDimensions(**checkpoint["dims"])
self.model = Whisper(dims)
Expand All @@ -40,8 +40,8 @@ def predict(
self,
audio: Path = Input(description="Audio file"),
model: str = Input(
default="large-v2",
choices=["large", "large-v2"],
default="large-v3",
choices=["large", "large-v3"],
description="Choose a Whisper model.",
),
transcription: str = Input(
Expand Down
3 changes: 2 additions & 1 deletion scripts/get_weights.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,5 @@ mkdir -p weights
# curl -o weights/small.pt -L https://openaipublic.azureedge.net/main/whisper/models/9ecf779972d90ba49c06d968637d720dd632c55bbf19d441fb42bf17a411e794/small.pt
# curl -o weights/medium.pt -L https://openaipublic.azureedge.net/main/whisper/models/345ae4da62f9b3d59415adc60127b97c714f32e89e936602e85993674d08dcb1/medium.pt
# curl -o weights/large-v1.pt -L https://openaipublic.azureedge.net/main/whisper/models/e4b87e7e0bf463eb8e6956e646f1e277e901512310def2c24bf0e11bd3c28e9a/large-v1.pt
curl -o weights/large-v2.pt -L https://openaipublic.azureedge.net/main/whisper/models/81f7c96c852ee8fc832187b0132e569d6c3065a3252ed18e56effd0b6a73e524/large-v2.pt
# curl -o weights/large-v2.pt -L https://openaipublic.azureedge.net/main/whisper/models/81f7c96c852ee8fc832187b0132e569d6c3065a3252ed18e56effd0b6a73e524/large-v2.pt
curl -o weights/large-v3.pt -L https://openaipublic.azureedge.net/main/whisper/models/e5b1a55b89c1367dacf97e3e19bfd829a01529dbfdeefa8caeb59b3f1b81dadb/large-v3.pt