GUI changes and updates

This commit is contained in:
Marcel Paffrath 2016-06-17 13:14:20 +02:00
parent f01187615b
commit 8393f283c7
3 changed files with 199 additions and 89 deletions

View File

@ -80,26 +80,26 @@ class gui_control(object):
def interpolate_receivers(self): def interpolate_receivers(self):
if not self.checkSeisArrayState(): if not self.checkSeisArrayState():
print('No Seismic Array defined.') self.printDialogMessage('No Seismic Array defined.')
return return
self.seisarray.interpolateAll() self.seisarray.interpolateAll()
def getPickParameters(self, ui, Picking_parameters): def getPickParameters(self, ui, Picking_parameters):
if Picking_parameters.exec_(): if Picking_parameters.exec_():
ncores = int(ui.lineEdit_ncores.text()) ncores = int(ui.ncores.value())
vmin = float(ui.lineEdit_vmin.text()) vmin = float(ui.lineEdit_vmin.text())
vmax = float(ui.lineEdit_vmax.text()) vmax = float(ui.lineEdit_vmax.text())
folm = float(ui.lineEdit_folm.text()) folm = float(ui.lineEdit_folm.text())
AIC = ui.checkBox.isChecked() AIC = ui.checkBox_AIC.isChecked()
aicwindow = [int(val) for val in ui.lineEdit_aicwindow.text().split(',')] aicwindow = (int(ui.lineEdit_aicleft.text()), int(ui.lineEdit_aicright.text()))
return ncores, vmin, vmax, folm, AIC, tuple(aicwindow) return ncores, vmin, vmax, folm, AIC, aicwindow
def connect2Survey(self): def connect2Survey(self):
if not self.checkSurveyState(): if not self.checkSurveyState():
print('Survey not defined.') self.printDialogMessage('No Survey defined.')
return return
if not self.checkSeisArrayState(): if not self.checkSeisArrayState():
print('Got no Seismic Array.') self.printDialogMessage('Got no Seismic Array.')
return return
if self.checkConnected2SurveyState(): if self.checkConnected2SurveyState():
if self.continueDialogMessage('Existing Survey already got Seismic Array object. Continue?'): if self.continueDialogMessage('Existing Survey already got Seismic Array object. Continue?'):
@ -108,16 +108,21 @@ class gui_control(object):
self.setConnected2SurveyState(True) self.setConnected2SurveyState(True)
print('Connected Seismic Array to active Survey object.') print('Connected Seismic Array to active Survey object.')
def getMaxCPU(self):
import multiprocessing
return multiprocessing.cpu_count()
def callPicker(self): def callPicker(self):
if not self.checkSurveyState(): if not self.checkSurveyState():
print('Survey not defined.') self.printDialogMessage('No Survey defined.')
return return
if self.checkPickState(): if self.checkPickState():
if not self.continueDialogMessage('Survey already picked. Continue?'): if not self.continueDialogMessage('Survey already picked. Continue?'):
return return
Picking_parameters = QtGui.QDialog(self.mainwindow) Picking_parameters = QtGui.QDialog(self.mainwindow)
ui = Ui_Picking_parameters() ui = Ui_picking_parameters()
ui.setupUi(Picking_parameters) ui.setupUi(Picking_parameters)
ui.ncores.setMaximum(self.getMaxCPU())
try: try:
ncores, vmin, vmax, folm, AIC, aicwindow = self.getPickParameters(ui, Picking_parameters) ncores, vmin, vmax, folm, AIC, aicwindow = self.getPickParameters(ui, Picking_parameters)
except TypeError: except TypeError:
@ -135,11 +140,13 @@ class gui_control(object):
def startFMTOMO(self): def startFMTOMO(self):
if not self.checkSurveyState(): if not self.checkSurveyState():
print('Survey not defined.') self.printDialogMessage('No Survey defined.')
return return
fmtomo_parameters = QtGui.QDialog(self.mainwindow) fmtomo_parameters = QtGui.QDialog(self.mainwindow)
ui = Ui_fmtomo_parameters() ui = Ui_fmtomo_parameters()
ui.setupUi(fmtomo_parameters) ui.setupUi(fmtomo_parameters)
ui.nproc.setMaximum(self.getMaxCPU())
self.fmtomo_parameters_ui = ui self.fmtomo_parameters_ui = ui
self.connectButtons_startFMTOMO() self.connectButtons_startFMTOMO()
self.getFMTOMOparameters(ui, fmtomo_parameters) self.getFMTOMOparameters(ui, fmtomo_parameters)
@ -148,7 +155,7 @@ class gui_control(object):
if fmtomo_parameters.exec_(): if fmtomo_parameters.exec_():
fmtomo_dir = ui.fmtomo_dir.text() fmtomo_dir = ui.fmtomo_dir.text()
nIter = int(ui.nIter.value()) nIter = int(ui.nIter.value())
nproc = int(ui.nproc.text()) nproc = int(ui.nproc.value())
btop = float(ui.btop.text()) btop = float(ui.btop.text())
bbot = float(ui.bbot.text()) bbot = float(ui.bbot.text())
propgrid = (int(ui.pgrid_x.text()), int(ui.pgrid_y.text()), int(ui.pgrid_z.text())) propgrid = (int(ui.pgrid_x.text()), int(ui.pgrid_y.text()), int(ui.pgrid_z.text()))
@ -178,7 +185,6 @@ class gui_control(object):
QtCore.QObject.connect(self.fmtomo_parameters_ui.browse_tomodir, QtCore.SIGNAL("clicked()"), self.chooseFMTOMOdir) QtCore.QObject.connect(self.fmtomo_parameters_ui.browse_tomodir, QtCore.SIGNAL("clicked()"), self.chooseFMTOMOdir)
QtCore.QObject.connect(self.fmtomo_parameters_ui.browse_customgrid, QtCore.SIGNAL("clicked()"), self.chooseCustomgrid) QtCore.QObject.connect(self.fmtomo_parameters_ui.browse_customgrid, QtCore.SIGNAL("clicked()"), self.chooseCustomgrid)
QtCore.QObject.connect(self.fmtomo_parameters_ui.browse_simuldir, QtCore.SIGNAL("clicked()"), self.chooseSimuldir) QtCore.QObject.connect(self.fmtomo_parameters_ui.browse_simuldir, QtCore.SIGNAL("clicked()"), self.chooseSimuldir)
QtCore.QObject.connect(self.fmtomo_parameters_ui.browse_seisarray, QtCore.SIGNAL("clicked()"), self.chooseSeisarray)
def chooseFMTOMOdir(self): def chooseFMTOMOdir(self):
self.fmtomo_parameters_ui.fmtomo_dir.setText(self.browseDir()) self.fmtomo_parameters_ui.fmtomo_dir.setText(self.browseDir())
@ -194,7 +200,7 @@ class gui_control(object):
def postprocessing(self): def postprocessing(self):
if not self.checkSurveyState(): if not self.checkSurveyState():
print('Survey not defined.') self.printDialogMessage('No Survey defined.')
return return
self.survey.plotAllPicks() self.survey.plotAllPicks()
@ -205,7 +211,16 @@ class gui_control(object):
filename = self.openFile() filename = self.openFile()
if filename is None: if filename is None:
return return
self.survey = activeSeismoPick.Survey.from_pickle(filename) try:
survey = activeSeismoPick.Survey.from_pickle(filename)
except:
self.printDialogMessage('Could not load object %s.'%filename)
return
if not type(survey) == activeSeismoPick.Survey:
self.printDialogMessage('Wrong input file of type %s, expected %s.'
%(type(survey), activeSeismoPick.Survey))
return
self.survey = survey
self.setSurveyState(True) self.setSurveyState(True)
if self.survey.picked: if self.survey.picked:
self.setPickState(True) self.setPickState(True)
@ -215,7 +230,7 @@ class gui_control(object):
self.seisarray = self.survey.seisarray self.seisarray = self.survey.seisarray
self.setConnected2SurveyState(True) self.setConnected2SurveyState(True)
self.setSeisArrayState(True) self.setSeisArrayState(True)
print('Loaded Survey with active Seismic Array.') self.printDialogMessage('Loaded Survey with active Seismic Array.')
def load_seisarray(self): def load_seisarray(self):
if self.checkSeisArrayState(): if self.checkSeisArrayState():
@ -224,12 +239,21 @@ class gui_control(object):
filename = self.openFile() filename = self.openFile()
if filename is None: if filename is None:
return return
self.seisarray = seismicArrayPreparation.SeisArray.from_pickle(filename) try:
seisarray = seismicArrayPreparation.SeisArray.from_pickle(filename)
except:
self.printDialogMessage('Could not load object %s.'%filename)
return
if not type(seisarray) == seismicArrayPreparation.SeisArray:
self.printDialogMessage('Wrong input file of type %s, expected %s.'
%(type(survey), seismicArrayPreparation.SeisArray))
return
self.seisarray = seisarray
self.setSeisArrayState(True) self.setSeisArrayState(True)
def save_seisarray(self): def save_seisarray(self):
if not self.checkSeisArrayState(): if not self.checkSeisArrayState():
print('No Seismic Array defined.') self.printDialogMessage('No Seismic Array defined.')
return return
filename = self.saveFile() filename = self.saveFile()
if filename is None: if filename is None:
@ -238,7 +262,7 @@ class gui_control(object):
def save_survey(self): def save_survey(self):
if not self.checkSurveyState(): if not self.checkSurveyState():
print('No Survey defined.') self.printDialogMessage('No Survey defined.')
return return
filename = self.saveFile() filename = self.saveFile()
if filename is None: if filename is None:
@ -268,7 +292,7 @@ class gui_control(object):
self.mainUI.picked_active.setPixmap(self.applypixmap) self.mainUI.picked_active.setPixmap(self.applypixmap)
self.survey.picked = True self.survey.picked = True
elif state == True and self.checkSurveyState() is False: elif state == True and self.checkSurveyState() is False:
print('No Survey defined.') self.printDialogMessage('No Survey defined.')
return return
elif state == False: elif state == False:
self.mainUI.picked_active.setPixmap(self.cancelpixmap) self.mainUI.picked_active.setPixmap(self.cancelpixmap)
@ -296,10 +320,17 @@ class gui_control(object):
def checkPickState(self): def checkPickState(self):
if not self.survey: if not self.survey:
print ('No Survey defined.') self.printDialogMessage('No Survey defined.')
return return
return self.survey.picked return self.survey.picked
def printDialogMessage(self, message):
qmb = QtGui.QMessageBox()
qmb.setText(message)
qmb.setStandardButtons(QtGui.QMessageBox.Ok)
qmb.setIcon(QtGui.QMessageBox.Warning)
qmb.exec_()
def continueDialogExists(self, name): def continueDialogExists(self, name):
qmb = QtGui.QMessageBox() qmb = QtGui.QMessageBox()
qmb.setText('%s object already exists. Overwrite?'%name) qmb.setText('%s object already exists. Overwrite?'%name)

View File

@ -2,7 +2,7 @@
# Form implementation generated from reading ui file 'fmtomo_parameters_layout.ui' # Form implementation generated from reading ui file 'fmtomo_parameters_layout.ui'
# #
# Created: Thu Jun 16 13:20:37 2016 # Created: Fri Jun 17 10:24:38 2016
# by: pyside-uic 0.2.15 running on PySide 1.2.2 # by: pyside-uic 0.2.15 running on PySide 1.2.2
# #
# WARNING! All changes made in this file will be lost! # WARNING! All changes made in this file will be lost!
@ -47,8 +47,10 @@ class Ui_fmtomo_parameters(object):
self.label_14 = QtGui.QLabel(fmtomo_parameters) self.label_14 = QtGui.QLabel(fmtomo_parameters)
self.label_14.setObjectName("label_14") self.label_14.setObjectName("label_14")
self.horizontalLayout_2.addWidget(self.label_14) self.horizontalLayout_2.addWidget(self.label_14)
self.nproc = QtGui.QLineEdit(fmtomo_parameters) self.nproc = QtGui.QSpinBox(fmtomo_parameters)
self.nproc.setAlignment(QtCore.Qt.AlignRight|QtCore.Qt.AlignTrailing|QtCore.Qt.AlignVCenter) self.nproc.setAlignment(QtCore.Qt.AlignRight|QtCore.Qt.AlignTrailing|QtCore.Qt.AlignVCenter)
self.nproc.setMinimum(1)
self.nproc.setMaximum(10000)
self.nproc.setObjectName("nproc") self.nproc.setObjectName("nproc")
self.horizontalLayout_2.addWidget(self.nproc) self.horizontalLayout_2.addWidget(self.nproc)
self.verticalLayout.addLayout(self.horizontalLayout_2) self.verticalLayout.addLayout(self.horizontalLayout_2)
@ -236,7 +238,6 @@ class Ui_fmtomo_parameters(object):
"installation", None, QtGui.QApplication.UnicodeUTF8)) "installation", None, QtGui.QApplication.UnicodeUTF8))
self.browse_tomodir.setText(QtGui.QApplication.translate("fmtomo_parameters", "Browse", None, QtGui.QApplication.UnicodeUTF8)) self.browse_tomodir.setText(QtGui.QApplication.translate("fmtomo_parameters", "Browse", None, QtGui.QApplication.UnicodeUTF8))
self.label_14.setText(QtGui.QApplication.translate("fmtomo_parameters", "nproc", None, QtGui.QApplication.UnicodeUTF8)) self.label_14.setText(QtGui.QApplication.translate("fmtomo_parameters", "nproc", None, QtGui.QApplication.UnicodeUTF8))
self.nproc.setText(QtGui.QApplication.translate("fmtomo_parameters", "1", None, QtGui.QApplication.UnicodeUTF8))
self.label.setText(QtGui.QApplication.translate("fmtomo_parameters", "Iterations", None, QtGui.QApplication.UnicodeUTF8)) self.label.setText(QtGui.QApplication.translate("fmtomo_parameters", "Iterations", None, QtGui.QApplication.UnicodeUTF8))
self.label_18.setText(QtGui.QApplication.translate("fmtomo_parameters", "Grid definitions from seismic Array:", None, QtGui.QApplication.UnicodeUTF8)) self.label_18.setText(QtGui.QApplication.translate("fmtomo_parameters", "Grid definitions from seismic Array:", None, QtGui.QApplication.UnicodeUTF8))
self.label_3.setText(QtGui.QApplication.translate("fmtomo_parameters", "Bottom boundary", None, QtGui.QApplication.UnicodeUTF8)) self.label_3.setText(QtGui.QApplication.translate("fmtomo_parameters", "Bottom boundary", None, QtGui.QApplication.UnicodeUTF8))

View File

@ -1,83 +1,161 @@
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# Form implementation generated from reading ui file 'fmtomo_parameters.ui' # Form implementation generated from reading ui file 'picking_parameters_layout.ui'
# #
# Created: Wed Jun 15 11:56:04 2016 # Created: Fri Jun 17 13:06:08 2016
# by: pyside-uic 0.2.15 running on PySide 1.2.2 # by: pyside-uic 0.2.15 running on PySide 1.2.2
# #
# WARNING! All changes made in this file will be lost! # WARNING! All changes made in this file will be lost!
from PySide import QtCore, QtGui from PySide import QtCore, QtGui
class Ui_Picking_parameters(object): class Ui_picking_parameters(object):
def setupUi(self, Picking_parameters): def setupUi(self, picking_parameters):
Picking_parameters.setObjectName("Picking_parameters") picking_parameters.setObjectName("picking_parameters")
Picking_parameters.resize(300, 300) picking_parameters.resize(325, 400)
self.gridLayoutWidget = QtGui.QWidget(Picking_parameters) picking_parameters.setMinimumSize(QtCore.QSize(325, 400))
self.gridLayoutWidget.setGeometry(QtCore.QRect(20, 20, 250, 211)) self.verticalLayout_3 = QtGui.QVBoxLayout(picking_parameters)
self.gridLayoutWidget.setObjectName("gridLayoutWidget") self.verticalLayout_3.setObjectName("verticalLayout_3")
self.gridLayout = QtGui.QGridLayout(self.gridLayoutWidget) self.label_7 = QtGui.QLabel(picking_parameters)
self.gridLayout.setContentsMargins(0, 0, 0, 0) sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Preferred, QtGui.QSizePolicy.Fixed)
self.gridLayout.setObjectName("gridLayout") sizePolicy.setHorizontalStretch(0)
self.label_cores = QtGui.QLabel(self.gridLayoutWidget) sizePolicy.setVerticalStretch(0)
self.label_cores.setObjectName("label_cores") sizePolicy.setHeightForWidth(self.label_7.sizePolicy().hasHeightForWidth())
self.gridLayout.addWidget(self.label_cores, 0, 0, 1, 1) self.label_7.setSizePolicy(sizePolicy)
self.label_vmax = QtGui.QLabel(self.gridLayoutWidget) font = QtGui.QFont()
self.label_vmax.setObjectName("label_vmax") font.setFamily("Sans Serif")
self.gridLayout.addWidget(self.label_vmax, 2, 0, 1, 1) font.setWeight(75)
self.label_vmin = QtGui.QLabel(self.gridLayoutWidget) font.setBold(True)
self.label_vmin.setObjectName("label_vmin") self.label_7.setFont(font)
self.gridLayout.addWidget(self.label_vmin, 1, 0, 1, 1) self.label_7.setObjectName("label_7")
self.lineEdit_ncores = QtGui.QLineEdit(self.gridLayoutWidget) self.verticalLayout_3.addWidget(self.label_7)
self.lineEdit_ncores.setObjectName("lineEdit_ncores") self.horizontalLayout = QtGui.QHBoxLayout()
self.gridLayout.addWidget(self.lineEdit_ncores, 0, 1, 1, 1) self.horizontalLayout.setObjectName("horizontalLayout")
self.lineEdit_vmin = QtGui.QLineEdit(self.gridLayoutWidget) self.label = QtGui.QLabel(picking_parameters)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Preferred, QtGui.QSizePolicy.Fixed)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.label.sizePolicy().hasHeightForWidth())
self.label.setSizePolicy(sizePolicy)
self.label.setObjectName("label")
self.horizontalLayout.addWidget(self.label)
self.ncores = QtGui.QSpinBox(picking_parameters)
self.ncores.setAlignment(QtCore.Qt.AlignRight|QtCore.Qt.AlignTrailing|QtCore.Qt.AlignVCenter)
self.ncores.setMinimum(1)
self.ncores.setMaximum(10000)
self.ncores.setObjectName("ncores")
self.horizontalLayout.addWidget(self.ncores)
self.verticalLayout_3.addLayout(self.horizontalLayout)
self.horizontalLayout_3 = QtGui.QHBoxLayout()
self.horizontalLayout_3.setObjectName("horizontalLayout_3")
self.verticalLayout_2 = QtGui.QVBoxLayout()
self.verticalLayout_2.setObjectName("verticalLayout_2")
self.label_2 = QtGui.QLabel(picking_parameters)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Preferred, QtGui.QSizePolicy.Fixed)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.label_2.sizePolicy().hasHeightForWidth())
self.label_2.setSizePolicy(sizePolicy)
self.label_2.setObjectName("label_2")
self.verticalLayout_2.addWidget(self.label_2)
self.lineEdit_vmin = QtGui.QLineEdit(picking_parameters)
self.lineEdit_vmin.setAlignment(QtCore.Qt.AlignRight|QtCore.Qt.AlignTrailing|QtCore.Qt.AlignVCenter)
self.lineEdit_vmin.setObjectName("lineEdit_vmin") self.lineEdit_vmin.setObjectName("lineEdit_vmin")
self.gridLayout.addWidget(self.lineEdit_vmin, 1, 1, 1, 1) self.verticalLayout_2.addWidget(self.lineEdit_vmin)
self.lineEdit_vmax = QtGui.QLineEdit(self.gridLayoutWidget) self.horizontalLayout_3.addLayout(self.verticalLayout_2)
self.verticalLayout = QtGui.QVBoxLayout()
self.verticalLayout.setObjectName("verticalLayout")
self.label_3 = QtGui.QLabel(picking_parameters)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Preferred, QtGui.QSizePolicy.Fixed)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.label_3.sizePolicy().hasHeightForWidth())
self.label_3.setSizePolicy(sizePolicy)
self.label_3.setObjectName("label_3")
self.verticalLayout.addWidget(self.label_3)
self.lineEdit_vmax = QtGui.QLineEdit(picking_parameters)
self.lineEdit_vmax.setAlignment(QtCore.Qt.AlignRight|QtCore.Qt.AlignTrailing|QtCore.Qt.AlignVCenter)
self.lineEdit_vmax.setObjectName("lineEdit_vmax") self.lineEdit_vmax.setObjectName("lineEdit_vmax")
self.gridLayout.addWidget(self.lineEdit_vmax, 2, 1, 1, 1) self.verticalLayout.addWidget(self.lineEdit_vmax)
self.checkBox = QtGui.QCheckBox(self.gridLayoutWidget) self.horizontalLayout_3.addLayout(self.verticalLayout)
self.checkBox.setObjectName("checkBox") self.verticalLayout_3.addLayout(self.horizontalLayout_3)
self.gridLayout.addWidget(self.checkBox, 4, 1, 1, 1) self.horizontalLayout_4 = QtGui.QHBoxLayout()
self.label_folm = QtGui.QLabel(self.gridLayoutWidget) self.horizontalLayout_4.setObjectName("horizontalLayout_4")
self.label_folm.setObjectName("label_folm") self.label_4 = QtGui.QLabel(picking_parameters)
self.gridLayout.addWidget(self.label_folm, 3, 0, 1, 1) sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Preferred, QtGui.QSizePolicy.Fixed)
self.label_aic = QtGui.QLabel(self.gridLayoutWidget) sizePolicy.setHorizontalStretch(0)
self.label_aic.setObjectName("label_aic") sizePolicy.setVerticalStretch(0)
self.gridLayout.addWidget(self.label_aic, 4, 0, 1, 1) sizePolicy.setHeightForWidth(self.label_4.sizePolicy().hasHeightForWidth())
self.lineEdit_folm = QtGui.QLineEdit(self.gridLayoutWidget) self.label_4.setSizePolicy(sizePolicy)
self.label_4.setObjectName("label_4")
self.horizontalLayout_4.addWidget(self.label_4)
self.lineEdit_folm = QtGui.QLineEdit(picking_parameters)
self.lineEdit_folm.setAlignment(QtCore.Qt.AlignRight|QtCore.Qt.AlignTrailing|QtCore.Qt.AlignVCenter)
self.lineEdit_folm.setObjectName("lineEdit_folm") self.lineEdit_folm.setObjectName("lineEdit_folm")
self.gridLayout.addWidget(self.lineEdit_folm, 3, 1, 1, 1) self.horizontalLayout_4.addWidget(self.lineEdit_folm)
self.label_aicwindow = QtGui.QLabel(self.gridLayoutWidget) self.verticalLayout_3.addLayout(self.horizontalLayout_4)
self.label_aicwindow.setObjectName("label_aicwindow") self.horizontalLayout_5 = QtGui.QHBoxLayout()
self.gridLayout.addWidget(self.label_aicwindow, 5, 0, 1, 1) self.horizontalLayout_5.setObjectName("horizontalLayout_5")
self.lineEdit_aicwindow = QtGui.QLineEdit(self.gridLayoutWidget) self.label_5 = QtGui.QLabel(picking_parameters)
self.lineEdit_aicwindow.setObjectName("lineEdit_aicwindow") sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Preferred, QtGui.QSizePolicy.Fixed)
self.gridLayout.addWidget(self.lineEdit_aicwindow, 5, 1, 1, 1) sizePolicy.setHorizontalStretch(0)
self.buttonBox = QtGui.QDialogButtonBox(Picking_parameters) sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.label_5.sizePolicy().hasHeightForWidth())
self.label_5.setSizePolicy(sizePolicy)
self.label_5.setObjectName("label_5")
self.horizontalLayout_5.addWidget(self.label_5)
self.checkBox_AIC = QtGui.QCheckBox(picking_parameters)
self.checkBox_AIC.setText("")
self.checkBox_AIC.setChecked(True)
self.checkBox_AIC.setObjectName("checkBox_AIC")
self.horizontalLayout_5.addWidget(self.checkBox_AIC)
self.verticalLayout_3.addLayout(self.horizontalLayout_5)
self.horizontalLayout_6 = QtGui.QHBoxLayout()
self.horizontalLayout_6.setObjectName("horizontalLayout_6")
self.label_6 = QtGui.QLabel(picking_parameters)
sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Preferred, QtGui.QSizePolicy.Fixed)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.label_6.sizePolicy().hasHeightForWidth())
self.label_6.setSizePolicy(sizePolicy)
self.label_6.setObjectName("label_6")
self.horizontalLayout_6.addWidget(self.label_6)
self.horizontalLayout_7 = QtGui.QHBoxLayout()
self.horizontalLayout_7.setObjectName("horizontalLayout_7")
self.lineEdit_aicleft = QtGui.QLineEdit(picking_parameters)
self.lineEdit_aicleft.setAlignment(QtCore.Qt.AlignRight|QtCore.Qt.AlignTrailing|QtCore.Qt.AlignVCenter)
self.lineEdit_aicleft.setObjectName("lineEdit_aicleft")
self.horizontalLayout_7.addWidget(self.lineEdit_aicleft)
self.lineEdit_aicright = QtGui.QLineEdit(picking_parameters)
self.lineEdit_aicright.setAlignment(QtCore.Qt.AlignRight|QtCore.Qt.AlignTrailing|QtCore.Qt.AlignVCenter)
self.lineEdit_aicright.setObjectName("lineEdit_aicright")
self.horizontalLayout_7.addWidget(self.lineEdit_aicright)
self.horizontalLayout_6.addLayout(self.horizontalLayout_7)
self.verticalLayout_3.addLayout(self.horizontalLayout_6)
self.buttonBox = QtGui.QDialogButtonBox(picking_parameters)
self.buttonBox.setOrientation(QtCore.Qt.Horizontal) self.buttonBox.setOrientation(QtCore.Qt.Horizontal)
self.buttonBox.setStandardButtons(QtGui.QDialogButtonBox.Cancel|QtGui.QDialogButtonBox.Ok) self.buttonBox.setStandardButtons(QtGui.QDialogButtonBox.Cancel|QtGui.QDialogButtonBox.Ok)
self.buttonBox.setObjectName("buttonBox") self.buttonBox.setObjectName("buttonBox")
self.buttonBox.setGeometry(QtCore.QRect(10, 240, 250, 32)) self.verticalLayout_3.addWidget(self.buttonBox)
QtCore.QObject.connect(self.buttonBox, QtCore.SIGNAL("accepted()"), Picking_parameters.accept) self.retranslateUi(picking_parameters)
QtCore.QObject.connect(self.buttonBox, QtCore.SIGNAL("rejected()"), Picking_parameters.reject) QtCore.QObject.connect(self.buttonBox, QtCore.SIGNAL("accepted()"), picking_parameters.accept)
self.retranslateUi(Picking_parameters) QtCore.QObject.connect(self.buttonBox, QtCore.SIGNAL("rejected()"), picking_parameters.reject)
QtCore.QMetaObject.connectSlotsByName(Picking_parameters) QtCore.QMetaObject.connectSlotsByName(picking_parameters)
def retranslateUi(self, picking_parameters):
picking_parameters.setWindowTitle(QtGui.QApplication.translate("picking_parameters", "Dialog", None, QtGui.QApplication.UnicodeUTF8))
self.label_7.setText(QtGui.QApplication.translate("picking_parameters", "Choose parameters for FMTOMO simulation", None, QtGui.QApplication.UnicodeUTF8))
self.label.setText(QtGui.QApplication.translate("picking_parameters", "nproc", None, QtGui.QApplication.UnicodeUTF8))
self.label_2.setText(QtGui.QApplication.translate("picking_parameters", "vmin [m/s]", None, QtGui.QApplication.UnicodeUTF8))
self.lineEdit_vmin.setText(QtGui.QApplication.translate("picking_parameters", "333", None, QtGui.QApplication.UnicodeUTF8))
self.label_3.setText(QtGui.QApplication.translate("picking_parameters", "vmax [m/s]", None, QtGui.QApplication.UnicodeUTF8))
self.lineEdit_vmax.setText(QtGui.QApplication.translate("picking_parameters", "5000", None, QtGui.QApplication.UnicodeUTF8))
self.label_4.setText(QtGui.QApplication.translate("picking_parameters", "Fraction of local maximum", None, QtGui.QApplication.UnicodeUTF8))
self.lineEdit_folm.setText(QtGui.QApplication.translate("picking_parameters", "0.6", None, QtGui.QApplication.UnicodeUTF8))
self.label_5.setText(QtGui.QApplication.translate("picking_parameters", "AIC", None, QtGui.QApplication.UnicodeUTF8))
self.label_6.setText(QtGui.QApplication.translate("picking_parameters", "AIC window indices\n"
"(only if AIC checked)", None, QtGui.QApplication.UnicodeUTF8))
self.lineEdit_aicleft.setText(QtGui.QApplication.translate("picking_parameters", "15", None, QtGui.QApplication.UnicodeUTF8))
self.lineEdit_aicright.setText(QtGui.QApplication.translate("picking_parameters", "0", None, QtGui.QApplication.UnicodeUTF8))
def retranslateUi(self, Picking_parameters):
Picking_parameters.setWindowTitle(QtGui.QApplication.translate("Picking_parameters", "Picking_parameters", None, QtGui.QApplication.UnicodeUTF8))
self.label_cores.setText(QtGui.QApplication.translate("Picking_parameters", "Number of cores", None, QtGui.QApplication.UnicodeUTF8))
self.label_vmax.setText(QtGui.QApplication.translate("Picking_parameters", "Vmax (default = 5000m/s)", None, QtGui.QApplication.UnicodeUTF8))
self.label_vmin.setText(QtGui.QApplication.translate("Picking_parameters", "Vmin (default = 333 m/s)", None, QtGui.QApplication.UnicodeUTF8))
self.lineEdit_ncores.setText(QtGui.QApplication.translate("Picking_parameters", "1", None, QtGui.QApplication.UnicodeUTF8))
self.lineEdit_vmin.setText(QtGui.QApplication.translate("Picking_parameters", "333", None, QtGui.QApplication.UnicodeUTF8))
self.lineEdit_vmax.setText(QtGui.QApplication.translate("Picking_parameters", "5000", None, QtGui.QApplication.UnicodeUTF8))
self.label_folm.setText(QtGui.QApplication.translate("Picking_parameters", "Fraction of local maximum\n"
"(default = 0.6)", None, QtGui.QApplication.UnicodeUTF8))
self.label_aic.setText(QtGui.QApplication.translate("Picking_parameters", "AIC", None, QtGui.QApplication.UnicodeUTF8))
self.lineEdit_folm.setText(QtGui.QApplication.translate("Picking_parameters", "0.6", None, QtGui.QApplication.UnicodeUTF8))
self.label_aicwindow.setText(QtGui.QApplication.translate("Picking_parameters", "AIC window (only if AIC\n"
" is checked)", None, QtGui.QApplication.UnicodeUTF8))
self.lineEdit_aicwindow.setText(QtGui.QApplication.translate("Picking_parameters", "15, 0", None, QtGui.QApplication.UnicodeUTF8))