software:topical:lifescience:vina

Screening the binding of Lingands with Autodock Vina

Screening / docking lingand binding with Autodock Vina can be done one molecule at a time. We provide a module bio/AutoDock_Vina/1).

To leverage the task from 1 (or a few) ligands to be screened to several thousand, we provide a wrapper script, which is available as a module:

bio/parallel_Vina

The code is under version management and hosted internally, here.

The wrapper script will submit a job, it is not intended to be just within a SLURM environment, but rather creates one.

Calling parallel_Vina -h will display a help message with all the options, the script provides. Likewise the call parallel_Vina –credits will display credits and a version history.

The Vina configuration file is important. Without it or with a minor glitch in it, Vina will either refuse to run or might not yield meaningful results. We therefore strongly encourage to run a couple of screenings (different ligands / receptors) per configuration on a login node before launching the wrapper script and producing zillions of error messages whilst wasting time and your productivity.

The script, after loading the module, can then be run like:

$ parall_Vina [options] -C <path to configuration file> <path to ligand directory> <path to pdbqt file>

About Arguments:

  • both, the ligand directory and the path to the pdbqt file, are mandatory
  • both can be relative paths
  • the ligand directory should contain one ligand per file
  • -C,–configfile is a mandatory flag and supposed to be a (relative) path to the configuration file

The options:

  • parallel_Vina attempts to deduce your SLURM account. This may fail, in which case -A, –account needs to be supplied.
  • -N,–nodes allows to reserve more than 1 node (the default). This may speed up the screening. A good rule of thumb is to divide the number of ligands by 64 * the number of nodes. This should yield number in the range of 10 (greater than 4, smaller than 12).
  • -l,–runlimit, this defaults to 300 minutes. If > 300 the partition will automatically be switched to nodelong
  • -p,–partition, the default is nodeshort, no smp-partition should be choosen.
  • -t,–threads, Vina can work in parallel. Please consult the manual. The default is 1.
  • -o,–outdir output directory path (default is the current working directory)
  • –timeout sometimes Vina does not converge, in which case it might be sensible to define a timeout (in seconds), to abort individual Vina runs, such that other ligands can be screened.

The output will be in the output directory. There will be 3 files:

  • the SLURM output with a prefix composed of the ligand prefix and the target prefix.
  • a file called energies.csv – results will be written listing the ligand prefix, the target prefix, the affinity of the first Vina output entry, as well as the connected rmsd-values and a time stamp. In case no result was retrieved, the respective rows contain NA,NA,NA.
  • a compressed tarball with all vina results, called docking_results.tar.gz

The energies.csv file allows for quick sorting and filtering, e.g. to retrieve the 10 best hits:

$ sort -k3 -t',' -r energies.csv |grep -v NA| head

Particular hits can be extracted from the tar file:

$ tar -zxvf docking_results.tar.gz <desired prefix>.pdbqt

where the “desired prefix” is the one listed in the energies.csv or a downstream analysis as shown.

For a downstream analysis with our AutoDock wrapper, you can use something like the following snippet (or a more sophisticated selection scheme). Be sure that you replace the '-n12' with the desired molecule count. You could also apply an affinity threshold:

$ # we assume a new directory for autodock ligands
$ autodock_ligand_dir="some_path"
$ # this is where our ligands, screened with Vina, are stored
$ vina_ligand_dir="some_path"
$ # link the best n-results to the new Autodock input directory location:
$ for prefix in $(tail -n+2 energies.csv| sort -k3 -t',' -r |grep -v NA| head -n12 |cut -f1 -d',' ); do
> ln -s ${vina_ligand_dir}/${prefix}.pdbqt ${autodock_ligand_dir}/${prefix}.pdbqt
> done

1)
As always the version information is omitted. Just loading the module will load the most current version.
  • software/topical/lifescience/vina.txt
  • Last modified: 2018/08/24 08:33
  • by meesters