The dataset viewer is not available for this dataset.
Error code: ConfigNamesError
Exception: TypeError
Message: Value.__init__() missing 1 required positional argument: 'dtype'
Traceback: Traceback (most recent call last):
File "/src/services/worker/src/worker/job_runners/dataset/config_names.py", line 67, in compute_config_names_response
config_names = get_dataset_config_names(
path=dataset,
token=hf_token,
)
File "/usr/local/lib/python3.14/site-packages/datasets/inspect.py", line 161, in get_dataset_config_names
dataset_module = dataset_module_factory(
path,
...<4 lines>...
**download_kwargs,
)
File "/usr/local/lib/python3.14/site-packages/datasets/load.py", line 1217, in dataset_module_factory
raise e1 from None
File "/usr/local/lib/python3.14/site-packages/datasets/load.py", line 1192, in dataset_module_factory
).get_module()
~~~~~~~~~~^^
File "/usr/local/lib/python3.14/site-packages/datasets/load.py", line 700, in get_module
config_name: DatasetInfo.from_dict(dataset_info_dict)
~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.14/site-packages/datasets/info.py", line 284, in from_dict
return cls(**{k: v for k, v in dataset_info_dict.items() if k in field_names})
File "<string>", line 20, in __init__
File "/usr/local/lib/python3.14/site-packages/datasets/info.py", line 170, in __post_init__
self.features = Features.from_dict(self.features)
~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.14/site-packages/datasets/features/features.py", line 1993, in from_dict
obj = generate_from_dict(dic)
File "/usr/local/lib/python3.14/site-packages/datasets/features/features.py", line 1574, in generate_from_dict
return {key: generate_from_dict(value) for key, value in obj.items()}
~~~~~~~~~~~~~~~~~~^^^^^^^
File "/usr/local/lib/python3.14/site-packages/datasets/features/features.py", line 1593, in generate_from_dict
return class_type(**{k: v for k, v in obj.items() if k in field_names})
TypeError: Value.__init__() missing 1 required positional argument: 'dtype'Need help to make the dataset viewer work? Make sure to review how to configure the dataset viewer, and open a discussion for direct support.
MP-20
Dataset Description
MP-20 is derived from the Materials Project database (Jain et al., 2013) and contains approximately 45,000 common inorganic materials. It covers most experimentally known materials with no more than 20 atoms in the unit cell. The data includes elemental compositions, CIF structures, space groups, formation energies per atom, DFT band gaps, bulk moduli, and magnetic densities.
Source paper: A. Jain et al., Commentary: The Materials Project: A materials genome approach to accelerating materials innovation, APL Materials 1, 011002 (2013).
Paper: https://pubs.aip.org/aip/apm/article/1/1/011002/119685
DOI: https://doi.org/10.1063/1.4812323
This repository provides both raw CSV files and preprocessed caches. The data split contains 27,136 structures in the training set, 9,047 structures in the validation set, and 9,046 structures in the test set, for a total of 45,229 crystal structures.
The current data package contains 30 data files totaling approximately 83 MB.
Supported Tasks
This standardized data repository organizes the MP-20 training, validation, and test data for:
- Data analysis and statistics for inorganic crystal structures
- Training and evaluation of crystal structure generation tasks
- Conditional modeling of material properties
- Research on properties such as formation energy, band gap, bulk modulus, and magnetic density
- Crystal data loading, preprocessing, and data pipeline validation
Dataset Format and Structure
The data files are located in the data/MP20/ directory:
data/MP20/
βββ raw/mp_20/
β βββ train.csv
β βββ val.csv
β βββ test.csv
βββ cache/mp_20/
βββ train/
βββ val/
βββ test/
| File Path | Format | Shape / Content | Description |
|---|---|---|---|
raw/mp_20/train.csv |
CSV + CIF | 27,136 structures | Raw crystal and property data for the training set |
raw/mp_20/val.csv |
CSV + CIF | 9,047 structures | Raw crystal and property data for the validation set |
raw/mp_20/test.csv |
CSV + CIF | 9,046 structures | Raw crystal and property data for the test set |
cache/mp_20/train/ |
NPY + JSON | 27,136 structures | Preprocessed cache for the training set |
cache/mp_20/val/ |
NPY + JSON | 9,047 structures | Preprocessed cache for the validation set |
cache/mp_20/test/ |
NPY + JSON | 9,046 structures | Preprocessed cache for the test set |
metadata/sha256_manifest.txt |
SHA256 | 30 records | Data file integrity checksum manifest |
CSV Data Format
Each row in a CSV file corresponds to one crystal structure. The cif field stores complete multiline CIF text, so the number of samples cannot be determined using a standard text line count.
| Field | Type | Description |
|---|---|---|
material_id |
str | Materials Project structure ID |
pretty_formula |
str | Chemical formula |
elements |
list[str] | Set of elements in the structure |
cif |
str | Crystal structure in CIF format |
spacegroup_number |
int | Space group number |
formation_energy_per_atom |
float | Formation energy per atom |
dft_band_gap |
float | DFT band gap |
dft_bulk_modulus |
float / null | DFT bulk modulus; null for some samples |
dft_mag_density |
float | DFT magnetic density |
Cache Data Format
Each train, val, and test cache directory contains the following files:
| File | Type | Shape | Description |
|---|---|---|---|
atomic_numbers.npy |
int64 | [N_atoms_total] |
Atomic numbers concatenated across all structures |
cell.npy |
float64 | [N_structures, 3, 3] |
Unit-cell matrices |
num_atoms.npy |
int64 | [N_structures] |
Number of atoms in each structure |
pos.npy |
float64 | [N_atoms_total, 3] |
Fractional coordinates concatenated across all structures |
structure_id.npy |
str | [N_structures] |
Structure IDs |
formation_energy_per_atom.json |
JSON | [N_structures] |
Formation energy per atom property |
dft_band_gap.json |
JSON | [N_structures] |
DFT band gap property |
dft_bulk_modulus.json |
JSON | [N_structures] |
DFT bulk modulus property |
dft_mag_density.json |
JSON | [N_structures] |
DFT magnetic density property |
How to Use the Dataset
Download the dataset:
hf download --dataset OneScience-Sugon/mp20 --local-dir ./data
Validate the dataset directory, sample counts, array shapes, and SHA256 checksums:
python scripts/validate_mp20.py \
--dataset-root data/MP20 \
--checksum-manifest metadata/sha256_manifest.txt
Skip SHA256 verification and check only the data structure:
python scripts/validate_mp20.py \
--dataset-root data/MP20 \
--skip-checksum
Official OneScience Information
| Platform | OneScience Main Repository | Skills Repository |
|---|---|---|
| Gitee | https://gitee.com/onescience-ai/onescience | https://gitee.com/onescience-ai/oneskills |
| GitHub | https://github.com/onescience-ai/OneScience | https://github.com/onescience-ai/oneskills |
Limitations and License
This repository standardizes the directory structure of the MP-20 data and provides raw CSV files, preprocessed caches, a checksum manifest, and a validation script. It does not generate new samples or alter the original crystal structures or property data.
- The structures and properties in the data come from the Materials Project and the original MP-20 data curation pipeline. When using the data, cite the 2013 Materials Project paper by Jain et al. and the specific data version used.
- Some material properties contain missing values and must be filtered or masked as appropriate for the task.
- The Materials Project states that its data is licensed under the Creative Commons Attribution 4.0 International (CC BY 4.0) license. This repository uses the same data license; appropriate attribution must be retained when using or redistributing the data.
- If individual entries contain third-party contributed data or additional restrictions, refer to the source of the corresponding entry and the information on its Materials Project page.
- Downloads last month
- -