PyQt4 is a set of Python bindings for the Qt4 toolkit
PyQt4 is a set of Python bindings for the Qt4 toolkit. The bindings are implemented as a set of Python modules: qt, qtcanvas, qtgl, qtnetwork, qtsql, qttable, qtui and qtxml, and contains 300 classes and over 5,750 functions and methods.
To install py27-pyqt4, paste this in macOS terminal after installing MacPorts
sudo port install py27-pyqt4