Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions .github/workflows/docker_build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,11 @@ jobs:
calculate_net_charge, generate_conformers,
mol2_to_pdbqt, nmr4md, openbabel,
remove_terminal_residue_name_prefixes,
rename_residues_mol, combine_structure,
rename_residues, combine_structure,
remove_terminal_residue_name_prefixes, molgan,
pdbbind_refined, onionnet-sfct, smina, pdbfixer,
fix_pdb_atom_column, extract_protein, extract_ligand_protein, generate_conformers] # No username for pdbind_refined
fix_pdb_atom_column, extract_protein, extract_ligand_protein, generate_conformers,
onionnet, combine_pdb] # No username for pdbind_refined
# skip data/ and cwl_adapters/file_format_conversions/biosimspace/
runs-on: [ubuntu-latest]

Expand Down
221 changes: 221 additions & 0 deletions cwl_adapters/autodock_vina.cwl
Original file line number Diff line number Diff line change
@@ -0,0 +1,221 @@

#!/usr/bin/env cwl-runner
cwlVersion: v1.1 # See `loadContents: true` below!

class: CommandLineTool

label: Wrapper of the AutoDock Vina software.

doc: |-
This class performs docking of the ligand to a set of grids describing the target protein via the AutoDock Vina software.

baseCommand: vina # NOTE: Only version >=1.2 supports --batch!
arguments:
# Need to parse box.pdb and pass in each number separately.
# REMARK BOX CENTER: 0.102 0.019 -0.004 SIZE: 30.195 31.940 27.005
# - "--dir" # Need to explicitly pass --dir . in --batch mode
# - "."
- "--center_x"
- $(inputs.input_box_path.contents.split("\n")[0].split(" ").filter(function(s) {return !isNaN(parseFloat(s))})[0])
- "--center_y"
- $(inputs.input_box_path.contents.split("\n")[0].split(" ").filter(function(s) {return !isNaN(parseFloat(s))})[1])
- "--center_z"
- $(inputs.input_box_path.contents.split("\n")[0].split(" ").filter(function(s) {return !isNaN(parseFloat(s))})[2])
- "--size_x"
- $(inputs.input_box_path.contents.split("\n")[0].split(" ").filter(function(s) {return !isNaN(parseFloat(s))})[3])
- "--size_y"
- $(inputs.input_box_path.contents.split("\n")[0].split(" ").filter(function(s) {return !isNaN(parseFloat(s))})[4])
- "--size_z"
- $(inputs.input_box_path.contents.split("\n")[0].split(" ").filter(function(s) {return !isNaN(parseFloat(s))})[5])
# NOTE: Cannot use a single javascript expression to create the entire arguments list because CWL treats it as a string:
# "the `arguments` field is not valid because value is a str"
# ${
# var words = inputs.input_box_path.contents.split("\n")[0].split(" ");
# var nums = words.filter(function(s) {return !isNaN(parseFloat(s))});
# var args = {};
# args.push("--dir"); // Need to explicitly pass --dir . in --batch mode
# args.push(".");
# args.push("--center_x");
# args.push(nums[0]);
# args.push("--center_y");
# args.push(nums[1]);
# args.push("--center_z");
# args.push(nums[2]);
# args.push("--size_x");
# args.push(nums[3]);
# args.push("--size_y");
# args.push(nums[4]);
# args.push("--size_z");
# args.push(nums[5]);
# return args;
# }

hints:
DockerRequirement:
dockerPull: jakefennick/autodock_vina

requirements:
InlineJavascriptRequirement: {}

inputs:
input_ligand_pdbqt_path:
label: Path to the input PDBQT ligand
doc: |-
Path to the input PDBQT ligand
Type: string
File type: input
Accepted formats: pdbqt
Example file: https://github.com/bioexcel/biobb_vs/raw/master/biobb_vs/test/data/vina/vina_ligand.pdbqt
type: File
format:
- edam:format_1476
inputBinding:
prefix: --ligand

input_receptor_pdbqt_path:
label: Path to the input PDBQT receptor
doc: |-
Path to the input PDBQT receptor
Type: string
File type: input
Accepted formats: pdbqt
Example file: https://github.com/bioexcel/biobb_vs/raw/master/biobb_vs/test/data/vina/vina_receptor.pdbqt
type: File
format:
- edam:format_1476
inputBinding:
#position: 2
prefix: --receptor

input_box_path:
label: Path to the PDB containing the residues belonging to the binding site
doc: |-
Path to the PDB containing the residues belonging to the binding site
Type: string
File type: input
Accepted formats: pdb
Example file: https://github.com/bioexcel/biobb_vs/raw/master/biobb_vs/test/data/vina/vina_box.pdb
type: File
format:
- edam:format_1476
# inputBinding:
# position: 3
# prefix: --input_box_path
loadContents: true # requires cwlVersion: v1.1
# See https://www.commonwl.org/v1.1/CommandLineTool.html#Changelog
# Curiously, cwlVersion: v1.0 allows loadContents for outputs, but not inputs.

output_pdbqt_path:
label: Path to the output PDBQT file
doc: |-
Path to the output PDBQT file
Type: string
File type: output
Accepted formats: pdbqt
Example file: https://github.com/bioexcel/biobb_vs/raw/master/biobb_vs/test/reference/vina/ref_output_vina.pdbqt
type: string
format:
- edam:format_1476
inputBinding:
prefix: --out
default: system.pdbqt

output_log_path:
label: Path to the log file
doc: |-
Path to the log file
Type: string
File type: output
Accepted formats: log
Example file: https://github.com/bioexcel/biobb_vs/raw/master/biobb_vs/test/reference/vina/ref_output_vina.log
type: string
format:
- edam:format_2330
default: system.log

cpu:
label: The number of CPUs to use
doc: |-
The number of CPUs to use
Type: int
type: int?
format:
- edam:format_2330
inputBinding:
prefix: --cpu
default: 1

exhaustiveness:
label: exhaustiveness of the global search (roughly proportional to time).
doc: |-
exhaustiveness of the global search (roughly proportional to time).
Type: int
type: int?
format:
- edam:format_2330
inputBinding:
prefix: --exhaustiveness
default: 8

num_modes:
label: maximum number of binding modes to generate
doc: |-
Tmaximum number of binding modes to generate
Type: int
type: int?
format:
- edam:format_2330
inputBinding:
prefix: --num_modes
default: 9

min_rmsd:
label: The minimum RMSD between output poses
doc: |-
The minimum RMSD between output poses
Type: int
type: int?
format:
- edam:format_2330
inputBinding:
prefix: --min_rmsd
default: 1

energy_range:
label: maximum energy difference between the best binding mode and the worst one displayed (kcal/mol).
doc: |-
maximum energy difference between the best binding mode and the worst one displayed (kcal/mol).
Type: int
type: int?
format:
- edam:format_2330
inputBinding:
prefix: --energy_range
default: 3

outputs:
output_pdbqt_path:
label: Path to the output PDBQT file
doc: |-
Path to the output PDBQT file
type: File
outputBinding:
glob: $(inputs.output_pdbqt_path)
format: edam:format_1476

output_log_path:
label: Path to the log file
doc: |-
Path to the log file
type: File
outputBinding:
glob: $(inputs.output_log_path)
format: edam:format_2330

stdout: $(inputs.output_log_path)

$namespaces:
edam: https://edamontology.org/

$schemas:
- https://raw.githubusercontent.com/edamontology/edamontology/master/EDAM_dev.owl
72 changes: 72 additions & 0 deletions cwl_adapters/combine_pdb.cwl
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
#!/usr/bin/env cwl-runner
cwlVersion: v1.0

class: CommandLineTool

label: A tool that employs MDAnalysis to combine two PDB structures in a single PDB file.

doc: |-
A tool that employs MDAnalysis to combine two PDB structures in a single PDB file.

baseCommand: ['python', '/combine_pdb.py']

hints:
DockerRequirement:
dockerPull: ndonyapour/combine_pdb

inputs:
input_structure1:
label: Input PDB structure 1 file path
doc: |-
Input PDB structure 1 file path
Type: string
File type: input
Accepted formats: pdb
type: File
format:
- edam:format_1476
inputBinding:
prefix: --input_structure1

input_structure2:
label: Input PDB structure 2 file path
doc: |-
Input PDB structure 2 file path
Type: string
File type: input
Accepted formats: pdb
type: File
format:
- edam:format_1476
inputBinding:
prefix: --input_structure2

output_structure_path:
label: Output combined PDB file path
doc: |-
Output combined PDB file path
Type: string
File type: output
Accepted formats: pdb
Example file: https://github.com/bioexcel/biobb_structure_utils/raw/master/biobb_structure_utils/test/reference/utils/ref_cat_pdb.pdb
type: string
format:
- edam:format_1476
inputBinding:
prefix: --output_structure_path
default: system.pdb
outputs:
output_structure_path:
label: Output protein file path
doc: |-
Output protein file path
type: File
outputBinding:
glob: $(inputs.output_structure_path)
format: edam:format_1476

$namespaces:
edam: https://edamontology.org/

$schemas:
- https://raw.githubusercontent.com/edamontology/edamontology/master/EDAM_dev.owl
Loading