Skip to content

ABFE

This reference page provides information on function signature for every function in the ABFE module.

src.tools.abfe

this module contains various functions to run steps of an ABFE workflow

Attributes

integrators module-attribute

integrators = Literal[
    "BAOABIntegrator",
    "LangevinIntegrator",
    "SteepestDescentMinimizer",
    "LeapFrogIntegrator",
    "SoluteSolventSplittingIntegrator",
]

Integrator available for simulation

force_fields module-attribute

force_fields = Literal['ff14SB', 'ff99SB-ildn']

Available force fields

charge_methods module-attribute

charge_methods = Literal['gas', 'bcc']

Available charge methods

Functions

init

init(*, ligand_file: str, protein_file: str) -> str

Initialize an ABFE run. Upload ligand and protein files to Data Hub.

complex_prep

complex_prep(
    row_id: str,
    *,
    keep_waters: bool = True,
    save_gmx_files: bool = False,
    is_lig_protonated: bool = True,
    is_protein_protonated: bool = True,
    do_loop_modelling: bool = False,
    charge_method: charge_methods = "bcc",
    lig_force_field: ligand_force_fields = "gaff2",
    padding: float = 1.0,
    system_name: str = "complex",
    force_field: force_fields = "ff14SB"
) -> None

Function to prepare uploaded Ligand and protein files using Deep Origin MDSuite. Use this function to run system prep on a ligand and protein pair, that exist as files on a row in the ABFE database.

Parameters:

Name Type Description Default
row_id str

row id that contains the ligand and protein files.

required
keep_waters bool

whether to keep water molecules in the system. Defaults to True.

True
save_gmx_files bool

whether to save gmx files. Defaults to False.

False
is_lig_protonated bool

whether the ligand is protonated. Defaults to True.

True
is_protein_protonated bool

whether the protein is protonated. Defaults to True.

True
do_loop_modelling bool

whether to do loop modelling. Defaults to False.

False
charge_method str

method to use for charge assignment. Defaults to "bcc".

'bcc'
lig_force_field str

ligand force field. Defaults to "gaff2".

'gaff2'
padding float

padding to use. Defaults to 1.0.

1.0
force_field str

force field. Defaults to "ff14SB".

'ff14SB'
system_name str

name of the system. Defaults to "complex". This name can be anything.

'complex'

emeq

emeq(
    row_id: str,
    *,
    system_name: str = "complex",
    fourier_spacing: float = 0.12,
    hydrogen_mass: int = 2,
    cutoff: float = 0.9,
    T: float = 298.15,
    Δt: float = 0.004,
    npt_reduce_restraints_ns: float = 0.2,
    nvt_heating_ns: float = 0.1
) -> None

Run emeq on a ligand and protein pair, that exist as files on a row in the ABFE database. For this to work, the complex prep step must have been run first.

Parameters:

Name Type Description Default
row_id str

row id that contains the ligand and protein files.

required
system_name str

name of the system. Defaults to "complex". This name can be anything.

'complex'
fourier_spacing float

spacing of the fourier grid. Defaults to 0.12.

0.12
hydrogen_mass int

hydrogen mass. Defaults to 2.

2
cutoff float

cutoff. Defaults to 0.9.

0.9
T float

temperature. Defaults to 298.15.

298.15
Δt float

time step. Defaults to 0.004.

0.004
npt_reduce_restraints_ns float

time step. Defaults to 0.2.

0.2
nvt_heating_ns float

time step. Defaults to 0.1.

0.1

solvation_prep

solvation_prep(
    row_id: str,
    *,
    is_lig_protonated: bool = True,
    charge_method: charge_methods = "bcc",
    lig_force_field: ligand_force_fields = "gaff2",
    system_name: str = "ligand_prep",
    force_field: force_fields = "ff14SB"
) -> None

Function to prepare uploaded Ligand and protein files using Deep Origin MDSuite. Use this function to run system prep on a ligand and protein pair, that exist as files on a row in the ABFE database.

Parameters:

Name Type Description Default
row_id str

row id that contains the ligand and protein files.

required
is_lig_protonated bool

whether the ligand is protonated. Defaults to True.

True
charge_method str

method to use for charge assignment. Defaults to "bcc".

'bcc'
lig_force_field str

ligand force field. Defaults to "gaff2".

'gaff2'
system_name str

name of the system. Defaults to "ligand_prep". This name can be anything.

'ligand_prep'
force_field str

force field. Defaults to "ff14SB".

'ff14SB'

solvation_fep

solvation_fep(
    row_id: str,
    *,
    integrator: integrators = "BAOABIntegrator",
    softcore_alpha: float = 0.5,
    steps: int = 300000,
    repeats: int = 1,
    threads: int = 0,
    annihilate: bool = True,
    hydrogen_mass: int = 2,
    T: float = 298.15
) -> None

Run a solvation simulation

Parameters:

Name Type Description Default
row_id str

row id of the ligand and protein files.

required
integrator integrators

integrator. Defaults to "BAOABIntegrator".

'BAOABIntegrator'
softcore_alpha float

softcore alpha. Defaults to 0.5.

0.5
steps int

The number of steps to run the simulation for the prod step.

300000
repeats int

The number of repeats for prod step.

1
threads int

The number of threads per worker. By default the number of threads will be determined by the number of windows and available cores on the CPU. Defaults to 0.

0
annihilate bool

Whether to annihilate the ligand or decouple it. Defaults to True.

True

simple_md

simple_md(
    row_id: str,
    *,
    integrator: integrators = "BAOABIntegrator",
    run_name: str = "complex_1ns_md",
    steps: int = 250000,
    threads: int = 0,
    Δt: float = 0.004,
    temperature: float = 298.15,
    cutoff: float = 0.9,
    fourier_spacing: float = 0.12
)

Run a simple MD simulation

Parameters:

Name Type Description Default
row_id str

row id of the ligand and protein files.

required
integrator integrators

integrator. Defaults to "BAOABIntegrator".

'BAOABIntegrator'
run_name str

run name. Defaults to "complex_1ns_md".

'complex_1ns_md'
steps int

The number of steps to run the simulation for the prod step.

250000
threads int

The number of threads per worker. By default the number of threads will be determined by the number of windows and available cores on the CPU. Defaults to 0.

0
Δt float

The time step in femtoseconds. Defaults to 0.004.

0.004
temperature float

The temperature in kelvin. Defaults to 298.15.

298.15
cutoff float

The cutoff distance in angstroms. Defaults to 0.9.

0.9
fourier_spacing float

The Fourier spacing in femtoseconds. Defaults to 0.12.

0.12

binding_fep

binding_fep(
    row_id,
    *,
    run_name: str = "annihilation_fep",
    softcore_alpha: float = 0.5,
    annihilate: bool = True,
    em_solvent: bool = True,
    em_all: bool = True,
    nvt_heating_ns: int = 1,
    npt_reduce_restraints_ns: int = 2,
    steps: int = 1250000,
    repeats: int = 1,
    threads: int = 0,
    integrator: integrators = "BAOABIntegrator",
    Δt: float = 0.004,
    T: float = 298.15
)

Run an ABFE simulation

Parameters:

Name Type Description Default
row_id str

row id of the ligand and protein files.

required
run_name str

run name. Defaults to "annihilation_fep".

'annihilation_fep'
softcore_alpha float

softcore alpha. Defaults to 0.5.

0.5
annihilate bool

Whether to annihilate the ligand or decouple it. Defaults to True.

True
em_solvent bool

Whether to use em solvent. Defaults to True.

True
em_all bool

Whether to use em all. Defaults to True.

True
nvt_heating_ns int

The number of nvt heating steps. Defaults to 1.

1
npt_reduce_restraints_ns int

The number of npt reduce restraints steps. Defaults to 2.

2
steps int

The number of steps to run the simulation for the prod step.

1250000
threads int

The number of threads per worker. By default the number of threads will be determined by the number of windows and available cores on the CPU. Defaults to 0.

0
integrator integrators

integrator. Defaults to "BAOABIntegrator".

'BAOABIntegrator'
Δt float

The time step in femtoseconds. Defaults to 0.004.

0.004
T float

The temperature in kelvin. Defaults to 298.15.

298.15