xnn.common.benchmark.energy.dataset_structures#

xnn.common.benchmark.energy.dataset_structures(dataset)[source]#

Return the raw structure dicts backing a dataset or subset.

Works for both an AtomicDataset and a torch.utils.data.Subset of one, so E0s can be fit from the dataset without building any graphs.

Parameters:

dataset (AtomicDataset or torch.utils.data.Subset) – The dataset (or subset) to read structures from.

Returns:

The underlying structure dicts (each with atomic_numbers and, when present, energy).

Return type:

list of dict