Skip to content

Commit

Permalink
Feature jobs update (#108)
Browse files Browse the repository at this point in the history
* start updating jebs

* pipeline previously jobs page updated

* remove old jobs page

* add anchors for links from pipeline page

* add anchors for the pipeline page
  • Loading branch information
vestalisvirginis authored Jul 25, 2024
1 parent 1284e29 commit c1dc89c
Show file tree
Hide file tree
Showing 38 changed files with 417 additions and 222 deletions.
1 change: 1 addition & 0 deletions docs/configurations.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

Using Dagster to run synphage pipeline allows the user to easily configure the jobs at run-time.

<a id="dir-config"></a>

## Plotting config options

Expand Down
3 changes: 3 additions & 0 deletions docs/images/pipeline/Job_step_1a_get_user_data.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions docs/images/pipeline/Job_step_1b_download.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions docs/images/pipeline/Job_step_2_make_validation.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions docs/images/pipeline/Job_step_2_make_validation_reloads.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions docs/images/pipeline/Job_step_3a_make_blastn.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions docs/images/pipeline/Job_step_3b_make_blastp.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions docs/images/pipeline/Job_step_3c_make_all_blast.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions docs/images/pipeline/Job_step_4_make_plot.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/images/pipeline/dag_jobs.png
Binary file added docs/images/pipeline/dag_landing_page.png
Binary file added docs/images/pipeline/navigating_job_logs.png
Binary file added docs/images/pipeline/navigating_left_panel.png
Binary file added docs/images/pipeline/step1b_launchpad.png
Binary file added docs/images/pipeline/step1b_open_launchpad.png
19 changes: 9 additions & 10 deletions docs/installation.md
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ pip install --upgrade pip

2. Data Input and Output

1. Data Input
1. Data Input <a id="data_input_pip"></a>

The input data are the GenBank files located in the `INPUT_DIR`. However paths to other data location can be passed at run time for loading data from another directory.

Expand All @@ -135,7 +135,7 @@ pip install --upgrade pip
`.gb`and `.gbk` are both valid extension for genbank files


2. Data Output
2. Data Output <a id="data_output_pip"></a>

All output data are located in the `OUTPUT_DIR` set by the user.
This directory can be reused in future runs if the user needs to process additional sequences or simply generate additional synteny diagrams.
Expand All @@ -147,7 +147,7 @@ pip install --upgrade pip


???+ tip
The current data directory can be checked in the [config panel](jobs.md#dir-config) of the jobs.
The current data directory can be checked in the [config panel](pipeline.md#dir-config) of the jobs.


3. Start synphage via dagster web-based interface
Expand Down Expand Up @@ -243,7 +243,6 @@ The following dependency needs to be installed in order to run synphage Docker I

### Run `synphage` container <a id="run-synphage-container"></a>

#### Start the container

=== ":simple-docker: Docker Desktop"
1. Start the container
Expand All @@ -266,7 +265,7 @@ The following dependency needs to be installed in order to run synphage Docker I

4. Set the `Volumes`

1. Data Output
1. Data Output <a id="data_output_dd"></a>
All output data are located in the `/data` directory of the container.
The output data can be copied after the run from the `/data` folder or they can be stored in a `Docker Volume` that can be mounted to a new Docker Container and reused in subsequent runs if the user needs to process additional sequences or simply generate additional synteny diagrams.

Expand All @@ -293,7 +292,7 @@ The following dependency needs to be installed in order to run synphage Docker I
If no Volume is mounted to the /data directory and the user do not save the data, data will be lost.


5. Set the environment variables (optional)
5. Set the environment variables (optional) <a id="env_dockerdesktop"></a>
`synphage` uses the following environment variables:
- `EMAIL` (optional): for connecting to the NCBI database.
- `API_KEY` (optional): for connecting to the NCBI database and download files.
Expand All @@ -309,7 +308,7 @@ The following dependency needs to be installed in order to run synphage Docker I
Your container is now running.


7. Import local GenBank files (optional)
7. Import local GenBank files (optional) <a id="data_input_dockerdesktop"></a>
`/user_files` is the directory that received users' GenBank files.
For using locally stored GenBank files, the files can be imported or dragged and dropped (depending on your system) into the `/user_files` directory.
Expand Down Expand Up @@ -340,7 +339,7 @@ The following dependency needs to be installed in order to run synphage Docker I
=== ":octicons-terminal-16: Bash"
1. Environment variables
1. Environment variables <a id="env_docker"></a>
`synphage` uses the following environment variables:
- `EMAIL` (optional): for connecting to the NCBI database.
Expand Down Expand Up @@ -384,7 +383,7 @@ The following dependency needs to be installed in order to run synphage Docker I
3. Set the `Volumes`
1. Data Output
1. Data Output <a id="data_output_docker"></a>
All output data are located in the `/data` directory of the container.
The output data can be copied after the run from the `/data` folder or they can be stored in a `Docker Volume` that can be mounted to a new Docker Container and reused in subsequent run if the user needs to process additional sequences or simply generate additional synteny diagrams.
Expand Down Expand Up @@ -423,7 +422,7 @@ The following dependency needs to be installed in order to run synphage Docker I
Volume names must be unique. You canot set two volumes wit the same name.
1. Import local GenBank files (optional)
1. Import local GenBank files (optional) <a id="data_input_docker"></a>
`/user_files` is the directory that received users GenBank files.
For using locally stored GenBank files, the files can be copied into the `/user_files` directory.
```bash
Expand Down
204 changes: 0 additions & 204 deletions docs/jobs.md

This file was deleted.

39 changes: 39 additions & 0 deletions docs/output.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
# Synphage output data

All the data generated during synphage runs are stored in the data directory. (see Data Output setup for [pip](installation.md#data_output_pip), [docker desktop](installation.md#data_output_dd) or [docker](installation.md#data_output_docker) users)

synphage's output consists of four to six main parquet files (depending if blastn and blastp were both executed) and the synteny graphic. However all the data generated by the synphage pipeline are made available in your data directory.


## Generated data architecture

The folders and files are organised as follow inside the `data directory`:

```
.
├── <path_to_synphage_folder>/
│ ├── download/
│ ├── fs/
│ ├── genbank/
│ ├── gene_identity/
│ │ ├── fasta_n/
│ │ ├── blastn_database/
│ │ └── blastn/
│ ├── protein_identity/
│ │ ├── fasta_p/
│ │ ├── blastp_database/
│ │ └── blastp/
│ ├── tables/
│ │ ├── genbank_db.parquet
│ │ ├── processed_genbank_df.parquet
│ │ ├── blastn_summary.parquet
│ │ ├── blastp_summary.parquet
│ │ ├── gene_uniqueness.parquet
│ │ └── protein_uniqueness.parquet
│ ├── sequences.csv
│ └── synteny/
│ ├── colour_table.parquet
│ ├── synteny_graph.png
│ └── synteny_graph.svg
└── ...
```
14 changes: 7 additions & 7 deletions docs/phages.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,20 +21,20 @@ To get familiar with `synphage` capabilities, you can reproduce the step-by-step
pip install synphage
dagster dev -h 0.0.0.0 -p 3000 -m synphage
```
For more details, see [installation instruction](https://vestalisvirginis.github.io/synphage/installation/#via-pip) or [how to run the software](https://vestalisvirginis.github.io/synphage/installation/#pull-synphage-image).
For more details, see [installation instruction](installation.md#pip-install) or [how to run the software](installation.md/#run-synphage-pip).
=== "docker"
``` bash
docker pull vestalisvirginis/synphage:<tag>
docker run --rm --name my-synphage-container -p 3000 vestalisvirginis/synphage:<tag>
```
For more details, see [installation instruction](https://vestalisvirginis.github.io/synphage/installation/#via-docker) or [how to run the software](https://vestalisvirginis.github.io/synphage/installation/#pull-synphage-image).
For more details, see [installation instruction](installation.md/#docker-install) or [how to run the software](installation.md/#run-synphage-container).
=== "Docker Desktop"
<iframe width="560" height="315"
src="../images/phages/docker_desktop_movie.mp4"
frameborder="0"
allow="accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture"
allowfullscreen></iframe>
For more details, see [installation instruction](https://vestalisvirginis.github.io/synphage/installation/#via-docker) or [how to run the software](https://vestalisvirginis.github.io/synphage/installation/#pull-synphage-image).
For more details, see [installation instruction](installation.md/#docker-install) or [how to run the software](installation.md/#run-synphage-container).


<figure markdown="span">
Expand Down Expand Up @@ -102,10 +102,10 @@ When the job finishes its execution, we can move to `step 2` to run the validati
</figure>


### Step 2: Run data quality checks on the dataset
### Step 2: Run data quality checks on the dataset <a id="step2-phage-example"></a>

???+ note
For more detailed information on this step, check the [Validation](jobs.md#step2-validation-job).
For more detailed information on this step, check the [Validation](pipeline.md#step2-validation-job).

Go to Dagster_home -> Jobs -> make_validations.
<figure markdown="span">
Expand Down Expand Up @@ -144,7 +144,7 @@ The metadata attached to the last step of the validation, render an overview of
</figure>


### Step 3: Run the blast
### Step 3: Run the blast <a id="step3-phage-example"></a>

For this example, blastn was run on the dataset.

Expand Down Expand Up @@ -224,7 +224,7 @@ This file can be read and manipulated with any DataFrame API the user choose, su
The unified dataset generated through the blastp pipeline is saved under `protein_uniqueness.parquet`.


### Step 4: Generate the plot
### Step 4: Generate the plot <a id="step4-phage-example"></a>

Go to Dagster_home -> Jobs -> make_plot
<figure markdown="span">
Expand Down
Loading

0 comments on commit c1dc89c

Please sign in to comment.