schrodinger.application.desmond.gui module

GUI code for the Desmond panels.

Copyright Schrodinger, LLC. All rights reserved.

schrodinger.application.desmond.gui.get_msj_template_path(template_fname)

Return a path to the specified MSJ template in the Desmond data directory.

Parameters

template_fname (str) – Template filename to get the path to

Returns

Full path to the template location in the Desmond data dir.

Return type

str

schrodinger.application.desmond.gui.update_membrane_relaxation_protocol(stage_str)

Update a membrane relaxation protocol based on the current production simulation.

Parameters

stage_str (str) – Current protocol to be updated

Returns

Updated stage string with the current production simulation.

Return type

str

schrodinger.application.desmond.gui.error_dialog(master, msg)

Pops out a dialog showing the error message given by msg

This function just provides a uniform way for doing the job.

schrodinger.application.desmond.gui.warning_dialog(master, msg)

Pops out a dialog showing the warning message given by msg

This function just provides a uniform way for doing the job.

schrodinger.application.desmond.gui.get_model_from_pt_row(row, use_msys=False)

Check that a specified PT row contains a valid Desmond system and if so return the system loaded from the row’s cms_file attribute.

Parameters
  • row (schrodinger.project.ProjectRow) – Row of the Project Table to process

  • use_msys (bool) – Whether to read CMS using msys loader and return both msys and cms models on successful read

Returns

The cms.Cms or msys.System (if use_msys is True) loaded from the PT’s cms_file attribute if possible, None otherwise.

Return type

cms.Cms or (cms.Cms, msys.System) or None

schrodinger.application.desmond.gui.process_loaded_model(model)

Utility function for processing models getting loaded for various jobs.

Sets full system ID for each atom in the component CTs.

Parameters

model (cms.Cms) – Model to be processed

schrodinger.application.desmond.gui.get_in_cms_from_cpt(cpt_path, cfg=None)

Return the -in.cms file associated with a cpt file.

Parameters
  • cpt_path (str) – Full path to the cpt file

  • cfg (sea.Map or None) – Optional config to check. If not specified, the config will be extracted from the cpt.

Returns

Path to related -in.cms file

Return type

str

schrodinger.application.desmond.gui.count_traj_frames(trj_dir)

Count the number of frames in the given trajectory directory. Returns 0 if the trajectory was not readable. :param trj_dir: Trajectory path :type: trj_dir: str :return: Number of frames :rtype: int

schrodinger.application.desmond.gui.is_valid_groupname(groupname)

Verify that a given groupname is valid.

Parameters

groupname (str) – Groupname to validate

Returns

True if the groupname is valid, False otherwise.

Return type

bool

class schrodinger.application.desmond.gui.HorizontalBar(parent=0)

Bases: PyQt6.QtWidgets.QFrame

__init__(parent=0)
Box = 1
DrawChildren = 2
DrawWindowBackground = 1
HLine = 4
IgnoreMask = 4
NoFrame = 0
class PaintDeviceMetric(value)

Bases: enum.Enum

An enumeration.

PdmWidth = 1
PdmHeight = 2
PdmWidthMM = 3
PdmHeightMM = 4
PdmNumColors = 5
PdmDepth = 6
PdmDpiX = 7
PdmDpiY = 8
PdmPhysicalDpiX = 9
PdmPhysicalDpiY = 10
PdmDevicePixelRatio = 11
PdmDevicePixelRatioScaled = 12
Panel = 2
PdmDepth = 6
PdmDevicePixelRatio = 11
PdmDevicePixelRatioScaled = 12
PdmDpiX = 7
PdmDpiY = 8
PdmHeight = 2
PdmHeightMM = 4
PdmNumColors = 5
PdmPhysicalDpiX = 9
PdmPhysicalDpiY = 10
PdmWidth = 1
PdmWidthMM = 3
Plain = 16
Raised = 32
class RenderFlag(value)

Bases: enum.Flag

An enumeration.

DrawWindowBackground = 1
DrawChildren = 2
IgnoreMask = 4
class Shadow(value)

Bases: enum.IntEnum

An enumeration.

Plain = 16
Raised = 32
Sunken = 48
Shadow_Mask = 240
class Shape(value)

Bases: enum.IntEnum

An enumeration.

NoFrame = 0
Box = 1
Panel = 2
WinPanel = 3
HLine = 4
VLine = 5
StyledPanel = 6
Shape_Mask = 15
class StyleMask(value)

Bases: enum.Enum

An enumeration.

Shadow_Mask = 240
Shape_Mask = 15
StyledPanel = 6
Sunken = 48
VLine = 5
WinPanel = 3
acceptDrops(self) bool
accessibleDescription(self) str
accessibleName(self) str
actionEvent(self, QActionEvent)
actions(self) List[QAction]
activateWindow(self)
addAction(self, QAction)
addActions(self, Iterable[QAction])
adjustSize(self)
autoFillBackground(self) bool
backgroundRole(self) QPalette.ColorRole
baseSize(self) QSize
blockSignals(self, bool) bool
changeEvent(self, QEvent)
childAt(self, QPoint) QWidget
HorizontalBar.childAt(self, int, int) -> QWidget
childEvent(self, QChildEvent)
children(self) List[QObject]
childrenRect(self) QRect
childrenRegion(self) QRegion
clearFocus(self)
clearMask(self)
close(self) bool
closeEvent(self, QCloseEvent)
colorCount(self) int
connectNotify(self, QMetaMethod)
contentsMargins(self) QMargins
contentsRect(self) QRect
contextMenuEvent(self, QContextMenuEvent)
contextMenuPolicy(self) Qt.ContextMenuPolicy
create(self, window: PyQt6.sip.voidptr = 0, initializeWindow: bool = True, destroyOldWindow: bool = True)
createWindowContainer(QWindow, parent: QWidget = None, flags: Qt.WindowType = Qt.WindowFlags()) QWidget
cursor(self) QCursor
customContextMenuRequested

customContextMenuRequested(self, QPoint) [signal]

customEvent(self, QEvent)
deleteLater(self)
depth(self) int
destroy(self, destroyWindow: bool = True, destroySubWindows: bool = True)
destroyed

destroyed(self, object: QObject = None) [signal]

devType(self) int
devicePixelRatio(self) float
devicePixelRatioF(self) float
devicePixelRatioFScale() float
disconnect(QMetaObject.Connection) bool
disconnect(self) None
disconnectNotify(self, QMetaMethod)
dragEnterEvent(self, QDragEnterEvent)
dragLeaveEvent(self, QDragLeaveEvent)
dragMoveEvent(self, QDragMoveEvent)
drawFrame(self, QPainter)
dropEvent(self, QDropEvent)
dumpObjectInfo(self)
dumpObjectTree(self)
dynamicPropertyNames(self) List[QByteArray]
effectiveWinId(self) PyQt6.sip.voidptr
ensurePolished(self)
enterEvent(self, QEnterEvent)
event(self, QEvent) bool
eventFilter(self, QObject, QEvent) bool
find(PyQt6.sip.voidptr) QWidget
findChild(self, type, name: str = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) QObject
findChild(self, Tuple, name: str = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) QObject
findChildren(self, type, name: str = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) List[QObject]
findChildren(self, Tuple, name: str = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) List[QObject]
findChildren(self, type, QRegularExpression, options: Qt.FindChildOption = Qt.FindChildrenRecursively) List[QObject]
findChildren(self, Tuple, QRegularExpression, options: Qt.FindChildOption = Qt.FindChildrenRecursively) List[QObject]
focusInEvent(self, QFocusEvent)
focusNextChild(self) bool
focusNextPrevChild(self, bool) bool
focusOutEvent(self, QFocusEvent)
focusPolicy(self) Qt.FocusPolicy
focusPreviousChild(self) bool
focusProxy(self) QWidget
focusWidget(self) QWidget
font(self) QFont
fontInfo(self) QFontInfo
fontMetrics(self) QFontMetrics
foregroundRole(self) QPalette.ColorRole
frameGeometry(self) QRect
frameRect(self) QRect
frameShadow(self) QFrame.Shadow
frameShape(self) QFrame.Shape
frameSize(self) QSize
frameStyle(self) int
frameWidth(self) int
geometry(self) QRect
grab(self, rectangle: QRect = QRect(QPoint(0, 0), QSize(- 1, - 1))) QPixmap
grabGesture(self, Qt.GestureType, flags: Qt.GestureFlag = Qt.GestureFlags())
grabKeyboard(self)
grabMouse(self)
grabMouse(self, Union[QCursor, Qt.CursorShape]) None
grabShortcut(self, Union[QKeySequence, QKeySequence.StandardKey, str, int], context: Qt.ShortcutContext = Qt.WindowShortcut) int
graphicsEffect(self) QGraphicsEffect
graphicsProxyWidget(self) QGraphicsProxyWidget
hasFocus(self) bool
hasHeightForWidth(self) bool
hasMouseTracking(self) bool
hasTabletTracking(self) bool
height(self) int
heightForWidth(self, int) int
heightMM(self) int
hide(self)
hideEvent(self, QHideEvent)
inherits(self, str) bool
initPainter(self, QPainter)
initStyleOption(self, QStyleOptionFrame)
inputMethodEvent(self, QInputMethodEvent)
inputMethodHints(self) Qt.InputMethodHint
inputMethodQuery(self, Qt.InputMethodQuery) Any
HorizontalBar.insertAction(self, QAction, QAction)
insertActions(self, QAction, Iterable[QAction])
installEventFilter(self, QObject)
isActiveWindow(self) bool
isAncestorOf(self, QWidget) bool
isEnabled(self) bool
isEnabledTo(self, QWidget) bool
isFullScreen(self) bool
isHidden(self) bool
isLeftToRight(self) bool
isMaximized(self) bool
isMinimized(self) bool
isModal(self) bool
isRightToLeft(self) bool
isSignalConnected(self, QMetaMethod) bool
isVisible(self) bool
isVisibleTo(self, QWidget) bool
isWidgetType(self) bool
isWindow(self) bool
isWindowModified(self) bool
isWindowType(self) bool
keyPressEvent(self, QKeyEvent)
keyReleaseEvent(self, QKeyEvent)
keyboardGrabber() QWidget
killTimer(self, int)
layout(self) QLayout
layoutDirection(self) Qt.LayoutDirection
leaveEvent(self, QEvent)
lineWidth(self) int
locale(self) QLocale
logicalDpiX(self) int
logicalDpiY(self) int
lower(self)
mapFrom(self, QWidget, QPoint) QPoint
mapFrom(self, QWidget, QPointF) QPointF
mapFromGlobal(self, QPoint) QPoint
mapFromGlobal(self, QPointF) QPointF
mapFromParent(self, QPoint) QPoint
mapFromParent(self, QPointF) QPointF
mapTo(self, QWidget, QPoint) QPoint
mapTo(self, QWidget, QPointF) QPointF
mapToGlobal(self, QPoint) QPoint
mapToGlobal(self, QPointF) QPointF
mapToParent(self, QPoint) QPoint
mapToParent(self, QPointF) QPointF
mask(self) QRegion
maximumHeight(self) int
maximumSize(self) QSize
maximumWidth(self) int
metaObject(self) QMetaObject
metric(self, QPaintDevice.PaintDeviceMetric) int
midLineWidth(self) int
minimumHeight(self) int
minimumSize(self) QSize
minimumSizeHint(self) QSize
minimumWidth(self) int
mouseDoubleClickEvent(self, QMouseEvent)
mouseGrabber() QWidget
mouseMoveEvent(self, QMouseEvent)
mousePressEvent(self, QMouseEvent)
mouseReleaseEvent(self, QMouseEvent)
move(self, QPoint)
HorizontalBar.move(self, int, int) -> None
moveEvent(self, QMoveEvent)
moveToThread(self, QThread)
nativeEvent(self, QByteArray, PyQt6.sip.voidptr) Tuple[bool, PyQt6.sip.voidptr]
nativeParentWidget(self) QWidget
nextInFocusChain(self) QWidget
normalGeometry(self) QRect
objectName(self) str
objectNameChanged

objectNameChanged(self, str) [signal]

overrideWindowFlags(self, Qt.WindowType)
overrideWindowState(self, Qt.WindowState)
paintEngine(self) QPaintEngine
paintEvent(self, QPaintEvent)
paintingActive(self) bool
palette(self) QPalette
parent(self) QObject
parentWidget(self) QWidget
physicalDpiX(self) int
physicalDpiY(self) int
pos(self) QPoint
previousInFocusChain(self) QWidget
property(self, str) Any
pyqtConfigure(...)

Each keyword argument is either the name of a Qt property or a Qt signal. For properties the property is set to the given value which should be of an appropriate type. For signals the signal is connected to the given value which should be a callable.

raise_(self)
receivers(self, PYQT_SIGNAL) int
rect(self) QRect
releaseKeyboard(self)
releaseMouse(self)
releaseShortcut(self, int)
removeAction(self, QAction)
removeEventFilter(self, QObject)
render(self, QPaintDevice, targetOffset: QPoint = QPoint(), sourceRegion: QRegion = QRegion(), flags: QWidget.RenderFlag = QWidget.RenderFlags(QWidget.DrawWindowBackground | QWidget.DrawChildren))
render(self, QPainter, targetOffset: QPoint = QPoint(), sourceRegion: QRegion = QRegion(), flags: QWidget.RenderFlag = QWidget.RenderFlags(QWidget.DrawWindowBackground | QWidget.DrawChildren)) None
repaint(self)
HorizontalBar.repaint(self, int, int, int, int) -> None
repaint(self, QRect) None
repaint(self, QRegion) None
resize(self, QSize)
HorizontalBar.resize(self, int, int) -> None
resizeEvent(self, QResizeEvent)
restoreGeometry(self, QByteArray) bool
saveGeometry(self) QByteArray
screen(self) QScreen
HorizontalBar.scroll(self, int, int)
HorizontalBar.scroll(self, int, int, QRect) -> None
sender(self) QObject
senderSignalIndex(self) int
setAcceptDrops(self, bool)
setAccessibleDescription(self, str)
setAccessibleName(self, str)
setAttribute(self, Qt.WidgetAttribute, on: bool = True)
setAutoFillBackground(self, bool)
setBackgroundRole(self, QPalette.ColorRole)
HorizontalBar.setBaseSize(self, int, int)
setBaseSize(self, QSize) None
HorizontalBar.setContentsMargins(self, int, int, int, int)
setContentsMargins(self, QMargins) None
setContextMenuPolicy(self, Qt.ContextMenuPolicy)
setCursor(self, Union[QCursor, Qt.CursorShape])
setDisabled(self, bool)
setEnabled(self, bool)
setFixedHeight(self, int)
setFixedSize(self, QSize)
HorizontalBar.setFixedSize(self, int, int) -> None
setFixedWidth(self, int)
setFocus(self)
setFocus(self, Qt.FocusReason) None
setFocusPolicy(self, Qt.FocusPolicy)
setFocusProxy(self, QWidget)
setFont(self, QFont)
setForegroundRole(self, QPalette.ColorRole)
setFrameRect(self, QRect)
setFrameShadow(self, QFrame.Shadow)
setFrameShape(self, QFrame.Shape)
setFrameStyle(self, int)
setGeometry(self, QRect)
HorizontalBar.setGeometry(self, int, int, int, int) -> None
setGraphicsEffect(self, QGraphicsEffect)
setHidden(self, bool)
setInputMethodHints(self, Qt.InputMethodHint)
setLayout(self, QLayout)
setLayoutDirection(self, Qt.LayoutDirection)
setLineWidth(self, int)
setLocale(self, QLocale)
setMask(self, QBitmap)
setMask(self, QRegion) None
setMaximumHeight(self, int)
HorizontalBar.setMaximumSize(self, int, int)
setMaximumSize(self, QSize) None
setMaximumWidth(self, int)
setMidLineWidth(self, int)
setMinimumHeight(self, int)
HorizontalBar.setMinimumSize(self, int, int)
setMinimumSize(self, QSize) None
setMinimumWidth(self, int)
setMouseTracking(self, bool)
setObjectName(self, str)
setPalette(self, QPalette)
setParent(self, QWidget)
setParent(self, QWidget, Qt.WindowType) None
setProperty(self, str, Any) bool
setScreen(self, QScreen)
setShortcutAutoRepeat(self, int, enabled: bool = True)
setShortcutEnabled(self, int, enabled: bool = True)
HorizontalBar.setSizeIncrement(self, int, int)
setSizeIncrement(self, QSize) None
setSizePolicy(self, QSizePolicy)
setSizePolicy(self, QSizePolicy.Policy, QSizePolicy.Policy) None
setStatusTip(self, str)
setStyle(self, QStyle)
setStyleSheet(self, str)
HorizontalBar.setTabOrder(QWidget, QWidget)
setTabletTracking(self, bool)
setToolTip(self, str)
setToolTipDuration(self, int)
setUpdatesEnabled(self, bool)
setVisible(self, bool)
setWhatsThis(self, str)
setWindowFilePath(self, str)
setWindowFlag(self, Qt.WindowType, on: bool = True)
setWindowFlags(self, Qt.WindowType)
setWindowIcon(self, QIcon)
setWindowIconText(self, str)
setWindowModality(self, Qt.WindowModality)
setWindowModified(self, bool)
setWindowOpacity(self, float)
setWindowRole(self, str)
setWindowState(self, Qt.WindowState)
setWindowTitle(self, str)
sharedPainter(self) QPainter
show(self)
showEvent(self, QShowEvent)
showFullScreen(self)
showMaximized(self)
showMinimized(self)
showNormal(self)
signalsBlocked(self) bool
size(self) QSize
sizeHint(self) QSize
sizeIncrement(self) QSize
sizePolicy(self) QSizePolicy
stackUnder(self, QWidget)
startTimer(self, int, timerType: Qt.TimerType = Qt.CoarseTimer) int
staticMetaObject = <PyQt6.QtCore.QMetaObject object>
statusTip(self) str
style(self) QStyle
styleSheet(self) str
tabletEvent(self, QTabletEvent)
testAttribute(self, Qt.WidgetAttribute) bool
thread(self) QThread
timerEvent(self, QTimerEvent)
toolTip(self) str
toolTipDuration(self) int
tr(str, disambiguation: str = None, n: int = - 1) str
underMouse(self) bool
ungrabGesture(self, Qt.GestureType)
unsetCursor(self)
unsetLayoutDirection(self)
unsetLocale(self)
update(self)
update(self, QRect) None
update(self, QRegion) None
HorizontalBar.update(self, int, int, int, int) -> None
updateGeometry(self)
updateMicroFocus(self, query: Qt.InputMethodQuery = Qt.ImQueryAll)
updatesEnabled(self) bool
visibleRegion(self) QRegion
whatsThis(self) str
wheelEvent(self, QWheelEvent)
width(self) int
widthMM(self) int
winId(self) PyQt6.sip.voidptr
window(self) QWidget
windowFilePath(self) str
windowFlags(self) Qt.WindowType
windowHandle(self) QWindow
windowIcon(self) QIcon
windowIconChanged

windowIconChanged(self, QIcon) [signal]

windowIconText(self) str
windowIconTextChanged

windowIconTextChanged(self, str) [signal]

windowModality(self) Qt.WindowModality
windowOpacity(self) float
windowRole(self) str
windowState(self) Qt.WindowState
windowTitle(self) str
windowTitleChanged

windowTitleChanged(self, str) [signal]

windowType(self) Qt.WindowType
x(self) int
y(self) int
class schrodinger.application.desmond.gui.TempItemDelegate

Bases: PyQt6.QtWidgets.QItemDelegate

Class for allowing the data in the TableModel to be modified. Only allows float-values to be entered into the table.

__init__()
createEditor(self, QWidget, QStyleOptionViewItem, QModelIndex) QWidget
setEditorData(self, QWidget, QModelIndex)
setModelData(self, QWidget, QAbstractItemModel, QModelIndex)
updateEditorGeometry(self, QWidget, QStyleOptionViewItem, QModelIndex)
EditNextItem = 1
EditPreviousItem = 2
class EndEditHint(value)

Bases: enum.Enum

An enumeration.

NoHint = 0
EditNextItem = 1
EditPreviousItem = 2
SubmitModelCache = 3
RevertModelCache = 4
NoHint = 0
RevertModelCache = 4
SubmitModelCache = 3
blockSignals(self, bool) bool
childEvent(self, QChildEvent)
children(self) List[QObject]
closeEditor

closeEditor(self, QWidget, hint: QAbstractItemDelegate.EndEditHint = QAbstractItemDelegate.NoHint) [signal]

commitData

commitData(self, QWidget) [signal]

connectNotify(self, QMetaMethod)
customEvent(self, QEvent)
deleteLater(self)
destroyEditor(self, QWidget, QModelIndex)
destroyed

destroyed(self, object: QObject = None) [signal]

disconnect(QMetaObject.Connection) bool
disconnect(self) None
disconnectNotify(self, QMetaMethod)
drawBackground(self, QPainter, QStyleOptionViewItem, QModelIndex)
drawCheck(self, QPainter, QStyleOptionViewItem, QRect, Qt.CheckState)
drawDecoration(self, QPainter, QStyleOptionViewItem, QRect, QPixmap)
drawDisplay(self, QPainter, QStyleOptionViewItem, QRect, str)
drawFocus(self, QPainter, QStyleOptionViewItem, QRect)
dumpObjectInfo(self)
dumpObjectTree(self)
dynamicPropertyNames(self) List[QByteArray]
editorEvent(self, QEvent, QAbstractItemModel, QStyleOptionViewItem, QModelIndex) bool
event(self, QEvent) bool
eventFilter(self, QObject, QEvent) bool
findChild(self, type, name: str = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) QObject
findChild(self, Tuple, name: str = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) QObject
findChildren(self, type, name: str = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) List[QObject]
findChildren(self, Tuple, name: str = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) List[QObject]
findChildren(self, type, QRegularExpression, options: Qt.FindChildOption = Qt.FindChildrenRecursively) List[QObject]
findChildren(self, Tuple, QRegularExpression, options: Qt.FindChildOption = Qt.FindChildrenRecursively) List[QObject]
hasClipping(self) bool
helpEvent(self, QHelpEvent, QAbstractItemView, QStyleOptionViewItem, QModelIndex) bool
inherits(self, str) bool
installEventFilter(self, QObject)
isSignalConnected(self, QMetaMethod) bool
isWidgetType(self) bool
isWindowType(self) bool
itemEditorFactory(self) QItemEditorFactory
killTimer(self, int)
metaObject(self) QMetaObject
moveToThread(self, QThread)
objectName(self) str
objectNameChanged

objectNameChanged(self, str) [signal]

paint(self, QPainter, QStyleOptionViewItem, QModelIndex)
parent(self) QObject
property(self, str) Any
pyqtConfigure(...)

Each keyword argument is either the name of a Qt property or a Qt signal. For properties the property is set to the given value which should be of an appropriate type. For signals the signal is connected to the given value which should be a callable.

receivers(self, PYQT_SIGNAL) int
removeEventFilter(self, QObject)
sender(self) QObject
senderSignalIndex(self) int
setClipping(self, bool)
setItemEditorFactory(self, QItemEditorFactory)
setObjectName(self, str)
setParent(self, QObject)
setProperty(self, str, Any) bool
signalsBlocked(self) bool
sizeHint(self, QStyleOptionViewItem, QModelIndex) QSize
sizeHintChanged

sizeHintChanged(self, QModelIndex) [signal]

startTimer(self, int, timerType: Qt.TimerType = Qt.CoarseTimer) int
staticMetaObject = <PyQt6.QtCore.QMetaObject object>
thread(self) QThread
timerEvent(self, QTimerEvent)
tr(str, disambiguation: str = None, n: int = - 1) str
class schrodinger.application.desmond.gui.TableModel(row_header)

Bases: PyQt6.QtCore.QAbstractTableModel

Class for storing the window table information.

__init__(row_header)
setColumns(columns)
addColumn(column)
removeColumn(self, int, parent: QModelIndex = QModelIndex()) bool
clear()
update()
rowCount(parent=<PyQt6.QtCore.QModelIndex object>)

Returns number of rows

columnCount(parent=<PyQt6.QtCore.QModelIndex object>)

Returns number of columns

flags(index)

Returns flags for the specified cell. Whether it is a checkbutton or not.

data(index, role=ItemDataRole.DisplayRole)

Given a cell index, returns the data that should be displayed in that cell (text or check button state). Used by the view.

setData(index, value, role=ItemDataRole.EditRole)

Called by the view to modify the model when the user changes the data in the table.

headerData(section, orientation, role)

Returns the string that should be displayed in the specified header cell. Used by the View.

class CheckIndexOption(value)

Bases: enum.Flag

An enumeration.

NoOption = 0
IndexIsValid = 1
DoNotUseParent = 2
ParentIsInvalid = 4
HorizontalSortHint = 2
class LayoutChangeHint(value)

Bases: enum.Enum

An enumeration.

NoLayoutChangeHint = 0
VerticalSortHint = 1
HorizontalSortHint = 2
NoLayoutChangeHint = 0
VerticalSortHint = 1
TableModel.beginInsertColumns(self, QModelIndex, int, int)
TableModel.beginInsertRows(self, QModelIndex, int, int)
TableModel.beginMoveColumns(self, QModelIndex, int, int, QModelIndex, int) -> bool
TableModel.beginMoveRows(self, QModelIndex, int, int, QModelIndex, int) -> bool
TableModel.beginRemoveColumns(self, QModelIndex, int, int)
TableModel.beginRemoveRows(self, QModelIndex, int, int)
beginResetModel(self)
blockSignals(self, bool) bool
buddy(self, QModelIndex) QModelIndex
canDropMimeData(self, QMimeData, Qt.DropAction, int, int, QModelIndex) bool
canFetchMore(self, QModelIndex) bool
TableModel.changePersistentIndex(self, QModelIndex, QModelIndex)
changePersistentIndexList(self, Iterable[QModelIndex], Iterable[QModelIndex])
checkIndex(self, QModelIndex, options: QAbstractItemModel.CheckIndexOption = QAbstractItemModel.CheckIndexOption.NoOption) bool
childEvent(self, QChildEvent)
children(self) List[QObject]
clearItemData(self, QModelIndex) bool
columnsAboutToBeInserted

columnsAboutToBeInserted(self, QModelIndex, int, int) [signal]

columnsAboutToBeMoved

columnsAboutToBeMoved(self, QModelIndex, int, int, QModelIndex, int) [signal]

columnsAboutToBeRemoved

columnsAboutToBeRemoved(self, QModelIndex, int, int) [signal]

columnsInserted

columnsInserted(self, QModelIndex, int, int) [signal]

columnsMoved

columnsMoved(self, QModelIndex, int, int, QModelIndex, int) [signal]

columnsRemoved

columnsRemoved(self, QModelIndex, int, int) [signal]

connectNotify(self, QMetaMethod)
TableModel.createIndex(self, int, int, object: object = 0) -> QModelIndex
customEvent(self, QEvent)
dataChanged

dataChanged(self, QModelIndex, QModelIndex, roles: Iterable[int] = []) [signal]

TableModel.decodeData(self, int, int, QModelIndex, QDataStream) -> bool
deleteLater(self)
destroyed

destroyed(self, object: QObject = None) [signal]

disconnect(QMetaObject.Connection) bool
disconnect(self) None
disconnectNotify(self, QMetaMethod)
dropMimeData(self, QMimeData, Qt.DropAction, int, int, QModelIndex) bool
dumpObjectInfo(self)
dumpObjectTree(self)
dynamicPropertyNames(self) List[QByteArray]
encodeData(self, Iterable[QModelIndex], QDataStream)
endInsertColumns(self)
endInsertRows(self)
endMoveColumns(self)
endMoveRows(self)
endRemoveColumns(self)
endRemoveRows(self)
endResetModel(self)
event(self, QEvent) bool
eventFilter(self, QObject, QEvent) bool
fetchMore(self, QModelIndex)
findChild(self, type, name: str = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) QObject
findChild(self, Tuple, name: str = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) QObject
findChildren(self, type, name: str = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) List[QObject]
findChildren(self, Tuple, name: str = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) List[QObject]
findChildren(self, type, QRegularExpression, options: Qt.FindChildOption = Qt.FindChildrenRecursively) List[QObject]
findChildren(self, Tuple, QRegularExpression, options: Qt.FindChildOption = Qt.FindChildrenRecursively) List[QObject]
hasChildren(self, parent: QModelIndex = QModelIndex()) bool
TableModel.hasIndex(self, int, int, parent: QModelIndex = QModelIndex()) -> bool
headerDataChanged

headerDataChanged(self, Qt.Orientation, int, int) [signal]

TableModel.index(self, int, int, parent: QModelIndex = QModelIndex()) -> QModelIndex
inherits(self, str) bool
insertColumn(self, int, parent: QModelIndex = QModelIndex()) bool
TableModel.insertColumns(self, int, int, parent: QModelIndex = QModelIndex()) -> bool
insertRow(self, int, parent: QModelIndex = QModelIndex()) bool
TableModel.insertRows(self, int, int, parent: QModelIndex = QModelIndex()) -> bool
installEventFilter(self, QObject)
isSignalConnected(self, QMetaMethod) bool
isWidgetType(self) bool
isWindowType(self) bool
itemData(self, QModelIndex) Dict[int, Any]
killTimer(self, int)
layoutAboutToBeChanged

layoutAboutToBeChanged(self, parents: Iterable[QPersistentModelIndex] = [], hint: QAbstractItemModel.LayoutChangeHint = QAbstractItemModel.NoLayoutChangeHint) [signal]

layoutChanged

layoutChanged(self, parents: Iterable[QPersistentModelIndex] = [], hint: QAbstractItemModel.LayoutChangeHint = QAbstractItemModel.NoLayoutChangeHint) [signal]

match(self, QModelIndex, int, Any, hits: int = 1, flags: Qt.MatchFlag = Qt.MatchFlags(Qt.MatchStartsWith | Qt.MatchWrap)) List[QModelIndex]
metaObject(self) QMetaObject
mimeData(self, Iterable[QModelIndex]) QMimeData
mimeTypes(self) List[str]
modelAboutToBeReset

modelAboutToBeReset(self) [signal]

modelReset

modelReset(self) [signal]

TableModel.moveColumn(self, QModelIndex, int, QModelIndex, int) -> bool
TableModel.moveColumns(self, QModelIndex, int, int, QModelIndex, int) -> bool
TableModel.moveRow(self, QModelIndex, int, QModelIndex, int) -> bool
TableModel.moveRows(self, QModelIndex, int, int, QModelIndex, int) -> bool
moveToThread(self, QThread)
objectName(self) str
objectNameChanged

objectNameChanged(self, str) [signal]

parent(self) QObject
persistentIndexList(self) List[QModelIndex]
property(self, str) Any
pyqtConfigure(...)

Each keyword argument is either the name of a Qt property or a Qt signal. For properties the property is set to the given value which should be of an appropriate type. For signals the signal is connected to the given value which should be a callable.

receivers(self, PYQT_SIGNAL) int
TableModel.removeColumns(self, int, int, parent: QModelIndex = QModelIndex()) -> bool
removeEventFilter(self, QObject)
removeRow(self, int, parent: QModelIndex = QModelIndex()) bool
TableModel.removeRows(self, int, int, parent: QModelIndex = QModelIndex()) -> bool
resetInternalData(self)
revert(self)
roleNames(self) Dict[int, QByteArray]
rowsAboutToBeInserted

rowsAboutToBeInserted(self, QModelIndex, int, int) [signal]

rowsAboutToBeMoved

rowsAboutToBeMoved(self, QModelIndex, int, int, QModelIndex, int) [signal]

rowsAboutToBeRemoved

rowsAboutToBeRemoved(self, QModelIndex, int, int) [signal]

rowsInserted

rowsInserted(self, QModelIndex, int, int) [signal]

rowsMoved

rowsMoved(self, QModelIndex, int, int, QModelIndex, int) [signal]

rowsRemoved

rowsRemoved(self, QModelIndex, int, int) [signal]

sender(self) QObject
senderSignalIndex(self) int
setHeaderData(self, int, Qt.Orientation, Any, role: int = Qt.EditRole) bool
setItemData(self, QModelIndex, Dict[int, Any]) bool
setObjectName(self, str)
setParent(self, QObject)
setProperty(self, str, Any) bool
TableModel.sibling(self, int, int, QModelIndex) -> QModelIndex
signalsBlocked(self) bool
sort(self, int, order: Qt.SortOrder = Qt.AscendingOrder)
span(self, QModelIndex) QSize
startTimer(self, int, timerType: Qt.TimerType = Qt.CoarseTimer) int
staticMetaObject = <PyQt6.QtCore.QMetaObject object>
submit(self) bool
supportedDragActions(self) Qt.DropAction
supportedDropActions(self) Qt.DropAction
thread(self) QThread
timerEvent(self, QTimerEvent)
tr(str, disambiguation: str = None, n: int = - 1) str
class schrodinger.application.desmond.gui.PosResDelegate

Bases: PyQt6.QtWidgets.QItemDelegate

Class for allowing the data in the PosResModel to be modified

__init__()
createEditor(self, QWidget, QStyleOptionViewItem, QModelIndex) QWidget
setEditorData(self, QWidget, QModelIndex)
setModelData(self, QWidget, QAbstractItemModel, QModelIndex)
updateEditorGeometry(self, QWidget, QStyleOptionViewItem, QModelIndex)
EditNextItem = 1
EditPreviousItem = 2
class EndEditHint(value)

Bases: enum.Enum

An enumeration.

NoHint = 0
EditNextItem = 1
EditPreviousItem = 2
SubmitModelCache = 3
RevertModelCache = 4
NoHint = 0
RevertModelCache = 4
SubmitModelCache = 3
blockSignals(self, bool) bool
childEvent(self, QChildEvent)
children(self) List[QObject]
closeEditor

closeEditor(self, QWidget, hint: QAbstractItemDelegate.EndEditHint = QAbstractItemDelegate.NoHint) [signal]

commitData

commitData(self, QWidget) [signal]

connectNotify(self, QMetaMethod)
customEvent(self, QEvent)
deleteLater(self)
destroyEditor(self, QWidget, QModelIndex)
destroyed

destroyed(self, object: QObject = None) [signal]

disconnect(QMetaObject.Connection) bool
disconnect(self) None
disconnectNotify(self, QMetaMethod)
drawBackground(self, QPainter, QStyleOptionViewItem, QModelIndex)
drawCheck(self, QPainter, QStyleOptionViewItem, QRect, Qt.CheckState)
drawDecoration(self, QPainter, QStyleOptionViewItem, QRect, QPixmap)
drawDisplay(self, QPainter, QStyleOptionViewItem, QRect, str)
drawFocus(self, QPainter, QStyleOptionViewItem, QRect)
dumpObjectInfo(self)
dumpObjectTree(self)
dynamicPropertyNames(self) List[QByteArray]
editorEvent(self, QEvent, QAbstractItemModel, QStyleOptionViewItem, QModelIndex) bool
event(self, QEvent) bool
eventFilter(self, QObject, QEvent) bool
findChild(self, type, name: str = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) QObject
findChild(self, Tuple, name: str = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) QObject
findChildren(self, type, name: str = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) List[QObject]
findChildren(self, Tuple, name: str = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) List[QObject]
findChildren(self, type, QRegularExpression, options: Qt.FindChildOption = Qt.FindChildrenRecursively) List[QObject]
findChildren(self, Tuple, QRegularExpression, options: Qt.FindChildOption = Qt.FindChildrenRecursively) List[QObject]
hasClipping(self) bool
helpEvent(self, QHelpEvent, QAbstractItemView, QStyleOptionViewItem, QModelIndex) bool
inherits(self, str) bool
installEventFilter(self, QObject)
isSignalConnected(self, QMetaMethod) bool
isWidgetType(self) bool
isWindowType(self) bool
itemEditorFactory(self) QItemEditorFactory
killTimer(self, int)
metaObject(self) QMetaObject
moveToThread(self, QThread)
objectName(self) str
objectNameChanged

objectNameChanged(self, str) [signal]

paint(self, QPainter, QStyleOptionViewItem, QModelIndex)
parent(self) QObject
property(self, str) Any
pyqtConfigure(...)

Each keyword argument is either the name of a Qt property or a Qt signal. For properties the property is set to the given value which should be of an appropriate type. For signals the signal is connected to the given value which should be a callable.

receivers(self, PYQT_SIGNAL) int
removeEventFilter(self, QObject)
sender(self) QObject
senderSignalIndex(self) int
setClipping(self, bool)
setItemEditorFactory(self, QItemEditorFactory)
setObjectName(self, str)
setParent(self, QObject)
setProperty(self, str, Any) bool
signalsBlocked(self) bool
sizeHint(self, QStyleOptionViewItem, QModelIndex) QSize
sizeHintChanged

sizeHintChanged(self, QModelIndex) [signal]

startTimer(self, int, timerType: Qt.TimerType = Qt.CoarseTimer) int
staticMetaObject = <PyQt6.QtCore.QMetaObject object>
thread(self) QThread
timerEvent(self, QTimerEvent)
tr(str, disambiguation: str = None, n: int = - 1) str
class schrodinger.application.desmond.gui.PosResRow(panel)

Bases: schrodinger.application.desmond.gui._BaseAslRow

__init__(panel)

:param guiapp Pass the guiapp instance.

validate()

Returns None if all values of this row are valid; error message otherwise.

setAsl(asl)

Set the ASL of the row object to the given value. If ASL is valid, sets the <atoms> list to the matching Workspace atoms. If ASL is invalid, raises ValueError and sets <atoms> to empty set. Empty ASL (“”) sets <atoms> to an empty set (row is invalid).

class schrodinger.application.desmond.gui.PosResModel

Bases: PyQt6.QtCore.QAbstractTableModel

Class for storing the window table information.

warning
__init__()
setRows(rows)
clear()
addOneRow(row)
removeOneRow(rownum)
rowCount(parent=<PyQt6.QtCore.QModelIndex object>)

Returns number of rows

columnCount(parent=<PyQt6.QtCore.QModelIndex object>)

Returns number of columns

flags(index)

Returns flags for the specified cell. Whether it is a checkbutton or not.

data(index, role=ItemDataRole.DisplayRole)

Given a cell index, returns the data that should be displayed in that cell (text or check button state). Used by the view.

setData(index, value, role=ItemDataRole.EditRole)

Called by the view to modify the model when the user changes the data in the table.

headerData(section, orientation, role)

Returns the string that should be displayed in the specified header cell. Used by the View.

class CheckIndexOption(value)

Bases: enum.Flag

An enumeration.

NoOption = 0
IndexIsValid = 1
DoNotUseParent = 2
ParentIsInvalid = 4
HorizontalSortHint = 2
class LayoutChangeHint(value)

Bases: enum.Enum

An enumeration.

NoLayoutChangeHint = 0
VerticalSortHint = 1
HorizontalSortHint = 2
NoLayoutChangeHint = 0
VerticalSortHint = 1
PosResModel.beginInsertColumns(self, QModelIndex, int, int)
PosResModel.beginInsertRows(self, QModelIndex, int, int)
PosResModel.beginMoveColumns(self, QModelIndex, int, int, QModelIndex, int) -> bool
PosResModel.beginMoveRows(self, QModelIndex, int, int, QModelIndex, int) -> bool
PosResModel.beginRemoveColumns(self, QModelIndex, int, int)
PosResModel.beginRemoveRows(self, QModelIndex, int, int)
beginResetModel(self)
blockSignals(self, bool) bool
buddy(self, QModelIndex) QModelIndex
canDropMimeData(self, QMimeData, Qt.DropAction, int, int, QModelIndex) bool
canFetchMore(self, QModelIndex) bool
PosResModel.changePersistentIndex(self, QModelIndex, QModelIndex)
changePersistentIndexList(self, Iterable[QModelIndex], Iterable[QModelIndex])
checkIndex(self, QModelIndex, options: QAbstractItemModel.CheckIndexOption = QAbstractItemModel.CheckIndexOption.NoOption) bool
childEvent(self, QChildEvent)
children(self) List[QObject]
clearItemData(self, QModelIndex) bool
columnsAboutToBeInserted

columnsAboutToBeInserted(self, QModelIndex, int, int) [signal]

columnsAboutToBeMoved

columnsAboutToBeMoved(self, QModelIndex, int, int, QModelIndex, int) [signal]

columnsAboutToBeRemoved

columnsAboutToBeRemoved(self, QModelIndex, int, int) [signal]

columnsInserted

columnsInserted(self, QModelIndex, int, int) [signal]

columnsMoved

columnsMoved(self, QModelIndex, int, int, QModelIndex, int) [signal]

columnsRemoved

columnsRemoved(self, QModelIndex, int, int) [signal]

connectNotify(self, QMetaMethod)
PosResModel.createIndex(self, int, int, object: object = 0) -> QModelIndex
customEvent(self, QEvent)
dataChanged

dataChanged(self, QModelIndex, QModelIndex, roles: Iterable[int] = []) [signal]

PosResModel.decodeData(self, int, int, QModelIndex, QDataStream) -> bool
deleteLater(self)
destroyed

destroyed(self, object: QObject = None) [signal]

disconnect(QMetaObject.Connection) bool
disconnect(self) None
disconnectNotify(self, QMetaMethod)
dropMimeData(self, QMimeData, Qt.DropAction, int, int, QModelIndex) bool
dumpObjectInfo(self)
dumpObjectTree(self)
dynamicPropertyNames(self) List[QByteArray]
encodeData(self, Iterable[QModelIndex], QDataStream)
endInsertColumns(self)
endInsertRows(self)
endMoveColumns(self)
endMoveRows(self)
endRemoveColumns(self)
endRemoveRows(self)
endResetModel(self)
event(self, QEvent) bool
eventFilter(self, QObject, QEvent) bool
fetchMore(self, QModelIndex)
findChild(self, type, name: str = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) QObject
findChild(self, Tuple, name: str = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) QObject
findChildren(self, type, name: str = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) List[QObject]
findChildren(self, Tuple, name: str = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) List[QObject]
findChildren(self, type, QRegularExpression, options: Qt.FindChildOption = Qt.FindChildrenRecursively) List[QObject]
findChildren(self, Tuple, QRegularExpression, options: Qt.FindChildOption = Qt.FindChildrenRecursively) List[QObject]
hasChildren(self, parent: QModelIndex = QModelIndex()) bool
PosResModel.hasIndex(self, int, int, parent: QModelIndex = QModelIndex()) -> bool
headerDataChanged

headerDataChanged(self, Qt.Orientation, int, int) [signal]

PosResModel.index(self, int, int, parent: QModelIndex = QModelIndex()) -> QModelIndex
inherits(self, str) bool
insertColumn(self, int, parent: QModelIndex = QModelIndex()) bool
PosResModel.insertColumns(self, int, int, parent: QModelIndex = QModelIndex()) -> bool
insertRow(self, int, parent: QModelIndex = QModelIndex()) bool
PosResModel.insertRows(self, int, int, parent: QModelIndex = QModelIndex()) -> bool
installEventFilter(self, QObject)
isSignalConnected(self, QMetaMethod) bool
isWidgetType(self) bool
isWindowType(self) bool
itemData(self, QModelIndex) Dict[int, Any]
killTimer(self, int)
layoutAboutToBeChanged

layoutAboutToBeChanged(self, parents: Iterable[QPersistentModelIndex] = [], hint: QAbstractItemModel.LayoutChangeHint = QAbstractItemModel.NoLayoutChangeHint) [signal]

layoutChanged

layoutChanged(self, parents: Iterable[QPersistentModelIndex] = [], hint: QAbstractItemModel.LayoutChangeHint = QAbstractItemModel.NoLayoutChangeHint) [signal]

match(self, QModelIndex, int, Any, hits: int = 1, flags: Qt.MatchFlag = Qt.MatchFlags(Qt.MatchStartsWith | Qt.MatchWrap)) List[QModelIndex]
metaObject(self) QMetaObject
mimeData(self, Iterable[QModelIndex]) QMimeData
mimeTypes(self) List[str]
modelAboutToBeReset

modelAboutToBeReset(self) [signal]

modelReset

modelReset(self) [signal]

PosResModel.moveColumn(self, QModelIndex, int, QModelIndex, int) -> bool
PosResModel.moveColumns(self, QModelIndex, int, int, QModelIndex, int) -> bool
PosResModel.moveRow(self, QModelIndex, int, QModelIndex, int) -> bool
PosResModel.moveRows(self, QModelIndex, int, int, QModelIndex, int) -> bool
moveToThread(self, QThread)
objectName(self) str
objectNameChanged

objectNameChanged(self, str) [signal]

parent(self) QObject
persistentIndexList(self) List[QModelIndex]
property(self, str) Any
pyqtConfigure(...)

Each keyword argument is either the name of a Qt property or a Qt signal. For properties the property is set to the given value which should be of an appropriate type. For signals the signal is connected to the given value which should be a callable.

receivers(self, PYQT_SIGNAL) int
removeColumn(self, int, parent: QModelIndex = QModelIndex()) bool
PosResModel.removeColumns(self, int, int, parent: QModelIndex = QModelIndex()) -> bool
removeEventFilter(self, QObject)
removeRow(self, int, parent: QModelIndex = QModelIndex()) bool
PosResModel.removeRows(self, int, int, parent: QModelIndex = QModelIndex()) -> bool
resetInternalData(self)
revert(self)
roleNames(self) Dict[int, QByteArray]
rowsAboutToBeInserted

rowsAboutToBeInserted(self, QModelIndex, int, int) [signal]

rowsAboutToBeMoved

rowsAboutToBeMoved(self, QModelIndex, int, int, QModelIndex, int) [signal]

rowsAboutToBeRemoved

rowsAboutToBeRemoved(self, QModelIndex, int, int) [signal]

rowsInserted

rowsInserted(self, QModelIndex, int, int) [signal]

rowsMoved

rowsMoved(self, QModelIndex, int, int, QModelIndex, int) [signal]

rowsRemoved

rowsRemoved(self, QModelIndex, int, int) [signal]

sender(self) QObject
senderSignalIndex(self) int
setHeaderData(self, int, Qt.Orientation, Any, role: int = Qt.EditRole) bool
setItemData(self, QModelIndex, Dict[int, Any]) bool
setObjectName(self, str)
setParent(self, QObject)
setProperty(self, str, Any) bool
PosResModel.sibling(self, int, int, QModelIndex) -> QModelIndex
signalsBlocked(self) bool
sort(self, int, order: Qt.SortOrder = Qt.AscendingOrder)
span(self, QModelIndex) QSize
startTimer(self, int, timerType: Qt.TimerType = Qt.CoarseTimer) int
staticMetaObject = <PyQt6.QtCore.QMetaObject object>
submit(self) bool
supportedDragActions(self) Qt.DropAction
supportedDropActions(self) Qt.DropAction
thread(self) QThread
timerEvent(self, QTimerEvent)
tr(str, disambiguation: str = None, n: int = - 1) str
class schrodinger.application.desmond.gui.IntegrationTab(master, key, ui)

Bases: schrodinger.application.desmond.gui._MdcBase

Frame for the Integration tab of the Mdc Advanced Options dialogs

__init__(master, key, ui)
respaBondChanged()
checkValidity()

Checks if all widgets have valid values. If a widget with invalid value was encountered, then returns string that describes the problem. Returns None if there are no issues.

updateKey(key)
updateFromKey(key)
add(w)
hasWidget(w)
refresh(widgets)
remove(w)
resetFromModel(model)
updateModel(model)
class schrodinger.application.desmond.gui.EnsembleTab(master, key, is_annealing, ui)

Bases: schrodinger.application.desmond.gui._MdcBase

Frame for the Ensemble tab of the Advanced Options dialog.

STYLE_NAMEMAP = {'Anisotropic': 'anisotropic', 'Constant area': 'constant_area', 'Isotropic': 'isotropic', 'Semi-isotropic': 'semi_isotropic', 'anisotropic': 'Anisotropic', 'constant_area': 'Constant area', 'isotropic': 'Isotropic', 'semi_isotropic': 'Semi-isotropic'}
METHOD_NAMEMAP = {'DPD': 'DPD', 'Langevin': 'Langevin', 'MTK': 'Nose-Hoover chain', 'NH': 'Nose-Hoover chain'}
__init__(master, key, is_annealing, ui)
getBaroMethod()
setBaroMethod(method)
getThermoMethod()
setThermoMethod(method)
baroMethodChanged(index)
thermoMethodChanged(index)
setBaroStyle(style)
checkValidity()

Checks if all widgets have valid values. If a widget with invalid value was encountered, then returns string that describes the problem. Returns None if there are no issues.

updateKey(key)
updateFromKey(key)
resetEnsClass(ens_class)
add(w)
hasWidget(w)
refresh(widgets)
remove(w)
resetFromModel(model)
updateModel(model)
class schrodinger.application.desmond.gui.InteractionTab(master, key, ui, command=None)

Bases: schrodinger.application.desmond.gui._MdcBase

Frame for the Interaction frame of the Advanced Options dialog.

NEAR_METHOD_NAMEMAP = {'Cutoff': 'none', 'Force tapering': 'c2switch', 'Potential tapering': 'c1switch', 'Shift': 'shift', 'c1switch': 'Potential tapering', 'c2switch': 'Force tapering', 'none': 'Cutoff', 'shift': 'Shift'}
__init__(master, key, ui, command=None)
nearMethodChanged(index=None)
taperingModified()
resetFromModel(model=None)

Update the interaction tab UI based on the given model CTs.

updateModel(model)
checkValidity()

Checks if all widgets have valid values. If a widget with invalid value was encountered, then returns string that describes the problem. Returns None if there are no issues.

updateKey(key)
updateFromKey(key)
add(w)
hasWidget(w)
refresh(widgets)
remove(w)
class schrodinger.application.desmond.gui.RestraintsTab(master, key, ui)

Bases: schrodinger.application.desmond.gui._MdcBase

Frame for the Restraints tab of the Advanced Options dialog

__init__(master, key, ui)
updatePosresButtons(ignored1=None, ignored2=None)
selectPosResAsl()
addPosResRow()
deletePosResRow()
resetPosResTable()
getRestrGroup()
checkValidity()

Checks if all widgets have valid values. If a widget with invalid value was encountered, then returns string that describes the problem. Returns None if there are no issues.

resetFromModel(model)

Update the Restraints tab UI based on the given model CTs.

updateModel(model)

Updates the given model to the data from the UI

updateKey(key)
updateFromKey(key)

Update the options in the restraints tab to the model.

reset()

Called when the panel is reset.

add(w)
hasWidget(w)
refresh(widgets)
remove(w)
class schrodinger.application.desmond.gui.OutputTab(master, key, ui)

Bases: schrodinger.application.desmond.gui._MdcBase

Frame for the Output tab of the Advanced Options dialog

__init__(master, key, ui)
checkValidity()

Checks if all widgets have valid values. If a widget with invalid value was encountered, then returns string that describes the problem. Returns None if there are no issues.

updateKey(key)
updateFromKey(key)
setASL()
add(w)
hasWidget(w)
refresh(widgets)
remove(w)
resetFromModel(model)
updateModel(model)
class schrodinger.application.desmond.gui.RandVelFrame(master, key, ui, root_master)

Bases: schrodinger.application.desmond.gui._MdcBase

Frame for the “Randomize velocities” group of the Misc tab of Advanced dialog.

__init__(master, key, ui, root_master)
enableCustomSeed()

Enables or disables custom seed line edit based on the radio buttons.

checkValidity()

Checks if all widgets have valid values. If a widget with invalid value was encountered, then returns string that describes the problem. Returns None if there are no issues.

updateKey(key)
updateFromKey(key)
add(w)
hasWidget(w)
refresh(widgets)
remove(w)
resetFromModel(model)
updateModel(model)
class schrodinger.application.desmond.gui.AtomGroupDelegate

Bases: PyQt6.QtWidgets.QItemDelegate

Class for allowing the data in the AtomGroupModel to be modified.

__init__()
createEditor(self, QWidget, QStyleOptionViewItem, QModelIndex) QWidget
setEditorData(self, QWidget, QModelIndex)
setModelData(self, QWidget, QAbstractItemModel, QModelIndex)
updateEditorGeometry(editor, option, index)
EditNextItem = 1
EditPreviousItem = 2
class EndEditHint(value)

Bases: enum.Enum

An enumeration.

NoHint = 0
EditNextItem = 1
EditPreviousItem = 2
SubmitModelCache = 3
RevertModelCache = 4
NoHint = 0
RevertModelCache = 4
SubmitModelCache = 3
blockSignals(self, bool) bool
childEvent(self, QChildEvent)
children(self) List[QObject]
closeEditor

closeEditor(self, QWidget, hint: QAbstractItemDelegate.EndEditHint = QAbstractItemDelegate.NoHint) [signal]

commitData

commitData(self, QWidget) [signal]

connectNotify(self, QMetaMethod)
customEvent(self, QEvent)
deleteLater(self)
destroyEditor(self, QWidget, QModelIndex)
destroyed

destroyed(self, object: QObject = None) [signal]

disconnect(QMetaObject.Connection) bool
disconnect(self) None
disconnectNotify(self, QMetaMethod)
drawBackground(self, QPainter, QStyleOptionViewItem, QModelIndex)
drawCheck(self, QPainter, QStyleOptionViewItem, QRect, Qt.CheckState)
drawDecoration(self, QPainter, QStyleOptionViewItem, QRect, QPixmap)
drawDisplay(self, QPainter, QStyleOptionViewItem, QRect, str)
drawFocus(self, QPainter, QStyleOptionViewItem, QRect)
dumpObjectInfo(self)
dumpObjectTree(self)
dynamicPropertyNames(self) List[QByteArray]
editorEvent(self, QEvent, QAbstractItemModel, QStyleOptionViewItem, QModelIndex) bool
event(self, QEvent) bool
eventFilter(self, QObject, QEvent) bool
findChild(self, type, name: str = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) QObject
findChild(self, Tuple, name: str = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) QObject
findChildren(self, type, name: str = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) List[QObject]
findChildren(self, Tuple, name: str = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) List[QObject]
findChildren(self, type, QRegularExpression, options: Qt.FindChildOption = Qt.FindChildrenRecursively) List[QObject]
findChildren(self, Tuple, QRegularExpression, options: Qt.FindChildOption = Qt.FindChildrenRecursively) List[QObject]
hasClipping(self) bool
helpEvent(self, QHelpEvent, QAbstractItemView, QStyleOptionViewItem, QModelIndex) bool
inherits(self, str) bool
installEventFilter(self, QObject)
isSignalConnected(self, QMetaMethod) bool
isWidgetType(self) bool
isWindowType(self) bool
itemEditorFactory(self) QItemEditorFactory
killTimer(self, int)
metaObject(self) QMetaObject
moveToThread(self, QThread)
objectName(self) str
objectNameChanged

objectNameChanged(self, str) [signal]

paint(self, QPainter, QStyleOptionViewItem, QModelIndex)
parent(self) QObject
property(self, str) Any
pyqtConfigure(...)

Each keyword argument is either the name of a Qt property or a Qt signal. For properties the property is set to the given value which should be of an appropriate type. For signals the signal is connected to the given value which should be a callable.

receivers(self, PYQT_SIGNAL) int
removeEventFilter(self, QObject)
sender(self) QObject
senderSignalIndex(self) int
setClipping(self, bool)
setItemEditorFactory(self, QItemEditorFactory)
setObjectName(self, str)
setParent(self, QObject)
setProperty(self, str, Any) bool
signalsBlocked(self) bool
sizeHint(self, QStyleOptionViewItem, QModelIndex) QSize
sizeHintChanged

sizeHintChanged(self, QModelIndex) [signal]

startTimer(self, int, timerType: Qt.TimerType = Qt.CoarseTimer) int
staticMetaObject = <PyQt6.QtCore.QMetaObject object>
thread(self) QThread
timerEvent(self, QTimerEvent)
tr(str, disambiguation: str = None, n: int = - 1) str
class schrodinger.application.desmond.gui.AtomGroupRow(panel)

Bases: schrodinger.application.desmond.gui._BaseAslRow

__init__(panel)

:param guiapp Pass the guiapp instance.

validate()

Returns None if all values of this row are valid; error message otherwise.

setAsl(asl)

Set the ASL of the row object to the given value. If ASL is valid, sets the <atoms> list to the matching Workspace atoms. If ASL is invalid, raises ValueError and sets <atoms> to empty set. Empty ASL (“”) sets <atoms> to an empty set (row is invalid).

class schrodinger.application.desmond.gui.AtomGroupModel

Bases: PyQt6.QtCore.QAbstractTableModel

Class for storing the window table information.

warning
__init__()
setRows(rows)
clear()
addOneRow(row)
removeOneRow(rownum)
rowCount(parent=<PyQt6.QtCore.QModelIndex object>)

Returns number of rows

columnCount(parent=<PyQt6.QtCore.QModelIndex object>)

Returns number of columns

flags(index)

Returns flags for the specified cell. Whether it is a checkbutton or not.

data(index, role=ItemDataRole.DisplayRole)

Given a cell index, returns the data that should be displayed in that cell (text or check button state). Used by the view.

setData(index, value, role=ItemDataRole.EditRole)

Called by the view to modify the model when the user changes the data in the table.

headerData(section, orientation, role)

Returns the string that should be displayed in the specified header cell. Used by the View.

class CheckIndexOption(value)

Bases: enum.Flag

An enumeration.

NoOption = 0
IndexIsValid = 1
DoNotUseParent = 2
ParentIsInvalid = 4
HorizontalSortHint = 2
class LayoutChangeHint(value)

Bases: enum.Enum

An enumeration.

NoLayoutChangeHint = 0
VerticalSortHint = 1
HorizontalSortHint = 2
NoLayoutChangeHint = 0
VerticalSortHint = 1
AtomGroupModel.beginInsertColumns(self, QModelIndex, int, int)
AtomGroupModel.beginInsertRows(self, QModelIndex, int, int)
AtomGroupModel.beginMoveColumns(self, QModelIndex, int, int, QModelIndex, int) -> bool
AtomGroupModel.beginMoveRows(self, QModelIndex, int, int, QModelIndex, int) -> bool
AtomGroupModel.beginRemoveColumns(self, QModelIndex, int, int)
AtomGroupModel.beginRemoveRows(self, QModelIndex, int, int)
beginResetModel(self)
blockSignals(self, bool) bool
buddy(self, QModelIndex) QModelIndex
canDropMimeData(self, QMimeData, Qt.DropAction, int, int, QModelIndex) bool
canFetchMore(self, QModelIndex) bool
AtomGroupModel.changePersistentIndex(self, QModelIndex, QModelIndex)
changePersistentIndexList(self, Iterable[QModelIndex], Iterable[QModelIndex])
checkIndex(self, QModelIndex, options: QAbstractItemModel.CheckIndexOption = QAbstractItemModel.CheckIndexOption.NoOption) bool
childEvent(self, QChildEvent)
children(self) List[QObject]
clearItemData(self, QModelIndex) bool
columnsAboutToBeInserted

columnsAboutToBeInserted(self, QModelIndex, int, int) [signal]

columnsAboutToBeMoved

columnsAboutToBeMoved(self, QModelIndex, int, int, QModelIndex, int) [signal]

columnsAboutToBeRemoved

columnsAboutToBeRemoved(self, QModelIndex, int, int) [signal]

columnsInserted

columnsInserted(self, QModelIndex, int, int) [signal]

columnsMoved

columnsMoved(self, QModelIndex, int, int, QModelIndex, int) [signal]

columnsRemoved

columnsRemoved(self, QModelIndex, int, int) [signal]

connectNotify(self, QMetaMethod)
AtomGroupModel.createIndex(self, int, int, object: object = 0) -> QModelIndex
customEvent(self, QEvent)
dataChanged

dataChanged(self, QModelIndex, QModelIndex, roles: Iterable[int] = []) [signal]

AtomGroupModel.decodeData(self, int, int, QModelIndex, QDataStream) -> bool
deleteLater(self)
destroyed

destroyed(self, object: QObject = None) [signal]

disconnect(QMetaObject.Connection) bool
disconnect(self) None
disconnectNotify(self, QMetaMethod)
dropMimeData(self, QMimeData, Qt.DropAction, int, int, QModelIndex) bool
dumpObjectInfo(self)
dumpObjectTree(self)
dynamicPropertyNames(self) List[QByteArray]
encodeData(self, Iterable[QModelIndex], QDataStream)
endInsertColumns(self)
endInsertRows(self)
endMoveColumns(self)
endMoveRows(self)
endRemoveColumns(self)
endRemoveRows(self)
endResetModel(self)
event(self, QEvent) bool
eventFilter(self, QObject, QEvent) bool
fetchMore(self, QModelIndex)
findChild(self, type, name: str = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) QObject
findChild(self, Tuple, name: str = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) QObject
findChildren(self, type, name: str = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) List[QObject]
findChildren(self, Tuple, name: str = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) List[QObject]
findChildren(self, type, QRegularExpression, options: Qt.FindChildOption = Qt.FindChildrenRecursively) List[QObject]
findChildren(self, Tuple, QRegularExpression, options: Qt.FindChildOption = Qt.FindChildrenRecursively) List[QObject]
hasChildren(self, parent: QModelIndex = QModelIndex()) bool
AtomGroupModel.hasIndex(self, int, int, parent: QModelIndex = QModelIndex()) -> bool
headerDataChanged

headerDataChanged(self, Qt.Orientation, int, int) [signal]

AtomGroupModel.index(self, int, int, parent: QModelIndex = QModelIndex()) -> QModelIndex
inherits(self, str) bool
insertColumn(self, int, parent: QModelIndex = QModelIndex()) bool
AtomGroupModel.insertColumns(self, int, int, parent: QModelIndex = QModelIndex()) -> bool
insertRow(self, int, parent: QModelIndex = QModelIndex()) bool
AtomGroupModel.insertRows(self, int, int, parent: QModelIndex = QModelIndex()) -> bool
installEventFilter(self, QObject)
isSignalConnected(self, QMetaMethod) bool
isWidgetType(self) bool
isWindowType(self) bool
itemData(self, QModelIndex) Dict[int, Any]
killTimer(self, int)
layoutAboutToBeChanged

layoutAboutToBeChanged(self, parents: Iterable[QPersistentModelIndex] = [], hint: QAbstractItemModel.LayoutChangeHint = QAbstractItemModel.NoLayoutChangeHint) [signal]

layoutChanged

layoutChanged(self, parents: Iterable[QPersistentModelIndex] = [], hint: QAbstractItemModel.LayoutChangeHint = QAbstractItemModel.NoLayoutChangeHint) [signal]

match(self, QModelIndex, int, Any, hits: int = 1, flags: Qt.MatchFlag = Qt.MatchFlags(Qt.MatchStartsWith | Qt.MatchWrap)) List[QModelIndex]
metaObject(self) QMetaObject
mimeData(self, Iterable[QModelIndex]) QMimeData
mimeTypes(self) List[str]
modelAboutToBeReset

modelAboutToBeReset(self) [signal]

modelReset

modelReset(self) [signal]

AtomGroupModel.moveColumn(self, QModelIndex, int, QModelIndex, int) -> bool
AtomGroupModel.moveColumns(self, QModelIndex, int, int, QModelIndex, int) -> bool
AtomGroupModel.moveRow(self, QModelIndex, int, QModelIndex, int) -> bool
AtomGroupModel.moveRows(self, QModelIndex, int, int, QModelIndex, int) -> bool
moveToThread(self, QThread)
objectName(self) str
objectNameChanged

objectNameChanged(self, str) [signal]

parent(self) QObject
persistentIndexList(self) List[QModelIndex]
property(self, str) Any
pyqtConfigure(...)

Each keyword argument is either the name of a Qt property or a Qt signal. For properties the property is set to the given value which should be of an appropriate type. For signals the signal is connected to the given value which should be a callable.

receivers(self, PYQT_SIGNAL) int
removeColumn(self, int, parent: QModelIndex = QModelIndex()) bool
AtomGroupModel.removeColumns(self, int, int, parent: QModelIndex = QModelIndex()) -> bool
removeEventFilter(self, QObject)
removeRow(self, int, parent: QModelIndex = QModelIndex()) bool
AtomGroupModel.removeRows(self, int, int, parent: QModelIndex = QModelIndex()) -> bool
resetInternalData(self)
revert(self)
roleNames(self) Dict[int, QByteArray]
rowsAboutToBeInserted

rowsAboutToBeInserted(self, QModelIndex, int, int) [signal]

rowsAboutToBeMoved

rowsAboutToBeMoved(self, QModelIndex, int, int, QModelIndex, int) [signal]

rowsAboutToBeRemoved

rowsAboutToBeRemoved(self, QModelIndex, int, int) [signal]

rowsInserted

rowsInserted(self, QModelIndex, int, int) [signal]

rowsMoved

rowsMoved(self, QModelIndex, int, int, QModelIndex, int) [signal]

rowsRemoved

rowsRemoved(self, QModelIndex, int, int) [signal]

sender(self) QObject
senderSignalIndex(self) int
setHeaderData(self, int, Qt.Orientation, Any, role: int = Qt.EditRole) bool
setItemData(self, QModelIndex, Dict[int, Any]) bool
setObjectName(self, str)
setParent(self, QObject)
setProperty(self, str, Any) bool
AtomGroupModel.sibling(self, int, int, QModelIndex) -> QModelIndex
signalsBlocked(self) bool
sort(self, int, order: Qt.SortOrder = Qt.AscendingOrder)
span(self, QModelIndex) QSize
startTimer(self, int, timerType: Qt.TimerType = Qt.CoarseTimer) int
staticMetaObject = <PyQt6.QtCore.QMetaObject object>
submit(self) bool
supportedDragActions(self) Qt.DropAction
supportedDropActions(self) Qt.DropAction
thread(self) QThread
timerEvent(self, QTimerEvent)
tr(str, disambiguation: str = None, n: int = - 1) str
class schrodinger.application.desmond.gui.AtomGroupFrame(master, key, ui)

Bases: object

Frame for the “Atom group” box of the Misc tab of the Advanced Options dialog.

__init__(master, key, ui)
updateAtomGroupButtons(ignored1=None, ignored2=None)
selectAtomGroupAsl()
addAtomGroupRow()
deleteAtomGroupRow()
resetAtomGroupTable()
getAtomGroups()
checkValidity()

Checks if all widgets have valid values. If a widget with invalid value was encountered, then returns string that describes the problem. Returns None if there are no issues.

resetFromModel(model)

Update the Atom group UI based on the given model CTs.

updateKey(key)
updateFromKey(key)
class schrodinger.application.desmond.gui.MdcMiscTab(master, key, ui, include_randvel=True)

Bases: schrodinger.application.desmond.gui._MdcBase

Frame for the Misc tab of Mdc Advanced Options dialogs.

__init__(master, key, ui, include_randvel=True)
resetFromModel(model)
  • Expands and reset the atom group table if the given ‘model’ is a ‘cms.Cms’ object.

  • Given a ‘model’( which is a ‘cms.Cms’ object), resets the atom group table.

updateModel(model)

Updates the given model to the data from the UI

add(w)
checkValidity()

Checks if all widgets have valid values. If a widget with invalid value was encountered, then returns string that describes the problem. Returns None if there are no issues.

hasWidget(w)
refresh(widgets)
remove(w)
updateFromKey(key)
updateKey(key)
class schrodinger.application.desmond.gui.MinAdvancedDialog(master, key, is_annealing, is_replica_exchange, buttons, title)

Bases: schrodinger.application.desmond.gui._BaseAdvancedDialog

Advanced Minimization options dialog for Desmond panels

__init__(master, key, is_annealing, is_replica_exchange, buttons, title)
checkTab()
checkValidity()
closeEvent(event)

Called by QApplication when the user clicked on the “x” button to close the advnaced dialog.

currentTabChanged(page_index)
reject()

Called when the user hits the Escape key.

reset()

Called when the “Reset” action is selected in the main window.

resetFromModel(model)

Update the advanced dialog based on the state of the specified model CTs.

setGuiState(state)

Set the state of the advanced dialog

updateFromKey(key)
updateKey(key)
updateModel(model)

Update the key to the options that are in the advanced dialog.

class schrodinger.application.desmond.gui.MdcAdvancedDialog(master, key, is_annealing, is_replica_exchange, buttons, title)

Bases: schrodinger.application.desmond.gui._BaseAdvancedDialog

Advanced Options dialog for Mdc Desmond panels

__init__(master, key, is_annealing, is_replica_exchange, buttons, title)
checkTab()
checkValidity()
closeEvent(event)

Called by QApplication when the user clicked on the “x” button to close the advnaced dialog.

currentTabChanged(page_index)
reject()

Called when the user hits the Escape key.

reset()

Called when the “Reset” action is selected in the main window.

resetFromModel(model)

Update the advanced dialog based on the state of the specified model CTs.

setGuiState(state)

Set the state of the advanced dialog

updateFromKey(key)
updateKey(key)
updateModel(model)

Update the key to the options that are in the advanced dialog.

class schrodinger.application.desmond.gui.MinMiscTab(master, key, ui)

Bases: schrodinger.application.desmond.gui.MdcMiscTab

Frame for the Misc Tab of Advanced Options dialog of Minimization GUI.

__init__(master, key, ui)
add(w)
checkValidity()

Checks if all widgets have valid values. If a widget with invalid value was encountered, then returns string that describes the problem. Returns None if there are no issues.

hasWidget(w)
refresh(widgets)
remove(w)
resetFromModel(model)
  • Expands and reset the atom group table if the given ‘model’ is a ‘cms.Cms’ object.

  • Given a ‘model’( which is a ‘cms.Cms’ object), resets the atom group table.

updateFromKey(key)
updateKey(key)
updateModel(model)

Updates the given model to the data from the UI

class schrodinger.application.desmond.gui.InputGroup(master, model_changed_callback, allow_checkpoint_files=True, check_infinite=False, reset_parent_on_load=True, cg_aware=False)

Bases: object

  • Group Frame for showing the widgets for loading the system model.

  • Used by the GuiApp class for all panels.

__init__(master, model_changed_callback, allow_checkpoint_files=True, check_infinite=False, reset_parent_on_load=True, cg_aware=False)

See class docstring. :param master: The root or master application :type master: af2.JobApp object.

Parameters
  • check_infinite (bool) – If a checkbox for infinite systems should be included and if the system should be checked for infinite bonding when loaded

  • reset_parent_on_load (bool) – Whether or not the InputGroup should call it’s parent widget’s setDefaults() function when loading a new model system.

  • cg_aware (bool) – Whether or not the InputGroup should check if the model is coarse-grained (and what type) or not

isInfiniteModel()

Is the current model marked as an infinitely bonded model?

Return type

bool

Returns

Whether the model is marked as infinitely bonded

browseSystemFile(fname)
reset()

Resets the input frame to defaults

class schrodinger.application.desmond.gui.SimOptionsFrame(master, key, app)

Bases: object

Responsible for drawing the simulation options widgets, including simulation time, recording intervals and the number of frames.

LE_WIDTH = 80
__init__(master, key, app)

See class docstring. :param master: The root or master application :type master: af2.JobApp object.

setup()

Sets up the panel with SLineEdit widgets

onTrajIntervalChanged()

Called when trajectory interval changes.

onNumOfFramesChanged(num_frames_str)

Called when the number of frames changes.

Parameters

num_frames_str (str) – Value of the number of frames field.

setEnabledExceptSimulationTime(enable)
onSimTimeChanged()

Called when simulation time changes.

setGuiState(state)
checkValidity()

Checks if all widgets have valid values. If a widget with invalid value was encountered, then returns string that describes the problem. Returns None if there are no issues.

updateKey(key)

Update the key based on the GUI settings

updateFromKey(key)

Updates widgets based on key.

class schrodinger.application.desmond.gui.EnsembleClassFrame(master, key, ens_callback, is_annealing, is_replica_exchange, app)

Bases: object

Frame that includes the Ensemble class pull-down menu and the entry fields correspondint to it.

TOOLTIP_TEXT = {'NPAT': 'Constant number of atoms, constant area, constant temperature', 'NPT': 'Constant number of atoms, constant pressure, constant temperature', 'NPγT': 'Constant number of atoms, constant surface tension, constant temperature', 'NVE': 'Constant number of atoms, constant volume, constant energy', 'NVT': 'Constant number of atoms, constant volume, constant temperature'}
__init__(master, key, ens_callback, is_annealing, is_replica_exchange, app)

See class docstring.

ensClassChanged(ens_class, should_callback=True)
updateEnsClassFromKey(key)
updateTempFromKey(key)

Updates the value of temperature to the first entry of key.temperature. Rest of the temperature entries will be ignored.

checkValidity()

Checks if all widgets have valid values. If a widget with invalid value was encountered, then returns string that describes the problem. Returns None if there are no issues.

updateKey(key)
updateFromKey(key)
model_changed_callback(model)
class schrodinger.application.desmond.gui.RelaxFrame(master, key, app)

Bases: object

Frame that includes the “Relax model…” check box and the relaxation protocol entry field.

__init__(master, key, app)

See class docstring

model_changed_callback(model)
shouldRelax()
getProtFilename()

Returns the name of the user-specified protocol file or None if user did not specifies any file.

toggleRelaxModel(ignored=None)
changeProtFile(fname)
checkValidity()

Checks if all widgets have valid values. If a widget with invalid value was encountered, then returns string that describes the problem. Returns None if there are no issues.

updateKey(key)

Update the key based on the GUI settings

updateFromKey(key)
class schrodinger.application.desmond.gui.AdvOptionsFrame(master, key, win, mdc_callback, adv_dialog_class, is_annealing, is_replica_exchange, app, dialog_master=None)

Bases: PyQt6.QtCore.QObject

Frame for the “Advanced Options” button.

MDC_DEFAULT_HEIGHT = 350
MDC_DEFAULT_WIDTH = 480
__init__(master, key, win, mdc_callback, adv_dialog_class, is_annealing, is_replica_exchange, app, dialog_master=None)

See class docstring.

Parameters

dialog_master (QWidget) – The widget that will be the master widget of the Advanced Options dialog. If not provided, the app argument will be used.

updateDialogKeys()

Update the keys of the dialog from the options.

openAdvancedDialog()
model_changed_callback(model)
closeDialog()

Close the advanced options dialog.

hideDialog()
okPressed()

Called when the “OK” button of the advanced dialog is pressed. Closes the dialog only if “Apply” operation was successful.

applySettings()

Called when the “Apply” button of the advanced dialog is pressed. Returns 0 on success, 1 if any of the widgets had invalid values.

cancelPressed()

Called when the “Cancel” button of the advanced dialog is pressed.

helpPressed()
checkValidity()

Checks if all widgets have valid values. If a widget with invalid value was encountered, then returns string that describes the problem. Returns None if there are no issues.

updateKey(key)
updateFromKey(key)
blockSignals(self, bool) bool
childEvent(self, QChildEvent)
children(self) List[QObject]
connectNotify(self, QMetaMethod)
customEvent(self, QEvent)
deleteLater(self)
destroyed

destroyed(self, object: QObject = None) [signal]

disconnect(QMetaObject.Connection) bool
disconnect(self) None
disconnectNotify(self, QMetaMethod)
dumpObjectInfo(self)
dumpObjectTree(self)
dynamicPropertyNames(self) List[QByteArray]
event(self, QEvent) bool
eventFilter(self, QObject, QEvent) bool
findChild(self, type, name: str = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) QObject
findChild(self, Tuple, name: str = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) QObject
findChildren(self, type, name: str = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) List[QObject]
findChildren(self, Tuple, name: str = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) List[QObject]
findChildren(self, type, QRegularExpression, options: Qt.FindChildOption = Qt.FindChildrenRecursively) List[QObject]
findChildren(self, Tuple, QRegularExpression, options: Qt.FindChildOption = Qt.FindChildrenRecursively) List[QObject]
inherits(self, str) bool
installEventFilter(self, QObject)
isSignalConnected(self, QMetaMethod) bool
isWidgetType(self) bool
isWindowType(self) bool
killTimer(self, int)
metaObject(self) QMetaObject
moveToThread(self, QThread)
objectName(self) str
objectNameChanged

objectNameChanged(self, str) [signal]

parent(self) QObject
property(self, str) Any
pyqtConfigure(...)

Each keyword argument is either the name of a Qt property or a Qt signal. For properties the property is set to the given value which should be of an appropriate type. For signals the signal is connected to the given value which should be a callable.

receivers(self, PYQT_SIGNAL) int
removeEventFilter(self, QObject)
sender(self) QObject
senderSignalIndex(self) int
setObjectName(self, str)
setParent(self, QObject)
setProperty(self, str, Any) bool
signalsBlocked(self) bool
startTimer(self, int, timerType: Qt.TimerType = Qt.CoarseTimer) int
staticMetaObject = <PyQt6.QtCore.QMetaObject object>
thread(self) QThread
timerEvent(self, QTimerEvent)
tr(str, disambiguation: str = None, n: int = - 1) str
class schrodinger.application.desmond.gui.MdGroup(master, key, win, is_annealing=False, is_replica_exchange=False, dialog_master=None)

Bases: schrodinger.application.desmond.gui._BaseGroup

Molecular Dynamics group

__init__(master, key, win, is_annealing=False, is_replica_exchange=False, dialog_master=None)
Parameters

dialog_master (QWidget) – The widget that will be the master widget of the Advanced Options dialog. If not provided, the master argument will be used.

setEnabledExceptSimulationTime(enable)

Ev:111016 Enable/disable this group. Does NOT disable the simulation time entry field.

adv_callback()

Called when the new Advanced Options are applied.

checkValidity()

Checks if all widgets have valid values. If a widget with invalid value was encountered, then returns string that describes the problem. Returns None if there are no issues.

model_changed_callback(model)
updateFromKey(key)

Set this frame to the values in key.

updateKey(key)

Updates the key based on the GUI settings.

class schrodinger.application.desmond.gui.DesmondBasicConfigDialog(*args, **kwargs)

Bases: schrodinger.ui.qt.config_dialog.ConfigDialog

This is identical to Appframework.ConfigDialog except adds platform check for localhost jobs

__init__(*args, **kwargs)

Adds a validate_platforms property that indicates whether the platform should be validated if it is localhost

enablePlatformValidation(state)

Enable/disable platform validation of localhost jobs

Parameters

state (bool) – Whether to use platform validation or not

validate()

Performs localhost validate if requested and then calls the parent class validation method

Return type

bool

Returns

Whether the dialog settings validate properly or not

CANCEL = 'Cancel'
CPU_UNIT_LABEL = 'processors'
GPU_UNIT_LABEL = 'GPUs'
HELP = 'Help'
HOST_LABEL_TEXT = 'Host:'
PRODUCT_HOSTS_KEY = 'product_hosts'
SAVE = 'OK'
START = 'Run'
WRITE = 'Write'
activate()

Display the dialog and return the dialog parameters as as StartDialogParam object. If the dialog was cancelled then return None and restore the prior state.

applySettings(settings)

Set dialog state using previously-saved parameters

Parameters

settings (StartDialogParams) – saved dialog settings

cpus3Edited(ignored=None)
currentHost(menu=None)

Returns the host currently selected in the menu parameter. If none is given, use self.host_menu. currentHost() can be overridden to use a different menu by default.

Parameters

menu (QtWidgets.QComboBox) – Menu to check for current host

error(text)

Show an error message with the specified text.

Parameters

msg (str) – Error to show.

getHostPref()

Get the stored host preference if available

Returns

Stored host preference if available or None

Return type

str or None

getHostType()
getHosts(ncpus=True, excludeGPGPUs=True)

Returns list of host entries from appropriate schrodinger.hosts file, with parenthetical entry of the number of available processors (if ‘ncpus’ is True). If excludeGPGPUs is True, hosts with GPGPUs will be excluded from the list

getNumCpusToValidate(is_queue)

Return the maximum number of processors that the job could potentially use, for validation.

Parameters

is_queue (bool) – If True, return number of threads per subjob requested, if False return number of threads * number of subjobs.

getOpenMPSettings()
Based on Open MP settings, return a tuple of:
  • Maximum number of CPUs to use

  • Number of threads to use.

  • Maximum number of subjobs to create.

Returns

(#cpus, #threads, #subjobs)

Return type

(int, int, int)

getSettings(extra_kws=None)
getTotalOpenMPCPUs()

Compute the total number of Open MP CPUs to use based on the number of threads and subjobs the user entered

Return type

int

Returns

total number of CPUs

isCPUHost()
isGPUHost()
savePressed()

Slot for Save button

setUpButtonBox(can_start=True)

Set up the button box items for the dialog.

Parameters

can_start – If True, add a Start button. Otherwise add a Write button.

setupHostCombo(combo, use_host=None, hosts=None)
setupHostLayout()

Setup the host layout, including hostlist/table and numbers of cpus (including cpus3).

Returns

Whether the dialog should add a start button.

Return type

bool

showHelp()
startPressed()

Slot for OK and Run button

updateCPULimits()

This method is called whenever host selection is changed. It updates maximum number of allowed CPUs.

updateOpenMPInfo()

Show/Hide the proper frames and update the processors label

updateOpenMPLabel()

Update the Open MP label with the current number of processors requested

updateQueueResources()

This updates the queue resources display when the host has changed.

validateAndAccept()

Validate the settings, and if no errors are found, close the dialog.

validateNumCpus(host, editfield, silent=False)

Validate number of CPUs :type host: Host :param host: the host on which the CPUs reside :type editfield: QWidget :param editfield: widget specifying the number of CPUs :type silent: bool :param silent: suppresses warning dialogs when set to True

validateNumGpus(host, editfield, silent=False)

Validate number of GPUs :type host: Host :param host: the host on which the GPUs reside :type editfield: QWidget :param editfield: widget specifying the number of GPUs :type silent: bool :param silent: suppresses warning dialogs when set to True

validateNumOpenMP(host, silent=False)

Checks to make sure the number of requested processors and threads is consistent with what we know of the host capabilities.

Parameters
  • host (Host) – The host on which the CPUs reside

  • silent (bool) – suppresses warning dialogs when set to True

Return type

bool

Returns

True if number of processors & threads is allowed, False if not

validateNumProcs(silent=False)

Checks that the number of processors requested is reasonable. Here the validation is conditional on the ‘cpus’ option. In derived classes this may not be valid (i.e. the validation should be run regardless of the ncpus options.

Parameters
  • menu (QComboBox) – The menu specifying the host selection to be validated

  • numfield (QLineEdit) – The widget specifying the requested # of processors

  • silent (bool) – suppresses warning dialogs when set to True

warning(text)

Display a warning window with the specified text.

writePressed()

Slot for Write button

class schrodinger.application.desmond.gui.GuiApp(key, validator, tag_spec, sim_class, is_replica_exchange=False, **kwargs)

Bases: schrodinger.ui.qt.appframework2.af2.JobApp

Base class of several Desmond panel GUI’s (see its subclasses below).

__init__(key, validator, tag_spec, sim_class, is_replica_exchange=False, **kwargs)
Parameters
  • stop_before (int) – Exit the constructor before specified step.

  • parent (QWidget) – Parent widget, if any.

  • in_knime (bool) – Whether we are currently running under KNIME - a mode in which input selector is hidden, optionally a custom Workspace Structure is specified, and buttom bar has OK & Cancel buttons.

  • workspace_st_file (bool) – Structure to be returned by getWorkspaceStructure() when in_knime is True.

setup()
layOut()

See af2.JobApp documentation for method documentation.

getConfigDialog()
enableSimulationGroupBox(state)

Set the simulation group box enabled state

Parameters

state (bool) – True if the groupbox should be enabled, False if not

model_changed_callback(model)

The GUI is designed to have some intelligence that can adapt its own look based on the imported model system. So if the model system is changed, we need to inform some other parts of the GUI.

The event that the model system is changed will be initially triggered from the InputGroup (see this class above), then it will go to here (i.e., GuiApp), and from here the signal will be sent forth to all interested parts of the GUI.

Parameters

model – A cms.Cms object, containing all information about the model system. If it is none, then the model is a checkpoint file.

updateFromKey(key)

Updates the look of the GUI with key

verifySettings(**kwargs)
startCommand(really_start=True)

Writes the job input files and assembles the command to execute.

Parameters

really_start (bol) – Whether to start the job after writing the input files.

getNonMembraneRelaxationProtocol()
Returns

A template file path for a non-membrane relaxation protocol

Return type

str

setUpMembraneRelaxation()

Set up the system for membrane relaxation and return a path to the membrane relaxation msj template.

Returns

Path to membrane relaxation msj template.

Return type

str

getRelaxationStageStringFromTemplate(pfile, cfg_fname)

Load a template relaxation protocol.

Parameters
  • pfile (str) – Template protocol file path

  • cfg_fname (str) – Config filename to include in the protocol

Returns

A relaxation stage protocol string loaded from the specified template.

Return type

str

getNoRelaxationProtocol(cfg_fname)

Get msj string when no relaxation protocol will be run.

Parameters

cfg_fname (str) – Config filename to be included in the protocol

Returns

No-relaxation protocol

Return type

str

readActionSelected()

Called when the “Read” action is selected by the user. It’s the responsibility of individual panels to hook this method to the “Read” menu action. See Ev:109801

writeCommand()
readCommand(fname)
isKeyConsistentWithPanel(key)
reset()
setDefaults()

Resets the parameters to their default values.

closeEvent(event)

Hide panel, if in Maestro. Otherwise close it.

DrawChildren = 2
DrawWindowBackground = 1
IGNORE_DELAYED_CALLBACKS = False
IgnoreMask = 4
class PaintDeviceMetric(value)

Bases: enum.Enum

An enumeration.

PdmWidth = 1
PdmHeight = 2
PdmWidthMM = 3
PdmHeightMM = 4
PdmNumColors = 5
PdmDepth = 6
PdmDpiX = 7
PdmDpiY = 8
PdmPhysicalDpiX = 9
PdmPhysicalDpiY = 10
PdmDevicePixelRatio = 11
PdmDevicePixelRatioScaled = 12
PdmDepth = 6
PdmDevicePixelRatio = 11
PdmDevicePixelRatioScaled = 12
PdmDpiX = 7
PdmDpiY = 8
PdmHeight = 2
PdmHeightMM = 4
PdmNumColors = 5
PdmPhysicalDpiX = 9
PdmPhysicalDpiY = 10
PdmWidth = 1
PdmWidthMM = 3
class RenderFlag(value)

Bases: enum.Flag

An enumeration.

DrawWindowBackground = 1
DrawChildren = 2
IgnoreMask = 4
acceptDrops(self) bool
accessibleDescription(self) str
accessibleName(self) str
actionEvent(self, QActionEvent)
actions(self) List[QAction]
activateWindow(self)
addAction(self, QAction)
addActions(self, Iterable[QAction])
addJaguarMarker(atoms, color=None, icon=None, text='', alt_color=None, highlight=False)

Add a marker to the specified atom(s)

Parameters
  • atoms (list or schrodinger.structure._StructureAtom) – The atom or list of atoms to mark. A list may contain between one and four atoms (inclusive).

  • color (tuple, str, int, or schrodinger.structutils.color) – The color of the marker and icon. May be an RGB tuple, color name, color index, or schrodinger.structutils.color instance. If not given, white will be used.

  • icon (int) – The icon to draw next to the marker. Should be one the self.MARKER_ICONS constants. If not given, no icon will be drawn.

  • text (str) – The text to display next to the marker. If not given, no text will be displayed. Note that this argument will be ignored when marking a single atom.

  • alt_color (tuple, str, int, or schrodinger.structutils.color) – The alternate marker color. This color is always used for text, and is used for the marker and icon when highlight is True. If not given, color will be used.

  • highlight (bool) – Whether the marker should be highlighted. A highlighted marker is indicated with thicker lines and is colored using alt_color instead of color.

Returns

The newly created marker

Return type

schrodinger.maestro.markers._BaseMarker

Raises

ValueError – If a marker already exists for the specified atoms

Note

Either an icon or text may be displayed on a marker, but not both. If both are given, only the text will be shown.

addMainTaskRunner(runner, taskwidget)

A “main” task runner is a runner that is operated by a task widget (generally a job bar) at the very bottom of the panel. A panel may have more than one main task, but there is always one that is the “current” task. This is useful for panels that have multiple modes, with each mode launching a different job.

The related method, self.setCurrentTask(), is used to switch between main runners that have been added via this function.

Parameters
  • runner (tasks.AbstractTaskRuner) – the task runner

  • taskwidget (taskwidgets.TaskUIMixin) – the associated task widget

addMarker(atoms, color=(1.0, 1.0, 1.0), group_name=None)

Generates a set of simple, dot-styled markers for a group of atoms.

Parameters
  • atoms (list or schrodinger.structure._StructureAtom) – List of atoms to be marked

  • color (tuple of 3 floats) – The amount of red, green and blue to use, each ranging from 0.0 to 1.0. Default is white (1., 1., 1.).

@group_name: Optional string to set as the name of this group of markers in Maestro. If not set, a unique identifier will be generated.

addMarkerFromAsl(asl, color=(1.0, 1.0, 1.0), group_name=None)

Generates a set of simple, dot-styled markers for group of Workspace atoms that match the given ASL. Same atoms continue to be marked even if the Workspace is later modified such that ASL matching changes.

Parameters
  • asl – ASL for the atoms to mark.

  • color (tuple of 3 floats) – The amount of red, green and blue to use, each ranging from 0.0 to 1.0. Default is white (1., 1., 1.).

@group_name: Optional string to set as the name of this group of markers in Maestro. If not set, a unique identifier will be generated.

Returns

Marker object

Return type

markers.Marker

addProjectJobNote(job_id, jobname)

Adds a note to the project annotation file. :param job_id: The ID of the job, as assigned by Maestro :type job_id: string :param jobname: The name of the job, as shown in the job panel :type jobname: string

adjustSize(self)
applyAliasedSettings(settings)

Applies any aliased settings with new values from the dictionary. Any aliases not present in the settings dictionary will be left unchanged.

Parameters

settings (dict) – a dictionary mapping aliases to new values to apply

applySettings(settings, target=None)
autoFillBackground(self) bool
backgroundRole(self) QPalette.ColorRole
baseSize(self) QSize
blockSignals(self, bool) bool
buildCallbackDicts()

Create a dictionary of all methods that have a maestro_callback decorator.

changeEvent(self, QEvent)
childAt(self, QPoint) QWidget
GuiApp.childAt(self, int, int) -> QWidget
childEvent(self, QChildEvent)
children(self) List[QObject]
childrenRect(self) QRect
childrenRegion(self) QRegion
cleanup()
clearFocus(self)
clearMask(self)
close(self) bool
colorCount(self) int
configDialogSettings()
connectNotify(self, QMetaMethod)
contentsMargins(self) QMargins
contentsRect(self) QRect
contextMenuEvent(self, QContextMenuEvent)
contextMenuPolicy(self) Qt.ContextMenuPolicy
create(self, window: PyQt6.sip.voidptr = 0, initializeWindow: bool = True, destroyOldWindow: bool = True)
createBottomBar()
createInputSelector()
createJobDir()
createWindowContainer(QWindow, parent: QWidget = None, flags: Qt.WindowType = Qt.WindowFlags()) QWidget
currentTaskRunner()
cursor(self) QCursor
customContextMenuRequested

customContextMenuRequested(self, QPoint) [signal]

customEvent(self, QEvent)
definePanelSettings()

Override this method to define the settings for the panel. The aliased settings provide an interface for saving/restoring panel state as well as for interacting with task/job runners that need to access the panel state in a way that is agnostic to the specifics of widget names and types.

Each panel setting is defined by a tuple that specifies the mapping of alias to panel setting. An optional third element in the tuple can be used to group settings by category. This allows multiple settings to share the same alias.

Each setting can either point to a specific object (usually a qt widget), or a pair of setter/getter functions.

If the mapped object is a string, this will be interpreted by af2 as referring to an attribute on the panel, and a AttributeSettingWrapper instance will automatically be created. For example, specifying the string ‘num_atoms’ will create a mapping to self.num_atoms which will simply get and set the value of that instance member.

Custom setter and getter functions should take the form getter(), returning a value that can be encoded/decoded by JSON, and setter(value), where the type of value is the same as the return type of the getter.

Commonly used objects/widgets should be handled automatically in settings.py. It’s worth considering whether it makes more sense to use a custom setter/getter here or add support for the widget in settings.py.

Returns

a list of tuples defining the custom settings.

Return type

list of tuples. Each tuple can be of type (str, object, str) or (str, (callable, callable), str) where the final str is optional.

Custom settings tuples consists of up to three elements:

  1. alias - a string identier for the setting. Ex. “box_centroid”

  2. either:

    1. an object of a type that is supported by settings.py or

    2. the string name of an existing panel attribute (i.e. member variable), or

    3. a (getter, setter) tuple. The getter should take no arguments, and the setter should take a single value.

  3. optionally, a group identifier. This can be useful if the panel runs two different jobs that both have a parameter with the same name but that needs to map to different widgets. If a setting has a group name, it will be ignored by runners unless the runner name matches the group name.

deleteLater(self)
depth(self) int
destroy(self, destroyWindow: bool = True, destroySubWindows: bool = True)
destroyed

destroyed(self, object: QObject = None) [signal]

devType(self) int
devicePixelRatio(self) float
devicePixelRatioF(self) float
devicePixelRatioFScale() float
disconnect(QMetaObject.Connection) bool
disconnect(self) None
disconnectNotify(self, QMetaMethod)
dragEnterEvent(self, QDragEnterEvent)
dragLeaveEvent(self, QDragLeaveEvent)
dragMoveEvent(self, QDragMoveEvent)
dropEvent(self, QDropEvent)
dumpObjectInfo(self)
dumpObjectTree(self)
dynamicPropertyNames(self) List[QByteArray]
effectiveWinId(self) PyQt6.sip.voidptr
ensurePolished(self)
enterEvent(self, QEnterEvent)
error(text, preferences=None, key='', detailed_text=None)

Display an error dialog with the specified text. If preferences and key are both supplied, then the dialog will contain a “Don’t show this again” checkbox. Future invocations of this dialog with the same preferences and key values will obey the user’s show preference.

Parameters
  • text (str) – The information to display in the dialog

  • preferences – obsolete; ignored.

  • key (str) – The key to store the preference under. If specified, a “Do not show again” checkbox will be rendered in the dialog box.

  • detailed_text (str) – Detailed (selectable) error text if any.

Return type

None

event(self, QEvent) bool
eventFilter(self, QObject, QEvent) bool
find(PyQt6.sip.voidptr) QWidget
findChild(self, type, name: str = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) QObject
findChild(self, Tuple, name: str = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) QObject
findChildren(self, type, name: str = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) List[QObject]
findChildren(self, Tuple, name: str = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) List[QObject]
findChildren(self, type, QRegularExpression, options: Qt.FindChildOption = Qt.FindChildrenRecursively) List[QObject]
findChildren(self, Tuple, QRegularExpression, options: Qt.FindChildOption = Qt.FindChildrenRecursively) List[QObject]
focusInEvent(self, QFocusEvent)
focusNextChild(self) bool
focusNextPrevChild(self, bool) bool
focusOutEvent(self, QFocusEvent)
focusPolicy(self) Qt.FocusPolicy
focusPreviousChild(self) bool
focusProxy(self) QWidget
focusWidget(self) QWidget
font(self) QFont
fontInfo(self) QFontInfo
fontMetrics(self) QFontMetrics
foregroundRole(self) QPalette.ColorRole
frameGeometry(self) QRect
frameSize(self) QSize
generateStatus()

Generate the text to put into the status bar

Returns

The text to put into the status bar

Return type

str

geometry(self) QRect
getAliasedSettings()
getAliasedValue(alias)
getAllJaguarMarkers()

Get all markers._BaseMarker currently loaded into the panel

Returns

An iterator of markers._BaseMarker

Return type

iterator

getAllMarkers()

Get all markers.Marker loaded into the panel

Returns

list(markers.Marker)

Return type

list

getCmdListArgValue(cmdlist, arg)
getJaguarMarker(atoms)

Retrieve a marker for the specified atom(s)

Parameters

atoms (list or schrodinger.structure._StructureAtom) – The atom or list of atoms to retrieve the marker for. A list may contain between one and four atoms (inclusive).

Returns

The requested marker

Return type

schrodinger.maestro.markers._BaseMarker

Raises

ValueError – If no marker exists for the specified atoms

Note

As indicated by the return type, this function only returns schrodinger.maestro.markers._BaseMarker derived markers. Multi atom schrodinger.maestro.markers.Marker type markers are not accessible in this way.

getJobSpec()
getObjValue(obj)
getPanelState()

Gets the current state of the panel in the form of a serializable dict. The state consists of the settings specified in definePanelSettings() as well as the automatically harvested settings.

getPersistenceKey(alias)

Return a unique identifier for saving/restoring a setting in the preferences. Override this method to change the key scheme (this is necessary if creating a common resource which is shared by multiple panels).

Parameters

alias (str) – the alias for which we are generating a key

getSettings(target=None, ignore_list=None)
getWorkspaceStructure()

If panel is open in Maestro session, returns the current workspace schrodinger.strucutre.Structure.

If panel is open from outside of Maestro, returns the self.workspace_st if self.workspace_st_file is available. Used while running from command line or starting the panel from KNIME.

Returns None otherwise.

Return type

schrodinger.structure.Structure or None

Returns

Maestro workspace structure or None

grab(self, rectangle: QRect = QRect(QPoint(0, 0), QSize(- 1, - 1))) QPixmap
grabGesture(self, Qt.GestureType, flags: Qt.GestureFlag = Qt.GestureFlags())
grabKeyboard(self)
grabMouse(self)
grabMouse(self, Union[QCursor, Qt.CursorShape]) None
grabShortcut(self, Union[QKeySequence, QKeySequence.StandardKey, str, int], context: Qt.ShortcutContext = Qt.WindowShortcut) int
graphicsEffect(self) QGraphicsEffect
graphicsProxyWidget(self) QGraphicsProxyWidget
gui_closed
hasFocus(self) bool
hasHeightForWidth(self) bool
hasMouseTracking(self) bool
hasTabletTracking(self) bool
height(self) int
heightForWidth(self, int) int
heightMM(self) int
hide(self)
hideAllJaguarMarkers()

Hide all schrodinger.maestro.markers._BaseMarker markers for this panel

hideAllMarkers()

Hide all schrodinger.maestro.markers.Marker markers for this panel.

hideEvent(self, QHideEvent)
hideLayoutElements(layout)

Hide all elements from the given layout. Used for customizing KNIME panel wrappers.

ignoreMaestroCallbacks()

A context manager for temporarily disabling Maestro callbacks created using the decorators above. (Note that callbacks that have been manually added using maestro.*_callback_add() will not be disabled.)

Example:

def includeEntry(self, entry_id):
    proj = maestro.project_table_get()
    with self.ignoreMaestroCallbacks():
        proj[entry_id].in_workspace = project.IN_WORKSPACE

@maestro_callback.project_changed
def onProjectChanged(self):
    print "This method will not be called during includeEntry."

@maestro_callback.workspace_changed
def onWorkspaceChanged(self):
    print "Neither will this one."
info(text, preferences=None, key='')

Display an information dialog with the specified text. If preferences and key are both supplied, then the dialog will contain a “Don’t show this again” checkbox. Future invocations of this dialog with the same preferences and key values will obey the user’s show preference.

Parameters
  • text (str) – The information to display in the dialog

  • preferences – obsolete; ignored.

  • key (str) – The key to store the preference under. If specified, a “Do not show again” checkbox will be rendered in the dialog box.

Return type

None

inherits(self, str) bool
initPainter(self, QPainter)
inputMethodEvent(self, QInputMethodEvent)
inputMethodHints(self) Qt.InputMethodHint
inputMethodQuery(self, Qt.InputMethodQuery) Any
GuiApp.insertAction(self, QAction, QAction)
insertActions(self, QAction, Iterable[QAction])
installEventFilter(self, QObject)
isActiveWindow(self) bool
isAncestorOf(self, QWidget) bool
isEnabled(self) bool
isEnabledTo(self, QWidget) bool
isFullScreen(self) bool
isHidden(self) bool
isLeftToRight(self) bool
isMaximized(self) bool
isMinimized(self) bool
isModal(self) bool
isRightToLeft(self) bool
isSignalConnected(self, QMetaMethod) bool
isVisible(self) bool
isVisibleTo(self, QWidget) bool
isWidgetType(self) bool
isWindow(self) bool
isWindowModified(self) bool
isWindowType(self) bool
jobCompleted
jobDir()
jobname()

Return the job name currently set for the current task.

jobnameData()

Provides panel settings that are to be incorporated into job names. If self.default_jobname includes string formatting characters (i.e. %s, {0}, etc.), then this method must be implemented. It should return a tuple or a dictionary to be interpolated into the job name.

jobnameDataChanged()

If the job name includes panel settings, then this method should be called whenever the relevant panel settings are modified

keyPressEvent(self, QKeyEvent)
keyReleaseEvent(self, QKeyEvent)
keyboardGrabber() QWidget
killTimer(self, int)
lastJobCompleted
launchFromJobSpec(oplsdir=None)

Call this function in start method if the calling script implements the launch api. This function requires implementation of getJobSpec to return the job specification.

Parameters

oplsdir (None, False or str) – If None (default), search widgets on the panel for a ffselector.ForceFieldSelector (or subclass thereof) and get any custom OPLS directory information from that widget. If False, do not use a custom OPLS directory. If a str, this is the path to use for the custom OPLS directory. Note that the OPLSDIR setting found by oplsdir=None is ambiguous if there is more than one ForceFieldSelector child widget, and that ForceFieldSelector widgets that are NOT child widgets of this panel - such as a widget on a dialog - will not be found. Setting this parameter to False for a panel that does not use a ForceFieldSelector widget avoids the widget search but will only shave a few thousandths of a second off job startup time even for very complex panels.

launchJobCmd(cmdlist, show_progress_bar=False, auto_add_host=True, use_parallel_flag=True, jobdir=None)

Launches a job control command. Use this to launch scripts that accept the standard job control options arguments like -HOST, -DISP, etc. By default, automatically populates standard arguments from the config dialog, but will not overwrite if they are already found in cmdlist. For example, if -HOST is found in cmdlist, launchJobCmd will ignore the host specified in the config dialog.

This method honors self.start_mode; it can either launch the script or write out a job file to the job directory.

Parameters
  • cmdlist (list) – the command list

  • show_progress_bar (bool) – Whether or not to show a progress bar tracking the job’s status.

  • auto_add_host (bool) – Whether or not to automatically add -HOST flag to command when it is not already included.

  • use_parallel_flag (bool) – Whether requesting CPUs > 1 without specifying threads > 1 should be represented by the use of the -PARALLEL X flag (True, default) or -HOST host:X (False). -PARALLEL is a Jaguar flag and may not be appropriate for other programs.

  • jobdir (str) – launch the job from this dir, if provided.

Returns

Job object for started job, or None if job start failed or if writing instead of starting. Panels should in general ignore the return value.

launchLauncher(slauncher, show_progress_bar=False)

Either launches a launcher instance or writes the job invocation command, depending on the state of self.start_mode. This allows the panel’s start method to double as a write method.

Calling launchLauncher() is only necessary if creating a customized launcher using makeLauncher().

Parameters

show_progress_bar (int) – Whether or not to show a progress bar tracking the job’s status.

launchScript(script, script_args=None, input_files=[], structure_output_file=None, output_files=[], aux_modules=[], show_progress_bar=False, **kwargs)

DEPRECATED, add get_job_spec_from_args() to the backend script and launch it using launchJobCmd() or also add getJobSpec() to the panel and launch using launchFromJobSpec().

Creates and launches a script using makeLauncher. For documentation on method parameters, see makeLauncher below. Use this method for scripts that do not themselves integrate with job control.

This method honors self.start_mode; it can either launch the script or write out a job file to the job directory.

Parameters

show_progress_bar (bool) – Whether or not to show a progress bar tracking the job’s status.

launcherToCmdList(slauncher)
layout(self) QLayout
layoutDirection(self) Qt.LayoutDirection
leaveEvent(self, QEvent)
loadPanelState(filename=None)

Load the panel state from a JSON file

Parameters

filename (str) – the JSON filename. Defaults to “panelstate.json”

loadPersistentOptions()

Load all persistent options from the preferences.

loadSettings(jobname)

Load the GUI state for the job in the CWD with the given name. Default implementation will return False. Each KNIME panel will need to implement a custom version. For example, the panel may want to read the <jobname.sh> file, parse the list of command-line options, and populate the GUI accordintly. If a panel writes key/value file, then it would need to read it here.

Returns

True if panel state was restored, False if saved state was not found.

Return type

bool

locale(self) QLocale
logicalDpiX(self) int
logicalDpiY(self) int
lower(self)
makeLauncher(script, script_args=[], input_files=[], structure_output_file=None, output_files=[], aux_modules=[], **kwargs)

DEPRECATED, add get_job_spec_from_args() to the backend script and launch it using launchJobCmd() or also add getJobSpec() to the panel and launch using launchFromJobSpec().

Create a launcher.Launcher instance using the settings defined by the panel, its config dialog, and specified arguments. Returns a launcher instance ready to be launched or further modified. Use this method for scripts that do not themselves integrate with job control.

Only use this method if you need to modify the launcher before launching it. Otherwise, the method launchScript() is preferred to create the launcher and launch it.

Parameters
  • script (str) – Remote path to the script to be launched. See Launcher documentation for more info. If only launching to localhost is desired, then a local path can be specified.

  • script_args (list of str) – arguments to be added to the script’s command line

  • input_files (list of str) – input files that will be copied to the temporary job directory.

  • structure_output_file (str) – this is the file that will be registered with job control to incorporate at the end of the job

  • output_files (list of str) – additional output files to be copied back from the temporary job directory

  • aux_modules (list of modules) – Additional modules required by the script

Returns

A prepped launcher

Return type

Launcher

mapFrom(self, QWidget, QPoint) QPoint
mapFrom(self, QWidget, QPointF) QPointF
mapFromGlobal(self, QPoint) QPoint
mapFromGlobal(self, QPointF) QPointF
mapFromParent(self, QPoint) QPoint
mapFromParent(self, QPointF) QPointF
mapTo(self, QWidget, QPoint) QPoint
mapTo(self, QWidget, QPointF) QPointF
mapToGlobal(self, QPoint) QPoint
mapToGlobal(self, QPointF) QPointF
mapToParent(self, QPoint) QPoint
mapToParent(self, QPointF) QPointF
mask(self) QRegion
maximumHeight(self) int
maximumSize(self) QSize
maximumWidth(self) int
metaObject(self) QMetaObject
metric(self, QPaintDevice.PaintDeviceMetric) int
minimumHeight(self) int
minimumSize(self) QSize
minimumSizeHint(self) QSize
minimumWidth(self) int
mouseDoubleClickEvent(self, QMouseEvent)
mouseGrabber() QWidget
mouseMoveEvent(self, QMouseEvent)
mousePressEvent(self, QMouseEvent)
mouseReleaseEvent(self, QMouseEvent)
move(self, QPoint)
GuiApp.move(self, int, int) -> None
moveEvent(self, QMoveEvent)
moveToThread(self, QThread)
nativeEvent(self, QByteArray, PyQt6.sip.voidptr) Tuple[bool, PyQt6.sip.voidptr]
nativeParentWidget(self) QWidget
nextInFocusChain(self) QWidget
normalGeometry(self) QRect
objectName(self) str
objectNameChanged

objectNameChanged(self, str) [signal]

overrideWindowFlags(self, Qt.WindowType)
overrideWindowState(self, Qt.WindowState)
paintEngine(self) QPaintEngine
paintEvent(self, QPaintEvent)
paintingActive(self) bool
palette(self) QPalette
classmethod panel(run=True)

Launch a singleton instance of this class. If the panel has already been instantiated, the existing panel instance will be re-opened and brought to the front.

Parameters

run (bool) – Whether to launch the panel

Returns

The singleton panel instance

Return type

App

parent(self) QObject
parentWidget(self) QWidget
physicalDpiX(self) int
physicalDpiY(self) int
pos(self) QPoint
previousInFocusChain(self) QWidget
processSettings(settings=None, runner=None)

This method is meant to be used as a callback to a task runner. If it is called with no arguments, it returns a dictionary of all the alieased settings. If settings are passed, the settings are first applied to self, and then the newly modified settings are returned.

Parameters
  • settings (dict or None) – a settings dictionary to apply to this object

  • runner (tasks.AbstractTaskRuner) – the task runner that is invoking this callback. This optional argument is necessary for per-runner grouping of settings

processTaskMessage(message_type, text, options=None, runner=None)

This method is meant to be used as a callback to a task runner, and provides a single point of interaction from the runner to the user.

Parameters
  • message_type (int) – the type of message being sent

  • text (str) – the main text to show the user

  • options – extra options

property(self, str) Any
pyqtConfigure(...)

Each keyword argument is either the name of a Qt property or a Qt signal. For properties the property is set to the given value which should be of an appropriate type. For signals the signal is connected to the given value which should be a callable.

question(msg, button1='OK', button2='Cancel', title='Question')

Display a prompt dialog window with specified text. Returns True if first button (default OK) is pressed, False otherwise.

raise_(self)
readShFile(jobname)

Reads the jobname.sh file (written by _write()) and returns the list of command line arguments

receivers(self, PYQT_SIGNAL) int
rect(self) QRect
registerJob(job, show_progress_bar=False)

Registers a job with the periodic job check callback and starts timer.

Parameters
  • job (jobcontrol.Job) – job to register

  • show_progress_bar (bool) – Whether or not to show a progress bar tracking the job’s status.

releaseKeyboard(self)
releaseMouse(self)
releaseShortcut(self, int)
removeAction(self, QAction)
removeAllJaguarMarkers()

Remove all markers schrodinger.maestro.markers._BaseMarker markers from this panel

removeAllJaguarMarkersForEntry(eid)

Remove all markers for the specified entry id from this panel

Parameters

eid (str) – The entry id to remove markers for

removeAllMarkers()

Remove all schrodinger.maestro.markers.Marker markers from this panel.

removeEventFilter(self, QObject)
removeJaguarMarker(marker)

Removes the specified marker

Parameters

marker (schrodinger.maestro.markers._BaseMarker) – The marker to remove

Raises

ValueError – If there is no marker on the specified atoms

removeJaguarMarkerForAtoms(atoms)

Removes the marker for specified atom(s)

Parameters

atoms (list or schrodinger.structure._StructureAtom) – The atom or list of atoms to retrieve the marker for. A list may contain between one and four atoms (inclusive).

Raises

ValueError – If no marker exists for the specified atoms

removeMarker(marker)

Remove the schrodinger.maestro.markers.Marker

Parameters

marker (schrodinger.maestro.markers.Marker) – Marker to remove

Raises

ValueError – If marker is the wrong type or is not associated with the panel.

render(self, QPaintDevice, targetOffset: QPoint = QPoint(), sourceRegion: QRegion = QRegion(), flags: QWidget.RenderFlag = QWidget.RenderFlags(QWidget.DrawWindowBackground | QWidget.DrawChildren))
render(self, QPainter, targetOffset: QPoint = QPoint(), sourceRegion: QRegion = QRegion(), flags: QWidget.RenderFlag = QWidget.RenderFlags(QWidget.DrawWindowBackground | QWidget.DrawChildren)) None
repaint(self)
GuiApp.repaint(self, int, int, int, int) -> None
repaint(self, QRect) None
repaint(self, QRegion) None
reportValidation(results)

Present validation messages to the user. This is an implmentation of the ValidationMixin interface and does not need to be called directly.

This method assumes that error and question methods have been defined in the subclass, as in e.g. widget_mixins.MessageBoxMixin.

Parameters

results (validation.ValidationResults) – Set of validation results generated by validate

Returns

if True, there were no validation errors and the user decided to continue despite any warnings. If False, there was at least one validation error or the user decided to abort when faced with a warning.

resetAllRunners()

Resets all task runners associated with this panel (main tasks and other tasks added via setupTaskRunner). This is called from _reset() and normally does not need to be called directly.

resize(self, QSize)
GuiApp.resize(self, int, int) -> None
resizeEvent(self, QResizeEvent)
restoreCursor(app_wide=True)

Restore the application level cursor to the default. If ‘app_wide’ is True then if will be restored for the entire application, if it’s False, it will be just for this panel.

Parameters

app_wide (bool) – If True then this will restore the cursor for the entire application (including Maestro if running there). If False then this will apply only to this panel.

restoreGeometry(self, QByteArray) bool
run()
runCanvas()

This handles Canvas-specific logic

classmethod runKnime(input_selector_file=None, workspace_st_file=None, jobname=None, run=True, load_settings=True, panel_state_file=None)

Call this static method to instantiate this panel in KNIME mode - where OK & Cancel buttons are shown at the bottom. Pressing OK button cases the job files to be written to the CWD.

Parameters
  • input_selector_file (str) – the filename to be fed into the input selector, replacing interactive input from the user. Required if the panel contains an input selector.

  • workspace_st_file (str) – the filename containing the schrodinger.structure.Structure that replaces the workspace structure in a Maestro session.

  • jobname (str) – Jobname for the panel

  • run (bool) – Whether to launch the panel. If False, just returns the panel instance without starting the event loop.

  • load_settings (bool) – Whether to load previous settings for the given jobname from the CWD.

  • panel_state_file – Unused (added for backwards compatability)

runMaestro()

This can be extended in derived classes to perform maestro-only tasks such as setting up the mini-monitor or connecting maestro callbacks

runMode()
runStandalone()
runSubpanel()
runValidation(silent=False, validate_children=True, stop_on_fail=True)

Runs validation and reports the results (unless run silently).

Parameters
  • silent (bool) – run without any reporting (i.e. error messages to the user). This is useful if we want to programmatically test validity. Changes return value of this method from ValidationResults to a boolean.

  • validate_children (bool) – run validation on all child objects. See _validateChildren for documentation on what this entails.

  • stop_on_fail (bool) – stop validation when first failure is encountered

Returns

if silent is False, returns the validation results. If silent is True, returns a boolean generated by reportValidation.

Return type

ValidationResults or bool

sanitizeJobnameText(text)

Modify the given text so it can be used in a job name. White space is replaced with underscores and all other disallowed characters are removed.

Parameters

text (basestring) – The text to sanitize

Returns

The sanitized text

Return type

basestring

saveGeometry(self) QByteArray
savePersistentOptions()

Store all persistent options to the preferences.

screen(self) QScreen
GuiApp.scroll(self, int, int)
GuiApp.scroll(self, int, int, QRect) -> None
sender(self) QObject
senderSignalIndex(self) int
setAcceptDrops(self, bool)
setAccessibleDescription(self, str)
setAccessibleName(self, str)
setAlias(alias, obj, persistent=False)

Sets an alias to conveniently access an object.

Parameters
  • alias (hashable) – any hashable, but typically a string name

  • obj (object) – the actual object to be referenced

  • persistent (bool) – whether to make the setting persistent

setAliasedValue(alias, value)
setAliases(alias_dict, persistent=False)

Sets multiple aliases at once. Already used aliases are overwritten; other existing aliases are not affected.

Parameters
  • alias_dict (dict) – map of aliases to objects

  • persistent (bool) – whether to make the settings persistent

setAttribute(self, Qt.WidgetAttribute, on: bool = True)
setAutoFillBackground(self, bool)
setBackgroundRole(self, QPalette.ColorRole)
GuiApp.setBaseSize(self, int, int)
setBaseSize(self, QSize) None
setConfigDialogSettings(new_values)
GuiApp.setContentsMargins(self, int, int, int, int)
setContentsMargins(self, QMargins) None
setContextMenuPolicy(self, Qt.ContextMenuPolicy)
setCurrentTask(index)

Selects the current main task for the panel. Switching to a new task involves several steps. These are 1) saving the current panel state to the task runner, 2) hiding the current task widget (and all others), 3) showing the widget for the new task, and 4) setting the panel state to correspond to the new task runner’s settings.

Parameters

index (int) – the index of the task to be selected. The index for each main task is set sequentially from 0 as each task as added using self.addMainTaskRunner()

setCursor(self, Union[QCursor, Qt.CursorShape])
setDisabled(self, bool)
setEnabled(self, bool)
setFixedHeight(self, int)
setFixedSize(self, QSize)
GuiApp.setFixedSize(self, int, int) -> None
setFixedWidth(self, int)
setFocus(self)
setFocus(self, Qt.FocusReason) None
setFocusPolicy(self, Qt.FocusPolicy)
setFocusProxy(self, QWidget)
setFont(self, QFont)
setForegroundRole(self, QPalette.ColorRole)
setGeometry(self, QRect)
GuiApp.setGeometry(self, int, int, int, int) -> None
setGraphicsEffect(self, QGraphicsEffect)
setHidden(self, bool)
setInputMethodHints(self, Qt.InputMethodHint)
setJobname(jobname)

Set the job name for the current task.

setLayout(self, QLayout)
setLayoutDirection(self, Qt.LayoutDirection)
setLocale(self, QLocale)
setMask(self, QBitmap)
setMask(self, QRegion) None
setMaximumHeight(self, int)
GuiApp.setMaximumSize(self, int, int)
setMaximumSize(self, QSize) None
setMaximumWidth(self, int)
setMinimumHeight(self, int)
GuiApp.setMinimumSize(self, int, int)
setMinimumSize(self, QSize) None
setMinimumWidth(self, int)
setMouseTracking(self, bool)
setObjValue(obj, value)
setObjectName(self, str)
setPalette(self, QPalette)
setPanelOptions()

See parent class for more options.

self.use_mini_jobbar - whether this panel use the narrow version of the bottom job bar. This is useful for narrow panels where the regular job bar is too wide to fit. Default: False

self.viewname - this identifier is used by the job status button so that it knows which jobs belong to this panel. This is automatically generated from the module and class name of the panel and so it does not need to be set unless the module/class names are generic.

self.program_name - a human-readable text name for the job this panel launches. This shows up in the main job monitor to help the user identify the job. Example: “Glide grid generation”. Default: “Job”

self.omit_one_from_standard_jobname - see documentation in jobnames.py

add_driverhost - If True, the backend supports running -DRIVERHOST to specify a different host for the driver job than subjobs. Only certain workflows support this option.

setPanelState(state)

Resets the panel and then sets the panel to the specified state

Parameters

state (PanelState) – the panel state to set. This object should originate from a call to getPanelState()

setParent(self, QWidget)
setParent(self, QWidget, Qt.WindowType) None
setPersistent(alias=None)

Set options to be persistent. Any options to be made persistent must be aliased, since the alias is used to form the preference key. If no alias is specified, all aliased settings will be made persistent.

Parameters

alias (str or None) – the alias to save, or None

setProperty(self, str, Any) bool
setScreen(self, QScreen)
setShortcutAutoRepeat(self, int, enabled: bool = True)
setShortcutEnabled(self, int, enabled: bool = True)
GuiApp.setSizeIncrement(self, int, int)
setSizeIncrement(self, QSize) None
setSizePolicy(self, QSizePolicy)
setSizePolicy(self, QSizePolicy.Policy, QSizePolicy.Policy) None
setStatusTip(self, str)
setStyle(self, QStyle)
setStyleSheet(self, str)
GuiApp.setTabOrder(QWidget, QWidget)
setTabletTracking(self, bool)
setToolTip(self, str)
setToolTipDuration(self, int)
setUpdatesEnabled(self, bool)
setVisible(self, bool)
setWaitCursor(app_wide=True)

Set the cursor to the wait cursor. This will be an hourglass, clock or similar. Call restoreCursor() to return to the default cursor.

Parameters

app_wide (bool) – If True then this will apply to the entire application (including Maestro if running there). If False then this will apply only to this panel.

setWhatsThis(self, str)
setWindowFilePath(self, str)
setWindowFlag(self, Qt.WindowType, on: bool = True)
setWindowFlags(self, Qt.WindowType)
setWindowIcon(self, QIcon)
setWindowIconText(self, str)
setWindowModality(self, Qt.WindowModality)
setWindowModified(self, bool)
setWindowOpacity(self, float)
setWindowRole(self, str)
setWindowState(self, Qt.WindowState)
setWindowTitle(self, str)
setupJobCmd(cmdlist, auto_add_host=True, use_parallel_flag=True)

Adds standard arguments HOST, NJOBS, PROJ, DISP, VIEWNAME to the cmdlist if they are set in the config dialog. Settings pre-existing in the cmdlist take precedence over the config dialog settings.

Parameters
  • cmdlist (list) – the command list

  • auto_add_host (bool) – Whether or not to automatically add -HOST flat to command when it is not already included.

  • use_parallel_flag (bool) – Whether requesting CPUs > 1 without specifying threads > 1 should be represented by the use of the -PARALLEL X flag (True, default) or -HOST host:X (False). -PARALLEL is a Jaguar flag and may not be appropriate for other programs.

setupTaskRunner(runner, taskwidget)

Connects a task widget to a task runner and associates the runner with this af2 panel via the panel callbacks.

This method is called by self.addMainTaskRunner() and does not need to be called for main tasks; however, it is useful for setting up other tasks that are not main tasks - for example, if there is a smaller job that gets launched from a button in the middle of the panel somewhere.

Parameters
  • runner (tasks.AbstractTaskRuner) – the task runner

  • taskwidget (taskwidgets.TaskUIMixin) – the associated task widget

sharedPainter(self) QPainter
show()

Re-show all panel markers when the panel is re-shown. This separate method is needed for QDialog instances.

showAllJaguarMarkers()

Show all schrodinger.maestro.markers._BaseMarker markers for which all marked atoms are in the workspace. Hide all other markers.

showAllMarkers()

Set all schrodinger.maestro.markers.Marker markers to be shown if the relevant atoms are in the workspace. These markers are hidden automatically by Maestro when atoms are excluded.

showEvent(event)

When the panel is shown, call the panel’s ‘show’-decorated methods. Note that restoring a minimized panel will not trigger the ‘show’ methods.

showFullScreen(self)
showMaximized(self)
showMinimized(self)
showNormal(self)
showProgressBarForJob(job, show_lbl=True, start_timer=True)

Show a progress bar that tracks the progress of the specified job

Parameters
  • job (schrodinger.job.jobcontrol.Job) – The job to track

  • show_lbl (bool) – If True, the job progress text description will be shown above the progress bar. If False, the text description will not be shown.

  • start_timer (bool) – If True, the progress bar will automatically be updated and removed when the job is complete. If False, it is the caller’s responsibility to periodically call self.progress_bar.readJobAndUpdateProgress() and to call self.status_bar.hideProgress() when the job is complete.

showSTUDialog(sh_txt, jobname)

Shows dialog with information necessary to start a STU test, including a label that links to the test suite.

Parameters

sh_txt (str) – Text contained within the .sh file

signalsBlocked(self) bool
size(self) QSize
sizeHint(self) QSize
sizeIncrement(self) QSize
sizePolicy(self) QSizePolicy
stackUnder(self, QWidget)
startDebug()
startTimer(self, int, timerType: Qt.TimerType = Qt.CoarseTimer) int
startUp()
staticMetaObject = <PyQt6.QtCore.QMetaObject object>
statusTip(self) str
style(self) QStyle
styleSheet(self) str
syncConfigDialog()
tabletEvent(self, QTabletEvent)
testAttribute(self, Qt.WidgetAttribute) bool
thread(self) QThread
timerEvent(self, QTimerEvent)
property title
toolTip(self) str
toolTipDuration(self) int
tr(str, disambiguation: str = None, n: int = - 1) str
underMouse(self) bool
ungrabGesture(self, Qt.GestureType)
unsetCursor(self)
unsetLayoutDirection(self)
unsetLocale(self)
update(self)
update(self, QRect) None
update(self, QRegion) None
GuiApp.update(self, int, int, int, int) -> None
updateGeometry(self)
updateJobname(uniquify_custom=True)

Generate a new job name based on the current panel settings

Parameters

uniquify_custom (bool) – Whether we should uniquify custom job name by adding integers to the end. If False, only standard and modified job names will be uniquified. (See JobnameType for an explanation of job name types.)

updateMicroFocus(self, query: Qt.InputMethodQuery = Qt.ImQueryAll)
updateStatusBar()

Updates the status bar.

updatesEnabled(self) bool
validForceFieldSelectorCustomOPLSDir()

Check whether a force field selector exists and if so whether it is set to use a custom OPLS directory that is valid. :return: whether OPLS directory has issues :rtype: bool

validateOPLSDir(opls_dir=None)

See forcefield.validate_opls_dir()

Parameters

opls_dir (str or None) – the opls dir to validate

Returns

the validation result

Return type

forcefield.OPLSDirResult

visibleRegion(self) QRegion
warning(text, preferences=None, key='')

Display a warning dialog with the specified text. If preferences and key are both supplied, then the dialog will contain a “Don’t show this again” checkbox. Future invocations of this dialog with the same preferences and key values will obey the user’s show preference.

Parameters
  • text (str) – The information to display in the dialog

  • preferences – obsolete; ignored.

  • key (str) – The key to store the preference under. If specified, a “Do not show again” checkbox will be rendered in the dialog box.

Return type

None

whatsThis(self) str
wheelEvent(self, QWheelEvent)
width(self) int
widthMM(self) int
winId(self) PyQt6.sip.voidptr
window(self) QWidget
windowFilePath(self) str
windowFlags(self) Qt.WindowType
windowHandle(self) QWindow
windowIcon(self) QIcon
windowIconChanged

windowIconChanged(self, QIcon) [signal]

windowIconText(self) str
windowIconTextChanged

windowIconTextChanged(self, str) [signal]

windowModality(self) Qt.WindowModality
windowOpacity(self) float
windowRole(self) str
windowState(self) Qt.WindowState
windowTitle(self) str
windowTitleChanged

windowTitleChanged(self, str) [signal]

windowType(self) Qt.WindowType
writeJobCmd(cmdlist, job_spec=None, launch_params=None)

Writes the job invocation command to a file named “<jobname>.sh” Removes options from the command that are maestro-specific.

Note this may modify the contents of cmdlist

Parameters
  • job_spec (schrodinger.job.launchapi.JobSpecification) – The job specification for the command you want to write. This is NOT used to write the command that is run; it is used to write a commented-out, un-hashed, human-readable command in the sh file. If None (which is also the default), then the human-readable comment is not written. If it is present, launch_params must be present too.

  • launch_params (job.launchparams.LaunchParameters) – Job launch params

writePanelState(filename=None)

Write the panel state to a JSON file

Parameters

filename (str) – the JSON filename. Defaults to “panelstate.json”

writeReadableCmdComment(cmdlist)

Append a readable and portable command (something that starts with $SCHRODINGER/run <script.py>) to the shell run file.

Parameters

cmdlist (list) – Commands to launch/submit the job

writeStateAndClose()

Will “write” the job files and close the panel.

x(self) int
y(self) int
class schrodinger.application.desmond.gui.DesmondGuiConfigDialog(parent, title='', jobname='', checkcommand=None, multi_gpgpu_allowed=True, no_cpu=True, **kw)

Bases: schrodinger.ui.qt.config_dialog.ConfigDialog

This Config Dialog allows toggling between CPU and GPU hosts.

__init__(parent, title='', jobname='', checkcommand=None, multi_gpgpu_allowed=True, no_cpu=True, **kw)

See class docstring. Raises an Exception if the disposition specified as the default is not recognized.

If pre_close_command is specified, it will be run when the user presses the Start button. The dialog is only closed if that function returns 0.

setUpButtonBox(can_start=True)

Set up the dialog’s button box and add ‘Write’ button.

onWriteRequested()

Slot for Write button.

validateNumProcs(silent=False)

See ConfigDialog.validateNumProcs docstring.

validate()

Checks the panel to make sure settings are valid. Return False if any validation test fails, otherwise return True.

getSettings(extra_kws=None)

Return dialog state by saving the state of the checkbox and then calling the base class

applySettings(settings)

See parent class docstring

setupHostLayout()

Setup the host layout, including hostlist/table and numbers of cpus (including cpus3).

Returns

Whether the dialog should add a start button.

Return type

bool

getHosts(_1=True, _2=False)

Get the hosts based on current CPU/GPU setting.

Returns

List of current hosts

Return type

config_dialog.Host

onProcUnitComboIndexChanged(use_host=None)

Update the available hosts based on the current processor unit type. Will also hide/show widgets based on whether GPU is selected but no GPU hosts are available or not.

Parameters

use_host (str) – Host to be set in the host combo

CANCEL = 'Cancel'
CPU_UNIT_LABEL = 'processors'
GPU_UNIT_LABEL = 'GPUs'
HELP = 'Help'
HOST_LABEL_TEXT = 'Host:'
PRODUCT_HOSTS_KEY = 'product_hosts'
SAVE = 'OK'
START = 'Run'
WRITE = 'Write'
activate()

Display the dialog and return the dialog parameters as as StartDialogParam object. If the dialog was cancelled then return None and restore the prior state.

cpus3Edited(ignored=None)
currentHost(menu=None)

Returns the host currently selected in the menu parameter. If none is given, use self.host_menu. currentHost() can be overridden to use a different menu by default.

Parameters

menu (QtWidgets.QComboBox) – Menu to check for current host

error(text)

Show an error message with the specified text.

Parameters

msg (str) – Error to show.

getHostPref()

Get the stored host preference if available

Returns

Stored host preference if available or None

Return type

str or None

getHostType()
getNumCpusToValidate(is_queue)

Return the maximum number of processors that the job could potentially use, for validation.

Parameters

is_queue (bool) – If True, return number of threads per subjob requested, if False return number of threads * number of subjobs.

getOpenMPSettings()
Based on Open MP settings, return a tuple of:
  • Maximum number of CPUs to use

  • Number of threads to use.

  • Maximum number of subjobs to create.

Returns

(#cpus, #threads, #subjobs)

Return type

(int, int, int)

getTotalOpenMPCPUs()

Compute the total number of Open MP CPUs to use based on the number of threads and subjobs the user entered

Return type

int

Returns

total number of CPUs

isCPUHost()
isGPUHost()
savePressed()

Slot for Save button

setupHostCombo(combo, use_host=None, hosts=None)
showHelp()
startPressed()

Slot for OK and Run button

updateCPULimits()

This method is called whenever host selection is changed. It updates maximum number of allowed CPUs.

updateOpenMPInfo()

Show/Hide the proper frames and update the processors label

updateOpenMPLabel()

Update the Open MP label with the current number of processors requested

updateQueueResources()

This updates the queue resources display when the host has changed.

validateAndAccept()

Validate the settings, and if no errors are found, close the dialog.

validateNumCpus(host, editfield, silent=False)

Validate number of CPUs :type host: Host :param host: the host on which the CPUs reside :type editfield: QWidget :param editfield: widget specifying the number of CPUs :type silent: bool :param silent: suppresses warning dialogs when set to True

validateNumGpus(host, editfield, silent=False)

Validate number of GPUs :type host: Host :param host: the host on which the GPUs reside :type editfield: QWidget :param editfield: widget specifying the number of GPUs :type silent: bool :param silent: suppresses warning dialogs when set to True

validateNumOpenMP(host, silent=False)

Checks to make sure the number of requested processors and threads is consistent with what we know of the host capabilities.

Parameters
  • host (Host) – The host on which the CPUs reside

  • silent (bool) – suppresses warning dialogs when set to True

Return type

bool

Returns

True if number of processors & threads is allowed, False if not

warning(text)

Display a warning window with the specified text.

writePressed()

Slot for Write button

class schrodinger.application.desmond.gui.SingleGpuDesmondGuiConfigDialog(*args, **kwargs)

Bases: schrodinger.application.desmond.gui.DesmondGuiConfigDialog

__init__(*args, **kwargs)

See class docstring. Raises an Exception if the disposition specified as the default is not recognized.

If pre_close_command is specified, it will be run when the user presses the Start button. The dialog is only closed if that function returns 0.

CANCEL = 'Cancel'
CPU_UNIT_LABEL = 'processors'
GPU_UNIT_LABEL = 'GPUs'
HELP = 'Help'
HOST_LABEL_TEXT = 'Host:'
PRODUCT_HOSTS_KEY = 'product_hosts'
SAVE = 'OK'
START = 'Run'
WRITE = 'Write'
activate()

Display the dialog and return the dialog parameters as as StartDialogParam object. If the dialog was cancelled then return None and restore the prior state.

applySettings(settings)

See parent class docstring

cpus3Edited(ignored=None)
currentHost(menu=None)

Returns the host currently selected in the menu parameter. If none is given, use self.host_menu. currentHost() can be overridden to use a different menu by default.

Parameters

menu (QtWidgets.QComboBox) – Menu to check for current host

error(text)

Show an error message with the specified text.

Parameters

msg (str) – Error to show.

getHostPref()

Get the stored host preference if available

Returns

Stored host preference if available or None

Return type

str or None

getHostType()
getHosts(_1=True, _2=False)

Get the hosts based on current CPU/GPU setting.

Returns

List of current hosts

Return type

config_dialog.Host

getNumCpusToValidate(is_queue)

Return the maximum number of processors that the job could potentially use, for validation.

Parameters

is_queue (bool) – If True, return number of threads per subjob requested, if False return number of threads * number of subjobs.

getOpenMPSettings()
Based on Open MP settings, return a tuple of:
  • Maximum number of CPUs to use

  • Number of threads to use.

  • Maximum number of subjobs to create.

Returns

(#cpus, #threads, #subjobs)

Return type

(int, int, int)

getSettings(extra_kws=None)

Return dialog state by saving the state of the checkbox and then calling the base class

getTotalOpenMPCPUs()

Compute the total number of Open MP CPUs to use based on the number of threads and subjobs the user entered

Return type

int

Returns

total number of CPUs

isCPUHost()
isGPUHost()
onProcUnitComboIndexChanged(use_host=None)

Update the available hosts based on the current processor unit type. Will also hide/show widgets based on whether GPU is selected but no GPU hosts are available or not.

Parameters

use_host (str) – Host to be set in the host combo

onWriteRequested()

Slot for Write button.

savePressed()

Slot for Save button

setUpButtonBox(can_start=True)

Set up the dialog’s button box and add ‘Write’ button.

setupHostCombo(combo, use_host=None, hosts=None)
setupHostLayout()

Setup the host layout, including hostlist/table and numbers of cpus (including cpus3).

Returns

Whether the dialog should add a start button.

Return type

bool

showHelp()
startPressed()

Slot for OK and Run button

updateCPULimits()

This method is called whenever host selection is changed. It updates maximum number of allowed CPUs.

updateOpenMPInfo()

Show/Hide the proper frames and update the processors label

updateOpenMPLabel()

Update the Open MP label with the current number of processors requested

updateQueueResources()

This updates the queue resources display when the host has changed.

validate()

Checks the panel to make sure settings are valid. Return False if any validation test fails, otherwise return True.

validateAndAccept()

Validate the settings, and if no errors are found, close the dialog.

validateNumCpus(host, editfield, silent=False)

Validate number of CPUs :type host: Host :param host: the host on which the CPUs reside :type editfield: QWidget :param editfield: widget specifying the number of CPUs :type silent: bool :param silent: suppresses warning dialogs when set to True

validateNumGpus(host, editfield, silent=False)

Validate number of GPUs :type host: Host :param host: the host on which the GPUs reside :type editfield: QWidget :param editfield: widget specifying the number of GPUs :type silent: bool :param silent: suppresses warning dialogs when set to True

validateNumOpenMP(host, silent=False)

Checks to make sure the number of requested processors and threads is consistent with what we know of the host capabilities.

Parameters
  • host (Host) – The host on which the CPUs reside

  • silent (bool) – suppresses warning dialogs when set to True

Return type

bool

Returns

True if number of processors & threads is allowed, False if not

validateNumProcs(silent=False)

See ConfigDialog.validateNumProcs docstring.

warning(text)

Display a warning window with the specified text.

writePressed()

Slot for Write button

class schrodinger.application.desmond.gui.DesmondRestGuiConfigDialog(parent, title='', jobname='', checkcommand=None, **kw)

Bases: schrodinger.application.desmond.gui.DesmondGuiConfigDialog

CANCEL = 'Cancel'
CPU_UNIT_LABEL = 'processors'
GPU_UNIT_LABEL = 'GPUs'
HELP = 'Help'
HOST_LABEL_TEXT = 'Host:'
PRODUCT_HOSTS_KEY = 'product_hosts'
SAVE = 'OK'
START = 'Run'
WRITE = 'Write'
activate()

Display the dialog and return the dialog parameters as as StartDialogParam object. If the dialog was cancelled then return None and restore the prior state.

applySettings(settings)

See parent class docstring

cpus3Edited(ignored=None)
currentHost(menu=None)

Returns the host currently selected in the menu parameter. If none is given, use self.host_menu. currentHost() can be overridden to use a different menu by default.

Parameters

menu (QtWidgets.QComboBox) – Menu to check for current host

error(text)

Show an error message with the specified text.

Parameters

msg (str) – Error to show.

getHostPref()

Get the stored host preference if available

Returns

Stored host preference if available or None

Return type

str or None

getHostType()
getHosts(_1=True, _2=False)

Get the hosts based on current CPU/GPU setting.

Returns

List of current hosts

Return type

config_dialog.Host

getNumCpusToValidate(is_queue)

Return the maximum number of processors that the job could potentially use, for validation.

Parameters

is_queue (bool) – If True, return number of threads per subjob requested, if False return number of threads * number of subjobs.

getOpenMPSettings()
Based on Open MP settings, return a tuple of:
  • Maximum number of CPUs to use

  • Number of threads to use.

  • Maximum number of subjobs to create.

Returns

(#cpus, #threads, #subjobs)

Return type

(int, int, int)

getSettings(extra_kws=None)

Return dialog state by saving the state of the checkbox and then calling the base class

getTotalOpenMPCPUs()

Compute the total number of Open MP CPUs to use based on the number of threads and subjobs the user entered

Return type

int

Returns

total number of CPUs

isCPUHost()
isGPUHost()
onProcUnitComboIndexChanged(use_host=None)

Update the available hosts based on the current processor unit type. Will also hide/show widgets based on whether GPU is selected but no GPU hosts are available or not.

Parameters

use_host (str) – Host to be set in the host combo

onWriteRequested()

Slot for Write button.

savePressed()

Slot for Save button

setUpButtonBox(can_start=True)

Set up the dialog’s button box and add ‘Write’ button.

setupHostCombo(combo, use_host=None, hosts=None)
setupHostLayout()

Setup the host layout, including hostlist/table and numbers of cpus (including cpus3).

Returns

Whether the dialog should add a start button.

Return type

bool

showHelp()
startPressed()

Slot for OK and Run button

updateCPULimits()

This method is called whenever host selection is changed. It updates maximum number of allowed CPUs.

updateOpenMPInfo()

Show/Hide the proper frames and update the processors label

updateOpenMPLabel()

Update the Open MP label with the current number of processors requested

updateQueueResources()

This updates the queue resources display when the host has changed.

validate()

Checks the panel to make sure settings are valid. Return False if any validation test fails, otherwise return True.

validateAndAccept()

Validate the settings, and if no errors are found, close the dialog.

validateNumCpus(host, editfield, silent=False)

Validate number of CPUs :type host: Host :param host: the host on which the CPUs reside :type editfield: QWidget :param editfield: widget specifying the number of CPUs :type silent: bool :param silent: suppresses warning dialogs when set to True

validateNumGpus(host, editfield, silent=False)

Validate number of GPUs :type host: Host :param host: the host on which the GPUs reside :type editfield: QWidget :param editfield: widget specifying the number of GPUs :type silent: bool :param silent: suppresses warning dialogs when set to True

validateNumOpenMP(host, silent=False)

Checks to make sure the number of requested processors and threads is consistent with what we know of the host capabilities.

Parameters
  • host (Host) – The host on which the CPUs reside

  • silent (bool) – suppresses warning dialogs when set to True

Return type

bool

Returns

True if number of processors & threads is allowed, False if not

validateNumProcs(silent=False)

See ConfigDialog.validateNumProcs docstring.

warning(text)

Display a warning window with the specified text.

writePressed()

Slot for Write button

__init__(parent, title='', jobname='', checkcommand=None, **kw)

See class docstring. Raises an Exception if the disposition specified as the default is not recognized.

If pre_close_command is specified, it will be run when the user presses the Start button. The dialog is only closed if that function returns 0.