| # CrystDB | |
| > **CrystDB** is a comprehensive crystal structure database that includes all thermodynamically stable structures from the Materials Project (MP-2024.1), covering data released up to January 2024 ([https://next-gen.materialsproject.org/materials-database](https://next-gen.materialsproject.org/materials-database)). It is designed to support the development of **XRD-based crystal structure identification**, **crystal property prediction (CPP)**, and **crystal structure prediction (CSP)**. | |
| > | |
| > This database is **freely accessible** and is maintained by **Mr. Bin Cao**. For questions, feedback, or technical issues, please contact: **[bcao686@connect.hkust-gz.edu.cn](mailto:bcao686@connect.hkust-gz.edu.cn)** | |
| --- | |
| ## 📚 Citation & License | |
| **Commercial use is strictly prohibited.** | |
| If you use this dataset in your research, please cite **all** the following works: | |
| ```bibtex | |
| @inproceedings{binsimxrd, | |
| title={SimXRD-4M: Big Simulated X-ray Diffraction Data and Crystal Symmetry Classification Benchmark}, | |
| author={Bin, CAO and Liu, Yang and Zheng, Zinan and Tan, Ruifeng and Li, Jia and Zhang, Tong-yi}, | |
| booktitle={The Thirteenth International Conference on Learning Representations} | |
| } | |
| @article{cao2025xqueryer, | |
| title={XQueryer: an intelligent crystal structure identifier for powder X-ray diffraction}, | |
| author={Cao, Bin and Zheng, Zinan and Liu, Yang and Zhang, Longhan and Wong, Lawrence WY and Weng, Lu-Tao and Li, Jia and Li, Haoxiang and Zhang, Tong-Yi}, | |
| journal={National Science Review}, | |
| volume={12}, | |
| number={12}, | |
| pages={nwaf421}, | |
| year={2025}, | |
| publisher={Oxford University Press} | |
| } | |
| @article{jain2020materials, | |
| title={The materials project: Accelerating materials design through theory-driven data and tools}, | |
| author={Jain, Anubhav and Montoya, Joseph and Dwaraknath, Shyam and Zimmermann, Nils ER and Dagdelen, John and Horton, Matthew and Huck, Patrick and Winston, Donny and Cholia, Shreyas and Ong, Shyue Ping and others}, | |
| journal={Handbook of Materials Modeling: Methods: Theory and Modeling}, | |
| pages={1751--1784}, | |
| year={2020}, | |
| publisher={Springer} | |
| } | |
| ``` | |
| --- | |
| ## 🧪 How to Use | |
| ### 1. Visualize the database using `CryDBkit` | |
| ```bash | |
| pip install CryDBkit | |
| ``` | |
| ```python | |
| from CryDBkit import website | |
| website.show('CrystDB.db') | |
| ``` | |
| > ⚠️ Note: The database is very large. It might not open on regular laptops. Please try on a Linux server or high-memory system. | |
| --- | |
| ### 2. Query data with ASE | |
| ```python | |
| from ase.db import connect | |
| from ase.spacegroup import get_spacegroup | |
| DB = connect('CrystDB.db') | |
| entry_id = 30 # data ID | |
| atoms = DB.get_atoms(id=entry_id) | |
| # Basic info | |
| N_symbols = atoms.get_chemical_symbols() # List of chemical elements | |
| G_spacegroup = get_spacegroup(atoms).no # Space group number | |
| sites = atoms.get_scaled_positions() # Fractional coordinates | |
| cell = atoms.get_cell() # Unit cell parameters | |
| atom_coor = atoms.get_positions() # Cartesian coordinates | |
| ``` | |