Instructions to use lesliejd/jt-whisper with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use lesliejd/jt-whisper with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("automatic-speech-recognition", model="lesliejd/jt-whisper")# Load model directly from transformers import AutoProcessor, AutoModelForSpeechSeq2Seq processor = AutoProcessor.from_pretrained("lesliejd/jt-whisper") model = AutoModelForSpeechSeq2Seq.from_pretrained("lesliejd/jt-whisper") - Notebooks
- Google Colab
- Kaggle
Leslie Jones-Dove commited on
Commit ·
78c28a3
1
Parent(s): f0386c6
remove returns_timestamp
Browse files- __pycache__/handler.cpython-39.pyc +0 -0
- handler.py +2 -2
__pycache__/handler.cpython-39.pyc
CHANGED
|
Binary files a/__pycache__/handler.cpython-39.pyc and b/__pycache__/handler.cpython-39.pyc differ
|
|
|
handler.py
CHANGED
|
@@ -1,5 +1,5 @@
|
|
| 1 |
from typing import Dict, List, Any
|
| 2 |
-
from transformers import pipeline
|
| 3 |
import torch
|
| 4 |
|
| 5 |
class EndpointHandler():
|
|
@@ -22,5 +22,5 @@ class EndpointHandler():
|
|
| 22 |
"""
|
| 23 |
inputs = data.pop("inputs",data)
|
| 24 |
print("inputs", inputs)
|
| 25 |
-
prediction = self.pipe(inputs
|
| 26 |
return prediction
|
|
|
|
| 1 |
from typing import Dict, List, Any
|
| 2 |
+
from transformers import pipeline
|
| 3 |
import torch
|
| 4 |
|
| 5 |
class EndpointHandler():
|
|
|
|
| 22 |
"""
|
| 23 |
inputs = data.pop("inputs",data)
|
| 24 |
print("inputs", inputs)
|
| 25 |
+
prediction = self.pipe(inputs)
|
| 26 |
return prediction
|