Update README.md
Browse files
README.md
CHANGED
|
@@ -57,10 +57,13 @@ This model is a fine-tuned version of [openai/whisper-large-v3](https://huggingf
|
|
| 57 |
|
| 58 |
```python
|
| 59 |
from transformers import WhisperProcessor, WhisperForConditionalGeneration
|
| 60 |
-
import torch
|
| 61 |
-
import torchaudio
|
| 62 |
|
| 63 |
model_id = "yehiazak/whisper-largev3-medical"
|
| 64 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 65 |
processor = WhisperProcessor.from_pretrained(model_id)
|
| 66 |
-
model = WhisperForConditionalGeneration.from_pretrained(model_id)
|
|
|
|
| 57 |
|
| 58 |
```python
|
| 59 |
from transformers import WhisperProcessor, WhisperForConditionalGeneration
|
|
|
|
|
|
|
| 60 |
|
| 61 |
model_id = "yehiazak/whisper-largev3-medical"
|
| 62 |
|
| 63 |
+
# Load FP16 model
|
| 64 |
+
model = WhisperForConditionalGeneration.from_pretrained(model_id, revision="fp16")
|
| 65 |
+
|
| 66 |
+
# Load FP32 model
|
| 67 |
+
model = WhisperForConditionalGeneration.from_pretrained(model_id)
|
| 68 |
+
|
| 69 |
processor = WhisperProcessor.from_pretrained(model_id)
|
|
|