GuacaMol Dataset¶
The GuacaMol (Brown et al., 2019) benchmark dataset implementation. GuacaMol provides a large corpus of ~1.6 million drug-like SMILES derived from ChEMBL, along with a suite of goal-directed molecular design benchmarks. This implementation supports two complementary modes: property prediction (RDKit physicochemical descriptors as regression targets) and benchmark tasks (goal-directed scoring functions that evaluate molecular design quality).
Data is downloaded automatically from Figshare <https://figshare.com/projects/GuacaMol/62224>``_
on first use and cached locally at ``~/.cache/alf/.
Supported physicochemical properties:
Property |
Description |
|---|---|
|
Bertz complexity index |
|
Wildman–Crippen partition coefficient (lipophilicity) |
|
Molecular weight (Da) |
|
Topological polar surface area (Ų) |
|
Number of hydrogen bond acceptors |
|
Number of hydrogen bond donors |
|
Number of rotatable bonds |
|
Number of aliphatic rings |
|
Number of aromatic rings |
|
Quantitative Estimate of Drug-likeness |
Supported benchmark tasks:
Benchmark task scores are computed on-the-fly via RDKit — no pre-labelled corpus is required. All scores are in [0, 1], aggregated using geometric or arithmetic means of sub-component scores (Tanimoto similarity, Gaussian property penalties, SMARTS presence/absence checks).
Split modes:
|
Behaviour |
|---|---|
|
Random train/validation/test/candidate_pool split of the
combined corpus file ( |
|
Split by target property value: low-value molecules form the train set; high-value molecules form the test set. |
|
Stratified split on target property quantiles. |
|
Uses the original train/valid/test file boundaries from
Brown et al. (2019), enabling direct comparison with published
results. |
Split mapping to ALF (non-paper modes):
ALF split |
Source |
|---|---|
|
|
|
|
|
|
|
Remaining corpus after train + validation
(capped at |
Paper split sizes:
Split |
Molecules |
|---|---|
Train |
1,273,104 |
Validation |
55,804 |
Test |
55,821 |
Total |
1,384,729 |
Property storage:
Computed property values are stored in a single contiguous NumPy array on the dataset instance
rather than in individual Candidate.features dicts. After loading, GuacaMol._prop_matrix
has shape (N, P) where N is the number of valid corpus molecules and P is the number of
requested properties; GuacaMol._prop_cols lists the property names in the corresponding column
order. Candidate.features is always {} for corpus molecules — accessing it will return an
empty dict, not a KeyError.
Novel molecules queried via :meth:~alf_tools.datasets.guacamol.GuacaMol.query still receive a
populated features dict in the returned candidate (properties are computed on-the-fly by
RDKit), because they have no entry in _prop_matrix.
Benchmark-task datasets do not compute RDKit properties on load; _prop_matrix retains its
empty sentinel shape of (0, 0) and _prop_cols is [].
Novel molecules: For property targets, SMILES not present in the loaded corpus are labelled
on-the-fly via RDKit in :meth:~alf_tools.datasets.guacamol.GuacaMol.query. This means
generative models can propose entirely new molecules and receive valid labels without reloading
the dataset.