在Anaconda下安装完labelImg后,spyder无法正常打开使用,解决方法:进入Anaconda prompt,建立一个python虚拟环境,在虚拟环境中安装labelImg,不影响spyder的使用。
Anaconda prompt:
conda env list(查看当前有哪些虚拟环境)
conda create -n LabelIMG python==3.7(创建python3.7的虚拟环境,文件夹命名LabelIMG)
activate LabelIMG(激活LabelIMG环境)
pip install PyQt5 -i https://pypi.tuna.tsinghua.edu.cn/simple/(使用镜像安装PyQt5)
pip install pyqt5-tools -i https://pypi.tuna.tsinghua.edu.cn/simple/(安装pyqt5-tools)
pip install lxml -i https://pypi.tuna.tsinghua.edu.cn/simple/(安装lxml)
pip install labelImg -i https://pypi.tuna.tsinghua.edu.cn/simple/(安装labelImg)
labelImg(启动labelImg)
labelImg和spyder均正常使用: