Dataset Viewer
Auto-converted to Parquet Duplicate
primaryAccession
stringlengths
6
10
sequence
stringlengths
2
1.02k
length
int32
2
1.02k
clusterSize
int32
1
1.71k
faissRow
int64
2
570k
embedding
list
Q57794
MVIMPFVHYIDEENFDDKLKEWTLGLNSDYVNPYDSGETQYINSNYPWPANINSLSSKICEMGLIEMDGVEIRSVPLHWVSTVSVPTAPSSSFVFNIPSMFQECMYECHIYNLPPDAGVTATYNAYFDNNFPIPYKYTLTIQTSADDMFNNQDYKIWMNGTWGPSFHIPESGTKILEFPIKYGKLNISFGISGSSLTVTLMWIIENNNINDFFDPDTEDYWQLIGRNINIVFGNFLPKHFPRGYINPIQNRTYLEKRILNTGDASNPTTIEYLWGSVTLLPDLESWQFYDDKGNSVDSKYATISDDGYVSIYYEEMIKDG...
795
1
2
[ -0.039829790592193604, -0.004164255224168301, -0.007934929803013802, 0.0183609239757061, -0.045303910970687866, -0.016470465809106827, -0.005757706705480814, 0.02806692011654377, -0.008997357450425625, 0.010903025045990944, -0.03048981912434101, 0.02756156586110592, -0.0027916894759982824, ...
Q54CZ2
MNSSSNIIYKSFKNSKIFLNKQCIINNGLKLNKKYFTTTSTKENNNNNNNKNPKFIENNLFQKGLLTIGSAFVAFINPGRGDMVATLGEMTGGCAIKSMKQKMMLDPIGRQLLKEKPRIKESTYPLNIHLLPSTTFGGAYYRWMKEHGYSPDERTEVTLIQDEDDAYVMQRYREVHDFWHVLAGVRPDFQGEVAIKWFEFLQTGLPMNAIGSIIGPLRCSWNERNELINHMIPWAIKSSKSCVYLMNVKYEDHWEDDLNEFRAKLNFIPYKYLSDINQNKTTTINM
286
1
6
[ 0.01612970419228077, -0.04600759223103523, -0.00979373324662447, 0.012935211881995201, -0.03212256729602814, 0.04485981538891792, -0.01344207115471363, 0.04996369034051895, -0.03301374241709709, 0.05600506812334061, 0.02628316357731819, -0.005395310930907726, 0.00039743472007103264, -0.040...
Q7RYU8
MSGDDDWWTSSNEALLVSLVTPSDTGVKTLDTFHPEYTNNIFGEKEQIFGYKGLRINLQYNASDMLPNLKVSYKKKYQPTADEEALDINEVLSEFLPEIAFQKQSDFETRLKSIPDNWTPPGTLVTSFTNKDGEYEVYSGKITDPAVKQLLNRIQILVPFFVDGGTPIDMEDPDVDRWTIYFLYNKRPLLNQPDKFSYHFAGYSTLYRYYAFQPPAESESKTPTDTPTFSVDGDFDLDTLPCRTRISQFIIIPPFQQKGLGSRLYSIIYQQYLKHEPTIELTVEDPNEAFDDMRDLADLAFLSKQPEFQALKIDTSVEIP...
508
1
8
[ -0.01542370393872261, -0.0727374404668808, -0.05080176517367363, 0.005716660991311073, 0.035591185092926025, -0.01220215205103159, -0.021746844053268433, -0.028476953506469727, 0.011199330911040306, 0.059053316712379456, -0.07720926403999329, -0.0243621077388525, -0.0041733914986252785, -0...
Q8P9S7
MTHTNGFDALHAHAQRLRGAAIPALLAAEPQRPTQYARQVGPLYFNFARQKYDRAALDALFAIARERDLAGAFQRLFRGEQVNVTEQRAALHTALRGDLTDAPVASDAYATAAEVRQRVGALIQQLEGTDVTDIVSVGIGGSDLGPRLVADALRAPSGARFRVHFVSNVDGAAMQRTLATLDPARTAGILISKTFGTQETLLNGSILHAWLGGSERLYAVSANPERAAKAFDIAPGRVLPMWDWVGGRYSLWSAVGFPIALAIGFERFEQLLDGAAQFDAHVLNTPLEENVAVLHGLTAVWNRNLLGSATHAVMTYDQRL...
504
15
13
[ 0.017451172694563866, -0.013192463666200638, -0.015418138355016708, 0.021721405908465385, 0.016910424456000328, -0.0015566799556836486, -0.016384366899728775, -0.015798039734363556, -0.0014084276044741273, 0.037617892026901245, -0.03608396649360657, 0.005236363969743252, 0.007677942514419556...
D0VWM8
MADETPKVKTEPAAEVKSPLDEVKEIRKEAELTQTGSDEKKTTDPEFITVQDPNGDEPIELPTVDGVVLMTTLQASFPGATGLKYKNPKTGANRAVQVDPSGLKLIAPADGWENKTFFVIVAPQSERVRALSSADATSAKRRKVGSSDDSDSDDGRDGRSGRKRAVERDSQPVDLIVLGVDFKTTDECFQKYFEDIGTVVFCEIKRKSDGNSKGFGFVRMSSVGEQNKVLAIPQHMIDGRRCDVKVPDGRSLQDKQGRPSISRIFVGRLTDKVDEHQLRKVFGDEAKSYIETAVVTDVFIPKPFRGFAFVTLSSAEAAER...
414
1
16
[ -0.02659659832715988, -0.02731979452073574, 0.014433227479457855, 0.0016388664953410625, -0.038582880049943924, -0.03120115026831627, -0.047245822846889496, -0.030186131596565247, -0.055515460669994354, 0.06638694554567337, -0.03868765011429787, -0.04716296121478081, 0.03427060320973396, -...
P23553
MAIMQINFYSKMLKKNTTILAILPVDKPDKKFQKDVDSENLKTLYLLHGYAGNYMDWLCGARIVELSMRYNVAVFLPSGENSFYLDDEEKEEYFGEFVGNEIIEFTRSVFPIPQKREKTFIGGLSMGGYGALRNGLKYNKNFVGIIALSSALIIHKIAGIPKDYRNAYASYNYYRRVFGDLNSLIGSDKDINALVTKLKQEKGSIPKIYMACGRDDFLVQENRDLFNFLKNEGIDVVYEEDEGGHDWDFWNKYIANAFEWMSKVSD
266
1
18
[ 0.0045618596486747265, -0.050384439527988434, -0.04458633437752724, -0.02972450852394104, 0.05076323449611664, 0.010072766803205013, 0.009104677475988865, -0.02035895176231861, -0.02595694549381733, 0.05901866778731346, -0.07216000556945801, 0.03207968547940254, 0.012013564817607403, -0.01...
P0A1U1
MSAVLTAEQALKLVGEMFVYHMPFNRALGLELERYEKAFAQLAFNNQPMMVGNWAQSILHGGVIASALDVAAGLVCVGSTLTRHETISEDELRQRLSRMGTIDLRVDYLRPGRGNRFTATSSLLRAGNKVAVARVELHNEDQLYIASATATYMVG
155
5
28
[ 0.02165585570037365, -0.005688847973942757, -0.021676141768693924, 0.024922095239162445, 0.05546709895133972, 0.01457881461828947, -0.0025725180748850107, 0.026598438620567322, 0.007414680905640125, 0.028997380286455154, 0.04557044804096222, -0.001227626926265657, -0.02946411818265915, -0....
Q9HA38
MILLQHAVLPPPKQPSPSPPMSVATRSTGTLQLPPQKPFGQEASLPLAGEEELSKGGEQDCALEELCKPLYCKLCNVTLNSAQQAQAHYQGKNHGKKLRNYYAANSCPPPARMSNVVEPAATPVVPVPPQMGSFKPGGRVILATENDYCKLCDASFSSPAVAQAHYQGKNHAKRLRLAEAQSNSFSESSELGQRRARKEGNEFKMMPNRRNMYTVQNNSAGPYFNPRSRQRIPRDLAMCVTPSGQFYCSMCNVGAGEEMEFRQHLESKQHKSKVSEQRYRNEMENLGYV
289
4
34
[ -0.03841717913746834, -0.03752781078219414, -0.09979605674743652, 0.008663059212267399, 0.03867211565375328, -0.029601698741316795, 0.012950420379638672, -0.014815544709563255, -0.045507535338401794, 0.02340942807495594, -0.05599066615104675, 0.004343122243881226, 0.005361798219382763, -0....
P0A9W7
MENNEIQSVLMNALSLQEVHVSGDGSHFQVIAVGELFDGMSRVKKQQTVYGPLMEYIADNRIHAVSIKAYTPAEWARDRKLNGF
84
3
38
[-0.0005762568325735629,-0.004089873284101486,-0.04142783209681511,0.020740676671266556,0.0281568318(...TRUNCATED)
A6L8E9
"MLYIEVLLLAIGLSMDSLAVSVTGGAVLKNNCTAGNIIKIASVLGIFQAGMTVIGYTMGLGFEKYICAFDHWIAFTLLLYLGGKMIYDSTKEEEEDGKF(...TRUNCATED)
188
1
39
[-0.0034092646092176437,-0.039548713713884354,0.012067843228578568,-0.04213137552142143,0.0765383765(...TRUNCATED)
End of preview. Expand in Data Studio

ProTrek-650M Swiss-Prot 50% representatives (sequence + embedding)

Swiss-Prot protein sequences paired with their ProTrek-650M embeddings, clustered to 50% sequence identity so each row is one cluster representative. Built for training models that decode an amino acid sequence from a protein embedding (inverse folding / embedding-to-sequence), but usable wherever you need Swiss-Prot sequences with fixed ProTrek vectors.

  • 118,576 cluster representatives, each with a 1024-dim L2-normalised embedding
  • Deduplicated at 50% identity, so rows are far less redundant than raw Swiss-Prot
  • Split into 100,000 train / 11,002 test, with sequence-identity groups held on one side
  • One self-contained parquet per split: sequence and embedding sit on the same row

Files

File Rows Size Contents
train.parquet 100,000 415 MB Training split
test.parquet 11,002 46 MB Held-out test split
excluded.parquet 7,574 36 MB Representatives left out of both splits, with exclusionReason
split_ids.tsv — 1.4 MB split + primaryAccession, so the split can be reproduced
manifest.json — — Counts, sha256 per file, upstream revisions, exclusion breakdown

train.parquet + test.parquet + excluded.parquet covers all 118,576 representatives. Every representative from the upstream index appears in exactly one file.

Schema

All three parquet files share these columns:

Column Type Description
primaryAccession string UniProt accession, e.g. P04637
sequence string Amino acid sequence (one-letter code)
length int32 Residue count
clusterSize int32 Number of sequences in this representative's 50% cluster
faissRow int64 Row index in the upstream faiss index (569,792 vectors)
embedding fixed_size_list<float32>[1024] ProTrek-650M protein vector, L2-normalised

excluded.parquet adds exclusionReason (string).

Usage

from datasets import load_dataset

ds = load_dataset("parquet", data_files={
    "train": "hf://datasets/yosshstd/protrek650m-swissprot50-reps/train.parquet",
    "test":  "hf://datasets/yosshstd/protrek650m-swissprot50-reps/test.parquet",
})

row = ds["train"][0]
row["primaryAccession"]  # 'Q57794'
row["sequence"]          # 'MVIMPFVHYI...'
row["embedding"]         # list of 1024 float32

Or with pandas / pyarrow:

import pandas as pd
df = pd.read_parquet("train.parquet")

embedding arrives as List(Value("float32"), length=1024); numpy.asarray(row["embedding"]) gives a (1024,) array. The vectors are not re-normalised on read, and they are stored as float32 without loss.

Data

Sequences. UniProt Swiss-Prot, as mirrored in westlake-repl/faiss_index under SwissProt/ProTrek_650M_UniRef50/sequence/ (revision 897d3661). The upstream file has 569,792 sequences; ids.tsv row order equals faiss vector id.

Clustering. MMseqs2 easy-cluster with --min-seq-id 0.5 --cov-mode 1 -c 0.8 --cluster-mode 0 (version 8cc5ce3) reduces those 569,792 sequences to 118,576 representatives. clusterSize is the full cluster size, so it can be used for weighting if you want to approximate the unclustered distribution.

Embeddings. Read straight out of the upstream faiss IndexFlatIP (dimension 1024) at each representative's faissRow. They are the index's stored vectors, not recomputed, so they match the upstream index exactly. All norms are 1.0 to within 1e-6.

Split. split_ids.tsv is derived from the seed-42 assignment; keep it with the data if you need to reproduce the exact split. The split is stratified over length buckets (0-50, 50-100, 100-200, 200-400, 400-800, 800-1024) so the length distribution is close between train and test.

What was excluded, and why

The 7,574 rows in excluded.parquet are representative sequences that a ProTrek-conditioned sequence model cannot learn from:

Reason Rows
Longer than 1024 residues 6,723
Non-standard residues (X, U, B, Z, O) 851

ProTrek-650M encodes only the first 1024 residues (plus a CLS/EOS token), so for a longer protein the embedding describes a prefix while the sequence describes the whole protein — the pair would be silently inconsistent. Non-standard residues are ambiguous or non-canonical and are left out so the target alphabet stays the 20 standard amino acids.

They are published rather than dropped so the filter is auditable and reversible. Note that for the 6,723 long sequences, the embedding is still the ProTrek vector of the full (truncated at 1024) input, so the row is a valid embedding — just a target sequence that does not correspond one-to-one to it.

Known characteristics

  • 15 rows share a sequence with another row (6 sequence groups, all short peptides of 7–11 residues whose clusters each had size 1). Their embeddings are identical because ProTrek is deterministic, and all duplicates sit on the same side of the split. This is why the split has 99,992 unique sequences in 100,000 train rows and 11,001 in 11,002 test rows.
  • faissRow indexes the 569,792-vector upstream index, not these files. Do not use it as a row index here; rows in these files are independent.
  • Lengths range from 2 to 1024 residues (max 34,350 in excluded.parquet). Mean length is ~339 residues in the eligible set.
  • clusterSize is almost always small (median 1, max 1,714), so unweighted training heavily favours singleton clusters — arguably the point of 50% clustering, but worth knowing.

Provenance

Item Value
Upstream embeddings westlake-repl/faiss_index @ 897d3661620e991653bba48cc2dac12bc54fa5e1
Clustering MMseqs2 8cc5ce367b5638c4306c2d7cfc652dd099a4643f
Built by build_hf_dataset.py in yosshstd/protein-generation
Seed 42

Rebuilding with the same inputs and seed reproduces the files bit for bit; the sha256 values in manifest.json are checked by the build script.

Citation

The embeddings come from ProTrek. If you use this dataset, please cite the ProTrek paper:

@article{su2024protrek,
  title   = {ProTrek: Navigating the Protein Universe through Tri-Modal Contrastive Learning},
  author  = {Su, Jin and Zhou, Xibin and Zhang, Xuting and Yuan, Fajie},
  journal = {bioRxiv},
  year    = {2024},
  doi     = {10.1101/2024.05.30.596740}
}

Please also follow the terms of UniProt (the sequence source) and of the upstream westlake-repl/faiss_index dataset.

Downloads last month
60