def openFileNameDialog4(self): fileName = QFileDialog.getExistingDirectory(self,"Select Folder") p = pg.Kmeans_detection(fileName)