schrodinger.application.phase.pt_hypothesis module

Module for manipulating hypothesis entries in the project table.

class schrodinger.application.phase.pt_hypothesis.PhaseHypothesisMonitor

Bases: QObject

This class provides signals that are emitted when hypothesis is changed. These signals should be emitted with the hypothesis entry id.

Variables:

hypothesisChanged (QtCore.pyqtSignal) – signal emitted when hypothesis is changed

hypothesisChanged

A pyqtSignal emitted by instances of the class.

schrodinger.application.phase.pt_hypothesis.get_hypo_monitor()

This function returns global PhaseHypothesisMonitor object that should be used to monitor signals emitted when hypothesis is changed.

Returns:

PhaseHypothesisMonitor

Return type:

PhaseHypothesisMonitor

schrodinger.application.phase.pt_hypothesis.update_hypothesis_entry(hypo, entry_id)

Updates the structure in the project table for the given entry ID with the current PhaseHypothesis.

Parameters:

entry_id (int or str) – entry id to set hypothesis to

schrodinger.application.phase.pt_hypothesis.get_hypothesis_from_project(entry_id)

Gets hypothesis with a given entry id from the project. It creates a hypothesis object from entries within same hypothesis group.

Parameters:

entry_id (int) – hypothesis ID

Returns:

Phase hypothesis

Return type:

PhaseHypothesis

schrodinger.application.phase.pt_hypothesis.convert_project_hypotheses(project_handle)

Converts all hypothesis datafiles in the original Phase format into PhaseHypothesis (PhpHypoAdaptor) objects. If successful, each hypothesis is updated in the project to the new format. If the given entry ID does not have a corresponding hypothesis datafile, nothing is done.

Parameters:

project_handle (int) – project.Project handle

schrodinger.application.phase.pt_hypothesis.is_hypothesis_entry(entry_id)

Returns whether project table row is a Phase hypothesis entry or not.

Parameters:

entry_id (int or str) – entry ID for row in project table

Returns:

True if the row is a hypothesis entry, false Otherwise

Return type:

bool

schrodinger.application.phase.pt_hypothesis.get_hypothesis_entry_ids(entry_id)

Returns entry_ids of all entries in the group associated with the passed hypothesis entry ID.

Parameters:
  • hypo_entry_id – hypothesis entry ID

  • hypo_entry_id – int

Returns:

list of entry ids associated with the given hypothesis

Return type:

list