File size: 3,735 Bytes
9e5e26a 138acd5 9e5e26a 138acd5 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 | ---
license: mit
pretty_name: DarkSpec
size_categories:
- 1M<n<10M
tags:
- mass-spectrometry
- proteomics
- de-novo-peptide-sequencing
- semi-supervised-learning
---
# DarkSpec
DarkSpec is a curated collection of **4.5 million unlabeled tandem mass
spectra** selected from PRIDE for semi-supervised de novo peptide sequencing.
It provides quality-controlled spectra that can be used without peptide
identification labels.
DarkSpec accompanies
[SemiNovo](https://github.com/grandOrgan/Seminovo), a framework for learning de
novo sequencing models from labeled and unlabeled spectra.
## Dataset summary
| Property | Value |
|---|---:|
| Number of spectra | 4,500,000 |
| Peaks per spectrum | 150 |
| Spectrum dtype | `float32` |
| Precursor charge range | 1-10 |
| Peptide labels | None |
| Peak-array size | Approximately 5.4 GB |
The dataset contains no peptide sequences, modified sequences, protein
accessions, database-search scores, or other identification labels.
## Files and schema
```text
DarkSpec/
├── manifest.json
├── precursor.npy
└── spectra.npy
```
| File | Shape | Dtype | Description |
|---|---:|---|---|
| `spectra.npy` | `(4,500,000, 150, 2)` | `float32` | Fragment m/z and normalized intensity |
| `precursor.npy` | `(4,500,000, 2)` | `float32` | Precursor m/z and precursor charge |
| `manifest.json` | - | JSON | Shape and preprocessing metadata |
For `spectra.npy`, `spectra[i, :, 0]` stores m/z values and
`spectra[i, :, 1]` stores intensities. Spectra with fewer than 150 retained
peaks are zero padded.
## Download
```bash
pip install -U huggingface_hub
hf download PanLiu/DarkSpec \
--repo-type dataset \
--local-dir DarkSpec
```
## Loading
Memory mapping is recommended:
```python
import json
import numpy as np
root = "DarkSpec"
spectra = np.load(f"{root}/spectra.npy", mmap_mode="r")
precursors = np.load(f"{root}/precursor.npy", mmap_mode="r")
with open(f"{root}/manifest.json") as handle:
manifest = json.load(handle)
mz = spectra[0, :, 0]
intensity = spectra[0, :, 1]
precursor_mz, precursor_charge = precursors[0]
print(spectra.shape)
print(precursors.shape)
print(manifest)
```
## Preprocessing
The released array store applies the following fixed preprocessing:
- precursor charge between 1 and 10;
- fragment m/z between 50.52564895 and 2500 Da;
- peaks within 2 Da of precursor m/z removed;
- relative intensity threshold of 0.01;
- at least 20 valid peaks required;
- at most 150 peaks retained;
- retained peaks sorted by m/z;
- duplicate-like spectra reduced using 32-bit spectral SimHash grouping.
The exact frozen preprocessing metadata is also stored in `manifest.json`.
## Intended use
DarkSpec is intended for:
- semi-supervised de novo peptide sequencing;
- self-supervised spectrum representation learning;
- robustness and domain-shift studies for tandem mass spectra;
- reproducible benchmarking of unlabeled-spectrum learning methods.
It is not intended to provide peptide identifications or to replace
database-search validation.
## Limitations
- DarkSpec is unlabeled, so individual peptide identities are unknown.
- PRIDE acquisition protocols, instruments, collision settings, and biological
sources are heterogeneous.
- Quality filtering reduces obvious invalid spectra but does not guarantee that
every retained spectrum is identifiable.
- Models trained on DarkSpec should still be evaluated on held-out labeled
benchmarks.
## Code
Training and evaluation code is available at:
<https://github.com/grandOrgan/Seminovo>
## License
The released dataset package is provided under the MIT License. Users remain
responsible for following applicable terms associated with the original PRIDE
source projects.
|