displaying image using a label
问题 I have converted a numpy array into a pixmap to display it on a label within my GUI. When I run the program, the GUI closes for some reason (no error messages). height, width = input_image.shape bytesPerLine = 3 * width qImg = QtGui.QImage(input_image.data, width, height, bytesPerLine, QtGui.QImage.Format_RGB888) pixmap01 = QtGui.QPixmap.fromImage(qImg) self.pixmap_image = QtGui.QPixmap(pixmap01) self.ui.label_imageDisplay.setPixmap(self.pixmap_image) self.ui.label_imageDisplay.setAlignment