This package provides the function run_lrip(**kwargs), which enables you to directly run the LRIP scoring function. All the modules in the package are presented as APIs. Users can customize scoring functions themselves or link the LRIP to their programs.
To run the lrip_py package, please install AMBER molecular dynamics with version >= 24. Then make sure you can execute the following from the command line:
antechamberpmemdsanderparmchk2pmemd.MPIpmemd.cuda
Schrodinger Maestro should also be installed before using this package for molecular docking. SCHRODINGER and AMBERHOME system variables should be set properly.
- Download the code
git clone git@github.com:nnnty/ipsf_py.git
cd ipsf_py
conda create -n <replace with your environment name> python=3.12
pip install .- After finished successfully, try to import the module lrip_py in another directory which is different from the ipsf_py/ directory:
import lrip_py
This import behavior should not return any thing if lrip_py was successfully installed.
Python script for running a job:
import lrip_py
lrip_py.run_lrip('<path of a ligands list file,str>',
'<path of a configuration JSON file,str>',
'<path of the directory contains the ligands structure file,str>',
'<Glide grid file (.zip),str>',
'<job type key word,str>',
'<path of the experimental values file,str>',
log_file="<log file,str>",
over_write=<If the log file will be overwirtten, bool>,
)This file must contain ligand names as the first column. We highly recommend providing the net charge for each ligand. For example:
<name1>,<net charge>
{
"job_root": "<job name>",
"lig_format": "<ligand structure files format, .mol2 format is highly recommended>",
"receptor_path": "<receptor structure file, must be PDB format>",
"num_mpi": "<MPI option for the jobs. Could be int or str. If an int is given, the MD will be run through pmemd.MPI. If a cuda str is given, the MD will be performed by pmemd.cuda.>"
}train: Train 7 different ML models using experimental data provided.pred: Load the pre-trained ML model to make predictions. For this type, the configuration JSON must include amodel_root_pathkeyword pointing to the directory storing the pre-trained model.bs: Perform bootstrap train-validation 10 times (default). This will write severalevaluation_ML_<i>.csvfiles to<execution directory>/<job name>/BS/. Each file contains statistical metrics for each ML model. The model order is described inMODEL_LIST.csvin the same directory.
This file (provided as the first argument to lrip_py.run_lrip()) must contain two key columns: ID and exp, separated by commas. Example:
ID,<other columns>,exp,<more columns>
<name1>,<...>,<value1>,<...>
<name2>,<...>,<value2>,<...>
- Each ligand's structural file must have the same name as listed in the ligands list file. For example, if the list includes
lig1, then a structural file namedlig1.mol2must be present. - Receptor PDB files must end with a TER line.。Although the package provides simple handling of PDB files, it is highly recommended to manually preprocess them.
- The ligand name in the mol2 file (i.e., the first line under @MOLECULE) must exactly match the name in the ligands list.
- Ligands containing iodine atoms are not supported. Please remove such ligands in advance.