danieltslz commited on
Commit
68eb776
·
verified ·
1 Parent(s): 87c5c31

Update curated README: spliceai_canonical_splice_site_profile

Browse files
data/embeddings/spliceai_canonical_splice_site_profile/README.md CHANGED
@@ -1,40 +1,23 @@
1
- # SpliceAI-canonical-splice-site-profile-zscore-v1.1
2
 
3
- Embedding ID: `spliceai_canonical_splice_site_profile`
4
-
5
- Former processing ID: `spliceai_canonical_splice_site_profile_v1_1`
 
 
6
 
7
  ## Public files
8
 
9
  - `embeddings.npz`: compressed NumPy archive containing the embedding matrix under key `embeddings`.
10
  - `genes.tsv`: row metadata table. Row order matches the embedding matrix.
11
  - `metadata.json`: machine-readable provenance and processing metadata.
12
- - `README.md`: this per-embedding documentation file.
13
 
14
  ## Matrix
15
 
16
  - Shape: `20097 genes × 606 dimensions`
17
  - Dtype: `float32`
18
- - NPZ array key: `embeddings`
19
-
20
- The row order is authoritative:
21
-
22
- ```text
23
- embeddings.npz['embeddings'][i, :] corresponds to genes.tsv row i
24
- ```
25
 
26
- ## Loading example
27
 
28
- ```python
29
- import numpy as np
30
- import pandas as pd
31
-
32
- with np.load('embeddings.npz') as z:
33
- X = z['embeddings']
34
-
35
- genes = pd.read_csv('genes.tsv', sep='\t')
36
- assert X.shape[0] == len(genes)
37
- ```
38
 
39
  ## genes.tsv columns
40
 
@@ -51,29 +34,93 @@ assert X.shape[0] == len(genes)
51
  | `canonical_transcript_id_versioned` | 20097 | 20097 | ENST00000373020.9<br>ENST00000373031.5<br>ENST00000371588.10<br>ENST00000367771.11 | Versioned canonical transcript identifier. |
52
  | `assembly` | 20097 | 1 | GRCh38 | Genome assembly used for coordinates. |
53
  | `gencode_release` | 20097 | 1 | 49 | GENCODE release used for annotation. |
54
- | `spliceai_site_status` | 20097 | 2 | ok<br>single_exon_or_no_junctions | TODO: define this source-specific column during manual curation. |
55
- | `n_splice_sites` | 20097 | 107 | 14<br>12<br>16<br>24 | TODO: define this source-specific column during manual curation. |
56
- | `n_donor_sites` | 20097 | 107 | 7<br>6<br>8<br>12 | TODO: define this source-specific column during manual curation. |
57
- | `n_acceptor_sites` | 20097 | 107 | 7<br>6<br>8<br>12 | TODO: define this source-specific column during manual curation. |
58
 
59
- ## Basic metadata
60
 
61
- | Field | Value |
62
- |---|---|
63
- | `status` | processed_qc_passed |
64
- | `modality` | splicing sequence model / canonical transcript splice-site profiles |
65
- | `embedding_name` | SpliceAI-canonical-splice-site-profile-zscore-v1.1 |
66
 
67
  ## Detailed processing notes
68
 
69
- TODO: manually paste and curate the processing explanation for this embedding from the central project README.
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
70
 
71
- Please include, when relevant:
72
 
73
- - original source/model/checkpoint;
74
- - whether the embedding was downloaded or generated locally;
75
- - input data used;
76
- - identifier mapping and filtering decisions;
77
- - pooling, aggregation, PCA, or normalization method;
78
- - coverage and important caveats;
79
- - license or redistribution notes.
 
 
 
 
 
1
+ # Embedding name: SpliceAI-canonical-splice-site-profile-zscore
2
 
3
+ - Modality: Splicing / canonical splice-site sequence profile
4
+ - Algorithm: Deep learning splice-site prediction model
5
+ - Source used here: Local inference with five pretrained SpliceAI models bundled in the installed spliceai package
6
+ - Embedding source URL: Local generation from GENCODE v49 canonical transcript splice sites and master_gene_table.csv
7
+ - Original model/code URL: https://github.com/Illumina/SpliceAI
8
 
9
  ## Public files
10
 
11
  - `embeddings.npz`: compressed NumPy archive containing the embedding matrix under key `embeddings`.
12
  - `genes.tsv`: row metadata table. Row order matches the embedding matrix.
13
  - `metadata.json`: machine-readable provenance and processing metadata.
 
14
 
15
  ## Matrix
16
 
17
  - Shape: `20097 genes × 606 dimensions`
18
  - Dtype: `float32`
 
 
 
 
 
 
 
19
 
 
20
 
 
 
 
 
 
 
 
 
 
 
21
 
22
  ## genes.tsv columns
23
 
 
34
  | `canonical_transcript_id_versioned` | 20097 | 20097 | ENST00000373020.9<br>ENST00000373031.5<br>ENST00000371588.10<br>ENST00000367771.11 | Versioned canonical transcript identifier. |
35
  | `assembly` | 20097 | 1 | GRCh38 | Genome assembly used for coordinates. |
36
  | `gencode_release` | 20097 | 1 | 49 | GENCODE release used for annotation. |
37
+ | `spliceai_site_status` | 20097 | 2 | ok<br>single_exon_or_no_junctions | Status of splice-site extraction for the gene. `ok` means the canonical transcript had splice junctions; `single_exon_or_no_junctions` means no canonical splice junctions were available and the raw splice profile was set to zero before z-scoring. |
38
+ | `n_splice_sites` | 20097 | 107 | 14<br>12<br>16<br>24 | Total number of canonical splice sites used for the gene, counting donor and acceptor sites together. |
39
+ | `n_donor_sites` | 20097 | 107 | 7<br>6<br>8<br>12 | Number of canonical donor splice sites used for the gene. |
40
+ | `n_acceptor_sites` | 20097 | 107 | 7<br>6<br>8<br>12 | Number of canonical acceptor splice sites used for the gene. |
41
 
 
42
 
 
 
 
 
 
43
 
44
  ## Detailed processing notes
45
 
46
+ ### Source and interpretation
47
+
48
+ This embedding is a gene-level splicing-context representation derived from SpliceAI predictions around canonical splice sites. In this project, it was generated locally from master-table canonical transcript IDs, GENCODE v49 exon coordinates, and the GRCh38 reference genome. It was not downloaded as a ready gene-level embedding table.
49
+
50
+ The model used was SpliceAI. For each master-table gene, canonical transcript exons were parsed from GENCODE v49. Canonical donor and acceptor splice sites were derived from the transcript exon structure and strand. Around each splice site, SpliceAI sequence context was extracted and SpliceAI acceptor/donor profiles were predicted. Predictions were averaged across the five pretrained SpliceAI models bundled in the installed package.
51
+
52
+ The final representation summarizes splice-site-centered SpliceAI profiles into one fixed-size vector per gene. It should therefore be interpreted as a splicing-context embedding, not as a whole-gene DNA embedding, promoter embedding, mature transcript embedding, or protein embedding.
53
+
54
+ ### Provenance fields
55
+
56
+ source_name: SpliceAI canonical splice-site profile
57
+ original_model_or_method: SpliceAI splice-site prediction model
58
+ input_sequence_type: splice-site DNA sequence context
59
+ input_sequence_source: GRCh38 primary assembly FASTA, GENCODE v49 exon coordinates, and master_gene_table.csv canonical transcript IDs
60
+ genome_build: GRCh38
61
+ annotation_reference: GENCODE release 49
62
+ model_interface: installed spliceai package
63
+ model_code_url: https://github.com/Illumina/SpliceAI
64
+ models_used: five pretrained SpliceAI models bundled in the installed package
65
+ context_length: 10 kb SpliceAI sequence context around each splice site
66
+ output_profile_window: +/- 50 bp around each splice site
67
+ output_channels_used: acceptor and donor
68
+ aggregation_strategy: aggregate canonical splice-site profiles to one fixed-size vector per gene
69
+ final_transformation: dimension-wise z-score across genes
70
+
71
+ ### Coordinate and sequence decisions
72
+
73
+ The source gene set came from master_gene_table.csv. Canonical transcript IDs from the master table were used to select the transcript structure for each gene. Exon coordinates were parsed from the GENCODE v49 GTF file.
74
+
75
+ Canonical donor and acceptor splice sites were derived using transcript strand. For minus-strand splice sites, sequence windows were reverse-complemented so that the resulting SpliceAI profiles are transcript-oriented rather than raw genomic-reference oriented.
76
+
77
+ Genes without canonical splice junctions were retained in the final output. Their raw splice profiles were set to zero before the final matrix transformation, and their status is documented in genes.tsv. This preserves one output row per master-table gene.
78
+
79
+ ### Processing workflow
80
+
81
+ For each gene in the master table:
82
+
83
+ 1. Read the canonical transcript ID from master_gene_table.csv.
84
+ 2. Parse the corresponding canonical transcript exons from GENCODE v49.
85
+ 3. Derive canonical donor and acceptor splice sites from exon structure and transcript strand.
86
+ 4. Extract 10 kb SpliceAI sequence context around each splice site.
87
+ 5. Extract a +/- 50 bp output profile around each splice site.
88
+ 6. Reverse-complement minus-strand splice-site windows so the profiles are transcript-oriented.
89
+ 7. Run the five pretrained SpliceAI models bundled in the installed spliceai package.
90
+ 8. Average predictions across the five models.
91
+ 9. Keep the acceptor and donor output channels.
92
+ 10. Aggregate splice-site profiles into one fixed-size 606-dimensional vector per gene.
93
+ 11. Z-score each dimension across genes.
94
+ 12. Save the final matrix as float32.
95
+
96
+ ### Important implementation decisions
97
+
98
+ Canonical transcripts were used to avoid creating multiple isoform-specific rows for the same gene. This keeps the output gene-level and directly aligned to master_gene_table.csv.
99
+
100
+ The final 606 raw features were formed from six 101-position profiles:
101
+
102
+ all_sites acceptor profile 101
103
+ all_sites donor profile 101
104
+ donor_sites acceptor profile 101
105
+ donor_sites donor profile 101
106
+ acceptor_sites acceptor profile 101
107
+ acceptor_sites donor profile 101
108
+ Total 606
109
+
110
+ Genes without canonical splice junctions were not removed. They were kept with zero raw splice profiles before z-scoring so that the final embedding has complete master-table coverage.
111
+
112
+ Earlier plain nohup attempts stopped before completion and were not used as final outputs. The final successful full run from scratch completed and passed QC.
113
 
114
+ ### Summary of final mapping:
115
 
116
+ Source identifiers / canonical splice sites: 380,380
117
+ Dimensions: 606
118
+ Rows generated before duplicate collapse: 20,097
119
+ Genes with at least one canonical splice site: 18,946
120
+ Genes without canonical splice sites: 1,151
121
+ Unmapped source rows: 0
122
+ Ambiguous source rows: 0
123
+ Final mapped genes: 20,097
124
+ Master table rows: 20,097
125
+ Master coverage: 100.000%
126
+ Duplicate final mappings averaged: 0