schrodinger.application.phase.packages.shape_generator module¶
Supplies consistent means of generating shape structures via ligand and pharmacophore command line options.
Copyright Schrodinger LLC, All Rights Reserved.
-
class
schrodinger.application.phase.packages.shape_generator.AtomTypes(value)¶ Bases:
enum.EnumAn enumeration.
-
mmod= 1¶
-
element= 2¶
-
qsar= 3¶
-
-
class
schrodinger.application.phase.packages.shape_generator.ShapeGenerator(args)[source]¶ Bases:
object-
__init__(args)[source]¶ Initializes shape generation options.
- Parameters
args (argparser.Namespace) – argument namespace with command line options
-
getFeatureDefinitions(args)[source]¶ Collects the feature definitions to use for generating pharmacophore hypothesis shapes from ligands.
- Parameters
args (argparser.Namespace) – argument namespace with command line options
- Returns
list of pharmacophore feature definitions
- Return type
list of phase.PhpFeatureDefinition
-
getHypothesisFeatureRadii(radii_file)[source]¶ Collects user specified pharmacophore feature radii to use for generating pharmacophore hypothesis shapes from ligands.
- Parameters
radii_file (str) – user supplied .rad filename
- Returns
Data for feature specific radii
- Return type
phase.PhpFeatureData
-
getHypothesisSitesShape(sites)[source]¶ Returns a shape structure created from the given Phase hypothesis.
- Parameters
sites (list(phase.PhpSite)) – pharmacophore sites source
- Returns
shape structure derived from the given hypothesis
- Return type
shape.ShapeStructure
-
getShape(st, atom_weight_property=None)[source]¶ Creates a shape structure from the given ligand structure.
- Parameters
st (structure.Structure) – ligand source structure
- Returns
shape structure derived from the given structure
- Return type
shape.ShapeStructure
-
getConformerShapes(conformers)[source]¶ Creates a list of shape structure from the given ligand conformers.
- Parameters
conformers (list(structure.Structure)) – ligand source conformers of the same structure
- Returns
shape structures derived from the given conformers
- Return type
list(shape.ShapeStructure)
-
-
class
schrodinger.application.phase.packages.shape_generator.SerializableShapeGenerator(params)[source]¶ Bases:
schrodinger.application.phase.packages.shape_generator.ShapeGenerator-
__init__(params)[source]¶ Accept either command line arguments or dictionary representation.
- Parameters
params (namespace or dict) – Command line arguments or dictionary representation similar to the one returned by the
toDictmethod.
-
fromDict(data)[source]¶ Configures the instance using data from
data.- Parameters
data (dict) – Dictionary representation of the instance configuration.
-
getConformerShapes(conformers)¶ Creates a list of shape structure from the given ligand conformers.
- Parameters
conformers (list(structure.Structure)) – ligand source conformers of the same structure
- Returns
shape structures derived from the given conformers
- Return type
list(shape.ShapeStructure)
-
getFeatureDefinitions(args)¶ Collects the feature definitions to use for generating pharmacophore hypothesis shapes from ligands.
- Parameters
args (argparser.Namespace) – argument namespace with command line options
- Returns
list of pharmacophore feature definitions
- Return type
list of phase.PhpFeatureDefinition
-
getHypothesisFeatureRadii(radii_file)¶ Collects user specified pharmacophore feature radii to use for generating pharmacophore hypothesis shapes from ligands.
- Parameters
radii_file (str) – user supplied .rad filename
- Returns
Data for feature specific radii
- Return type
phase.PhpFeatureData
-
getHypothesisSitesShape(sites)¶ Returns a shape structure created from the given Phase hypothesis.
- Parameters
sites (list(phase.PhpSite)) – pharmacophore sites source
- Returns
shape structure derived from the given hypothesis
- Return type
shape.ShapeStructure
-
getShape(st, atom_weight_property=None)¶ Creates a shape structure from the given ligand structure.
- Parameters
st (structure.Structure) – ligand source structure
- Returns
shape structure derived from the given structure
- Return type
shape.ShapeStructure
-
-
schrodinger.application.phase.packages.shape_generator.add_shape_generation_options(parser)[source]¶ Adds ligand-based screening options to the provided parser.
- Parameters
parser (argparser.ArgumentParser) – Argument parser object
-
schrodinger.application.phase.packages.shape_generator.validate_shape_gen_options(args)[source]¶ Validates command-line argument pharmacophore option compatibility.
- Parameters
args (argparse.Namespace) – argument namespace with command line options
- Returns
tuple of validation success, and error message
- Return type
bool, str
-
schrodinger.application.phase.packages.shape_generator.validate_shape_generator_dict(data)[source]¶ Validates “serialized” (as dictionary) representation of ShapeGenerator.
- Parameters
data (dict) – Dictionary representation of the instance configuration.
- Returns
Validation outcome and complain (if any).
- Return type
(bool, str)
-
schrodinger.application.phase.packages.shape_generator.validate_shape_generator_dict_compatibility(meta1, meta2)[source]¶ Validates shape generators compatibility.
- Parameters
meta1 (dict) – Validated shape generator dict #1.
meta2 (dict) – Validated shape generator dict #2.
- Returns
Validation outcome and complain (if any).
- Return type
(bool, str)