-
Notifications
You must be signed in to change notification settings - Fork 141
Expand file tree
/
Copy pathpyproject.toml
More file actions
265 lines (244 loc) · 8.2 KB
/
pyproject.toml
File metadata and controls
265 lines (244 loc) · 8.2 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
[build-system]
requires = ["setuptools >= 42, < 83", "versioningit >= 1,< 4", "wheel"]
build-backend = "setuptools.build_meta"
[project]
name = "atomate2"
description = "atomate2 is a library of materials science workflows"
readme = "README.md"
keywords = ["automated", "dft", "high-throughput", "vasp", "workflow"]
license = "BSD-3-Clause-LBNL"
authors = [{ name = "Alex Ganose", email = "alexganose@gmail.com" }]
dynamic = ["version"]
classifiers = [
"Development Status :: 5 - Production/Stable",
"Intended Audience :: Information Technology",
"Intended Audience :: Science/Research",
"Intended Audience :: System Administrators",
"Operating System :: OS Independent",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Topic :: Other/Nonlisted Topic",
"Topic :: Scientific/Engineering",
]
requires-python = ">=3.11"
dependencies = [
"PyYAML",
"click",
"custodian>=2024.4.18",
"emmet-core>=0.86.1",
"jobflow>=0.1.11",
"monty>=2024.12.10",
"numpy",
"pydantic-settings>=2.0.3",
"pydantic>=2.0.1",
"pymatgen>=2024.11.13",
"pymongo<=4.16.0",
]
[project.optional-dependencies]
abinit = [
"abipy>=0.9.3",
"netCDF4<1.7.5", # TODO: latest NetCDF missing 3.12 support: https://github.com/Unidata/netcdf4-python/issues/1461
]
aims = ["pymatgen-io-aims>=0.0.5", "pymatgen>=2025.10.7"]
amset = ["amset>=0.4.15", "pydash"]
cclib = ["cclib>=1.8.1"]
mp = ["mp-api>=0.37.5"]
phonons = ["phonopy>=2.43.6", "seekpath>=2.0.0"]
lobster = ["ijson>=3.2.2", "lobsterpy>=0.6.0"]
defects = [
"dscribe>=1.2.0",
"pymatgen-analysis-defects>=2024.5.11",
"python-ulid>=2.7",
]
ase = ["ase>=3.26.0"]
ase-ext = ["tblite>=0.3.0; platform_system=='Linux'"]
forcefields-demo = ["chgnet>=0.3.8","atomate2[ase]"]
torchsim = [
"torch-sim-atomistic==0.5.0; python_version >= '3.12'"
]
jdftx = ["pymatgen==2026.3.23"]
approxneb = ["pymatgen-analysis-diffusion>=2024.7.15"]
openmm = [
"mdanalysis>=2.8.0",
"openmm-mdanalysis-reporter>=0.1.0",
"openmm>=8.1.0",
]
fireworks = ["fireworks==2.1.3"]
strict-openff = [
"mdanalysis==2.10.0",
"monty==2026.2.18",
"openmm-mdanalysis-reporter==0.1.0",
"openmm==8.5.1",
"pymatgen==2026.3.23", # EXERCISE CAUTION WHEN UPDATING - open ff is extremely sensitive to pymatgen version
]
# Forcefields have separate strict groupings because of conflicting dependencies.
# The labels below should not be taken as fixed in time.
# They are meant to be instructive as to why certain forcefields are grouped together.
# Ex: `strict-forcefields-torch-limited` might indicate that these require a lower version of `pytorch`
# Whereas `strict-forcefields-generic` might indicate that no dependency conflicts are known for the group
# ALWAYS REMEMBER to update `.github/workflows/testing.yml` to reflect the current set of
# forcefield dependency groups.
strict-forcefields-generic = [
"calorine==3.3; python_version >= '3.12'",
"calorine==3.1; python_version < '3.12'",
"chgnet==0.4.2",
"quippy-ase==0.10.2",
"sevenn==0.12.1",
"deepmd-kit==3.1.3",
"tensorflow-cpu==2.21.0; sys_platform == 'linux'",
"tensorflow==2.21.0; sys_platform == 'darwin' or sys_platform == 'win32'",
"mattersim==1.2.2",
"ase<3.29.0", # TODO: remove, required for mattersim because of ase.constraints import
"wandb>=0.24.0", # required for mattersim
"upet>=0.2.1",
]
strict-forcefields-torch-limited = [
"matgl==2.1.1",
# Note that DGL stopped building new releases for Mac + Windows after 2.2.0.
# That enforces a simultaneous pin on torch / torchdata
# Linux users can acces newer versions of dgl / torch / torchdata via conda.
# Mac / Windows users will need to install from source
"dgl==2.2.0; sys_platform == 'darwin' or sys_platform == 'win32'",
"dgl<=2.4.0; sys_platform == 'linux'",
"torch==2.11.0; sys_platform == 'darwin' or sys_platform == 'win32'",
"torch==2.2.0; sys_platform == 'linux'",
"torchdata==0.7.1",
"nequip==0.17.1", # requires numpy<2 because of matscipy
"numpy==1.26.4",
]
strict-forcefields-e3nn-limited = [
"mace-torch==0.3.15",
"torch-dftd==0.5.3",
]
strict-forcefields-numpy-limited = [
"nequip-allegro==0.8.2",
"numpy==1.26.4",
]
strict = [
"atomate2[cclib, phonons, lobster, openmm, mp, defects, ase, ase-ext]",
"numpy<3.0",
"numba>=0.60.0", # needed to get numpy >2,<3 installed
"pymatgen==2026.3.23",
]
[project.scripts]
atm = "atomate2.cli:cli"
[project.urls]
homepage = "https://materialsproject.github.io/atomate2/"
repository = "https://github.com/materialsproject/atomate2"
documentation = "https://materialsproject.github.io/atomate2/"
changelog = "https://github.com/materialsproject/atomate2/blob/main/CHANGELOG.md"
[dependency-groups]
dev = ["pre-commit>=4.5.1"]
tests = [
"fireworks==2.1.3",
"nbmake==1.5.5",
"pytest-cov==7.1.0",
"pytest-mock==3.15.1",
"pytest-split==0.11.0",
"pytest-xdist==3.8.0",
"pytest==9.0.3",
]
docs = [
"fireworks==2.1.3",
"autodoc_pydantic==2.2.0",
"furo==2025.12.19",
"ipython==9.10.1",
"jsonschema[format]",
"myst_parser==5.0.0",
"numpydoc==1.10.0",
"sphinx-copybutton==0.5.2",
"sphinx==9.0.4",
"sphinx_design==0.7.0",
"jupyterlab==4.5.6",
]
[tool.setuptools.package-data]
atomate2 = ["py.typed"]
"atomate2.vasp.sets" = ["*.yaml"]
"atomate2.cp2k.sets" = ["*.yaml"]
"atomate2.cp2k.schemas.calc_types" = ["*.yaml"]
"atomate2.jdftx.sets" = ["*.yaml"]
[tool.versioningit.vcs]
method = "git"
default-tag = "0.0.1"
[tool.mypy]
ignore_missing_imports = true
no_strict_optional = true
[tool.pytest.ini_options]
addopts = "-p no:warnings --import-mode=importlib --cov-config=pyproject.toml"
filterwarnings = [
"ignore:.*POTCAR.*:UserWarning",
"ignore:.*input structure.*:UserWarning",
"ignore:.*is not gzipped.*:UserWarning",
"ignore:.*magmom.*:UserWarning",
"ignore::DeprecationWarning",
]
[tool.coverage.run]
include = ["src/*"]
parallel = true
branch = true
[tool.coverage.paths]
source = ["src/"]
[tool.coverage.report]
skip_covered = true
show_missing = true
exclude_lines = [
'^\s*@overload( |$)',
'^\s*assert False(,|$)',
'if typing.TYPE_CHECKING:',
'if TYPE_CHECKING:',
]
[tool.ruff]
target-version = "py310"
output-format = "concise"
[tool.ruff.lint]
select = ["ALL"]
ignore = [
"ANN002", # Missing type annotation for *arg
"ANN003", # Missing type annotation for **kwargs
"ANN401", # typing.Any disallowed
"ARG002", # unused method argument
"C408", # Unnecessary (dict/list/tuple) call - remove call
"C901", # function too complex
"COM812", # trailing comma missing
"EM", # exception message must not use f-string literal
"ERA001", # found commented out code
"FBT001",
"FBT002",
"FIX002",
"G004", # logging uses f-string
"ISC001",
"PD011", # pandas-use-of-dot-values
"PERF203", # try-except-in-loop
"PLC0415", # imports not at top level are OK
"PLR0911", # too many returns
"PLR0912", # too many branches
"PLR0913", # too many arguments
"PLR0915", # too many local statements
"PLR2004",
"PT006", # pytest-parametrize-names-wrong-type
"PT013", # pytest-incorrect-pytest-import
"PTH", # prefer Pathlib to os.path
"RUF013", # implicit-optional
"S324", # use of insecure hash function
"S507", # paramiko auto trust
"S603", # use of insecure subprocess
"TD", # todos
"TRY003", # long message outside exception class
]
pydocstyle.convention = "numpy"
isort.known-first-party = ["atomate2"]
isort.split-on-trailing-comma = false
[tool.ruff.format]
docstring-code-format = true
[tool.ruff.lint.per-file-ignores]
"__init__.py" = ["F401"]
"**/tests/*" = ["ANN", "ARG001", "D", "INP001", "PLR2004", "S101"]
# flake8-type-checking (TCH): things inside TYPE_CHECKING aren't available
# at runtime and so can't be used by pydantic models
# flake8-future-annotations (FA): pipe operator for type unions only work in pydantic models in python 3.10+
"**/schemas/*" = ["FA", "TCH", "UP007"]
"**/schemas.py" = ["FA", "TCH", "UP007"]
"**/settings.py" = ["FA", "TCH", "UP007"]
"docs/*" = ["INP001"]