Create usage.py
Browse files
usage.py
ADDED
|
@@ -0,0 +1,6 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
from transformers import pipeline
|
| 2 |
+
|
| 3 |
+
pipe = pipeline("greek.wav","automatic-speech-recognition", model="stt-greek",return_timestamps=True)
|
| 4 |
+
result=pipe(audio, generate_kwargs={"task": "transcribe"},"language":"el"})["text"]
|
| 5 |
+
print (result)
|
| 6 |
+
|