1+ #!/usr/bin/env python3
2+ #
3+ # bcl2fastq.protocols.py: Fastq generation protocol definitions
4+ # Copyright (C) University of Manchester 2025 Peter Briggs
5+ #
6+
7+ """
8+ Defines the ``PROTOCOLS`` dictionary, which specifies the available Fastq
9+ generation protocols which can be used in the Fastq generation pipeline.
10+
11+ Each protocol is defined as a name (the dictionary key) and a dictionary
12+ of parameters (the dictionary value).
13+
14+ The following parameters compulsory for each protocol:
15+
16+ * description: free-text string describing the protocol
17+ * pipeline_variant: a string specifying which of the implemented sub-pipelines
18+ the protocol will use; must be one of: "standard", "10x_cellranger",
19+ "10x_cellranger-atc", "10x_cellranger-arc", "10x_spaceranger"
20+ * supported_indexes: a sequence (list or tuple) which specifies the types
21+ of sample sheet index that the protocol supports; must be one or more of:
22+ "ILLUMINA", "10X", "NONE"
23+
24+ The remaining parameters can be none or more of any of the possible lane
25+ subset attributes. Most commonly:
26+
27+ * r1_length
28+ * r2_length
29+ * r3_length
30+ * i1_length
31+ * i2_length
32+ * minimum_trimmed_read_lengths
33+ * mask_short_adapter_reads
34+ * no_lane_splitting
35+ * create_fastq_for_index_read
36+ * trim_adapters
37+ """
38+
39+ PROTOCOLS = {
40+ "standard" : {
41+ "description" : "Standard Illumina sequencing data (default)" ,
42+ "pipeline_variant" : "standard" ,
43+ "supported_indexes" : ("ILLUMINA" , "NONE" ),
44+ },
45+ "mirna" : {
46+ # miRNA-seq protocol
47+ # Set minimum trimmed read length and turn off masking
48+ "description" : "miRNA-seq data" ,
49+ "pipeline_variant" : "standard" ,
50+ "supported_indexes" : ("ILLUMINA" ,),
51+ "minimum_trimmed_read_length" : 10 ,
52+ "mask_short_adapter_reads" : 0 ,
53+ },
54+ "10x_chromium_sc" : {
55+ # 10xGenomics Chromium SC (GEX/Flex)
56+ # -- truncate R1 to 28 bases
57+ # -- truncate R2 to 90 bases
58+ # -- truncate I1 and I2 to 10 bases
59+ # -- minimum trimmed read length 8bp
60+ # -- minimum masked read length 8bp
61+ # -- no lane splitting
62+ # -- create Fastqs for index read
63+ # -- disable adapter trimming
64+ "description" : "10x Genomics Chromium 3' and 5' single cell "
65+ "gene expression data" ,
66+ "pipeline_variant" : "10x_cellranger" ,
67+ "supported_indexes" : ("ILLUMINA" , "10X" ),
68+ "r1_length" : 28 ,
69+ "r2_length" : 90 ,
70+ "i1_length" : 10 ,
71+ "i2_length" : 10 ,
72+ "minimum_trimmed_read_length" : 8 ,
73+ "mask_short_adapter_reads" : 8 ,
74+ "no_lane_splitting" : True ,
75+ "create_fastq_for_index_read" : True ,
76+ "trim_adapters" : False
77+ },
78+ "10x_atac" : {
79+ # 10xGenomics ATAC-seq
80+ # -- convert I2 to R2
81+ # -- truncate R1 to 50 bases
82+ # -- truncate R2 to 16 bases
83+ # -- truncate R3 to 50 bases
84+ # -- truncate I1 to 8 bases
85+ # -- enable filter single index
86+ # -- no lane splitting
87+ # -- create Fastqs for index read
88+ # -- disable adapter trimming
89+ "description" : "10x Genomics Chromium single cell ATAC-seq data" ,
90+ "pipeline_variant" : "10x_cellranger-atac" ,
91+ "supported_indexes" : ("10X" ,),
92+ "r1_length" : 50 ,
93+ "r2_length" : 16 ,
94+ "r3_length" : 50 ,
95+ "i1_length" : 8 ,
96+ "override_template" : "RIRR" ,
97+ "tenx_filter_single_index" : True ,
98+ "no_lane_splitting" : True ,
99+ "create_fastq_for_index_read" : True ,
100+ "trim_adapters" : False
101+ },
102+ "10x_multiome" : {
103+ # 10xGenomics multiome
104+ # -- set bases mask to "auto"
105+ # -- no lane splitting
106+ # -- create Fastqs for index read
107+ # -- disable adapter trimming
108+ "description" : "10x Genomics single cell multiome data "
109+ "(unpooled data i.e. ATAC or GEX data only in single run)" ,
110+ "pipeline_variant" : "10x_cellranger-arc" ,
111+ "supported_indexes" : ("10X" ,),
112+ "bases_mask" : "auto" ,
113+ "no_lane_splitting" : True ,
114+ "create_fastq_for_index_read" : True ,
115+ "trim_adapters" : False
116+ },
117+ "10x_multiome_atac" : {
118+ # 10xGenomics multiome (ATAC)
119+ # -- convert I2 to R2
120+ # -- truncate R1 to 50 bases
121+ # -- truncate R2 to 24 bases
122+ # -- truncate R3 to 49 bases
123+ # -- truncate I1 to 8 bases
124+ # -- enable filter single index
125+ # -- no lane splitting
126+ # -- create Fastqs for index read
127+ # -- disable adapter trimming
128+ "description" : "10x Genomics single cell multiome ATAC-seq data "
129+ "(run with pooled GEX and ATAC data)" ,
130+ "pipeline_variant" : "10x_cellranger-arc" ,
131+ "supported_indexes" : ("10X" ,),
132+ "r1_length" : 50 ,
133+ "r2_length" : 24 ,
134+ "r3_length" : 49 ,
135+ "i1_length" : 8 ,
136+ "override_template" : "RIRR" ,
137+ "tenx_filter_single_index" : True ,
138+ "no_lane_splitting" : True ,
139+ "create_fastq_for_index_read" : True ,
140+ "trim_adapters" : False
141+ },
142+ "10x_multiome_gex" : {
143+ # 10xGenomics multiome (GEX)
144+ # -- truncate I1 and I2 to 10 bases
145+ # -- truncate R1 to 28 bases
146+ # -- truncate R2 to 90 bases
147+ # -- enable filter dual index
148+ # -- no lane splitting
149+ # -- create Fastqs for index read
150+ # -- disable adapter trimming
151+ "description" : "10x Genomics single cell multiome GEX data "
152+ "(run with pooled GEX and ATAC data)" ,
153+ "pipeline_variant" : "10x_cellranger-arc" ,
154+ "supported_indexes" : ("10X" ,),
155+ "r1_length" : 28 ,
156+ "r2_length" : 90 ,
157+ "i1_length" : 10 ,
158+ "i2_length" : 10 ,
159+ "tenx_filter_dual_index" : True ,
160+ "no_lane_splitting" : True ,
161+ "create_fastq_for_index_read" : True ,
162+ "trim_adapters" : False
163+ },
164+ "10x_visium" : {
165+ # 10xGenomics Visium
166+ # -- truncate R1 to 28 bases
167+ # -- truncate R2 to 50 bases
168+ # -- truncate I1 and I2 to 10 bases
169+ # -- minimum trimmed read length 8bp
170+ # -- minimum masked read length 8bp
171+ # -- no lane splitting
172+ # -- create Fastqs for index read
173+ # -- disable adapter trimming
174+ "description" : "10x Genomics Visium CytAssist FFPE, Fresh Frozen, Fixed "
175+ "Frozen spatial GEX or FFPE PEX data" ,
176+ "pipeline_variant" : "10x_spaceranger" ,
177+ "supported_indexes" : ("ILLUMINA" , "10X" ),
178+ "r1_length" : 28 ,
179+ "r2_length" : 50 ,
180+ "i1_length" : 10 ,
181+ "i2_length" : 10 ,
182+ "minimum_trimmed_read_length" : 8 ,
183+ "mask_short_adapter_reads" : 8 ,
184+ "no_lane_splitting" : True ,
185+ "create_fastq_for_index_read" : True ,
186+ "trim_adapters" : False
187+ },
188+ "10x_visium_v1" : {
189+ # 10xGenomics Visium v1
190+ # -- truncate R1 to 28 bases
191+ # -- truncate R2 to 90 bases
192+ # -- truncate I1 and I2 to 10 bases
193+ # -- minimum trimmed read length 8bp
194+ # -- minimum masked read length 8bp
195+ # -- no lane splitting
196+ # -- create Fastqs for index read
197+ # -- disable adapter trimming
198+ "description" : "10x Genomics Visium Fresh Frozen Spatial GEX (v1) "
199+ "data (no CytAssist)" ,
200+ "pipeline_variant" : "10x_spaceranger" ,
201+ "supported_indexes" : ("ILLUMINA" , "10X" ),
202+ "r1_length" : 28 ,
203+ "r2_length" : 90 ,
204+ "i1_length" : 10 ,
205+ "i2_length" : 10 ,
206+ "minimum_trimmed_read_length" : 8 ,
207+ "mask_short_adapter_reads" : 8 ,
208+ "no_lane_splitting" : True ,
209+ "create_fastq_for_index_read" : True ,
210+ "trim_adapters" : False
211+ },
212+ "10x_visium_hd" : {
213+ # 10xGenomics Visium (HD)
214+ # -- truncate R1 to 43 bases
215+ # -- truncate R2 to 50 bases
216+ # -- truncate I1 and I2 to 10 bases
217+ # -- minimum trimmed read length 8bp
218+ # -- minimum masked read length 8bp
219+ # -- no lane splitting
220+ # -- create Fastqs for index read
221+ # -- disable adapter trimming
222+ "description" : "10x Genomics Visium CytAssist FFPE HD spatial GEX "
223+ "data" ,
224+ "pipeline_variant" : "10x_spaceranger" ,
225+ "supported_indexes" : ("ILLUMINA" , "10X" ),
226+ "r1_length" : 43 ,
227+ "r2_length" : 50 ,
228+ "i1_length" : 10 ,
229+ "i2_length" : 10 ,
230+ "minimum_trimmed_read_length" : 8 ,
231+ "mask_short_adapter_reads" : 8 ,
232+ "no_lane_splitting" : True ,
233+ "create_fastq_for_index_read" : True ,
234+ "trim_adapters" : False
235+ },
236+ "10x_visium_hd_3prime" : {
237+ # 10xGenomics Visium (HD 3')
238+ # -- truncate R1 to 43 bases
239+ # -- truncate R2 to 75 bases
240+ # -- truncate I1 and I2 to 10 bases
241+ # -- minimum trimmed read length 8bp
242+ # -- minimum masked read length 8bp
243+ # -- no lane splitting
244+ # -- create Fastqs for index read
245+ # -- disable adapter trimming
246+ "description" : "10x Visium CytAssist FFPE HD 3' spatial GEX data" ,
247+ "pipeline_variant" : "10x_spaceranger" ,
248+ "supported_indexes" : ("ILLUMINA" , "10X" ),
249+ "r1_length" : 43 ,
250+ "r2_length" : 75 ,
251+ "i1_length" : 10 ,
252+ "i2_length" : 10 ,
253+ "minimum_trimmed_read_length" : 8 ,
254+ "mask_short_adapter_reads" : 8 ,
255+ "no_lane_splitting" : True ,
256+ "create_fastq_for_index_read" : True ,
257+ "trim_adapters" : False
258+ },
259+ "parse_evercode" : {
260+ # Parse Evercode
261+ # Disable adapter trimming
262+ "description" : "Parse Evercode single cell data" ,
263+ "pipeline_variant" : "standard" ,
264+ "supported_indexes" : ("ILLUMINA" ,),
265+ "trim_adapters" : False ,
266+ },
267+ "biorad_ddseq" : {
268+ # Bio-Rad ddSEQ
269+ # Disable adapter trimming
270+ "description" : "Bio-Rad ddSEQ single cell data" ,
271+ "pipeline_variant" : "standard" ,
272+ "supported_indexes" : ("ILLUMINA" ,),
273+ "trim_adapters" : False ,
274+ }
275+ }
0 commit comments