Gustavo Henrique Ferreira Cruz commited on
Commit
ec5c07d
·
verified ·
1 Parent(s): 5da5821

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +222 -60
README.md CHANGED
@@ -1,60 +1,222 @@
1
- ---
2
- license: cc-by-4.0
3
- configs:
4
- - config_name: default
5
- data_files:
6
- - split: train
7
- path: data/train-*
8
- dataset_info:
9
- features:
10
- - name: accession
11
- dtype: string
12
- - name: organism
13
- dtype: string
14
- - name: sequence
15
- dtype: string
16
- - name: introns
17
- list:
18
- - name: after
19
- dtype: string
20
- - name: before
21
- dtype: string
22
- - name: end
23
- dtype: int64
24
- - name: gene
25
- dtype: string
26
- - name: sequence
27
- dtype: string
28
- - name: start
29
- dtype: int64
30
- - name: exons
31
- list:
32
- - name: after
33
- dtype: string
34
- - name: before
35
- dtype: string
36
- - name: end
37
- dtype: int64
38
- - name: gene
39
- dtype: string
40
- - name: sequence
41
- dtype: string
42
- - name: start
43
- dtype: int64
44
- - name: proteins
45
- list:
46
- - name: end
47
- dtype: int64
48
- - name: gene
49
- dtype: string
50
- - name: sequence
51
- dtype: string
52
- - name: start
53
- dtype: int64
54
- splits:
55
- - name: train
56
- num_bytes: 11536678696
57
- num_examples: 1677609
58
- download_size: 5448417115
59
- dataset_size: 11536678696
60
- ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ license: cc-by-4.0
3
+ configs:
4
+ - config_name: default
5
+ data_files:
6
+ - split: train
7
+ path: data/train-*
8
+ dataset_info:
9
+ features:
10
+ - name: accession
11
+ dtype: string
12
+ - name: organism
13
+ dtype: string
14
+ - name: sequence
15
+ dtype: string
16
+ - name: introns
17
+ list:
18
+ - name: after
19
+ dtype: string
20
+ - name: before
21
+ dtype: string
22
+ - name: end
23
+ dtype: int64
24
+ - name: gene
25
+ dtype: string
26
+ - name: sequence
27
+ dtype: string
28
+ - name: start
29
+ dtype: int64
30
+ - name: exons
31
+ list:
32
+ - name: after
33
+ dtype: string
34
+ - name: before
35
+ dtype: string
36
+ - name: end
37
+ dtype: int64
38
+ - name: gene
39
+ dtype: string
40
+ - name: sequence
41
+ dtype: string
42
+ - name: start
43
+ dtype: int64
44
+ - name: proteins
45
+ list:
46
+ - name: end
47
+ dtype: int64
48
+ - name: gene
49
+ dtype: string
50
+ - name: sequence
51
+ dtype: string
52
+ - name: start
53
+ dtype: int64
54
+ splits:
55
+ - name: train
56
+ num_bytes: 11536678696
57
+ num_examples: 1677609
58
+ download_size: 5448417115
59
+ dataset_size: 11536678696
60
+ task_categories:
61
+ - text-classification
62
+ - token-classification
63
+ - translation
64
+ tags:
65
+ - Exons
66
+ - Introns
67
+ - Proteins
68
+ - DNA
69
+ pretty_name: DNA Coding Regions
70
+ size_categories:
71
+ - 1M<n<10M
72
+ ---
73
+
74
+ # DNA Coding Regions Dataset
75
+
76
+ This is a curated collection of genomic sequences extracted directly from **NCBI GenBank**, designed to support research in **, **DNA-to-protein translation**, **gene structure analysis**, and **biological sequence modeling** with deep learning architectures.
77
+
78
+ ---
79
+
80
+ ## Source and Extraction Pipeline
81
+
82
+ All records were extracted from **GenBank** using [Biopython](https://biopython.org/).
83
+ The dataset construction followed a reproducible data processing pipeline written in Python, which:
84
+
85
+ - Downloads and parses GenBank records.
86
+ - Extracts **genomic DNA sequences**, their associated **exons**, **introns**, and **coding sequences (CDS)**.
87
+ - Processes the `strand` orientation to produce normalized sequences.
88
+ - Removes duplicate entries based on `(sequence, organism)` pairs.
89
+ - Assembles each record into a structured JSONL format suitable for machine learning models.
90
+
91
+ The GenBank **search query** used for data collection was:
92
+
93
+ ```
94
+ "genomic DNA"[Filter]
95
+ AND ("exon"[Feature Key] OR "intron"[Feature Key])
96
+ AND "CDS"[Feature Key]
97
+ AND ("3"[SLEN] : "16384"[SLEN])
98
+ ````
99
+
100
+ You can find more information about the pipeline in the GitHub from the [DNA Coding Regions](https://github.com/GustavoHCruz/CodingDNATransformers) repository.
101
+
102
+ ---
103
+
104
+ ## Dataset Structure
105
+
106
+ Each entry in the dataset corresponds to a **unique DNA sequence**, identified by its **GenBank accession**.
107
+ The dataset is serialized in JSON Lines (`.jsonl`) format and can be loaded with the Hugging Face `datasets` library.
108
+
109
+ ### Example record
110
+
111
+ ```json
112
+ {
113
+ "accession": "NC_045512.2",
114
+ "organism": "Homo sapiens",
115
+ "sequence": "ATTAAAGGTTTATACCTTCCCAGGTAACAAACCAACCAACTTTCGAT...",
116
+ "introns": [
117
+ {
118
+ "sequence": "TTGTAGACCAGTGCAGTA...",
119
+ "start": 1450,
120
+ "end": 1783,
121
+ "gene": "ORF1ab",
122
+ "before": "ATGCCDG",
123
+ "after": "TAACAFG"
124
+ }
125
+ ],
126
+ "exons": [
127
+ {
128
+ "sequence": "ATGGACACAAGTCAGG...",
129
+ "start": 1,
130
+ "end": 1449,
131
+ "gene": "ORF1ab",
132
+ "before": null,
133
+ "after": "GT"
134
+ }
135
+ ],
136
+ "proteins": [
137
+ {
138
+ "sequence": "MESLVPGFNEKTHVQLSLPVLQVRDVLVRGFGDSVEEVL...",
139
+ "start": 1,
140
+ "end": 4405,
141
+ "gene": "ORF1ab"
142
+ }
143
+ ]
144
+ }
145
+ ````
146
+
147
+ ---
148
+
149
+ ## Field Descriptions
150
+
151
+ | Field | Type | Description |
152
+ | ------------- | ------ | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
153
+ | **accession** | `str` | GenBank accession number for the DNA sequence. |
154
+ | **organism** | `str` | Name of the organism from which the sequence was derived. |
155
+ | **sequence** | `str` | The full genomic DNA sequence (processed strand). |
156
+ | **introns** | `list` | List of intronic regions associated with this DNA sequence. Each item contains: <ul><li>`sequence`: only the nucleotide sequence of the intron</li><li>`start`, `end`: coordinates relative to the DNA sequence</li><li>`gene`: gene name when annotated</li><li>`before`, `after`: short flanking sequences</li></ul> |
157
+ | **exons** | `list` | List of exonic regions associated with this DNA sequence. Same structure as `introns`. |
158
+ | **proteins** | `list` | List of coding sequences (CDS) translated to amino acid sequences, with: <ul><li>`sequence`: protein sequence</li><li>`start`, `end`: coordinates in the DNA sequence</li><li>`gene`: gene name</li></ul> |
159
+
160
+ ---
161
+
162
+ ## Applications
163
+
164
+ This dataset can be directly used for:
165
+
166
+ * **DNA to protein translation modeling**
167
+ * **Exon and Introns classification**
168
+ * **Splicing prediction**
169
+ * **Genomic representation learning**
170
+ * **Bioinformatics-focused LLM pretraining (DAPT)**
171
+
172
+ ---
173
+
174
+ ## Loading Example
175
+
176
+ ```python
177
+ from datasets import load_dataset
178
+
179
+ dataset = load_dataset("gu-dudi/DNA_coding_regions")
180
+
181
+ print(dataset)
182
+ print(dataset["train"][0])
183
+ ```
184
+
185
+ ---
186
+
187
+ ## Dataset Metadata
188
+
189
+ * **Source:** NCBI GenBank
190
+ * **Processed with:** Biopython, Pandas, tqdm
191
+ * **Maintainer:** [Gustavo Henrique Ferreira Cruz](https://huggingface.co/gu-dudi)
192
+ * **License:** Open for research and educational use
193
+ * **Format:** JSON Lines (UTF-8)
194
+
195
+ ---
196
+
197
+ ### Citation
198
+
199
+ If you use this dataset in your research, please cite:
200
+
201
+ > Cruz, G. H. F. (2025). *DNA Coding Regions Dataset: Genomic Sequences with Introns, Exons, and Protein Mappings Extracted from GenBank.*
202
+
203
+ ---
204
+
205
+ ### Version and Integrity
206
+
207
+ * **Version:** 1.0
208
+ * **Total entries:** 1,677,609
209
+ * **Deduplication:** duplicates removed based on `(sequence, organism)` pair
210
+ * **Strand normalization:** handled during extraction
211
+
212
+ ---
213
+
214
+ ### Notes
215
+
216
+ * Coordinates (`start`, `end`) are **relative to the parent DNA sequence**.
217
+ * `sequence` inside each **intron/exon** corresponds *only to that region* (not the full DNA).
218
+ * Protein sequences are already **translated amino acid chains**, not nucleotide fragments.
219
+
220
+ ---
221
+
222
+ *Developed as part of the Master’s research project on DNA sequence understanding and translation using deep learning models.*