Vfvs_prepare_newcollections.sh does not create input that works with VFVS

Hello all,

I have been trying to create input files that work with VFVS from a custom selection of ready-to-dock ligands for several weeks, but I cannot get any combination of tar/gzip to create folders/archives that will be accepted by VFVS.

Tranches downloaded from the REAL library work fine every time. My custom selection works with Vina on my local computer when I test a handful, so my configuration files and ligands are good to go.

I have tried using vfvs_prepare_newcollections.sh and vfvs_prepare_newcollections2.sh plus three other versions that I have modified to build the folders in slightly different ways. I have also tried to create the folders by doing each archiving/zipping step individually in the terminal. I have tried tar and gtar. I have tried doing these steps on my linux VM (vs. on Mac OSX). I have also tried unpacking and then repacking a tranche downloaded from the REAL library to ensure that my .pdbqt, all.ctrl, and todo.all files are not the problem. Nothing I’ve tried results in archives/folders that are accepted by VFVS.

Has anyone been able to use a custom library with VFVS successfully? I do not need the full VFLP process since I can’t use it anyway (no ChemAxon license) and all preparation can be done with open babel and MGLTools scripts locally (albeit much more slowly than using SLURM).

I just need to pack my ligands. If I figure it out, I’ll comment my solution in case it will help someone else.

My Directory Structure:

Folders (ex. AA)
-contains AABBCC.tar, etc.
Tar archives (ex. AABBCC.tar)
-contains 00000.tar.gz, etc.
-created with “tar -cvf AABBCC.tar 00000.tar.gz …” or a vfvs_prepare_newcollections*.sh script
Tar.gz archives (ex. 00000.tar.gz)
-contains ligands
-created with “tar -czvf 00000.tar.gz ligand.pdbqt …” or a vfvs_prepare_newcollections*.sh script
Text files (ex. ligand1.pdbqt)
prepared ligands files w/ open babel and MGLTools scripts

Some of the Errors:

workflow/output-files/jobs/

The ligand-collections/todo/todo.all (if existent) did not meet the requirements for continuation (trial 3)

error_response_std 187
echo ‘Error was trapped’
Error was trapped
++ basename /home/audmhugh/VirtualFlow/VFVS-develop/tools/…/workflow/job-files/sub/one-step.sh
echo ‘Error in bash script one-step.sh’
Error in bash script one-step.sh
echo ‘Error on line 187’
Error on line 187
srun: error: g1-compute-0-0: task 0: Exited with exit code 1

error_response_std 314
echo ‘Error was trapped’
Error was trapped
echo ‘Error in bash script /var/spool/slurmd/job00047/slurm_script’
Error in bash script /var/spool/slurmd/job00047/slurm_script
echo ‘Error on line 314’
Error on line 314

workflow/output-files/queues/

Error: The ligand collection ZZAAHH_00001 could not be prepared.
++ error_response_std 387
++ echo ‘Error was trapped’
Error was trapped
+++ basename …/workflow/job-files/sub/one-queue.sh
++ echo ‘Error in bash script one-queue.sh’
Error in bash script one-queue.sh
++ echo ‘Error on line 387’
Error on line 387

After many hours of work… SOLVED! I couldn’t get any of the VFTools scripts to work. Mine is not an elegant solution, but it works. Because I am not experienced at looping scripts (or whatever is required for this method to look nicer), I used the CONCATENATE function in excel to:

  • Create a script that would build my starting folders systematically and put the right ligands into each folder
  • Create the pack.sh script

NOTE: Mac OSX creates a bunch of duplicate “._” type files when archiving/zipping, and those VFVS attempts failed for me, so try to do everything listed below on a linux VM. I don’t know if PCs have this problem.

1. First move your (ready-to-dock) ligands into folders organized like the example below. Folder structure before archiving/zipping:

WORKING_DIRECTORY 			## I suggest making a folder just for these archiving steps
 ├─ pack.sh 				## this script is described below
 ├─ AA 						## empty folder, this is where the final products will end up
 ├─ AAAAAA_0 				## folder
 │   └─ 00000 				## folder
 │       ├─ ligand1.pdbqt 	## your ligands
 │       ├─ ligand2.pdbqt
 │       └─ ligand3.pdbqt
 ├─ AAAAAB_0
 │   └─ 00000
 │       ├─ ligand4.pdbqt
 │       ├─ ligand5.pdbqt
 │       └─ ligand6.pdbqt
 └─ AAAAAC_0
     └─ 00000
         ├─ ligand7.pdbqt
         ├─ ligand8.pdbqt
         └─ ligand9.pdbqt

2. Create the pack.sh script and place it in your WORKING_DIRECTORY. Contents of the file pack.sh:

cd AAAAAA_0 				## this first line is different, excludes "../"
mkdir AAAAAA
tar -cf 00000.tar 00000/*.pdbqt
gzip 00000.tar
cp 00000.tar.gz AAAAAA
tar -cf AAAAAA.tar AAAAAA
cp AAAAAA.tar ../AA

cd ../AAAAAB_0
mkdir AAAAAB
tar -cf 00000.tar 00000/*.pdbqt
gzip 00000.tar
cp 00000.tar.gz AAAAAB
tar -cf AAAAAB.tar AAAAAB
cp AAAAAB.tar ../AA

cd ../AAAAAC_0
mkdir AAAAAC
tar -cf 00000.tar 00000/*.pdbqt
gzip 00000.tar
cp 00000.tar.gz AAAAAC
tar -cf AAAAAC.tar AAAAAC
cp AAAAAC.tar ../AA

3. In the terminal:

cd ~/WORKING_DIRECTORY
sh pack.sh

4. Now you can move your AA folder to the ligand-library in VFVS. Create a collections.txt file formatted similar to:

AAAAAA_00000 3
AAAAAB_00000 3
AAAAAC_00000 3

P.S. If anyone is interested in the scripts I used to prep my ligands using Open Babel and MGLTools, let me know. I know not everyone will have access to ChemAxon. :slight_smile: