mdondrup/divergence_time

None

Overview

Topics:

Latest release: None, Last update: 2025-05-31

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/mdondrup/divergence_time . --tag None

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.

Describe how to configure the workflow (using config.yaml and maybe additional files). All of them need to be present with example entries inside of the config folder.

Linting and formatting

Linting results

 1Lints for snakefile /tmp/tmpc66vlp8m/workflow/Snakefile:
 2    * Absolute path "/|" in line 129:
 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    * Path composition with '+' in line 24:
10      This becomes quickly unreadable. Usually, it is better to endure some
11      redundancy against having a more readable workflow. Hence, just repeat
12      common prefixes. If path composition is unavoidable, use pathlib or
13      (python >= 3.6) string formatting with f"...".
14    * Path composition with '+' in line 8:
15      This becomes quickly unreadable. Usually, it is better to endure some
16      redundancy against having a more readable workflow. Hence, just repeat
17      common prefixes. If path composition is unavoidable, use pathlib or
18      (python >= 3.6) string formatting with f"...".
19    * Path composition with '+' in line 24:
20      This becomes quickly unreadable. Usually, it is better to endure some
21      redundancy against having a more readable workflow. Hence, just repeat
22      common prefixes. If path composition is unavoidable, use pathlib or
23      (python >= 3.6) string formatting with f"...".
24
25Lints for rule degenotate (line 45, /tmp/tmpc66vlp8m/workflow/Snakefile):
26    * No log directive defined:
27      Without a log directive, all output will be printed to the terminal. In
28      distributed environments, this means that errors are harder to discover.
29      In local environments, output of concurrent jobs will be mixed and become
30      unreadable.
31      Also see:
32      https://snakemake.readthedocs.io/en/stable/snakefiles/rules.html#log-files
33
34Lints for rule rename_chromosomes (line 60, /tmp/tmpc66vlp8m/workflow/Snakefile):
35    * No log directive defined:
36      Without a log directive, all output will be printed to the terminal. In
37      distributed environments, this means that errors are harder to discover.
38      In local environments, output of concurrent jobs will be mixed and become
39      unreadable.
40      Also see:
41      https://snakemake.readthedocs.io/en/stable/snakefiles/rules.html#log-files
42    * Shell command directly uses variable rule from outside of the rule:
43      It is recommended to pass all files as input and output, and non-file
44      parameters via the params directive. Otherwise, provenance tracking is
45      less accurate.
46      Also see:
47      https://snakemake.readthedocs.io/en/stable/snakefiles/rules.html#non-file-parameters-for-rules
48
49Lints for rule index_vcf (line 79, /tmp/tmpc66vlp8m/workflow/Snakefile):
50    * No log directive defined:
51      Without a log directive, all output will be printed to the terminal. In
52      distributed environments, this means that errors are harder to discover.
53      In local environments, output of concurrent jobs will be mixed and become
54      unreadable.
55      Also see:
56      https://snakemake.readthedocs.io/en/stable/snakefiles/rules.html#log-files
57
58Lints for rule filter_vcf (line 93, /tmp/tmpc66vlp8m/workflow/Snakefile):
59    * No log directive defined:
60      Without a log directive, all output will be printed to the terminal. In
61      distributed environments, this means that errors are harder to discover.
62      In local environments, output of concurrent jobs will be mixed and become
63      unreadable.
64      Also see:
65      https://snakemake.readthedocs.io/en/stable/snakefiles/rules.html#log-files
66
67Lints for rule make_genotype_matrix (line 116, /tmp/tmpc66vlp8m/workflow/Snakefile):
68    * No log directive defined:
69      Without a log directive, all output will be printed to the terminal. In
70      distributed environments, this means that errors are harder to discover.
71      In local environments, output of concurrent jobs will be mixed and become
72      unreadable.
73      Also see:
74      https://snakemake.readthedocs.io/en/stable/snakefiles/rules.html#log-files
75
76Lints for rule difference_matrix (line 134, /tmp/tmpc66vlp8m/workflow/Snakefile):
77    * Shell command directly uses variable rule from outside of the rule:
78      It is recommended to pass all files as input and output, and non-file
79      parameters via the params directive. Otherwise, provenance tracking is
80      less accurate.
81      Also see:
82      https://snakemake.readthedocs.io/en/stable/snakefiles/rules.html#non-file-parameters-for-rules
83    * Shell command directly uses variable rule from outside of the rule:
84      It is recommended to pass all files as input and output, and non-file
85      parameters via the params directive. Otherwise, provenance tracking is
86      less accurate.
87      Also see:
88      https://snakemake.readthedocs.io/en/stable/snakefiles/rules.html#non-file-parameters-for-rules
89    * Shell command directly uses variable rule from outside of the rule:
90      It is recommended to pass all files as input and output, and non-file
91      parameters via the params directive. Otherwise, provenance tracking is
92      less accurate.
93      Also see:
94      https://snakemake.readthedocs.io/en/stable/snakefiles/rules.html#non-file-parameters-for-rules

Formatting results

1[DEBUG] 
2[DEBUG] In file "/tmp/tmpc66vlp8m/workflow/Snakefile":  Formatted content is different from original
3[INFO] 1 file(s) would be changed 😬
4
5snakefmt version: 0.11.0