File size: 7,797 Bytes
2defbcb 581838b 2defbcb 581838b 2defbcb 581838b 2defbcb 581838b | 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 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 | ---
pretty_name: SwissSidechain Residues
license: other
tags:
- biology
- chemistry
- protein
- amino-acids
- sidechains
- molecular-dynamics
- smiles
- pdb
- mol2
- parquet
configs:
- config_name: default
data_files:
- split: train
path: data/train-*.parquet
- split: test
path: data/test-*.parquet
---
# SwissSidechain Residues
SwissSideChain is a molecular and structural database of non-natural amino-acid sidechains, including structures, rotamers, and molecular mechanics parameters.
This dataset contains a viewer-friendly Parquet table derived from the SwissSidechain archives in this repository. Each row is one unique residue entry from the L or D SMI archives, with parsed availability and summary fields for PDB, MOL2, CHARMM topology, GROMACS RTP/HDB, bundle files, and rotamer libraries.
The original ZIP archives remain in the repository. The default `datasets` configuration uses the normalized Parquet files under `data/` so that the Hugging Face Dataset Viewer and `load_dataset()` can read the residue table directly.
The source library comments state that the SwissSidechain entries are copyright of the Swiss Institute of Bioinformatics, with non-profit use allowed when the content is not modified and the copyright statement is retained. Commercial use requires a license agreement. Check the original SwissSidechain terms before commercial use.
## Splits
The split is deterministic by entry identifier: `sha256(entry_id) % 10`. Bucket `0` is `test`; buckets `1` through `9` are `train`.
| Split | Rows |
|---|---:|
| train | 400 |
| test | 59 |
| total | 459 |
## Dataset Statistics
| Field | Value |
|---|---:|
| Unique residue entries | 459 |
| L entries | 230 |
| D entries | 229 |
| Entries with PDB | 459 |
| Entries with MOL2 | 459 |
| Entries with CHARMM topologies | 437 |
| Entries with GROMACS RTP/HDB | 437 |
| Entries with source bundles | 459 |
| Entries with backbone-dependent rotamers | 454 |
| Entries with backbone-independent rotamers | 453 |
| Backbone-dependent rotamer rows | 15,256,136 |
| Backbone-independent rotamer rows | 11,144 |
## Usage
Install the Hugging Face Datasets library:
```bash
pip install datasets
```
Load all splits:
```python
from datasets import load_dataset
ds = load_dataset("LiteFold/SwissSidechain")
print(ds)
row = ds["train"][0]
print(row["entry_id"], row["residue_code"], row["smiles"])
```
Load one split:
```python
from datasets import load_dataset
train = load_dataset("LiteFold/SwissSidechain", split="train")
test = load_dataset("LiteFold/SwissSidechain", split="test")
```
Stream rows without downloading the full table first:
```python
from datasets import load_dataset
stream = load_dataset("LiteFold/SwissSidechain", split="train", streaming=True)
for row in stream.take(5):
print(row["entry_id"], row["stereochemistry"], row["pdb_atom_count"])
```
Filter D residues with complete topology files:
```python
from datasets import load_dataset
ds = load_dataset("LiteFold/SwissSidechain", split="train")
d_topologies = ds.filter(
lambda row: row["stereochemistry"] == "D"
and row["has_top"]
and row["has_rtp"]
and row["has_hdb"]
)
print(d_topologies[0])
```
Find entries with rotamer data:
```python
from datasets import load_dataset
ds = load_dataset("LiteFold/SwissSidechain", split="train")
with_rotamers = ds.filter(lambda row: row["bbdep_rotamer_rows"] > 0)
print(with_rotamers[0]["entry_id"], with_rotamers[0]["bbdep_rotamer_rows"])
```
Load metadata tables directly:
```python
import pandas as pd
from huggingface_hub import hf_hub_download
rotamer_path = hf_hub_download(
repo_id="LiteFold/SwissSidechain",
repo_type="dataset",
filename="metadata/rotamer_library_counts.parquet",
)
rotamers = pd.read_parquet(rotamer_path)
print(rotamers.head())
manifest_path = hf_hub_download(
repo_id="LiteFold/SwissSidechain",
repo_type="dataset",
filename="metadata/archive_manifest.parquet",
)
manifest = pd.read_parquet(manifest_path)
print(manifest)
```
## Columns
| Column | Description |
|---|---|
| `entry_id` | Stable table ID in the form `L:<code>` or `D:<code>`. |
| `residue_code` | Residue code from the source file names. |
| `stereochemistry` | Source stereochemistry group: `L` or `D`. |
| `smiles` | SMILES string from the SMI archive. |
| `smiles_reference_file` | Filename referenced inside the SMI row. |
| `source_*_path` | Source archive path used for each parsed format. |
| `has_smi` | Whether an SMI file exists. |
| `has_pdb` | Whether a PDB file exists. |
| `has_mol2` | Whether a MOL2 file exists. |
| `has_top` | Whether a CHARMM `.top` file exists. |
| `has_rtp` | Whether a GROMACS `.rtp` file exists. |
| `has_hdb` | Whether a GROMACS `.hdb` file exists. |
| `has_bundle` | Whether the entry appears in `L_sidechain.zip` or `D_residues.zip`. |
| `has_png` | Whether the source bundle contains a PNG image. |
| `has_bundle_bbdep_lib` | Whether the source bundle contains a per-entry backbone-dependent rotamer ZIP. |
| `has_bundle_bbind_lib` | Whether the source bundle contains a per-entry backbone-independent rotamer ZIP. |
| `bundle_file_extensions` | File extensions found in the source bundle. |
| `pdb_residue_names` | Residue names parsed from PDB records. |
| `pdb_atom_names` | Atom names parsed from PDB records. |
| `pdb_elements` | Element symbols parsed from PDB records. |
| `pdb_atom_count` | Number of PDB atoms. |
| `pdb_heavy_atom_count` | Number of non-hydrogen PDB atoms. |
| `pdb_hydrogen_atom_count` | Number of hydrogen PDB atoms. |
| `mol2_molecule_name` | Molecule name from the MOL2 file. |
| `mol2_molecule_type` | MOL2 molecule type. |
| `mol2_charge_type` | MOL2 charge type. |
| `mol2_atom_names` | Atom names parsed from MOL2. |
| `mol2_atom_types` | Atom types parsed from MOL2. |
| `mol2_atom_charges` | Partial charges parsed from MOL2. |
| `mol2_atom_count` | Number of MOL2 atoms. |
| `mol2_bond_count` | Number of MOL2 bonds. |
| `mol2_total_partial_charge` | Sum of MOL2 partial charges. |
| `charmm_residue_name` | Residue name parsed from CHARMM `RESI`. |
| `charmm_residue_charge` | Residue charge parsed from CHARMM `RESI`. |
| `charmm_residue_comment` | Comment attached to the CHARMM `RESI` line. |
| `charmm_atom_names` | Atom names from CHARMM topology. |
| `charmm_atom_types` | Atom types from CHARMM topology. |
| `charmm_atom_charges` | Atom charges from CHARMM topology. |
| `charmm_atom_count` | Number of CHARMM atoms. |
| `charmm_bond_count` | Number of CHARMM bond pairs. |
| `gromacs_residue_name` | Residue name from GROMACS RTP. |
| `gromacs_residue_comment` | Comment attached to the GROMACS residue header. |
| `gromacs_atom_names` | Atom names from GROMACS RTP. |
| `gromacs_atom_types` | Atom types from GROMACS RTP. |
| `gromacs_atom_charges` | Atom charges from GROMACS RTP. |
| `gromacs_atom_count` | Number of GROMACS RTP atoms. |
| `gromacs_bond_count` | Number of GROMACS RTP bonds. |
| `gromacs_improper_count` | Number of GROMACS RTP impropers. |
| `hdb_rule_count` | Number of hydrogen database rules. |
| `hdb_declared_rule_count` | Rule count declared in the HDB header. |
| `bbind_rotamer_rows` | Rows in the backbone-independent rotamer library for this residue code. |
| `bbdep_rotamer_rows` | Rows in the backbone-dependent rotamer library for this residue code. |
| `split_bucket` | Deterministic split bucket from `sha256(entry_id) % 10`. |
# Citation
```
@article{gfeller2013swisssidechain,
title = {{SwissSidechain}: a molecular and structural database of non-natural sidechains},
author = {Gfeller, David and Michielin, Olivier and Zoete, Vincent},
journal = {Nucleic Acids Research},
volume = {41},
number = {D1},
pages = {D327--D332},
year = {2013},
doi = {10.1093/nar/gks991}
}
``` |