youssefsassi's picture
Upload README.md with huggingface_hub
0edd1f0 verified
|
Raw
History Blame Contribute Delete
9.05 kB
---
configs:
- config_name: default
data_files:
- split: train
path: Dataset_A_MatterGen_Reproduction.parquet
- config_name: no_lanthanoids
data_files:
- split: train
path: Dataset_A_No_Lanthanoids.parquet
- config_name: extension
data_files:
- split: train
path: Dataset_B_Extension.parquet
---
# Le-Mat-Bulk_matgen_constrained
This repository contains preprocessed datasets from the LeMat-Bulk dataset prepared for MatterGen-style retraining.
---
## 🚀 Loading the Dataset
Since this repository is public, you can load the dataset subsets directly without authentication using the Hugging Face `datasets` library:
```python
from datasets import load_dataset
# Load Default (Dataset A)
dataset_a = load_dataset("youssefsassi/Le-Mat-Bulk_matgen_constrained", name="default")
# Load No Lanthanoids
dataset_no_lan = load_dataset("youssefsassi/Le-Mat-Bulk_matgen_constrained", name="no_lanthanoids")
# Load Extension (Dataset B)
dataset_b = load_dataset("youssefsassi/Le-Mat-Bulk_matgen_constrained", name="extension")
```
---
## 🛠️ Generation Procedure and Filter Counts
To save computation time (since `pymatgen` and `spglib` primitive structure standardization are highly expensive CPU operations), the pipeline performs **primitivization only once on the broader Dataset B superset** (which uses looser constraints). The stricter Dataset A and its subsets are then derived directly from the pre-primitivized Dataset B.
### Step-by-Step Preprocessing Flow:
1. **Joined Inputs**: Loads and joins the structures from `LeMaterial/LeMat-Bulk` (config `compatible_pbe`) and DFT hulls from `LeMaterial/LeMat-Bulk-DFT-Hull-All` on `immutable_id`.
2. **Element Exclusions**: Excludes noble gases, Technetium (`Tc`), Promethium (`Pm`), and elements with atomic numbers greater than 84 (`> Po`).
3. **DFT Hull Pre-filtering**:
* Dataset B filter: `dft_hull <= 0.15`
* Dataset A filter: `dft_hull <= 0.10`
4. **Primitivization (Symmetry Standardization)**:
* Performed on the Dataset B candidates. Spglib standardizes the structures and obtains primitive cells.
5. **Post-primitive Site Filtering**:
* Applies the site count filter `nsites <= 40` on Dataset B's standardized primitive cells.
6. **Deduplication**:
* Removes any duplicate entries to produce the final **Dataset B (Extension)**.
7. **Derivation of Dataset A (MatterGen Reproduction)**:
* Applies stricter filters to the deduplicated Dataset B primitive superset: `dft_hull <= 0.10` and `nsites <= 20`.
8. **Derivation of Dataset A No Lanthanoids**:
* Derived from the finalized Dataset A by removing all Lanthanoids (`La`, `Ce`, `Pr`, `Nd`, `Sm`, `Eu`, `Gd`, `Tb`, `Dy`, `Ho`, `Er`, `Tm`, `Yb`, `Lu`).
---
## 📐 Primitive Structure Standardization Statistics
Symmetry standardization using `spglib` and `pymatgen`'s SpacegroupAnalyzer was run to reduce structures to their standard primitive form. By comparing the site counts (`nsites`) before and after the standardization pass, we find the following ratios of structures that were **already primitive** (i.e., their site counts remained unchanged):
* **Dataset B (Extension)**:
* Total matched structures: **1,664,351**
* Already primitive before standardization: **1,639,324**
* Ratio: **98.50%**
* **Dataset A (MatterGen)**:
* Total matched structures: **1,181,982**
* Already primitive before standardization: **1,165,630**
* Ratio: **98.62%**
This indicates that **~98.5%** of the LeMat-Bulk structures matching our initial constraints were already in their primitive standardized representation, with only **~1.5%** being conventional cells that standard-reduced to a smaller site count.
---
## 📊 Detailed Filtering and Exclusion Statistics
### Step-Wise Preprocessing Pipeline Counts:
| Dataset / Subset | Preprocessing Step | Row Count | Details |
| :--- | :--- | :--- | :--- |
| **All** | Joined Input (Initial) | **5,335,286** | Initial raw join on `immutable_id` |
| **All** | After Element Exclusions | **4,426,249** | Excluded noble gases, Tc, Pm, and Z > 84 |
| **Dataset B (Candidate)** | After DFT Hull Filtering | **1,699,744** | Cutoff: `dft_hull <= 0.15` |
| **Dataset B (Candidate)** | Primitivization Success | **1,699,744** | Standardized primitive cells (0 failures) |
| **Dataset B (Candidate)** | After Post-primitive `nsites` Filter | **1,664,358** | Cutoff: post-primitive `nsites <= 40` |
| **Dataset B (Extension)** | **Final Deduplicated Output** | **1,664,351** | Final Dataset B count |
| **Dataset A** | Primitive Superset Input | **1,664,351** | Input from finalized Dataset B |
| **Dataset A (MatterGen)** | **Final Derived Output** | **1,181,982** | Stricter filters: `dft_hull <= 0.10` and `nsites <= 20` |
| **Dataset A (No Lanthanoids)**| **Final Derived Output** | **611,142** | Excluded 14 Lanthanoids from Dataset A |
---
### Step-Wise Element Exclusions Simulation (Initial Join):
When processing the initial raw joined dataset of **5,335,265** rows:
1. **Exclude Noble Gases** (Ar, He, Kr, Ne, Rn, Xe):
* Dropped: **280** rows
* Remaining: **5,334,985** rows
2. **Exclude MatterGen Excluded Elements** (Pm, Tc):
* Dropped: **368,159** rows
* Remaining: **4,966,826** rows
3. **Exclude Z > 84 elements**:
* Dropped: **540,598** rows
* Remaining: **4,426,228** rows (Total Baseline Excluded dropped: **909,037** rows)
---
### Specific Excluded Element Occurrences in Joined Structures:
The number of structures in the initial joined dataset containing each of the excluded/ablation elements (sorted by occurrence count):
| Element Group | Element | Row Count | % of Joined |
| :--- | :--- | :--- | :--- |
| **Lanthanoids** | La | 282,978 | 5.3039% |
| **MatterGen Excluded** | Pm | 201,275 | 3.7725% |
| **Lanthanoids** | Nd | 199,001 | 3.7299% |
| **Lanthanoids** | Dy | 196,523 | 3.6835% |
| **Lanthanoids** | Pr | 196,414 | 3.6814% |
| **Lanthanoids** | Sm | 196,112 | 3.6758% |
| **Lanthanoids** | Tb | 195,823 | 3.6704% |
| **Lanthanoids** | Ho | 193,884 | 3.6340% |
| **Lanthanoids** | Tm | 189,611 | 3.5539% |
| **Lanthanoids** | Er | 188,347 | 3.5302% |
| **MatterGen Excluded** | Tc | 168,798 | 3.1638% |
| **Z > 84** | Ac | 159,246 | 2.9848% |
| **Lanthanoids** | Ce | 130,640 | 2.4486% |
| **Z > 84** | Th | 121,488 | 2.2771% |
| **Z > 84** | Pu | 109,016 | 2.0433% |
| **Z > 84** | Pa | 95,786 | 1.7953% |
| **Z > 84** | U | 66,848 | 1.2529% |
| **Lanthanoids** | Lu | 61,123 | 1.1456% |
| **Lanthanoids** | Gd | 60,788 | 1.1394% |
| **Z > 84** | Np | 59,124 | 1.1082% |
| **Lanthanoids** | Eu | 33,606 | 0.6299% |
| **Lanthanoids** | Yb | 10,032 | 0.1880% |
| **Noble Gases** | Xe | 215 | 0.0040% |
| **Noble Gases** | Kr | 29 | 0.0050% |
| **Noble Gases** | He | 19 | 0.0004% |
| **Noble Gases** | Ar | 10 | 0.0002% |
| **Noble Gases** | Ne | 7 | 0.0001% |
---
## ⚛️ Atom Type (Element) Frequencies
The overall atom occurrences (by total count across all sites in the joined dataset) for all **89** unique elements present in the structures:
* **O**: 466,021
* **Li**: 325,150
* **Se**: 315,703
* **Cu**: 311,939
* **In**: 309,555
* **Tl**: 306,728
* **Zn**: 306,426
* **Ag**: 303,354
* **Te**: 302,900
* **Mg**: 299,780
* **Au**: 290,434
* **Cd**: 286,238
* **Ni**: 285,705
* **Y**: 284,036
* **La**: 282,978
* **Hg**: 282,741
* **Pd**: 273,467
* **Pt**: 271,824
* **Al**: 269,539
* **S**: 264,889
* **Sc**: 256,428
* **Ga**: 255,553
* **Co**: 252,470
* **P**: 251,653
* **As**: 247,732
* **Pb**: 242,001
* **Si**: 238,068
* **N**: 237,804
* **Sb**: 233,741
* **Rh**: 232,227
* **Ir**: 232,066
* **Sn**: 229,583
* **Cl**: 229,435
* **K**: 229,055
* **Ba**: 221,147
* **Br**: 219,288
* **Ca**: 218,521
* **Sr**: 218,021
* **Fe**: 217,204
* **Ge**: 214,440
* **Na**: 213,838
* **Zr**: 202,165
* **Pm**: 201,275
* **Nd**: 199,001
* **Dy**: 196,523
* **Pr**: 196,414
* **Sm**: 196,112
* **Tb**: 195,823
* **Ho**: 193,884
* **Tm**: 189,611
* **Er**: 188,347
* **Mn**: 187,062
* **Ru**: 182,009
* **Rb**: 179,613
* **H**: 176,728
* **I**: 175,575
* **Bi**: 173,363
* **Os**: 172,771
* **Tc**: 168,798
* **F**: 167,288
* **Ta**: 166,574
* **Mo**: 160,262
* **Be**: 160,154
* **Ac**: 159,246
* **W**: 149,643
* **Re**: 148,063
* **Cr**: 146,883
* **Cs**: 143,895
* **Hf**: 142,792
* **C**: 141,806
* **B**: 137,847
* **Nb**: 131,949
* **Ce**: 130,640
* **Ti**: 126,835
* **Th**: 121,488
* **Pu**: 109,016
* **V**: 108,048
* **Pa**: 95,786
* **U**: 66,848
* **Lu**: 61,123
* **Gd**: 60,788
* **Np**: 59,124
* **Eu**: 33,606
* **Yb**: 10,032
* **Xe**: 215
* **Kr**: 29
* **He**: 19
* **Ar**: 10
* **Ne**: 7
---
## Dataset Subsets Summary
* **`default`** (Dataset A - MatterGen Reproduction): 1,181,982 rows.
* **`no_lanthanoids`** (Dataset A Robustness Subset): 611,142 rows.
* **`extension`** (Dataset B): 1,664,351 rows.