A more specific answer to this.
Instead of using the command like this in python:
os.system("ffmpeg -i /Users/krish/audio.mp3 -acodec pcm_s16le -ar 16000 -ac 1 /Users/krish/converted_audio.wav")
First try to find out where is your ffmpeg installation by giving the following command in terminal (Works on linux and mac)
which ffmpeg
In my case this was the output of the above command:
/usr/local/bin/ffmpeg
Now, modify the os.system command in python as follows:
os.system("/usr/local/bin/ffmpeg -i /Users/krish/audio.mp3 -acodec pcm_s16le -ar 16000 -ac 1 /Users/krish/converted_audio.wav")
which should work great without throwing 32512 error!