Processing and visualization of atomic coordinates; featurizing atomic structures
Project description
AtomicAI
AtomicAI is a Python-based package for building machine learning models in the field of computational materials science. It can be used for machine learning force field generation, atomic structure classifications based on temperature, defects, phase, and more.
Table of Contents
- Features
- Installation
- Requirements
- Usage
- Examples
- Documentation
- Contributing
- License
- Authors
- Contact
- Cite
Features
AtomicAI offers a wide range of features for computational materials science:
Analysis
- Processing and visualization of atomic coordinates in various file formats (CIF, VASP, XYZ, Conquest, etc.)
- Utilizes 'ase' library for reading and writing structure files
- Radial Distribution Function (RDF) calculation and analysis
- Structure analysis tools
Data Processing
- Classification of atoms in trajectory files
- File format conversion between different atomic structure formats
Machine Learning
- Featurization of atomic structures
- Dimension reduction techniques (PCA, LPP, TsLPP, TsNE, UMAP)
- Machine Learning Force Field (MLFF) generation
- Descriptor generation for atomic environments and forces
Clustering and Visualization
- Various clustering methods
- Data plotting and visualization tools for RDF, molecular dynamics statistics, and clustering results
Installation
Install AtomicAI using pip:
pip install AtomicAI
Requirements
AtomicAI requires Python 3.7 or higher. Other dependencies will be automatically installed during the pip installation process.
Usage
AtomicAI provides several command-line tools for various tasks. Here are some examples:
File Conversion
cq2vasp: Convert Conquest files to VASP formatxyz2vasp: Convert XYZ files to VASP formatvasp2cif: Convert VASP files to CIF formatvasp2xyz: Convert VASP files to XYZ formatvasp2lmp_data: Convert VASP files to LAMMPS data formatvasp2cq: Convert VASP files to Conquest formatlmp2vasp: Convert LAMMPS trajectory to VASP formatcif2cq: Convert CIF files to Conquest formatcq2cif: Convert Conquest files to CIF formatase_traj2xyz_traj: Convert ASE trajectory to XYZ trajectory
Structure Manipulation
supercell: Create supercell structuresbuild_interface: Build interfaces between materialswrap2unwrap: Convert wrapped coordinates to unwrapped
Analysis
rdf: Calculate Radial Distribution Functionstructure_analysis: Perform various structural analyses
Visualization
plot_rdf_data: Plot RDF dataplot_md_stats: Plot molecular dynamics statisticsplot_vasp_md: Plot VASP molecular dynamics resultsplot_lammps_md: Plot LAMMPS molecular dynamics resultsplot_clusters: Visualize clustering results
Machine Learning
Atomic Descriptors — generate_descriptors
Computes locally-averaged atomic fingerprints (LAAF) for all element pairs in a trajectory.
generate_descriptors trajectory.xyz [--descriptor TYPE [TYPE ...]] [--n-eta N]
| Option | Default | Description |
|---|---|---|
--descriptor / -d |
ACSF_G2 ACSF_G2G4 SOAP |
One or more descriptor types (see table below) |
--n-eta / -n |
50 |
Number of eta decay functions |
Available descriptor types:
| Type | Description |
|---|---|
ACSF_G2 |
Radial symmetry functions (Behler-Parrinello G2) |
ACSF_G3 |
Cosine basis functions parameterised by kappa |
ACSF_G4 |
Angular symmetry functions including the r_jk cutoff (Behler-Parrinello G4) |
ACSF_G5 |
Angular symmetry functions without r_jk cutoff (G5 variant) |
ACSF_G2G4 |
Combined radial (G2) + angular (G4) descriptor |
ACSF_G2G4G5 |
Combined radial (G2) + angular G4 + angular G5 descriptor |
SOAP |
Smooth Overlap of Atomic Positions (via DScribe) |
MBSF |
Many-body symmetry functions (radial gr + angular ga) |
Examples:
# G2 radial only, 60 eta functions
generate_descriptors traj.xyz --descriptor ACSF_G2 --n-eta 60
# Multiple descriptor types in one run
generate_descriptors traj.xyz --descriptor ACSF_G2G4 ACSF_G2G4G5 MBSF
# SOAP descriptor
generate_descriptors traj.xyz --descriptor SOAP
Output files are written to ./descriptors/ with naming convention <TYPE>_<rc>_<ra>_<elem1>_<elem2>.dat.
Force Descriptors — generate_force_descriptors
Generates force-projected descriptors for machine learning force field training.
generate_force_descriptors trajectory.xyz [--fp-type TYPE] [--rc R] [--n2b N] [--n3b N]
| Option | Default | Description |
|---|---|---|
--fp-type / -f |
Split2b3b_ss |
Fingerprint type: BP2b or Split2b3b_ss |
--rc / -r |
10.5 |
Cutoff radius in Angstrom |
--n2b |
20 |
Number of 2-body eta functions |
--n3b |
10 |
Number of 3-body eta functions |
Available fingerprint types:
| Type | Description |
|---|---|
BP2b |
2-body Behler-Parrinello fingerprint |
Split2b3b_ss |
Split 2-body + 3-body fingerprint (same species) |
Examples:
# Default: Split2b3b_ss with 10.5 Å cutoff
generate_force_descriptors traj.xyz
# BP2b with shorter cutoff and more eta functions
generate_force_descriptors traj.xyz --fp-type BP2b --rc 8.0 --n2b 30
# Split2b3b with custom eta counts
generate_force_descriptors traj.xyz --fp-type Split2b3b_ss --rc 9.0 --n2b 25 --n3b 12
Output is written to ./descriptors/force_descriptors.dat.
Other ML Tools
laaf: Calculate LAAF descriptorsdim_reduction: Perform dimension reductiondim_reduction_mpi: Perform parallel dimension reduction using MPIpca: Perform Principal Component Analysislpp: Perform Locality Preserving Projectionoptimize_tslpp_hyperparameters_without_prediction: Optimize TsLPP hyperparametersoptimize_tslpp_hyperparameters_with_prediction: Optimize TsLPP hyperparameters with predictionpredict_tslpp: Predict using optimized TsLPP model
Structure Building
build_multilayers: Stack multiple VASP structures into commensurate multilayer systemsbuild_constrained_multilayers: Build multilayers with lattice constraintssurfaces: Generate surface slabs for common Miller indices from a bulk structure
LAMMPS Input Generation
lammps_npt_inputs: Generate LAMMPS NPT input fileslammps_nvt_inputs: Generate LAMMPS NVT input files
For more details on any tool, run it with the --help flag.
Examples
(This section should be filled with basic examples of how to use the main features of AtomicAI. As the context doesn't provide specific examples, I'll leave this section for you to fill in with relevant use cases.)
Documentation
(Add a link to the full documentation when available. The context doesn't provide this information, so you may want to add it when documentation is ready.)
Contributing
We welcome contributions to AtomicAI! Please see our contributing guidelines for more information. (You may want to add a CONTRIBUTING.md file to your repository with detailed guidelines.)
License
AtomicAI is released under the MIT License. See the LICENSE.md file for details.
Authors
- Selva Chandrasekaran Selvaraj
Contact
- Email: selvachandrasekar.s@gmail.com
- Website: https://sites.google.com/view/selvas
- Twitter: https://twitter.com/selva_odc
- LinkedIn: https://www.linkedin.com/in/selvachandrasekaranselvaraj/
- Google Scholar: https://scholar.google.com/citations?user=vNozeNYAAAAJ&hl=en
- Scopus: https://www.scopus.com/authid/detail.uri?authorId=57225319817
- ResearchGate: https://www.researchgate.net/profile/Selva-Chandrasekaran-Selvaraj
- PyPI: https://pypi.org/project/AtomicAI/
- Documentation: https://atomicai.readthedocs.io/en/latest/
- GitHub: https://github.com/SelvaGith/AtomicAI
Cite
If you use AtomicAI in your research, please cite:
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file atomicai-0.4.0.tar.gz.
File metadata
- Download URL: atomicai-0.4.0.tar.gz
- Upload date:
- Size: 110.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6b69d8bdb345534f6f4632c490cf9983b14f6dfaecfc199c1dcc75b32005489f
|
|
| MD5 |
03dca89c9b6da0fb145ce45531e47a6f
|
|
| BLAKE2b-256 |
2593d5569eaf2d93fb7a2ff2667f609e89ef386b2cb7c82920bded4a40b1edbd
|
File details
Details for the file atomicai-0.4.0-py3-none-any.whl.
File metadata
- Download URL: atomicai-0.4.0-py3-none-any.whl
- Upload date:
- Size: 159.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8053510d86ebfafd7d66f2dcc6735d80e1200a18f89153f5feabda5256cff6dd
|
|
| MD5 |
adc861d5776ddad7d1292fc510689d8d
|
|
| BLAKE2b-256 |
965f2a2ea0776bcaec76bc655d10479e16b21d444e57ff8e1c1791a7c65b223d
|