screen = QtGui.QApplication.desktop().screenNumber(QtGui.QApplication.
    desktop().cursor().pos())
centerPoint = QtGui.QApplication.desktop().screenGeometry(screen).center()
frameGm.moveCenter(centerPoint)
PyQt4 center window on active screen