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

Cg particle support #148

Open
wants to merge 16 commits into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 12 additions & 6 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,11 @@ maintainers = [
{ name = "Joseph F. Rudzinski", email = "[email protected]" }
]
license = { file = "LICENSE" }
# dependencies = [
# "nomad-lab>=1.3.0",
# "matid>=2.0.0.dev2",
# "nomad-simulations@file:///home/bmohr/software/nomad-simulations",
# ]
dependencies = [
"nomad-lab>=1.3.0",
"matid>=2.0.0.dev2",
Expand All @@ -40,12 +45,13 @@ dependencies = [

[project.optional-dependencies]
dev = [
"mypy==1.0.1",
"ruff",
"pytest",
"pytest-timeout",
"pytest-cov",
"structlog",
'mypy==1.0.1',
'pytest>= 5.3.0, <8',
'pytest-timeout>=1.4.2',
'pytest-cov>=2.7.1',
'ruff>=0.6',
'structlog>=1.0',
'typing-extensions>=4.12',
]

[tool.uv]
Expand Down
4 changes: 2 additions & 2 deletions src/nomad_simulations/schema_packages/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,8 @@ class NOMADSimulationsEntryPoint(SchemaPackageEntryPoint):
description='Limite of the number of atoms in the unit cell to be treated for the system type classification from MatID to work. This is done to avoid overhead of the package.',
)
equal_cell_positions_tolerance: float = Field(
1e-12,
description='Tolerance (in meters) for the cell positions to be considered equal.',
12,
description='Decimal order or tolerance (in meters) for comparing cell positions.',
)

def load(self):
Expand Down
2 changes: 2 additions & 0 deletions src/nomad_simulations/schema_packages/general.py
Original file line number Diff line number Diff line change
Expand Up @@ -217,6 +217,7 @@ def _set_system_branch_depth(
system_parent=system_child, branch_depth=branch_depth + 1
)

#! Generalize from checks for atomic systems, error with CG input
def resolve_composition_formula(self, system_parent: ModelSystem) -> None:
"""Determine and set the composition formula for `system_parent` and all of its
descendants.
Expand Down Expand Up @@ -275,6 +276,7 @@ def get_composition_recurs(system: ModelSystem, atom_labels: list[str]) -> None:
for subsystem in subsystems:
get_composition_recurs(system=subsystem, atom_labels=atom_labels)

# ! CG: system_parent.cell[0].particles_state instead of atoms_state!
atoms_state = (
system_parent.cell[0].atoms_state if system_parent.cell is not None else []
)
Expand Down
Loading
Loading