Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- from danspeech import Recognizer
- from danspeech.pretrained_models import DanSpeechPrimary
- from danspeech.audio import load_audio
- # Load a DanSpeech model. If the model does not exists, it will be downloaded.
- model = DanSpeechPrimary()
- recognizer = Recognizer(model=model)
- # Load the audio file.
- audio = load_audio(path="../example_files/u0042019.wav")
- # Recognize and print output
- print(recognizer.recognize(audio))
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement