Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

create OC22 dataset #88

Open
mingyue605 opened this issue Oct 24, 2024 · 0 comments
Open

create OC22 dataset #88

mingyue605 opened this issue Oct 24, 2024 · 0 comments

Comments

@mingyue605
Copy link

Hi,

I have a question regarding the function get_random_clean_slabs from the termination_generator.py script in the Open Catalyst Dataset (OC22). Specifically, I’m trying to create metal oxide structures myself following the OC22 dataset format. However, I encounter an issue on line 163 where I get the error 'O'.

I'm unsure whether the problem is related to how I’m creating the bulk structure. Below is the script I’m using to generate the bulk structure for Al₂O₃:

python
Copy code
from pymatgen.core import Structure, Lattice

Define the lattice for Al2O3 (corundum structure - hexagonal/trigonal lattice)

lattice = Lattice.hexagonal(a=4.759, c=12.991) # Lattice constants for Al2O3 in angstroms

Define the atomic basis (positions of atoms in the unit cell for Al2O3)

species = ["Al", "Al", "Al", "Al", "Al", "Al", "O", "O", "O", "O", "O", "O"]
coords = [
[0.3522, 0.0000, 0.2500],
[0.6478, 0.0000, 0.7500],
[0.0000, 0.3522, 0.7500],
[0.0000, 0.6478, 0.2500],
[0.6478, 0.6478, 0.2500],
[0.3522, 0.3522, 0.7500],
[0.3060, 0.0000, 0.2500],
[0.6940, 0.0000, 0.7500],
[0.0000, 0.3060, 0.7500],
[0.0000, 0.6940, 0.2500],
[0.6940, 0.6940, 0.2500],
[0.3060, 0.3060, 0.7500]
]

Create the bulk structure as a Structure object

bulk_structure = Structure(lattice, species, coords)

Import the slab generator

from termination_generator import get_random_clean_slabs

Set parameters for slab generation

n_slabs = 3
max_index = 2
min_slab_size = 10 # in Å
min_vacuum_size = 15 # in Å

Generate random clean slabs

random_slabs = get_random_clean_slabs(bulk=bulk_structure,
n_slabs=n_slabs,
max_index=max_index,
min_slab_size=min_slab_size,
min_vacuum_size=min_vacuum_size)
Could you please help me identify whether the bulk structure is being created correctly, or if there might be an issue causing the error during slab generation? I’d appreciate any guidance or advice you can offer on how to resolve this issue.

Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant