Skip to content

2025

#291: Extract Text From Audio Files With Vosk

With sounddevice and PyAudio we found two solutions to record audio files. With this new knowledge we can go one step further and find an option to extract the text from those recordings. For this task we ignore the online services and jump directly to two solutions that run on our local machine. In this post we use Vosk to transcribe our audio file, while next week we find out how well Whisper solves this task.

#290: Record Audio With PyAudio

Last week we used sounddevice to record audio with Python. In this post we do the same thing, but with the PyAudio library. Depending on your environment and sound devices, you may need more flexibility and operating-system specific support than what sounddevice can offer.

#287: PyTorch With GPU Support

Last week we noticed that Coqui did not run on our GPU. If you have a dedicated graphics card, that is not what you want. While CPUs are getting faster and faster, they are usually much slower than what we could get out of our graphics card. Let us see how we can activate GPU support for PyTorch.

#284: Basic Text-to-Speech With Google Translate

When it comes to text-to-speech (TTS), we may think that this is a solved problem, and we can use any library we find to get a good result. Unfortunately, that is not the case. There are a lot of older models that sound like a robot and even newer ones are far away from the quality we got used to by commercial products.

For our first steps with text-to-speech we try a minimal approach and use Google Translate. That gives us a quick win and is enough if we only want to work with a few sentences. The next posts will cover locally installed solutions that do not send data to a service.

#282: Working With Temporary Files

Sometimes we just need a file to store some temporary data and discard it as soon as we are done. In this case, creating permanent files and deleting them manually does not make sense. Fortunately, Python gives us a solution tailored for this situation: the tempfile module. Let us explore how it can help.