【Python】安装Pocketsphinx 时报错:error: command ‘swig.exe‘ failed: No such file or directory 解决

在网上试了很多种方法,比如下载swig 安装包,解压配置环境变量之类的,试了好几个解压路径然后配置都不对,气呼呼!!!

【Python】安装Pocketsphinx 时报错:error: command ‘swig.exe‘ failed: No such file or directory 解决_第1张图片

最后,尝试了用conda来安装,超级开心!

因此,下面这种方法仅限于安装了anaconda的用户有效,且不一定100%有效,下面就开始吧

两个命令

conda install swig

【Python】安装Pocketsphinx 时报错:error: command ‘swig.exe‘ failed: No such file or directory 解决_第2张图片

安装完成,然后接着安装Pocketsphinx

pip install pocketsphinx

【Python】安装Pocketsphinx 时报错:error: command ‘swig.exe‘ failed: No such file or directory 解决_第3张图片
太开心啦!!

 

你可能感兴趣的:(python,python,anaconda)