schrodinger.application.peptide_workflow.beam_adapter module

Contains beam transforms to use in the beam pipeline when running PeptideWorkflowBeam.

class schrodinger.application.peptide_workflow.beam_adapter.PeptideReplicate(seed: int, st: Structure)

Bases: object

Holds necessary information for a peptide during the workflow.

Parameters:
  • seed – Random seed for reproducibility.

  • st – The peptide structure copy as read in from the input_file from a PeptideConfig.

seed: int
st: Structure
__init__(seed: int, st: Structure) None
class schrodinger.application.peptide_workflow.beam_adapter.PeptideWorkflowSettings(steps: int, num_simulations: int, rmsd_cutoff: float, num_poses_per_peptide: int, monte_options: MonteOptions)

Bases: object

Holds peptide workflow settings applicable to all modes.

Parameters:
  • steps – The number of monte carlo steps

  • num_simulations – The number of simulations to run. This variable is just used for logging purposes

  • rmsd_cutoff – RMSD cutoff for similar peptides

  • num_poses_per_peptide – Max number of poses to keep during deduplication post processing

  • monte_options – The monte carlo options

steps: int
num_simulations: int
rmsd_cutoff: float
num_poses_per_peptide: int
monte_options: MonteOptions
__init__(steps: int, num_simulations: int, rmsd_cutoff: float, num_poses_per_peptide: int, monte_options: MonteOptions) None
class schrodinger.application.peptide_workflow.beam_adapter.SuperimposeSettings(steps: int, num_simulations: int, rmsd_cutoff: float, num_poses_per_peptide: int, monte_options: MonteOptions, ff_clash_tolerance: float, ff_dielectric_constant: float)

Bases: PeptideWorkflowSettings

Holds peptide workflow settings for running with the OPLS minimizer

Parameters:
  • ff_clash_tolerance – force field clash tolerance constant

  • ff_dielectric_constant – force field dielectric constant

ff_clash_tolerance: float
ff_dielectric_constant: float
classmethod fromArgs(args)
__init__(steps: int, num_simulations: int, rmsd_cutoff: float, num_poses_per_peptide: int, monte_options: MonteOptions, ff_clash_tolerance: float, ff_dielectric_constant: float) None
class schrodinger.application.peptide_workflow.beam_adapter.GlideSettings(steps: int, num_simulations: int, rmsd_cutoff: float, num_poses_per_peptide: int, monte_options: MonteOptions, grid: GridArchive, glide_minimizer_options: dict, randomize_input_in_gridbox: bool)

Bases: PeptideWorkflowSettings

Holds peptide workflow settings for running with the Glide minimizer

Parameters:
  • grid – A glide grid archive with grid information

  • glide_minimizer_options – Options for the glide minimizer

  • randomize_input_in_gridbox – To randomize the input in the grid box

grid: GridArchive
glide_minimizer_options: dict
randomize_input_in_gridbox: bool
classmethod fromArgs(args)
__init__(steps: int, num_simulations: int, rmsd_cutoff: float, num_poses_per_peptide: int, monte_options: MonteOptions, grid: GridArchive, glide_minimizer_options: dict, randomize_input_in_gridbox: bool) None
class schrodinger.application.peptide_workflow.beam_adapter.PrimeSettings(steps: int, num_simulations: int, rmsd_cutoff: float, num_poses_per_peptide: int, monte_options: MonteOptions, recept_asl: str, recept_st: str)

Bases: PeptideWorkflowSettings

Holds peptide workflow settings for running with the Prime minimizer.

Parameters:
  • recept_asl – Receptor ASL to minimize with Prime

  • recept_st – Receptor filename

recept_asl: str
recept_st: str
classmethod fromArgs(args)
__init__(steps: int, num_simulations: int, rmsd_cutoff: float, num_poses_per_peptide: int, monte_options: MonteOptions, recept_asl: str, recept_st: str) None
schrodinger.application.peptide_workflow.beam_adapter.get_workflow_settings(args)

Get the workflow settings for the correct mode defined by the args.

Parameters:

args (argparse.Namespace) – job settings

Return type:

GlideSettings|PrimeSettings|SuperimposeSettings

Returns:

a settings dataclass

class schrodinger.application.peptide_workflow.beam_adapter.ReadPeptideStructures(label: Optional[str] = None)

Bases: _LocalOnlyPTransform, ReadPeptideStructures

Beam transform to create peptide structures with their output file and number of replicates as structure properties.

class schrodinger.application.peptide_workflow.beam_adapter.PeptideWorkflowMonteCarlo(settings, random_seed)

Bases: PTransform

Beam transform to run the monte carlo based peptide docking.

Parameters:
Return type:

tuple[str, list[Structure]]

Returns:

a tuple of output file and list of structure poses to write

__init__(settings, random_seed)
expand(peptide_structure)
schrodinger.application.peptide_workflow.beam_adapter.duplicate_and_enumerate_replicate(peptide_structure: Structure, seed: int)

Reads input files to create peptide structures and binds them with a randomly generated seed in a PeptideReplicate object.

Parameters:
  • peptide_structure – Config for the peptide containing input file, output file, jobname and replicates.

  • seed – Random seed.

Return type:

list[PeptideReplicate]

Returns:

A list of PeptideReplicate objects.

class schrodinger.application.peptide_workflow.beam_adapter.CreateReplicates(seed)

Bases: PTransform

Create Peptide elements based on PeptideConfig elements which were created during argument parsing.

__init__(seed)
expand(peptide_structure)
class schrodinger.application.peptide_workflow.beam_adapter.PostProcessPeptides(settings)

Bases: PTransform

Beam transform to map a PCollection of tuple[str, [structures]] to post_process to deduplicate the list of structures.

Parameters:

setting (GlideSettings|PrimeSettings|SuperimposeSettings) – a settings dataclass

Return type:

tuple[str, list[Structure]]

Returns:

A PCollection of tuples containing the output file and list of output structure poses

__init__(settings)
expand(simulation_result)
schrodinger.application.peptide_workflow.beam_adapter.run_single_peptide_workflow(peptide_obj, mover, minimizer, random_seed, monte_options, steps)

Run the Peptide Workflow with a single peptide structure.

Parameters:
  • peptide_obj – A peptide.Peptide object

  • mover (PeptideMovements) – movement sampler to be used

  • minimizer (PeptideMinimizer) – minimizer to be used

  • random_seed (int) – random seed to create random generator

  • monte_options (MonteOptions) – contains constants for monte

  • steps (int) – max steps to run for the simulation

Return type:

Structure

Returns:

Yields an output pose

class schrodinger.application.peptide_workflow.beam_adapter.RunMonte(settings)

Bases: PTransform

Beam transform to transform a PCollection of PeptideReplicate to a PCollection of tuples bundling the output file and the output structure together. There are 3 monte carlo methods each with a unique minimizer which are run by different DoFn based classes.

The transform reads the grid or receptor as bytes when a grid or receptor supplied by the user.

Parameters:

settings (GlideSettings | PrimeSettings | SuperimposeSettings) – Settings for which workflow method to use

Return type:

PCollection(Structure)

Returns:

A colleciton of output structures (poses)

__init__(settings)
expand(peptide_replicate)
schrodinger.application.peptide_workflow.beam_adapter.write_sts(simulation_result)

Write out the structures associated with each output file. Removes the internal properties s_peptide_outputfile and i_peptide_num_replicates.

Parameters:

simulation_result (tuple of str and list of structures) – A tuple that contains the output file and list of structures