-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #78 from i-VRESSE/interactive_apps
Interactive apps
- Loading branch information
Showing
31 changed files
with
3,566 additions
and
1,812 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -23,6 +23,9 @@ moving the input and output files to the right place. To pick where an | |
application should be run you can choose from a list of existing Python | ||
functions or supply your own. | ||
|
||
Bartender can run quick interactive applications on completed jobs. | ||
This is handy if you want to run a quick analysis on the output of a job. | ||
|
||
Bartender can be used as the computational backend for a web application, the | ||
web application should guide visitors into the submission and show the results. | ||
See <https://github.com/i-VRESSE/haddock3-webapp> for an example. | ||
|
@@ -44,17 +47,20 @@ at <https://i-vresse-bartender.readthedocs.io> . | |
curl -o config.yaml https://raw.githubusercontent.com/i-VRESSE/bartender/main/config-example.yaml | ||
``` | ||
|
||
1. In another terminal, start up a database for storing users and jobs. | ||
1. In another terminal, start up a database for storing jobs. | ||
|
||
```bash | ||
docker run \ | ||
-p "5432:5432" \ | ||
-e "POSTGRES_PASSWORD=bartender" \ | ||
-e "POSTGRES_USER=bartender" \ | ||
-e "POSTGRES_DB=bartender" \ | ||
--mount type=volume,source=bartender-db,target=/var/lib/postgresql/data \ | ||
postgres:15.2-bullseye | ||
``` | ||
|
||
(Use `docker volume rm bartender-db` to clear the database storage`) | ||
1. Create tables in the database | ||
```bash | ||
|
@@ -115,11 +121,10 @@ following steps to run a job: | |
4. Use authorize button on top of page to login with username | ||
`[email protected]` and password `string`. | ||
4. Submit archive. | ||
1. Try out the `POST /api/application/{application}/job` route. | ||
2. Use `wc` as application parameter | ||
3. Upload the `README.zip` as request body. | ||
4. Press execute button | ||
5. The response contains a job identifier (`id` property) that can be used | ||
1. Try out the `PUT /api/application/wc/job` route. | ||
2. Upload the `README.zip` as request body. | ||
3. Press execute button | ||
4. The response contains a job identifier (`id` property) that can be used | ||
to fetch the job state. | ||
5. Fetch job state | ||
1. Try out the `GET /api/job/{jobid}` | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,28 +1,133 @@ | ||
destination_picker: bartender.config:pick_first | ||
# Example configuration file for haddock3 and haddock3-re. | ||
# Expects executables to be in PATH, | ||
# if not edit this file to use absolute path to executables | ||
job_root_dir: jobs | ||
destination_picker: bartender.picker:pick_first | ||
applications: | ||
haddock3: | ||
command: haddock3 $config | ||
config: workflow.cfg | ||
command_template: haddock3 workflow.cfg | ||
upload_needs: | ||
- workflow.cfg | ||
# Below are other haddock3 commands, | ||
# that could be hosted by bartender web service. | ||
# TODO add support for label and parameters keys | ||
haddock3-pp: | ||
label: HADDOCK3 preprocess PDB files | ||
command: haddock3-pp --output-directory . *.pdb | ||
haddock3-analyse: | ||
command: haddock3-analyse --run-dir . --modules $modules | ||
parameters: | ||
modules: | ||
type: array | ||
items: | ||
type: int | ||
haddock3-score: | ||
command: haddock3-score --outputpdb --outputpsf $config | ||
config: complex.pdb | ||
# haddock3-pp: | ||
# summary: HADDOCK3 preprocess PDB files | ||
# command_template: haddock3-pp --output-directory . *.pdb | ||
# haddock3-analyse: | ||
# command_template: haddock3-analyse --run-dir . -m {{ modules|q }} | ||
# input_schema: | ||
# additionalProperties: false | ||
# type: object | ||
# properties: | ||
# modules: | ||
# type: string | ||
# description: List of module numbers to analyse. Space separated. | ||
destinations: | ||
local: | ||
scheduler: | ||
type: memory | ||
slots: 1 | ||
filesystem: | ||
type: local | ||
interactive_applications: | ||
rescore: | ||
command_template: > | ||
haddock3-re score | ||
--w_elec {{w_elec|q}} --w_vdw {{w_vdw|q}} --w_desolv {{w_desolv|q}} --w_bsa {{w_bsa|q}} --w_air {{w_air|q}} | ||
{{ capri_dir|q }} | ||
&& | ||
haddock3-analyse --is_cleaned True --inter True -m {{ module_nr|q }} -r output/ | ||
description: Rescore a HADDOCK run with different weights. | ||
job_application: haddock3 | ||
input_schema: | ||
additionalProperties: false | ||
properties: | ||
module_nr: | ||
type: number | ||
capri_dir: | ||
type: string | ||
w_air: | ||
type: number | ||
w_bsa: | ||
type: number | ||
w_desolv: | ||
type: number | ||
w_elec: | ||
type: number | ||
w_vdw: | ||
type: number | ||
required: | ||
- module_nr | ||
- capri_dir | ||
- w_elec | ||
- w_vdw | ||
- w_desolv | ||
- w_bsa | ||
- w_air | ||
type: object | ||
reclustrmsd: | ||
command_template: > | ||
haddock3-re clustrmsd | ||
{% if criterion == 'maxclust' -%} | ||
--n_clusters {{n_clusters|q}} | ||
{% else -%} | ||
--clust_cutoff {{clust_cutoff|q}} | ||
{% endif -%} | ||
{% if min_population -%} | ||
--min_population {{min_population|q}} | ||
{% endif -%} | ||
{{clustrmsd_dir|q}} | ||
&& | ||
haddock3-analyse --is_cleaned True --inter True -m {{ module_nr|q }} -r output/ | ||
description: Recluster a HADDOCK run with RSMD and different parameters. | ||
job_application: haddock3 | ||
input_schema: | ||
additionalProperties: false | ||
properties: | ||
module_nr: | ||
type: number | ||
clustrmsd_dir: | ||
type: string | ||
criterion: | ||
type: string | ||
enum: [maxclust, distance] | ||
clust_cutoff: | ||
type: number | ||
n_clusters: | ||
type: number | ||
min_population: | ||
type: number | ||
required: | ||
- module_nr | ||
- criterion | ||
- clustrmsd_dir | ||
type: object | ||
reclustfcc: | ||
command_template: > | ||
haddock3-re clustfcc | ||
--clust_cutoff {{clust_cutoff|q}} --strictness {{strictness|q}} --min_population {{min_population|q}} | ||
{{clustfcc_dir|q}} | ||
&& | ||
haddock3-analyse --is_cleaned True --inter True -m {{ module_nr|q }} -r output/ | ||
description: Recluster a HADDOCK run with FCC and different parameters. | ||
job_application: haddock3 | ||
input_schema: | ||
additionalProperties: false | ||
properties: | ||
module_nr: | ||
type: number | ||
clustfcc_dir: | ||
type: string | ||
clust_cutoff: | ||
type: number | ||
strictness: | ||
type: number | ||
min_population: | ||
type: number | ||
required: | ||
- module_nr | ||
- clustfcc_dir | ||
- clust_cutoff | ||
- strictness | ||
- min_population | ||
type: object |
Oops, something went wrong.