1.安装pyqt5
1.打开anaconda prompt命令窗口,激活虚拟环境:activate tensorflow
2.安装PyQt5
pip install pyqt5
3.安装PyQt5-tools
pip install pyqt5-tools
4.检验是否安装成功
执行如下代码,
# FileName : PyQtDemo.py # Author : Adil # DateTime : 2018/2/1 11:07 # SoftWare : PyCharm from PyQt5 import QtWidgets, QtGui import sys app = QtWidgets.QApplication(sys.argv) window = QtWidgets.QWidget(); window.show() sys.exit(app.exec_())