Is there a way to detect pauses while taking input from the microphone in python? I have a sample code that uses speech-recognition google API to convert speech to text usin