diff --git a/config/example_assignment_bbmap.yaml b/config/example_assignment_bbmap.yaml index aa48288..30381e7 100644 --- a/config/example_assignment_bbmap.yaml +++ b/config/example_assignment_bbmap.yaml @@ -8,13 +8,9 @@ assignments: alignment_tool: tool: bbmap configs: - min_mapping_quality: 35 # integer >=0. 35 is default - sequence_length: # sequence length of design excluding adapters. - min: 166 - max: 175 - alignment_start: # start of an alignment in the reference/design_file. Here using 15 bp adapters. Can be different when using adapter free approaches - min: 1 # integer - max: 3 # integer + min_mapping_quality: 30 # integer >=0. 30 is default for bbmap + sequence_length: 171 # sequence length of design excluding adapters. + alignment_start: 1 # start of an alignment in the reference/design_file. Here using 15 bp adapters. Can be different when using adapter free approaches FW: - resources/Assignment_BasiC/R1.fastq.gz BC: diff --git a/config/example_config.yaml b/config/example_config.yaml index 3da3db5..85a45d2 100644 --- a/config/example_config.yaml +++ b/config/example_config.yaml @@ -6,9 +6,9 @@ assignments: exampleAssignment: # name of an example assignment (can be any string) bc_length: 15 alignment_tool: - tool: exact # bbbmap, bwa or exact + tool: exact # bbmap, bwa or exact configs: - sequence_length: 170 # sequence length of design excluding adapters. + sequence_length: 171 # sequence length of design excluding adapters. alignment_start: 1 # start of the alignment in the reference/design_file FW: - resources/assoc_basic/data/SRR10800986_1.fastq.gz diff --git a/resources/assoc_basic/config.yml b/resources/assoc_basic/config.yml index 9746bc5..10a1020 100644 --- a/resources/assoc_basic/config.yml +++ b/resources/assoc_basic/config.yml @@ -8,12 +8,8 @@ assignments: alignment_tool: tool: bbmap configs: - sequence_length: - min: 166 - max: 175 - alignment_start: - min: 1 - max: 3 + sequence_length: 171 + alignment_start: 1 FW: - data/SRR10800986_1.fastq.gz BC: diff --git a/resources/combined_basic/config.yml b/resources/combined_basic/config.yml index b1c0a16..c18a618 100644 --- a/resources/combined_basic/config.yml +++ b/resources/combined_basic/config.yml @@ -8,12 +8,8 @@ assignments: alignment_tool: tool: bbmap configs: - sequence_length: - min: 166 - max: 175 - alignment_start: - min: 1 - max: 3 + sequence_length: 171 + alignment_start: 1 FW: - data/SRR10800986_1.fastq.gz BC: diff --git a/workflow/rules/assignment.smk b/workflow/rules/assignment.smk index 620e2f2..fe3aaf2 100644 --- a/workflow/rules/assignment.smk +++ b/workflow/rules/assignment.smk @@ -29,28 +29,24 @@ rule assignment_check_design: start=lambda wc: ( config["assignments"][wc.assignment]["alignment_tool"]["configs"][ "alignment_start" - ] - if config["assignments"][wc.assignment]["alignment_tool"]["tool"] - == "exact" + ]["max"] + if config["assignments"][wc.assignment]["alignment_tool"]["tool"] == "bwa" else config["assignments"][wc.assignment]["alignment_tool"]["configs"][ "alignment_start" - ]["max"] + ] ), length=lambda wc: ( config["assignments"][wc.assignment]["alignment_tool"]["configs"][ "sequence_length" - ] - if config["assignments"][wc.assignment]["alignment_tool"]["tool"] - == "exact" + ]["min"] + if config["assignments"][wc.assignment]["alignment_tool"]["tool"] == "bwa" else config["assignments"][wc.assignment]["alignment_tool"]["configs"][ "sequence_length" - ]["min"] + ] ), fast_check=lambda wc: ( "--fast-dict" if config["assignments"][wc.assignment]["design_check"]["fast"] - or config["assignments"][wc.assignment]["alignment_tool"]["tool"] - == "bbmap" else "--slow-string-search" ), check_sequence_collitions=lambda wc: ( diff --git a/workflow/schemas/config.schema.yaml b/workflow/schemas/config.schema.yaml index 5ededb3..5e5e642 100644 --- a/workflow/schemas/config.schema.yaml +++ b/workflow/schemas/config.schema.yaml @@ -99,29 +99,13 @@ properties: min_mapping_quality: type: integer minimum: 0 - default: 35 + default: 30 sequence_length: - type: object - properties: - min: - type: integer - max: - type: integer - additionalProperties: false - required: - - min - - max + type: integer + minimum: 1 alignment_start: - type: object - properties: - min: - type: integer - max: - type: integer - additionalProperties: false - required: - - min - - max + type: integer + minimum: 1 additionalProperties: false required: - min_mapping_quality