12 lines
298 B
Python
12 lines
298 B
Python
import whisper
|
|
import json
|
|
|
|
|
|
model = whisper.load_model('tiny')
|
|
|
|
|
|
result = model.transcribe(str("C:\\Users\\afist\\Downloads\\Aufzeichnung.mp3"), language='de', verbose=True)
|
|
|
|
# Dump the results to a JSON file
|
|
with open('transcript.json', "w") as file:
|
|
json.dump(result['text'], file, indent=4) |