richardstoeckl/prokanota

prokanota - Flexible pipeline for prokaryotic annotation

Overview

Topics:

Latest release: 1.1.0, Last update: 2025-07-01

Linting: linting: failed, Formatting: formatting: failed

Deployment

Step 1: Install Snakemake and Snakedeploy

Snakemake and Snakedeploy are best installed via the Mamba package manager (a drop-in replacement for conda). If you have neither Conda nor Mamba, it is recommended to install Miniforge. More details regarding Mamba can be found here.

When using Mamba, run

mamba create -c conda-forge -c bioconda --name snakemake snakemake snakedeploy

to install both Snakemake and Snakedeploy in an isolated environment. For all following commands ensure that this environment is activated via

conda activate snakemake

Step 2: Deploy workflow

With Snakemake and Snakedeploy installed, the workflow can be deployed as follows. First, create an appropriate project working directory on your system and enter it:

mkdir -p path/to/project-workdir
cd path/to/project-workdir

In all following steps, we will assume that you are inside of that directory. Then run

snakedeploy deploy-workflow https://github.com/richardstoeckl/prokanota . --tag 1.1.0

Snakedeploy will create two folders, workflow and config. The former contains the deployment of the chosen workflow as a Snakemake module, the latter contains configuration files which will be modified in the next step in order to configure the workflow to your needs.

Step 3: Configure workflow

To configure the workflow, adapt config/config.yml to your needs following the instructions below.

Step 4: Run workflow

The deployment method is controlled using the --software-deployment-method (short --sdm) argument.

To run the workflow with automatic deployment of all required software via conda/mamba, use

snakemake --cores all --sdm conda

Snakemake will automatically detect the main Snakefile in the workflow subfolder and execute the workflow module that has been defined by the deployment in step 2.

For further options such as cluster and cloud execution, see the docs.

Step 5: Generate report

After finalizing your data analysis, you can automatically generate an interactive visual HTML report for inspection of results together with parameters and code inside of the browser using

snakemake --report report.zip

Configuration

The following section is imported from the workflow’s config/README.md.

General configuration

To configure this workflow, modify config/config.yaml and config/metadata.csv according to your needs, following the explanations provided in the file.

Pipeline configuration

To successfully run the annotation pipeline, you will need to configure the paths to the databases and the output directories in the config/config.yaml file.

Sample setup

The sample setup is specified via comma-separated tabular file (.csv). Missing values can be specified by empty columns.

Sample sheet

The default sample sheet is config/metadata.csv (as configured in config/config.yaml). Each row usually corresponds to one genome with the first collumn being the sampleID (Note: The sampleID is used to name the output files and is used to calculate the gene_ids!), and the second column being the path to the genome assembly in FASTA format.

Linting and formatting

Linting results

  1Lints for snakefile /tmp/tmp47pq5vhm/richardstoeckl-prokanota-a6b001a/workflow/rules/parseSearchResults.smk:
  2    * Absolute path "/^#/d" in line 52:
  3      Do not define absolute paths inside of the workflow, since this renders
  4      your workflow irreproducible on other machines. Use path relative to the
  5      working directory instead, or make the path configurable via a config
  6      file.
  7      Also see:
  8      https://snakemake.readthedocs.io/en/latest/snakefiles/configuration.html#configuration
  9    * Absolute path "/^#/d" in line 111:
 10      Do not define absolute paths inside of the workflow, since this renders
 11      your workflow irreproducible on other machines. Use path relative to the
 12      working directory instead, or make the path configurable via a config
 13      file.
 14      Also see:
 15      https://snakemake.readthedocs.io/en/latest/snakefiles/configuration.html#configuration
 16    * Absolute path "/mnt/DATA/common/AnnotateGenomesDBs/arCOG/arCOGdef.tab" in line 140:
 17      Do not define absolute paths inside of the workflow, since this renders
 18      your workflow irreproducible on other machines. Use path relative to the
 19      working directory instead, or make the path configurable via a config
 20      file.
 21      Also see:
 22      https://snakemake.readthedocs.io/en/latest/snakefiles/configuration.html#configuration
 23    * Absolute path "/^#/d" in line 172:
 24      Do not define absolute paths inside of the workflow, since this renders
 25      your workflow irreproducible on other machines. Use path relative to the
 26      working directory instead, or make the path configurable via a config
 27      file.
 28      Also see:
 29      https://snakemake.readthedocs.io/en/latest/snakefiles/configuration.html#configuration
 30    * Absolute path "/^#/d" in line 231:
 31      Do not define absolute paths inside of the workflow, since this renders
 32      your workflow irreproducible on other machines. Use path relative to the
 33      working directory instead, or make the path configurable via a config
 34      file.
 35      Also see:
 36      https://snakemake.readthedocs.io/en/latest/snakefiles/configuration.html#configuration
 37
 38Lints for rule prepareCDDdb (line 30, /tmp/tmp47pq5vhm/richardstoeckl-prokanota-a6b001a/workflow/rules/prepDBs.smk):
 39    * No log directive defined:
 40      Without a log directive, all output will be printed to the terminal. In
 41      distributed environments, this means that errors are harder to discover.
 42      In local environments, output of concurrent jobs will be mixed and become
 43      unreadable.
 44      Also see:
 45      https://snakemake.readthedocs.io/en/stable/snakefiles/rules.html#log-files
 46    * Specify a conda environment or container for each rule.:
 47      This way, the used software for each specific step is documented, and the
 48      workflow can be executed on any machine without prerequisites.
 49      Also see:
 50      https://snakemake.readthedocs.io/en/latest/snakefiles/deployment.html#integrated-package-management
 51      https://snakemake.readthedocs.io/en/latest/snakefiles/deployment.html#running-jobs-in-containers
 52
 53Lints for rule prepareCOGdb (line 70, /tmp/tmp47pq5vhm/richardstoeckl-prokanota-a6b001a/workflow/rules/prepDBs.smk):
 54    * No log directive defined:
 55      Without a log directive, all output will be printed to the terminal. In
 56      distributed environments, this means that errors are harder to discover.
 57      In local environments, output of concurrent jobs will be mixed and become
 58      unreadable.
 59      Also see:
 60      https://snakemake.readthedocs.io/en/stable/snakefiles/rules.html#log-files
 61    * Specify a conda environment or container for each rule.:
 62      This way, the used software for each specific step is documented, and the
 63      workflow can be executed on any machine without prerequisites.
 64      Also see:
 65      https://snakemake.readthedocs.io/en/latest/snakefiles/deployment.html#integrated-package-management
 66      https://snakemake.readthedocs.io/en/latest/snakefiles/deployment.html#running-jobs-in-containers
 67
 68Lints for rule preparePGAPdb (line 108, /tmp/tmp47pq5vhm/richardstoeckl-prokanota-a6b001a/workflow/rules/prepDBs.smk):
 69    * No log directive defined:
 70      Without a log directive, all output will be printed to the terminal. In
 71      distributed environments, this means that errors are harder to discover.
 72      In local environments, output of concurrent jobs will be mixed and become
 73      unreadable.
 74      Also see:
 75      https://snakemake.readthedocs.io/en/stable/snakefiles/rules.html#log-files
 76
 77Lints for rule prepareARCOGdb (line 144, /tmp/tmp47pq5vhm/richardstoeckl-prokanota-a6b001a/workflow/rules/prepDBs.smk):
 78    * Param outdir is a prefix of input or output file but hardcoded:
 79      If this is meant to represent a file path prefix, it will fail when
 80      running workflow in environments without a shared filesystem. Instead,
 81      provide a function that infers the appropriate prefix from the input or
 82      output file, e.g.: lambda w, input: os.path.splitext(input[0])[0]
 83      Also see:
 84      https://snakemake.readthedocs.io/en/stable/snakefiles/rules.html#non-file-parameters-for-rules
 85      https://snakemake.readthedocs.io/en/stable/tutorial/advanced.html#tutorial-input-functions
 86
 87Lints for rule prepareARCOGdbMapping (line 175, /tmp/tmp47pq5vhm/richardstoeckl-prokanota-a6b001a/workflow/rules/prepDBs.smk):
 88    * No log directive defined:
 89      Without a log directive, all output will be printed to the terminal. In
 90      distributed environments, this means that errors are harder to discover.
 91      In local environments, output of concurrent jobs will be mixed and become
 92      unreadable.
 93      Also see:
 94      https://snakemake.readthedocs.io/en/stable/snakefiles/rules.html#log-files
 95
 96Lints for rule collectMasterTable (line 254, /tmp/tmp47pq5vhm/richardstoeckl-prokanota-a6b001a/workflow/rules/parseSearchResults.smk):
 97    * No log directive defined:
 98      Without a log directive, all output will be printed to the terminal. In
 99      distributed environments, this means that errors are harder to discover.
100      In local environments, output of concurrent jobs will be mixed and become
101      unreadable.
102      Also see:
103      https://snakemake.readthedocs.io/en/stable/snakefiles/rules.html#log-files

Formatting results

 1[DEBUG] 
 2[DEBUG] In file "/tmp/tmp47pq5vhm/richardstoeckl-prokanota-a6b001a/workflow/rules/searchDBs.smk":  Formatted content is different from original
 3[DEBUG] 
 4[DEBUG] In file "/tmp/tmp47pq5vhm/richardstoeckl-prokanota-a6b001a/workflow/rules/parseSearchResults.smk":  Formatted content is different from original
 5[DEBUG] 
 6[DEBUG] In file "/tmp/tmp47pq5vhm/richardstoeckl-prokanota-a6b001a/workflow/rules/prepProteins.smk":  Formatted content is different from original
 7[DEBUG] 
 8[DEBUG] In file "/tmp/tmp47pq5vhm/richardstoeckl-prokanota-a6b001a/workflow/Snakefile":  Formatted content is different from original
 9[DEBUG] 
10[WARNING] In file "/tmp/tmp47pq5vhm/richardstoeckl-prokanota-a6b001a/workflow/rules/prepDBs.smk":  Keyword "output" at line 156 has comments under a value.
11	PEP8 recommends block comments appear before what they describe
12(see https://www.python.org/dev/peps/pep-0008/#id30)
13[DEBUG] In file "/tmp/tmp47pq5vhm/richardstoeckl-prokanota-a6b001a/workflow/rules/prepDBs.smk":  Formatted content is different from original
14[INFO] 5 file(s) would be changed 😬
15
16snakefmt version: 0.11.0