schrodinger.application.bioluminate.immunebuilder.immunebuilder_adapter module

This module allows use of ImmuneBuilder structure prediction, replacing (and disabling) the third-party modules openmm and pdbfixer.

WARNING: Importing this module will prevent the caller from using the third party modules openmm and pdbfixer.

class schrodinger.application.bioluminate.immunebuilder.immunebuilder_adapter.MockOpenMM

Bases: object

These mocked modules are imported by ImmuneBuilder, but we don’t need them.

class Unit

Bases: object

kilocalories_per_mole = 1
angstroms = 1
class App

Bases: object

ForceField()
app

alias of App

LangevinIntegrator = None
CustomExternalForce = None
CustomTorsionForce = None
OpenMMException = None
Platform = None
unit

alias of Unit

class schrodinger.application.bioluminate.immunebuilder.immunebuilder_adapter.ImmuneBuilderType

Bases: Enum

TCR = 'TCR'
ANTIBODY = 'Antibody'
NANOBODY = 'Nanobody'
schrodinger.application.bioluminate.immunebuilder.immunebuilder_adapter.predict_and_refine_model(model_type: ImmuneBuilderType, seq_dict: dict[str, str], refine: bool = True) Structure

Predict models of TCR, Antibody, or Nanobody

schrodinger.application.bioluminate.immunebuilder.immunebuilder_adapter.predict_model(model_type: ImmuneBuilderType, seq_dict: dict[str, str], model_weights_dir=None) ImmuneBuilder.ABodyBuilder2.Antibody | ImmuneBuilder.TCRBuilder2.TCR | ImmuneBuilder.NanoBodyBuilder2.Nanobody

Predict models of TCR, Antibody, or Nanobody

schrodinger.application.bioluminate.immunebuilder.immunebuilder_adapter.get_default_weights_dir()
schrodinger.application.bioluminate.immunebuilder.immunebuilder_adapter.refine_model(model: ImmuneBuilder.ABodyBuilder2.Antibody | ImmuneBuilder.TCRBuilder2.TCR | ImmuneBuilder.NanoBodyBuilder2.Nanobody)

Save and refine the top-ranked structure.

schrodinger.application.bioluminate.immunebuilder.immunebuilder_adapter.run_prepwizard(input_file: str, model_type: ImmuneBuilderType, output_file: str = None, scheme: AntibodyCDRScheme = None)

Run PrepWizard to minimize and clean up a predicted structure

schrodinger.application.bioluminate.immunebuilder.immunebuilder_adapter.cleanup_after_prep_calculation(directory: str = '.')

Remove intermediate files and hidden files created by Prep Wizard.

schrodinger.application.bioluminate.immunebuilder.immunebuilder_adapter.build_peptide_bonds(st: Structure)

Manually build peptide bonds between residues in a structure to ensure that PrepWizard preserves them.

schrodinger.application.bioluminate.immunebuilder.immunebuilder_adapter.save_and_refine_models(seqs: dict[str, str], model_type: ImmuneBuilderType, dirname: str, filename: str, scheme: AntibodyCDRScheme = None, num_structures_to_save: int = 1) int

Save all structures to files, refine the best-ranked structure, and add error estimates.

Parameters:
  • seqs – A dictionary of sequences to model.

  • model_type – The ImmuneBuilder modeling type.

  • dirname – The directory to save the files.

  • filename – The filename to save the refined structure.

  • scheme – The numbering scheme to use.

  • num_structures_to_save – The number of structures to save.

Returns:

The number of successful models saved.

schrodinger.application.bioluminate.immunebuilder.immunebuilder_adapter.get_refined_filename(dirname: str, filename: str, structure_rank: int = None) str

Get the refined filename given the directory path, filename, and optional structure rank.

Parameters:
  • dirname – path to the directory where the output files will be saved

  • filename – desired output filename

  • structure_rank – the rank of the output file

Returns:

the filename

schrodinger.application.bioluminate.immunebuilder.immunebuilder_adapter.get_all_refined_structures_filename(dirname: str, filename: str) str

Get the filename for all refined structures. :param dirname: path to the directory where the output files will be saved :param filename: desired output filename :return: the filename

schrodinger.application.bioluminate.immunebuilder.immunebuilder_adapter.get_unrefined_filename(dirname: str, filename: str, structure_rank: int = None) str

Get the unrefined filename given the directory path, filename, and optional structure rank.

Parameters:
  • dirname – path to the directory where the output files will be saved

  • filename – desired output filename

  • structure_rank – the rank of the output file

Returns:

the filename

schrodinger.application.bioluminate.immunebuilder.immunebuilder_adapter.get_output_files(dirname: str, filename: str, num_structures: int) list[str]

Get the output files produced by this script.

Parameters:
  • dirname – The directory where the output files will be saved.

  • filename – The filename for which the refined and unrefined filenames will be derived.

  • num_structures – The number of structures to save.

schrodinger.application.bioluminate.immunebuilder.immunebuilder_adapter.merge_refined_structure_files(refined_structure_files: list[str], merged_filename: str)

Merge refined structure files.

Parameters:
  • refined_structure_files – The list of structure files.

  • merged_filename – The filename for the merged files.

schrodinger.application.bioluminate.immunebuilder.immunebuilder_adapter.get_critical_reliability_issues(input_file: str)

Check for critical reliability issues in a structure.

schrodinger.application.bioluminate.immunebuilder.immunebuilder_adapter.get_scheme_for_arg(scheme_arg: str) schrodinger.infra.util.AntibodyCDRScheme | None

Get the antibody CDR scheme based on the provided argument.

schrodinger.application.bioluminate.immunebuilder.immunebuilder_adapter.get_compatible_sequences_from_fasta(fasta_file: str, model_type: ImmuneBuilderType) dict[str, str]
schrodinger.application.bioluminate.immunebuilder.immunebuilder_adapter.get_seqs_from_fasta_file(fasta_file: str) list[str]

Read a FASTA file and return the sequences as a list

schrodinger.application.bioluminate.immunebuilder.immunebuilder_adapter.get_compatible_sequences_dict(sequences: list[str], model_type: ImmuneBuilderType) dict[str, str]

Read a FASTA file and return a dictionary of sequences to model with the provided ImmuneBuilder modeling type

schrodinger.application.bioluminate.immunebuilder.immunebuilder_adapter.parse_immunebuilder_args(model_type: ImmuneBuilderType, program_name: str, description: str, exp_fasta_contents: str, args: list[str], allowed_schemes: list[str] = None) Namespace

Parse command-line arguments for ImmuneBuilder modeling.

Parameters:
  • model_type – The ImmuneBuilder modeling type.

  • program_name – The name of the program.

  • description – The description of the program.

  • exp_fasta_contents – The expected contents of the FASTA file.

  • allowed_schemes – The numbering schemes allowed for the modeling.

  • args – The command-line arguments to parse.

Returns:

The parsed command-line arguments.

class schrodinger.application.bioluminate.immunebuilder.immunebuilder_adapter.ValidateNumStructures(option_strings, dest, nargs=None, const=None, default=None, type=None, choices=None, required=False, help=None, metavar=None)

Bases: Action