Package schrodinger :: Package application :: Package bioluminate :: Package patch_utils :: Module patch_finder :: Class PatchFinder
[hide private]
[frames] | no frames]

Class PatchFinder

object --+
         |
        PatchFinder

Find surface patches using the output of PreAnalyzer. This object is intended to run in a separate thread and therefore must not use mmlibs after initialization.

Instance Methods [hide private]
 
__init__(self, surf, clogp_smoothed, partial_charge_smoothed, neighboring_vertices, neighboring_triangles, res_data_by_vertex, prot_properties)
x.__init__(...) initializes x; see help(type(x)) for signature
tuple
calculate(self, settings)
Calculate patches and residue aggregation data using the specified settings.
list
_calcPatches(self, settings)
Calculate patches using the specified settings.
list
_calcPatchesFor(self, smoothed, settings, op, patch_type)
Calculate the patches using the specified data
list
_findAllPatchVertices(self, starting_vertex, smoothed, op, threshold, vertex_examined)
Find all vertices that are part of the same patch as starting_vertex.
list
_calcResData(self, patches)
The function takes in a list of patches and calculates for each patch the following properties that are set in the object:

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Class Methods [hide private]
 
read(cls, basename)
Read the PreAnalyzer data from the specified basename and use it to create a PatchFinder object.
Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, surf, clogp_smoothed, partial_charge_smoothed, neighboring_vertices, neighboring_triangles, res_data_by_vertex, prot_properties)
(Constructor)

 

x.__init__(...) initializes x; see help(type(x)) for signature

Parameters:
  • surf (schrodinger.surface.Surface) - The surface to find patches on
  • clogp_smoothed (list) - The cLogP (hydrophobicity) values smoothed over the surface. This list contains the smoothed value at each surface vertex.
  • partial_charge_smoothed (list) - The partial charge values smoothed over the surface. This list contains the smoothed value at each surface vertex.
  • neighboring_vertices (list) - A list of neighboring vertices for each vertex.
  • neighboring_triangles (list) - A list of neighboring triangles for each vertex, where each triangle is represented as a frozenset of three vertex indices.
  • res_data_by_vertex (list) - A list of residue data for each vertex. The ResData object is given for the residue closest to the vertex.
  • prot_properties (ProteinProperties) - The protein properties to be loaded into the Properties tab.
Overrides: object.__init__

read(cls, basename)
Class Method

 

Read the PreAnalyzer data from the specified basename and use it to create a PatchFinder object.

Parameters:
  • basename (str) - The basename for the PreAnalyzer output files

calculate(self, settings)

 

Calculate patches and residue aggregation data using the specified settings.

Parameters:
Returns: tuple
A tuple of:
  • the calculated patches as a list of Patch objects
  • the residue aggregation data as a list of {ResidueAggData} objects

_calcPatches(self, settings)

 

Calculate patches using the specified settings.

Parameters:
Returns: list
A list of Patch objects

_calcPatchesFor(self, smoothed, settings, op, patch_type)

 

Calculate the patches using the specified data

Parameters:
  • smoothed (list) - The smoothed values to use for patch calculation
  • settings (settings.PatchTypeSettings) - The settings to use for the patch calculations
  • op (function) - An operator indicating whether patches vertices should contains values less than or greater than the threshold value in settings.
  • patch_type (settings.PatchType) - The type of patch to find
Returns: list
A list of Patch objects

_findAllPatchVertices(self, starting_vertex, smoothed, op, threshold, vertex_examined)

 

Find all vertices that are part of the same patch as starting_vertex.

Parameters:
  • starting_vertex (int) - The index of the vertex to start the search at.
  • smoothed (list) - The smoothed values to use for patch calculation
  • op (function) - An operator indicating whether patches vertices should contains values less than or greater than the threshold value.
  • threshold (float) - All patch vertices must have a smoothed value less than or greater than this value.
  • vertex_examined (list) - For each vertex, a Boolean indicating whether or not the vertex has been examined during this patch search. Will be updated by this method.
Returns: list
A list of vertex indices

_calcResData(self, patches)

 

The function takes in a list of patches and calculates for each patch the following properties that are set in the object:

  • energy: The combined score for residues in the patch (including residues that were excluded later filtered from the patch).
  • res: list of residue data
  • contribution: sorted list of energy contribution per residue to the patch (highest contributor is listed first)
  • patch_atms: list of atom indices that contribute to the patch. This list is sorted by residue affiliation
  • seg: segmentation vector. Determine, how many atoms per residue are contributing to the patch
Parameters:
  • patches (list) - A list of Patch objects
Returns: list
A list of ResData objects