Skip to content

Commit 2405193

Browse files
docs: fix readme (#11)
1 parent 9f29bda commit 2405193

1 file changed

Lines changed: 29 additions & 10 deletions

File tree

README.md

Lines changed: 29 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,10 @@ AtomWorks is built atop [biotite](https://www.biotite-python.org/): We are grate
2525

2626
## atomworks.io
2727

28-
*A general-purpose Python toolkit for working with biomolecular files*
28+
> *A general-purpose Python toolkit for cleaning up, standardizing, and working with biomolecular files - based on biotite*
2929
3030
**atomworks.io** lets you:
31+
3132
- Parse, convert, and clean any common biological file (structure or sequence). For example, identifying and removing leaving groups, correcting bond order after nucleophilic addition, fixing charges, parsing covalent geometries, and appropriate treatment of structures with multiple occupancies and ligands at symmetry centers
3233
- Transform all data to a consistent `AtomArray` representation for further analysis or machine learning applications, regardless of initial source
3334
- Model missing atoms (those implied by the sequence but not represented in the coordinates) and initialize entity- and instance-level annotations (see the [glossary]() for more detail on our composable naming conventions)
@@ -38,9 +39,10 @@ We have found `atomworks.io` to be useful to a general bioinformatics and protei
3839

3940
## atomworks.ml
4041

41-
*Modular, component-based library for dataset featurization within biomolecular deep learning workflows*
42+
> *Modular, component-based library for dataset featurization within biomolecular deep learning workflows*
4243
4344
**atomworks.ml** provides:
45+
4446
- A library of pre-built, well-tested `Transforms` that can be slotted into novel pipelines
4547
- An extensible framework, integrated with `atomworks.io`, to write `Transforms` for arbitrary use cases
4648
- Scripts to pre-process the PDB or other databases into dataframes appropriate for network training
@@ -102,6 +104,7 @@ for chain_id, info in result["chain_info"].items():
102104
```
103105

104106
The output of `parse` includes:
107+
105108
- **chain_info** — Sequences/metadata for each chain
106109
- **ligand_info** — Ligand annotation & metrics
107110
- **asym_unit** — Structure (`AtomArrayStack`)
@@ -118,8 +121,8 @@ from atomworks.io.utils.io_utils import load_any
118121
atom_array: AtomArray = load_any("3nez.cif.gz", model=1) # model=1 means that we want to load the model 1 (i.e. the first model) rather than a stack of all models in the file
119122
```
120123

121-
122124
### 3. Training on the PDB
125+
123126
> ⚠️ **Disclaimer:** Documentation for this section is currently under construction. Please check back soon for updates!
124127
125128
**Step 1 — Mirror the PDB (mmCIFs)**
@@ -154,20 +157,23 @@ atom_array: AtomArray = load_any("3nez.cif.gz", model=1) # model=1 means that w
154157

155158
This produces parquet files at:
156159

157-
- `/path/to/metadata/ml/pdb_pn_units/metadata.parquet` — Contains metadata for each *PN unit* in the PDB. The term *pn unit* is shorthand for `polymer XOR non-polymer unit` and behaves for almost all purposes like the `chain` in a PDB file. The only difference is that a ligand composed of multiple covalently bonded ligands is considered a single PN unit (whilst it would be multiple chains in a PDB file). Effectively this `.parquet` is a large table of all individual chains, ligands, etc (to be precise, it has one entry per pn unit) in the PDB that includes helpful metadata for filtering and sampling.
158-
- `/path/to/metadata/ml/pdb_interfaces/metadata.parquet` — Contains metadata for each interface in the PDB. This `.parquet` is a large table of all binary interfaces in the PDB. It lists each interface as (pn_unit_1, pn_unit_2) pairs and includes helpful metadata for filtering and sampling.
160+
- `/path/to/metadata/pn_units_df.parquet` — Contains metadata for each *PN unit* in the PDB. The term *pn unit* is shorthand for `polymer XOR non-polymer unit` and behaves for almost all purposes like the `chain` in a PDB file. The only difference is that a ligand composed of multiple covalently bonded ligands is considered a single PN unit (whilst it would be multiple chains in a PDB file). Effectively this `.parquet` is a large table of all individual chains, ligands, etc (to be precise, it has one entry per pn unit) in the PDB that includes helpful metadata for filtering and sampling.
161+
- `/path/to/metadata/interfaces_df.parquet` — Contains metadata for each interface in the PDB. This `.parquet` is a large table of all binary interfaces in the PDB. It lists each interface as (pn_unit_1, pn_unit_2) pairs and includes helpful metadata for filtering and sampling.
159162

160163
Alternatively, you can generate fresher metadata yourself (scripts will be uploaded in the coming weeks).
161164

162165
**Step 3 — Configure an AF3-style dataset (example: train only on D-polypeptides)**
163-
164166
Next we need to use the metadata to configure a dataset that we would like to sample from. This includes e.g. training cut-off, filters, transforms to apply, etc.
165167
Here's a simple example that:
166168

167169
- Filters to D-polypeptide and L-polypeptide chains only (`POLYPEPTIDE_D` and `POLYPEPTIDE_L` -- to include additional chain types, replace the lists with the appropriate IDs (see [mapping](./src/atomworks/enums.py#L31-L45) in comments).
168170
- Excludes ligands in the AF3 list of excluded ligands, available at [`atomworks.io.constants.AF3_EXCLUDED_LIGANDS_REGEX`](./src/atomworks/io/constants.py#L350).
169171

170172
```yaml
173+
# NOTE: The below is a hydra config and the _target_ fields are the hydra syntax for instantiating a class.
174+
# You can use this without hyrda, but will then instead need to provide the corresponding arguments for the
175+
# _target_ objects directly.
176+
171177
# Chain type ids used below (from atomworks.enums.ChainType):
172178
# 0=CyclicPseudoPeptide, 1=OtherPolymer, 2=PeptideNucleicAcid,
173179
# 3=DNA, 4=DNA_RNA_HYBRID, 5=POLYPEPTIDE_D, 6=POLYPEPTIDE_L, 7=RNA,
@@ -200,7 +206,7 @@ af3_pdb_dataset:
200206
_target_: atomworks.ml.datasets.datasets.PandasDataset
201207
name: pn_units
202208
id_column: example_id
203-
data: /path/to/metadata/ml/pdb_pn_units/metadata.parquet
209+
data: /path/to/metadata/pn_units_df.parquet
204210
filters:
205211
- "deposition_date < '2022-01-01'"
206212
- "resolution < 5.0 and ~method.str.contains('NMR')"
@@ -237,7 +243,7 @@ af3_pdb_dataset:
237243
_target_: atomworks.ml.datasets.datasets.PandasDataset
238244
name: interfaces
239245
id_column: example_id
240-
data: /path/to/metadata/ml/pdb_interfaces/metadata.parquet
246+
data: /path/to/metadata/interfaces_df.parquet
241247
filters:
242248
- "deposition_date < '2022-01-01'"
243249
- "resolution < 5.0 and ~method.str.contains('NMR')"
@@ -294,5 +300,18 @@ Please see the [full documentation](https://baker-laboratory.github.io/atomworks
294300

295301
If you make use of AtomWorks in your research, please cite:
296302

297-
* N. Corley, S. Mathis, R. Krishna, M. S. Bauer, T. R. Thompson, W. Ahern, M. W. Kazman, R. I. Brent, K. Didi, A. Kubaney, L. McHugh, A. Nagle, A. Favor, M. Kshirsagar, P. Sturmfels, Y. Li, J. Butcher, B. Qiang, L. L. Schaaf, R. Mitra, K. Campbell, O. Zhang, R. Weissman, I. R. Humphreys, Q. Cong, J. Funk, S. Sonthalia, P. Lio, D. Baker, F. DiMaio,
298-
"Accelerating Biomolecular Modeling with AtomWorks and RF3," bioRxiv, August 2025. doi: [10.1101/2025.08.14.670328](https://doi.org/10.1101/2025.08.14.670328)
303+
> N. Corley\*, S. Mathis\*, R. Krishna\*, M. S. Bauer, T. R. Thompson, W. Ahern, M. W. Kazman, R. I. Brent, K. Didi, A. Kubaney, L. McHugh, A. Nagle, A. Favor, M. Kshirsagar, P. Sturmfels, Y. Li, J. Butcher, B. Qiang, L. L. Schaaf, R. Mitra, K. Campbell, O. Zhang, R. Weissman, I. R. Humphreys, Q. Cong, J. Funk, S. Sonthalia, P. Lio, D. Baker, F. DiMaio,
304+
> "Accelerating Biomolecular Modeling with AtomWorks and RF3," bioRxiv, August 2025. doi: [10.1101/2025.08.14.670328](https://doi.org/10.1101/2025.08.14.670328)
305+
306+
If you use bibtex, here's the GoogleScholar formatted citation:
307+
308+
```bibtex
309+
@article{corley2025accelerating,
310+
title={Accelerating Biomolecular Modeling with AtomWorks and RF3},
311+
author={Corley, Nathaniel and Mathis, Simon and Krishna, Rohith and Bauer, Magnus S and Thompson, Tuscan R and Ahern, Woody and Kazman, Maxwell W and Brent, Rafael I and Didi, Kieran and Kubaney, Andrew and others},
312+
journal={bioRxiv},
313+
pages={2025--08},
314+
year={2025},
315+
publisher={Cold Spring Harbor Laboratory}
316+
}
317+
```

0 commit comments

Comments
 (0)