atomic-datasets 0.1.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- atomic_datasets-0.1.0/.gitignore +168 -0
- atomic_datasets-0.1.0/.python-version +1 -0
- atomic_datasets-0.1.0/CITATION.cff +12 -0
- atomic_datasets-0.1.0/LICENSE +21 -0
- atomic_datasets-0.1.0/PKG-INFO +414 -0
- atomic_datasets-0.1.0/README.md +362 -0
- atomic_datasets-0.1.0/atomic_datasets/__init__.py +3 -0
- atomic_datasets-0.1.0/atomic_datasets/datasets/__init__.py +15 -0
- atomic_datasets-0.1.0/atomic_datasets/datasets/chembl3d.py +205 -0
- atomic_datasets-0.1.0/atomic_datasets/datasets/crossdocked.py +167 -0
- atomic_datasets-0.1.0/atomic_datasets/datasets/geom_drugs.py +209 -0
- atomic_datasets-0.1.0/atomic_datasets/datasets/platonic_solids.py +135 -0
- atomic_datasets-0.1.0/atomic_datasets/datasets/proteins.py +672 -0
- atomic_datasets-0.1.0/atomic_datasets/datasets/qm9.py +308 -0
- atomic_datasets-0.1.0/atomic_datasets/datasets/tetris.py +51 -0
- atomic_datasets-0.1.0/atomic_datasets/datasets/tmqm.py +475 -0
- atomic_datasets-0.1.0/atomic_datasets/datatypes.py +61 -0
- atomic_datasets-0.1.0/atomic_datasets/utils/__init__.py +14 -0
- atomic_datasets-0.1.0/atomic_datasets/utils/cache.py +95 -0
- atomic_datasets-0.1.0/atomic_datasets/utils/decorators.py +9 -0
- atomic_datasets-0.1.0/atomic_datasets/utils/download.py +99 -0
- atomic_datasets-0.1.0/atomic_datasets/utils/periodic_table.py +59 -0
- atomic_datasets-0.1.0/atomic_datasets/utils/rdkit.py +79 -0
- atomic_datasets-0.1.0/atomic_datasets/utils/visualizer.py +112 -0
- atomic_datasets-0.1.0/atomic_datasets/utils/xyz.py +24 -0
- atomic_datasets-0.1.0/atomic_datasets/wrappers/__init__.py +0 -0
- atomic_datasets-0.1.0/atomic_datasets/wrappers/jax.py +99 -0
- atomic_datasets-0.1.0/atomic_datasets/wrappers/torch.py +104 -0
- atomic_datasets-0.1.0/atomic_datasets.egg-info/PKG-INFO +414 -0
- atomic_datasets-0.1.0/atomic_datasets.egg-info/SOURCES.txt +46 -0
- atomic_datasets-0.1.0/atomic_datasets.egg-info/dependency_links.txt +1 -0
- atomic_datasets-0.1.0/atomic_datasets.egg-info/requires.txt +13 -0
- atomic_datasets-0.1.0/atomic_datasets.egg-info/top_level.txt +1 -0
- atomic_datasets-0.1.0/examples/.gitignore +1 -0
- atomic_datasets-0.1.0/examples/jax.ipynb +106 -0
- atomic_datasets-0.1.0/examples/torch.ipynb +104 -0
- atomic_datasets-0.1.0/examples/viz.ipynb +197 -0
- atomic_datasets-0.1.0/pyproject.toml +71 -0
- atomic_datasets-0.1.0/requirements-dev.in +3 -0
- atomic_datasets-0.1.0/requirements.in +8 -0
- atomic_datasets-0.1.0/scripts/preprocess_chembl3d.py +403 -0
- atomic_datasets-0.1.0/scripts/preprocess_crossdocked.py +372 -0
- atomic_datasets-0.1.0/scripts/preprocess_geom.py +433 -0
- atomic_datasets-0.1.0/scripts/upload_to_zenodo.py +183 -0
- atomic_datasets-0.1.0/setup.cfg +4 -0
- atomic_datasets-0.1.0/tests/wrappers/jax.py +115 -0
- atomic_datasets-0.1.0/tests/wrappers/torch.py +136 -0
- atomic_datasets-0.1.0/uv.lock +1730 -0
|
@@ -0,0 +1,168 @@
|
|
|
1
|
+
# Byte-compiled / optimized / DLL files
|
|
2
|
+
__pycache__/
|
|
3
|
+
*.py[cod]
|
|
4
|
+
*$py.class
|
|
5
|
+
|
|
6
|
+
# C extensions
|
|
7
|
+
*.so
|
|
8
|
+
|
|
9
|
+
# Distribution / packaging
|
|
10
|
+
.DS_Store
|
|
11
|
+
.Python
|
|
12
|
+
build/
|
|
13
|
+
develop-eggs/
|
|
14
|
+
dist/
|
|
15
|
+
downloads/
|
|
16
|
+
eggs/
|
|
17
|
+
.eggs/
|
|
18
|
+
lib/
|
|
19
|
+
lib64/
|
|
20
|
+
parts/
|
|
21
|
+
sdist/
|
|
22
|
+
var/
|
|
23
|
+
wheels/
|
|
24
|
+
share/python-wheels/
|
|
25
|
+
*.egg-info/
|
|
26
|
+
.installed.cfg
|
|
27
|
+
*.egg
|
|
28
|
+
MANIFEST
|
|
29
|
+
|
|
30
|
+
# PyInstaller
|
|
31
|
+
# Usually these files are written by a python script from a template
|
|
32
|
+
# before PyInstaller builds the exe, so as to inject date/other infos into it.
|
|
33
|
+
*.manifest
|
|
34
|
+
*.spec
|
|
35
|
+
|
|
36
|
+
# Installer logs
|
|
37
|
+
pip-log.txt
|
|
38
|
+
pip-delete-this-directory.txt
|
|
39
|
+
|
|
40
|
+
# Unit test / coverage reports
|
|
41
|
+
htmlcov/
|
|
42
|
+
.tox/
|
|
43
|
+
.nox/
|
|
44
|
+
.coverage
|
|
45
|
+
.coverage.*
|
|
46
|
+
.cache
|
|
47
|
+
nosetests.xml
|
|
48
|
+
coverage.xml
|
|
49
|
+
*.cover
|
|
50
|
+
*.py,cover
|
|
51
|
+
.hypothesis/
|
|
52
|
+
.pytest_cache/
|
|
53
|
+
cover/
|
|
54
|
+
|
|
55
|
+
# Translations
|
|
56
|
+
*.mo
|
|
57
|
+
*.pot
|
|
58
|
+
|
|
59
|
+
# Django stuff:
|
|
60
|
+
*.log
|
|
61
|
+
local_settings.py
|
|
62
|
+
db.sqlite3
|
|
63
|
+
db.sqlite3-journal
|
|
64
|
+
|
|
65
|
+
# Flask stuff:
|
|
66
|
+
instance/
|
|
67
|
+
.webassets-cache
|
|
68
|
+
|
|
69
|
+
# Scrapy stuff:
|
|
70
|
+
.scrapy
|
|
71
|
+
|
|
72
|
+
# Sphinx documentation
|
|
73
|
+
docs/_build/
|
|
74
|
+
|
|
75
|
+
# PyBuilder
|
|
76
|
+
.pybuilder/
|
|
77
|
+
target/
|
|
78
|
+
|
|
79
|
+
# Jupyter Notebook
|
|
80
|
+
.ipynb_checkpoints
|
|
81
|
+
|
|
82
|
+
# IPython
|
|
83
|
+
profile_default/
|
|
84
|
+
ipython_config.py
|
|
85
|
+
|
|
86
|
+
# pyenv
|
|
87
|
+
# For a library or package, you might want to ignore these files since the code is
|
|
88
|
+
# intended to run in multiple environments; otherwise, check them in:
|
|
89
|
+
# .python-version
|
|
90
|
+
|
|
91
|
+
# pipenv
|
|
92
|
+
# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
|
|
93
|
+
# However, in case of collaboration, if having platform-specific dependencies or dependencies
|
|
94
|
+
# having no cross-platform support, pipenv may install dependencies that don't work, or not
|
|
95
|
+
# install all needed dependencies.
|
|
96
|
+
#Pipfile.lock
|
|
97
|
+
|
|
98
|
+
# poetry
|
|
99
|
+
# Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control.
|
|
100
|
+
# This is especially recommended for binary packages to ensure reproducibility, and is more
|
|
101
|
+
# commonly ignored for libraries.
|
|
102
|
+
# https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control
|
|
103
|
+
#poetry.lock
|
|
104
|
+
|
|
105
|
+
# pdm
|
|
106
|
+
# Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control.
|
|
107
|
+
#pdm.lock
|
|
108
|
+
# pdm stores project-wide configurations in .pdm.toml, but it is recommended to not include it
|
|
109
|
+
# in version control.
|
|
110
|
+
# https://pdm.fming.dev/latest/usage/project/#working-with-version-control
|
|
111
|
+
.pdm.toml
|
|
112
|
+
.pdm-python
|
|
113
|
+
.pdm-build/
|
|
114
|
+
|
|
115
|
+
# PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm
|
|
116
|
+
__pypackages__/
|
|
117
|
+
|
|
118
|
+
# Celery stuff
|
|
119
|
+
celerybeat-schedule
|
|
120
|
+
celerybeat.pid
|
|
121
|
+
|
|
122
|
+
# SageMath parsed files
|
|
123
|
+
*.sage.py
|
|
124
|
+
|
|
125
|
+
# Environments
|
|
126
|
+
.env
|
|
127
|
+
.venv
|
|
128
|
+
env/
|
|
129
|
+
venv/
|
|
130
|
+
ENV/
|
|
131
|
+
env.bak/
|
|
132
|
+
venv.bak/
|
|
133
|
+
|
|
134
|
+
# Spyder project settings
|
|
135
|
+
.spyderproject
|
|
136
|
+
.spyproject
|
|
137
|
+
|
|
138
|
+
# Rope project settings
|
|
139
|
+
.ropeproject
|
|
140
|
+
|
|
141
|
+
# mkdocs documentation
|
|
142
|
+
/site
|
|
143
|
+
|
|
144
|
+
# mypy
|
|
145
|
+
.mypy_cache/
|
|
146
|
+
.dmypy.json
|
|
147
|
+
dmypy.json
|
|
148
|
+
|
|
149
|
+
# Pyre type checker
|
|
150
|
+
.pyre/
|
|
151
|
+
|
|
152
|
+
# pytype static type analyzer
|
|
153
|
+
.pytype/
|
|
154
|
+
|
|
155
|
+
# Cython debug symbols
|
|
156
|
+
cython_debug/
|
|
157
|
+
|
|
158
|
+
# PyCharm
|
|
159
|
+
# JetBrains specific template is maintained in a separate JetBrains.gitignore that can
|
|
160
|
+
# be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
|
|
161
|
+
# and can be added to the global gitignore or merged into this file. For a more nuclear
|
|
162
|
+
# option (not recommended) you can uncomment the following to ignore the entire idea folder.
|
|
163
|
+
#.idea/
|
|
164
|
+
|
|
165
|
+
data/
|
|
166
|
+
raw/
|
|
167
|
+
processed/
|
|
168
|
+
check.py
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
3.11
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
cff-version: 1.2.0
|
|
2
|
+
message: "If you use this software, please cite it as below."
|
|
3
|
+
authors:
|
|
4
|
+
- family-names: "Daigavane"
|
|
5
|
+
given-names: "Ameya"
|
|
6
|
+
orcid: "https://orcid.org/0000-0002-5116-3075"
|
|
7
|
+
- family-names: "Kim"
|
|
8
|
+
given-names: "Song"
|
|
9
|
+
title: "atomic_datasets"
|
|
10
|
+
version: 1.0.0
|
|
11
|
+
date-released: 2025-05-25
|
|
12
|
+
url: "https://github.com/atomicarchitects/datasets"
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2024 The Atomic Architects
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
|
@@ -0,0 +1,414 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: atomic-datasets
|
|
3
|
+
Version: 0.1.0
|
|
4
|
+
Summary: An easy-to-use API for popular 3D molecular datasets
|
|
5
|
+
Author: Ameya Daigavane, Song Kim
|
|
6
|
+
License: MIT License
|
|
7
|
+
|
|
8
|
+
Copyright (c) 2024 The Atomic Architects
|
|
9
|
+
|
|
10
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
11
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
12
|
+
in the Software without restriction, including without limitation the rights
|
|
13
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
14
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
15
|
+
furnished to do so, subject to the following conditions:
|
|
16
|
+
|
|
17
|
+
The above copyright notice and this permission notice shall be included in all
|
|
18
|
+
copies or substantial portions of the Software.
|
|
19
|
+
|
|
20
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
21
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
22
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
23
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
24
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
25
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
26
|
+
SOFTWARE.
|
|
27
|
+
|
|
28
|
+
Project-URL: Homepage, https://github.com/atomicarchitects/datasets
|
|
29
|
+
Project-URL: Repository, https://github.com/atomicarchitects/datasets.git
|
|
30
|
+
Classifier: Programming Language :: Python :: 3
|
|
31
|
+
Classifier: License :: OSI Approved :: MIT License
|
|
32
|
+
Classifier: Operating System :: OS Independent
|
|
33
|
+
Classifier: Topic :: Scientific/Engineering :: Physics
|
|
34
|
+
Classifier: Topic :: Scientific/Engineering :: Chemistry
|
|
35
|
+
Classifier: Topic :: Database
|
|
36
|
+
Requires-Python: >=3.10
|
|
37
|
+
Description-Content-Type: text/markdown
|
|
38
|
+
License-File: LICENSE
|
|
39
|
+
Requires-Dist: numpy
|
|
40
|
+
Requires-Dist: pandas
|
|
41
|
+
Requires-Dist: ase
|
|
42
|
+
Requires-Dist: rdkit
|
|
43
|
+
Requires-Dist: GitPython
|
|
44
|
+
Requires-Dist: tqdm
|
|
45
|
+
Requires-Dist: sh
|
|
46
|
+
Requires-Dist: biotite
|
|
47
|
+
Provides-Extra: dev
|
|
48
|
+
Requires-Dist: pytest>=7.0; extra == "dev"
|
|
49
|
+
Requires-Dist: ruff>=0.2.0; extra == "dev"
|
|
50
|
+
Requires-Dist: ipykernel>=6.0; extra == "dev"
|
|
51
|
+
Dynamic: license-file
|
|
52
|
+
|
|
53
|
+
# atomic-datasets
|
|
54
|
+
|
|
55
|
+
[](https://www.python.org/downloads/)
|
|
56
|
+
[](https://opensource.org/licenses/MIT)
|
|
57
|
+
|
|
58
|
+
This repository provides an easy (but fast!) interface to to popular 3D molecular datasets in pure [numpy](https://numpy.org/), with wrappers in [PyTorch](https://pytorch.org/) and [JAX](https://docs.jax.dev/en/latest/)!
|
|
59
|
+
|
|
60
|
+
<p align="center" width="100%">
|
|
61
|
+
<img width="2948" height="2303" alt="atomic-datasets" src="https://github.com/user-attachments/assets/6cd41eac-144d-4213-937e-494e57435195" />
|
|
62
|
+
</p>
|
|
63
|
+
|
|
64
|
+
Datasets supported:
|
|
65
|
+
- [QM9](https://www.nature.com/articles/sdata201422): ~134000 small organic molecules with quantum chemical properties.
|
|
66
|
+
- [GEOM (Drugs)](https://www.nature.com/articles/s41597-022-01288-4): a subset of the GEOM dataset containing ~300000 drug-like molecules with multiple conformers and properties.
|
|
67
|
+
- [tmQM](https://pubs.acs.org/doi/10.1021/acs.jcim.0c01041): ~86000 transition metal complexes with quantum chemical properties.
|
|
68
|
+
- [ChEMBL3D](https://chemrxiv.org/doi/10.26434/chemrxiv-2025-k4h7v): ~1800000 drug-like molecules with low-energy conformers and properties.
|
|
69
|
+
- [CrossDocked](https://pubs.acs.org/doi/full/10.1021/acs.jcim.0c00411?casa_token=2OPWUPi2RRYAAAAA%3A_1AHwm3Btx8fT00JW78Et9v8il5KU_F8mR49MPH3owHoFlVDWzlE521XtH-_Sudhskke8V9O5YL0): ~100000 protein-ligand pairs after filtering for high-quality pairs with binding pose RMSD less than 1Å.
|
|
70
|
+
|
|
71
|
+
Our hope is to standardize [processing](https://arxiv.org/abs/2505.00169v2) and splits which have long been [inconsistent](https://arxiv.org/abs/2505.00518) across different papers, and to provide a common interface across programming frameworks for working with these datasets.
|
|
72
|
+
|
|
73
|
+
We have preliminary support for the [Miniproteins](https://pubmed.ncbi.nlm.nih.gov/35332283/) dataset, a collection of protein-binding proteins upto 65 residues in length.
|
|
74
|
+
We also provide some toy datasets (Platonic Solids, 3D Tetris) for testing.
|
|
75
|
+
|
|
76
|
+
## Installation
|
|
77
|
+
|
|
78
|
+
Install directly from PyPI with [pip](https://pypi.org/project/pip/):
|
|
79
|
+
```
|
|
80
|
+
pip install atomic-datasets
|
|
81
|
+
```
|
|
82
|
+
or, from source:
|
|
83
|
+
```bash
|
|
84
|
+
git clone https://github.com/atomicarchitects/datasets.git
|
|
85
|
+
cd datasets
|
|
86
|
+
pip install -e .
|
|
87
|
+
```
|
|
88
|
+
|
|
89
|
+
## Example
|
|
90
|
+
```python
|
|
91
|
+
from atomic_datasets import QM9, GEOMDrugs
|
|
92
|
+
|
|
93
|
+
# Initialization will trigger preprocessing which may take some time,
|
|
94
|
+
# but once preprocessed, load speeds should be fast!
|
|
95
|
+
dataset = QM9(
|
|
96
|
+
root_dir="data/",
|
|
97
|
+
split="train",
|
|
98
|
+
)
|
|
99
|
+
# Or, for example:
|
|
100
|
+
# dataset = GEOMDrugs(root_dir="data/", split="train")
|
|
101
|
+
|
|
102
|
+
for graph in dataset:
|
|
103
|
+
positions = graph["nodes"]["positions"] # (N, 3) array of 3D coordinates
|
|
104
|
+
species = graph["nodes"]["species"] # (N,) array of atomic species indices
|
|
105
|
+
atom_types = graph["nodes"]["atom_types"] # (N,) array of element symbols
|
|
106
|
+
properties = graph["properties"] # dict of molecular properties
|
|
107
|
+
|
|
108
|
+
print(f"Molecule: {properties['smiles']}")
|
|
109
|
+
print(f" Atoms: {atom_types}")
|
|
110
|
+
print(f" HOMO-LUMO gap: {properties['gap']:.4f} Ha")
|
|
111
|
+
```
|
|
112
|
+
|
|
113
|
+
We also provide some simple utilities. For example, to visualize a graph with [py3Dmol](https://pypi.org/project/py3Dmol/) in a notebook:
|
|
114
|
+
```python
|
|
115
|
+
from atomic_datasets import utils
|
|
116
|
+
|
|
117
|
+
utils.visualize(graph)
|
|
118
|
+
```
|
|
119
|
+
or save a graph as a `.xyz` file:
|
|
120
|
+
```python
|
|
121
|
+
utils.save_xyz(graph, "example_graph")
|
|
122
|
+
```
|
|
123
|
+
|
|
124
|
+
See [examples/viz.ipynb](./examples/viz.ipynb) for a simple example.
|
|
125
|
+
|
|
126
|
+
### Data Format
|
|
127
|
+
|
|
128
|
+
Each sample is a dictionary with the following structure:
|
|
129
|
+
|
|
130
|
+
```python
|
|
131
|
+
{
|
|
132
|
+
"nodes": {
|
|
133
|
+
"positions": np.ndarray, # (N, 3) atomic coordinates
|
|
134
|
+
"species": np.ndarray, # (N,) integer species indices
|
|
135
|
+
"atom_types": np.ndarray, # (N,) element symbols (e.g., 'C', 'H', 'O')
|
|
136
|
+
},
|
|
137
|
+
"edges": ...,
|
|
138
|
+
"senders": ...,
|
|
139
|
+
"receivers": ...,
|
|
140
|
+
"globals": ...,
|
|
141
|
+
"n_node": np.ndarray, # number of nodes per graph
|
|
142
|
+
"n_edge": ...,
|
|
143
|
+
"properties": {...}, # dataset-specific properties
|
|
144
|
+
}
|
|
145
|
+
```
|
|
146
|
+
|
|
147
|
+
Available properties vary by dataset.
|
|
148
|
+
|
|
149
|
+
## Wrappers for PyTorch and JAX
|
|
150
|
+
|
|
151
|
+
We provide wrappers for both [PyTorch](https://pytorch.org/) via [PyTorch Geometric](https://pytorch-geometric.readthedocs.io/en/latest/):
|
|
152
|
+
```python
|
|
153
|
+
from atomic_datasets import Tetris
|
|
154
|
+
from atomic_datasets.wrappers.torch import PyTorchGeometricDataset
|
|
155
|
+
from torch_geometric.loader import DataLoader
|
|
156
|
+
|
|
157
|
+
dataset = PyTorchGeometricDataset(Tetris())
|
|
158
|
+
loader = DataLoader(dataset, batch_size=32, shuffle=True)
|
|
159
|
+
|
|
160
|
+
for batch in loader:
|
|
161
|
+
print(batch.pos.shape) # (total_atoms_in_batch, 3)
|
|
162
|
+
print(batch.species.shape) # (total_atoms_in_batch,)
|
|
163
|
+
print(batch.batch.shape) # (total_atoms_in_batch,)
|
|
164
|
+
```
|
|
165
|
+
|
|
166
|
+
and [JAX](https://docs.jax.dev/en/latest/) via [Jraph](https://github.com/google-deepmind/jraph):
|
|
167
|
+
```python
|
|
168
|
+
from atomic_datasets import Tetris
|
|
169
|
+
from atomic_datasets.wrappers.jax import JraphDataset
|
|
170
|
+
import jraph
|
|
171
|
+
|
|
172
|
+
dataset = JraphDataset(Tetris())
|
|
173
|
+
batch = jraph.batch([dataset[i] for i in range(4)])
|
|
174
|
+
|
|
175
|
+
print(batch.nodes["positions"].shape) # (16, 3)
|
|
176
|
+
print(batch.nodes["species"].shape) # (16,)
|
|
177
|
+
print(batch.n_node) # [4, 4, 4, 4]
|
|
178
|
+
```
|
|
179
|
+
|
|
180
|
+
To avoid any version conflicts, this repository does not have hard dependencies on PyTorch, JAX, or their respective graph libraries. You must install them separately if you want to use the wrappers.
|
|
181
|
+
|
|
182
|
+
See [examples/torch.ipynb](./examples/torch.ipynb) and [examples/jax.ipynb](./examples/jax.ipynb) for some simple examples.
|
|
183
|
+
|
|
184
|
+
## License
|
|
185
|
+
|
|
186
|
+
The code in this repository is released under the MIT License.
|
|
187
|
+
|
|
188
|
+
**Note:** The datasets themselves belong to their original authors and are subject to their respective licenses and terms of use. Please refer to the original sources and cite the appropriate papers (see below) when using these datasets in your work.
|
|
189
|
+
|
|
190
|
+
## Citation
|
|
191
|
+
|
|
192
|
+
If you use this repository, please cite:
|
|
193
|
+
```bibtex
|
|
194
|
+
@software{atomic_datasets,
|
|
195
|
+
title = {{atomic\_datasets}},
|
|
196
|
+
author = {Daigavane, Ameya and Kim, Song},
|
|
197
|
+
year = 2025,
|
|
198
|
+
month = may,
|
|
199
|
+
url = {https://github.com/atomicarchitects/datasets},
|
|
200
|
+
version = {1.0.0}
|
|
201
|
+
}
|
|
202
|
+
```
|
|
203
|
+
|
|
204
|
+
<details>
|
|
205
|
+
<summary><strong>Dataset-specific citations</strong> (click to expand)</summary>
|
|
206
|
+
|
|
207
|
+
### QM9
|
|
208
|
+
```bibtex
|
|
209
|
+
@article{qm9,
|
|
210
|
+
author = {Ramakrishnan, Raghunathan and Dral, Pavlo O. and Rupp, Matthias and von Lilienfeld, O. Anatole},
|
|
211
|
+
journal = {Scientific Data},
|
|
212
|
+
number = {1},
|
|
213
|
+
pages = {140022},
|
|
214
|
+
title = {Quantum chemistry structures and properties of 134 kilo molecules},
|
|
215
|
+
volume = {1},
|
|
216
|
+
year = {2014}
|
|
217
|
+
}
|
|
218
|
+
```
|
|
219
|
+
|
|
220
|
+
### GEOM
|
|
221
|
+
```bibtex
|
|
222
|
+
@article{geom,
|
|
223
|
+
author = {Axelrod, Simon and G{\'o}mez-Bombarelli, Rafael},
|
|
224
|
+
journal = {Scientific Data},
|
|
225
|
+
number = {1},
|
|
226
|
+
pages = {185},
|
|
227
|
+
title = {GEOM, energy-annotated molecular conformations for property prediction and molecular generation},
|
|
228
|
+
volume = {9},
|
|
229
|
+
year = {2022}
|
|
230
|
+
}
|
|
231
|
+
```
|
|
232
|
+
|
|
233
|
+
### tmQM
|
|
234
|
+
```bibtex
|
|
235
|
+
@article{tmQM,
|
|
236
|
+
author = {Balcells, David and Skjelstad, Bastian Bjerkem},
|
|
237
|
+
journal = {Journal of Chemical Information and Modeling},
|
|
238
|
+
month = {12},
|
|
239
|
+
number = {12},
|
|
240
|
+
pages = {6135--6146},
|
|
241
|
+
title = {tmQM Dataset---Quantum Geometries and Properties of 86k Transition Metal Complexes},
|
|
242
|
+
volume = {60},
|
|
243
|
+
year = {2020}
|
|
244
|
+
}
|
|
245
|
+
```
|
|
246
|
+
|
|
247
|
+
### ChEMBL3D
|
|
248
|
+
```bibtex
|
|
249
|
+
@article{nikitin2025scalable,
|
|
250
|
+
title={Scalable Low-Energy Molecular Conformer Generation with Quantum Mechanical Accuracy},
|
|
251
|
+
author={Nikitin, Filipp and Anstine, Dylan M and Zubatyuk, Roman and Paliwal, Saee Gopal and Isayev, Olexandr},
|
|
252
|
+
year={2025}
|
|
253
|
+
}
|
|
254
|
+
```
|
|
255
|
+
|
|
256
|
+
### CATH
|
|
257
|
+
```bibtex
|
|
258
|
+
@article{cath2021,
|
|
259
|
+
author = {Sillitoe, Ian and Bordin, Nicola and Dawson, Natalie and Waman, Vaishali P and Ashford, Paul and Scholes, Harry M and Pang, Camilla S M and Woodridge, Laurel and Rauer, Clemens and Sen, Neeladri and Abbasian, Mahnaz and Le Cornu, Sean and Lam, Su Datt and Berka, Karel and Varekova, Ivana Hutařová and Svobodova, Radka and Lees, Jon and Orengo, Christine A},
|
|
260
|
+
title = {CATH: increased structural coverage of functional space},
|
|
261
|
+
journal = {Nucleic Acids Research},
|
|
262
|
+
volume = {49},
|
|
263
|
+
number = {D1},
|
|
264
|
+
pages = {D266--D273},
|
|
265
|
+
year = {2021},
|
|
266
|
+
doi = {10.1093/nar/gkaa1079}
|
|
267
|
+
}
|
|
268
|
+
|
|
269
|
+
@article{cath2024,
|
|
270
|
+
author = {Waman, Vaishali P and Bordin, Nicola and Alcraft, Rachel and Vickerstaff, Robert and Rauer, Clemens and Chan, Qian and Sillitoe, Ian and Yamamori, Hazuki and Orengo, Christine},
|
|
271
|
+
title = {CATH 2024: CATH-AlphaFlow Doubles the Number of Structures in CATH and Reveals Nearly 200 New Folds},
|
|
272
|
+
journal = {Journal of Molecular Biology},
|
|
273
|
+
volume = {436},
|
|
274
|
+
number = {17},
|
|
275
|
+
pages = {168551},
|
|
276
|
+
year = {2024},
|
|
277
|
+
doi = {10.1016/j.jmb.2024.168551}
|
|
278
|
+
}
|
|
279
|
+
|
|
280
|
+
@article{cath1997,
|
|
281
|
+
author = {Orengo, C A and Michie, A D and Jones, S and Jones, D T and Swindells, M B and Thornton, J M},
|
|
282
|
+
title = {CATH--a hierarchic classification of protein domain structures},
|
|
283
|
+
journal = {Structure},
|
|
284
|
+
volume = {5},
|
|
285
|
+
number = {8},
|
|
286
|
+
pages = {1093--1108},
|
|
287
|
+
year = {1997},
|
|
288
|
+
doi = {10.1016/s0969-2126(97)00260-8}
|
|
289
|
+
}
|
|
290
|
+
|
|
291
|
+
@article{gene3d,
|
|
292
|
+
author = {Lewis, Tony E and Sillitoe, Ian and Dawson, Natalie and Lam, Su Datt and Clarke, Tristan and Lee, David and Orengo, Christine and Lees, Jonathan},
|
|
293
|
+
title = {Gene3D: Extensive prediction of globular domains in proteins},
|
|
294
|
+
journal = {Nucleic Acids Research},
|
|
295
|
+
volume = {46},
|
|
296
|
+
number = {D1},
|
|
297
|
+
pages = {D1282},
|
|
298
|
+
year = {2018},
|
|
299
|
+
doi = {10.1093/nar/gkx1187}
|
|
300
|
+
}
|
|
301
|
+
```
|
|
302
|
+
|
|
303
|
+
### Miniproteins
|
|
304
|
+
```bibtex
|
|
305
|
+
@article{miniproteins,
|
|
306
|
+
author = {Cao, Longxing and Coventry, Brian and Goreshnik, Inna and Huang, Buwei and Sheffler, William and Park, Joon Sung and Jude, Kevin M. and Markovi{\'c}, Iva and Kadam, Rameshwar U. and Verschueren, Koen H. G. and Verstraete, Kenneth and Walsh, Scott Thomas Russell and Bennett, Nathaniel and Phal, Ashish and Yang, Aerin and Kozodoy, Lisa and DeWitt, Michelle and Picton, Lora and Miller, Lauren and Strauch, Eva-Maria and DeBouver, Nicholas D. and Pires, Allison and Bera, Asim K. and Halabiya, Samer and Hammerson, Bradley and Yang, Wei and Bernard, Steffen and Stewart, Lance and Wilson, Ian A. and Ruohola-Baker, Hannele and Schlessinger, Joseph and Lee, Sangwon and Savvides, Savvas N. and Garcia, K. Christopher and Baker, David},
|
|
307
|
+
journal = {Nature},
|
|
308
|
+
number = {7910},
|
|
309
|
+
pages = {551--560},
|
|
310
|
+
title = {Design of protein-binding proteins from the target structure alone},
|
|
311
|
+
volume = {605},
|
|
312
|
+
year = {2022}
|
|
313
|
+
}
|
|
314
|
+
```
|
|
315
|
+
|
|
316
|
+
### CrossDocked
|
|
317
|
+
```bibtex
|
|
318
|
+
@article{doi:10.1021/acs.jcim.0c00411,
|
|
319
|
+
author = {Francoeur, Paul G. and Masuda, Tomohide and Sunseri, Jocelyn and Jia, Andrew and Iovanisci, Richard B. and Snyder, Ian and Koes, David R.},
|
|
320
|
+
title = {Three-Dimensional Convolutional Neural Networks and a Cross-Docked Data Set for Structure-Based Drug Design},
|
|
321
|
+
journal = {Journal of Chemical Information and Modeling},
|
|
322
|
+
volume = {60},
|
|
323
|
+
number = {9},
|
|
324
|
+
pages = {4200-4215},
|
|
325
|
+
year = {2020},
|
|
326
|
+
doi = {10.1021/acs.jcim.0c00411},
|
|
327
|
+
note = {PMID: 32865404},
|
|
328
|
+
url = {https://doi.org/10.1021/acs.jcim.0c00411},
|
|
329
|
+
eprint = {https://doi.org/10.1021/acs.jcim.0c00411}
|
|
330
|
+
}
|
|
331
|
+
@inproceedings{sbdd,
|
|
332
|
+
author = {Luo, Shitong and Guan, Jiaqi and Ma, Jianzhu and Peng, Jian},
|
|
333
|
+
booktitle = {Advances in Neural Information Processing Systems},
|
|
334
|
+
editor = {M. Ranzato and A. Beygelzimer and Y. Dauphin and P.S. Liang and J. Wortman Vaughan},
|
|
335
|
+
pages = {6229--6239},
|
|
336
|
+
publisher = {Curran Associates, Inc.},
|
|
337
|
+
title = {A 3D Generative Model for Structure-Based Drug Design},
|
|
338
|
+
url = {https://proceedings.neurips.cc/paper_files/paper/2021/file/314450613369e0ee72d0da7f6fee773c-Paper.pdf},
|
|
339
|
+
volume = {34},
|
|
340
|
+
year = {2021}
|
|
341
|
+
}
|
|
342
|
+
```
|
|
343
|
+
|
|
344
|
+
### 3D Tetris
|
|
345
|
+
```bibtex
|
|
346
|
+
@phdthesis{tetris,
|
|
347
|
+
author = {Smidt, Tess E.},
|
|
348
|
+
title = {Toward the Systematic Design of Complex Materials from Structural Motifs},
|
|
349
|
+
year = {2018},
|
|
350
|
+
school = {University of California, Berkeley},
|
|
351
|
+
url = {https://www.proquest.com/dissertations-theses/toward-systematic-design-complex-materials/docview/2137540057/se-2}
|
|
352
|
+
}
|
|
353
|
+
```
|
|
354
|
+
|
|
355
|
+
</details>
|
|
356
|
+
|
|
357
|
+
<details>
|
|
358
|
+
<summary><strong>Preprocessing code acknowledgments</strong> (click to expand)</summary>
|
|
359
|
+
|
|
360
|
+
Preprocessing code adapted from:
|
|
361
|
+
|
|
362
|
+
```bibtex
|
|
363
|
+
@misc{anderson2019cormorant,
|
|
364
|
+
title = {Cormorant: Covariant Molecular Neural Networks},
|
|
365
|
+
author = {Anderson, Brandon and Hy, Truong-Son and Kondor, Risi},
|
|
366
|
+
year = {2019},
|
|
367
|
+
eprint = {1906.04015},
|
|
368
|
+
archivePrefix = {arXiv},
|
|
369
|
+
primaryClass = {physics.comp-ph},
|
|
370
|
+
url = {https://arxiv.org/abs/1906.04015}
|
|
371
|
+
}
|
|
372
|
+
|
|
373
|
+
@misc{hoogeboom2022edm,
|
|
374
|
+
title = {Equivariant Diffusion for Molecule Generation in 3D},
|
|
375
|
+
author = {Hoogeboom, Emiel and Garcia Satorras, Victor and Vignac, Cl{\'e}ment and Welling, Max},
|
|
376
|
+
year = {2022},
|
|
377
|
+
eprint = {2203.17003},
|
|
378
|
+
archivePrefix = {arXiv},
|
|
379
|
+
primaryClass = {cs.LG},
|
|
380
|
+
url = {https://arxiv.org/abs/2203.17003}
|
|
381
|
+
}
|
|
382
|
+
|
|
383
|
+
@misc{morehead2024gcdiff,
|
|
384
|
+
title = {Geometry-Complete Diffusion for 3D Molecule Generation and Optimization},
|
|
385
|
+
author = {Morehead, Alex and Cheng, Jianlin},
|
|
386
|
+
year = {2024},
|
|
387
|
+
eprint = {2302.04313},
|
|
388
|
+
archivePrefix = {arXiv},
|
|
389
|
+
primaryClass = {cs.LG},
|
|
390
|
+
url = {https://arxiv.org/abs/2302.04313}
|
|
391
|
+
}
|
|
392
|
+
|
|
393
|
+
@misc{nikitin2025geomrevisited,
|
|
394
|
+
title = {GEOM-Drugs Revisited: Toward More Chemically Accurate Benchmarks for 3D Molecule Generation},
|
|
395
|
+
author = {Nikitin, Filipp and Dunn, Ian and Koes, David Ryan and Isayev, Olexandr},
|
|
396
|
+
year = {2025},
|
|
397
|
+
eprint = {2505.00169},
|
|
398
|
+
archivePrefix = {arXiv},
|
|
399
|
+
primaryClass = {cs.LG},
|
|
400
|
+
url = {https://arxiv.org/abs/2505.00169}
|
|
401
|
+
}
|
|
402
|
+
|
|
403
|
+
@misc{vignac2023midi,
|
|
404
|
+
title = {MiDi: Mixed Graph and 3D Denoising Diffusion for Molecule Generation},
|
|
405
|
+
author = {Vignac, Clement and Osman, Nagham and Toni, Laura and Frossard, Pascal},
|
|
406
|
+
year = {2023},
|
|
407
|
+
eprint = {2302.09048},
|
|
408
|
+
archivePrefix = {arXiv},
|
|
409
|
+
primaryClass = {cs.LG},
|
|
410
|
+
url = {https://arxiv.org/abs/2302.09048}
|
|
411
|
+
}
|
|
412
|
+
```
|
|
413
|
+
|
|
414
|
+
</details>
|