schrodinger.application.bioluminate.patch_utils.settings module

Classes for storing panel settings.

class schrodinger.application.bioluminate.patch_utils.settings.PatchTypeSettings(size=10, threshold=None, color=None)

Bases: object

Settings for a single patch type (i.e. hydrophobic, positive, or negative).

__init__(size=10, threshold=None, color=None)
Parameters:
  • size (float) – The minimum size of a patch in Angstroms squared
  • threshold (float) – The minimum value for a vertex to be considered part of a patch
  • color (list or tuple) – What to color the patch in the workspace and panel tables, given as integer (r, g, b) values.
class schrodinger.application.bioluminate.patch_utils.settings.PatchSettings

Bases: object

Settings for all patch types (i.e. hydrophobic, positive, and negative).

Variables:EP (float) – A very small value (i.e. epsilon) used for floating point comparisons in sameSizeAndThreshold.
DEFAULT_TRANSPARENCY = 15
EP = 1e-07
__init__()

Initialize self. See help(type(self)) for accurate signature.

color(patch_type)

Get the color for the specified patch type. If coloring by AggScore, then the user’s color for AggScore is always returned instead.

Parameters:patch_type (PatchType) – The patch type to get the color for
Returns:The requested color as a tuple of integer (r, g, b) values
Return type:tuple
getPatchColorRamp(patch_type)

Return the ColorRamp object for the given patch type. Used for coloring Workspace patch surface, as well as background column in tables. If coloring by AggScore, then color ramp for AggScore is always used.

Parameters:patch_type (PatchType) – The patch type to get the color ramp for
Returns:The requeted color ramp
Return type:color.ColorRamp
sameSizeAndThreshold(other)

Check to see if this object and other have the same patch size and patch threshold settings. Differences in color are ignored.

Parameters:other (PatchSettings) – The object to compare
Returns:True if these objects have the same size and threshold settings. False otherwise.
Return type:bool
class schrodinger.application.bioluminate.patch_utils.settings.PatchType(long_name, short_name, unit)

Bases: enum.Enum

An enumeration.

positive = ('Positive', 'pos', 'eV')
negative = ('Negative', 'neg', 'eV')
hydrophobic = ('Hydrophobic', 'hyd', 'sLogP')
__init__(long_name, short_name, unit)
Parameters:
  • long_name (str) – The patch name used in the details dialog
  • short_name (str) – The patch name used in the patch table
  • unit (str) – The unit for values of this patch