deeporigin.drug_discovery.docking¶
This module encapsulates methods to run docking and show docking results on Deep Origin
Attributes¶
Classes¶
Docking
¶
Bases: WorkflowStep
class to handle Docking-related tasks within the Complex class.
Objects instantiated here are meant to be used within the Complex class.
Attributes¶
Functions¶
get_jobs_df
¶
get_jobs_df(
*,
pocket_center: Optional[
tuple[Number, Number, Number] | list[Number]
] = None,
box_size: Optional[
tuple[Number, Number, Number] | list[Number]
] = None
)
search for all jobs that match this protein and ligands in the Job DB, and return a dataframe of the results
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
pocket_center
|
Optional[tuple[Number, Number, Number] | list[Number]]
|
Optional tuple of (x, y, z) coordinates to filter by pocket center |
None
|
box_size
|
Optional[tuple[Number, Number, Number] | list[Number]]
|
Optional tuple of (x, y, z) dimensions to filter by box size |
None
|
get_results
¶
get_results(
*, file_type: Literal["csv", "sdf"] = "csv"
) -> DataFrame | None | list[str]
return a list of paths to CSV and SDF files that contain the results from docking
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
file_type
|
str
|
"csv" or "sdf". Defaults to "csv". |
'csv'
|
Returns:
| Type | Description |
|---|---|
DataFrame | None | list[str]
|
pd.DataFrame | None | list[str]: DataFrame of results, None if no results found, or list of file paths. |
run
¶
run(
*,
pocket: Optional[Pocket] = None,
box_size: Optional[
tuple[Number, Number, Number]
] = None,
pocket_center: Optional[
tuple[Number, Number, Number]
] = None,
batch_size: Optional[int] = 32,
n_workers: Optional[int] = None,
output_dir_path: Optional[str] = None,
use_parallel: bool = True,
approve_amount: Optional[int] = None,
quote: bool = False,
re_run: bool = False
) -> JobList | None
Run bulk docking on Deep Origin. Ligands will be split into batches based on the batch_size argument, and will run in parallel on Deep Origin clusters.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
pocket
|
Pocket
|
pocket object. This can be generated using the pocket finder function. |
None
|
box_size
|
tuple[float, float, float]
|
box size |
None
|
pocket_center
|
tuple[float, float, float]
|
pocket center |
None
|
batch_size
|
int
|
batch size. Defaults to 30. |
32
|
n_workers
|
int
|
number of workers. Defaults to None. |
None
|
output_dir_path
|
str
|
path to output directory. Defaults to None. |
None
|
use_parallel
|
bool
|
whether to run jobs in parallel. Defaults to True. |
True
|
approve_amount
|
int
|
amount to approve for the jobs. Defaults to None. |
None
|
quote
|
bool
|
whether to request a quote for the jobs. Defaults to False. |
False
|
re_run
|
bool
|
whether to re-run jobs. Defaults to False. |
False
|
Returns:
| Name | Type | Description |
|---|---|---|
JobList |
JobList | None
|
A JobList containing all the created docking jobs. |
show_results
¶
show_results()
show results of bulk Docking run in a table, rendering 2D structures of molecules