Skip to content

Commit

Permalink
feat: Add assignment_merge thread configuration
Browse files Browse the repository at this point in the history
The code changes include adding a new thread configuration option `assignment_merge` with a value of 10 in the `config.yaml` file. This configuration option is used to control the number of threads for the `assignment_merge` step in the workflow.

Recent user commits and repository commits are not relevant for generating the commit message.
  • Loading branch information
Max Schubach committed Jul 19, 2024
1 parent 60806e9 commit 26e68c2
Show file tree
Hide file tree
Showing 5 changed files with 2,246 additions and 2,247 deletions.
14 changes: 7 additions & 7 deletions docs/assignment_example1.rst
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,11 @@ It is necessary to get the ordered oligo array so that each enhancer sequence ca

.. code-block:: bash
mkdir -p assoc_basic/data
cd assoc_basic/data
wget ftp://ftp.ncbi.nlm.nih.gov/geo/samples/GSM4237nnn/GSM4237954/suppl/GSM4237954_9MPRA_elements.fa.gz
mkdir -p assoc_basic/data
cd assoc_basic/data
wget ftp://ftp.ncbi.nlm.nih.gov/geo/samples/GSM4237nnn/GSM4237954/suppl/GSM4237954_9MPRA_elements.fa.gz
zcat GSM4237954_9MPRA_elements.fa.gz |awk '{ count+=1; if (count == 1) { print } else { print substr($1,1,171)}; if (count == 2) { count=0 } }' > design.fa
zcat GSM4237954_9MPRA_elements.fa.gz |awk '{ count+=1; if (count == 1) { print } else { print substr($1,1,171)}; if (count == 2) { count=0 } }' | awk '{gsub(/[\]\[]/,"_")} $0' > design.fa
Reads
----------
Expand Down Expand Up @@ -114,13 +114,13 @@ You should see a list of rules that will be executed. This is the summary:

.. code-block:: text
Building DAG of jobs...
Job stats:
job count
----------------------------------- -------
all 1
assignment_attach_idx 60
assignment_bwa_ref 1
assignment_check_design 1
assignment_collect 1
assignment_collectBCs 1
assignment_fastq_split 3
Expand All @@ -133,14 +133,14 @@ You should see a list of rules that will be executed. This is the summary:
assignment_statistic_assignedCounts 1
assignment_statistic_assignment 1
assignment_statistic_totalCounts 1
total 163
total 164
When dry-drun does not give any errors we will run the workflow. We use a machine with 30 threads/cores to run the workflow. Therefore :code:`split_number` is set to 30 to parallize the workflow. Also we are using 10 threads for mapping (bwa mem). But snakemake takes care that no more than 30 threads are used.

.. code-block:: bash
snakemake -c 30 --use-conda --snakefile /home/user/MPRAsnakeflow/workflow/Snakefile --configfile /home/user/MPRAsnakeflow/resources/assoc_basic/config.yml
snakemake -c 30 --sdm conda --snakefile /home/user/MPRAsnakeflow/workflow/Snakefile --configfile /home/user/MPRAsnakeflow/resources/assoc_basic/config.yml -n -q --set-threads assignment_mapping_bwa=10
.. note:: Please modify your code when running in a cluster environment. We have an example SLURM config file here :code:`config/sbatch.yml`.
Expand Down
2 changes: 1 addition & 1 deletion docs/combined_example1.rst
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ It is necessary to get the ordered oligo array so that each enhancer sequence ca
cd combined_basic/data
wget ftp://ftp.ncbi.nlm.nih.gov/geo/samples/GSM4237nnn/GSM4237954/suppl/GSM4237954_9MPRA_elements.fa.gz
zcat GSM4237954_9MPRA_elements.fa.gz |awk '{ count+=1; if (count == 1) { print } else { print substr($1,1,171)}; if (count == 2) { count=0 } }' > design.fa
zcat GSM4237954_9MPRA_elements.fa.gz |awk '{ count+=1; if (count == 1) { print } else { print substr($1,1,171)}; if (count == 2) { count=0 } }' | awk '{gsub(/[\]\[]/,"_")} $0'> design.fa
Reads
----------
Expand Down
1 change: 1 addition & 0 deletions profiles/default/config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ set-threads:
assignment_mapping_bwa: 30
assignment_collect: 30
assignment_collectBCs: 20
assignment_merge: 10
set-resources:
assignment_check_design:
runtime: 240
Expand Down
Loading

0 comments on commit 26e68c2

Please sign in to comment.