-
Notifications
You must be signed in to change notification settings - Fork 23
/
pyproject.toml
321 lines (303 loc) · 8.63 KB
/
pyproject.toml
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
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
[build-system]
# Minimum requirements for the build system to execute.
requires = ["setuptools>=65.0.0"] # PEP 508 specifications.
build-backend = "setuptools.build_meta"
[project]
name = "SMACT"
version = "3.0.1"
description = "Semiconducting Materials by Analogy and Chemical Theory"
readme = "README.md"
authors = [
{name = "The SMACT Developers", email = "[email protected]"},
]
maintainers = [
{name = "Anthony O. Onwuli", email = "[email protected]"},
]
classifiers = [
"Development Status :: 5 - Production/Stable",
"Intended Audience :: Science/Research",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Topic :: Scientific/Engineering",
"Topic :: Scientific/Engineering :: Chemistry",
]
requires-python = ">=3.10"
keywords = [
"python",
"machine-learning",
"computational-chemistry",
"materials-science",
"materials-informatics",
"materials-screening",
"materials-design",
"materials"
]
dependencies = [
"ase",
"numpy<3",
"pandas",
"pathos",
"pymatgen>=2024.2.20",
"scipy",
"spglib",
"typing-extensions",
]
license = {text = "MIT"}
[project.urls]
Homepage = "https://github.com/WMD-group/SMACT"
Documentation = "https://smact.readthedocs.io/en/latest/"
Repository = "https://github.com/WMD-group/SMACT"
Issues = "https://github.com/WMD-group/SMACT/issues"
Pypi = "https://pypi.org/project/SMACT/"
[project.optional-dependencies]
dev = [
"pytest",
"ruff",
"pyright",
"codespell",
"pytest-cov",
"blacken-docs",
"nbstripout"
]
docs = [
"sphinx==8.1.3",
"sphinx_rtd_theme==3.0.2",
"readthedocs-sphinx-search==0.3.2",
"sphinx-book-theme==1.1.3",
"myst-nb==1.1.2"
]
mp = ["mp-api"]
crystal_space = ["mp-api",
"ElementEmbeddings",
"umap-learn==0.5.3",
"kaleido",
"pydantic<2.10.0"]
featurisers = [
"matminer",
"ElementEmbeddings",
]
visualisation = [
"seaborn",
"pymatviz",
"dash",
]
optional = [
"pydantic>=2.9.2",
"mp-api>=0.42.2",
"pymatviz>=0.14",
"seaborn>=0.13.2",
"pymatgen>=2024.2.20",
"matminer>=0.9.2",
"kaleido>=0.2.1",
"ase>=3.22.0",
"llvmlite>=0.40",
"ElementEmbeddings>=0.4",
"dash>=2.18.2",
]
strict = [
"pydantic==2.9.2",
"mp-api==0.42.2",
"pymatviz==0.14",
"seaborn==0.13.2",
"pymatgen==2024.11.13",
"matminer==0.9.2",
"umap-learn==0.5.3",
"kaleido==0.2.1",
"ase==3.23.0",
"numpy",
"ElementEmbeddings==0.6.1",
"dash==2.18.2",
]
[tool.semantic_release]
version_variable = "setup.py:__version__"
version_source = "tag"
[tool.ruff]
target-version = "py310"
line-length = 120
force-exclude = true
[tool.ruff.lint]
select = ["ALL"]
ignore = [
# Rule families
"ANN", # flake8-annotations (not ready, require types for ALL args)
"ARG", # Check for unused function arguments
"BLE", # General catch of Exception
"C90", # Check for functions with a high McCabe complexity
"COM", # flake8-commas (conflict with line wrapper)
"CPY", # Missing copyright notice at top of file (need preview mode)
"EM", # Format nice error messages
"ERA", # Check for commented-out code
"FIX", # Check for FIXME, TODO and other developer notes
"FURB", # refurb (need preview mode, too many preview errors)
"G", # Validate logging format strings
"INP", # Ban PEP-420 implicit namespace packages
"N", # PEP8-naming (many var/arg names are intended)
"PTH", # Prefer pathlib over os.path
"SLF", # Access "private" class members
"T20", # Check for print/pprint
"TD", # TODO tags related
# Single rules
"B023", # Function definition does not bind loop variable
"B028", # No explicit stacklevel keyword argument found
"B904", # Within an except clause, raise exceptions with ...
"C408", # unnecessary-collection-call
"D105", # Missing docstring in magic method
"D205", # One blank line required between summary line and description
"D212", # Multi-line docstring summary should start at the first line
"E501", # Line too long
"E722", # Do not use bare `except` TODO fix this
"FBT001", # Boolean-typed positional argument in function definition
"FBT002", # Boolean default positional argument in function
"ISC001",
"NPY201", # TODO: enable after migration to NumPy 2.0
"PD901", # pandas-df-variable-name
"PERF203", # Use of try-except in for/while loop
"PERF401", # Replace "for" loops with list comprehension
"PLR0911", # Too many return statements
"PLR0912", # Too many branches
"PLR0913", # Too many arguments
"PLR0915", # Too many statements
"PLR2004", # Magic-value-comparison TODO fix these
"PLW2901", # Outer for loop variable overwritten by inner assignment target
"PLW0603", # Using the global statement to update `_el_ox_states_wiki` is discouraged TODO fix these
"PT009", # Use a regular `assert` instead of unittest-style `assertAlmostEqual`
"PT011", # `pytest.raises(ValueError)` is too broad, set the `match` parameter or use a more specific exception TODO fix these
"PT013", # Incorrect import of pytest
"RET505", # Unnecessary `else` after `return` statement
"S101", # Use of "assert"
"S110", # Log for try-except-pass
"S112", # Log for try-except-continue
"S301", # `pickle` and modules that wrap it can be unsafe when used to deserialize untrusted data, possible security issue
"S311", # Use random module for cryptographic purposes
"S314", # Replace xml with defusedxml to avoid XML attacks
"S603", # Check source for use of "subprocess" call
"S607", # Start process with relative path
"S608", # Possible SQL injection vector through string-based query construction
"SIM105", # Use contextlib.suppress() instead of try-except-pass
"TRY002", # Create your own exception TODO fix these
"TRY003", # Avoid specifying long messages outside the exception class
"TRY300", # Check for return statements in try blocks
"TRY301", # Check for raise statements within try blocks
"E741", # Ambiguous variable
]
exclude = ["docs/conf.py", "docs/*"]
pydocstyle.convention = "google"
isort.required-imports = ["from __future__ import annotations"]
[tool.ruff.format]
docstring-code-format = true
[tool.ruff.lint.per-file-ignores]
"smact/tests/*" = ["D"]
[tool.pyright]
typeCheckingMode = "off"
reportPossiblyUnboundVariable = true
reportUnboundVariable = true
[tool.codespell]
skip = "*.csv,*/site/*,*/docs/_build/*,paper.md,*dev_docs/*,paper.bib,*.txt,*examples/Structure_Prediction/Li-Garnets_SP-Pym-new.ipynb"
check-filenames = true
ignore-regex = "[A-Za-z0-9+/]{100,}"
ignore-words-list = [
"H",
"He",
"Li",
"Be",
"B",
"C",
"N",
"O",
"F",
"Ne",
"Na",
"Mg",
"Al",
"Si",
"P",
"S",
"Cl",
"Ar",
"K",
"Ca",
"Sc",
"Ti",
"V",
"Cr",
"Mn",
"Fe",
"Co",
"Ni",
"Cu",
"Zn",
"Ga",
"Ge",
"As",
"Se",
"Br",
"Kr",
"Rb",
"Sr",
"Y",
"Zr",
"Nb",
"Mo",
"Tc",
"Ru",
"Rh",
"Pd",
"Ag",
"Cd",
"In",
"Sn",
"Sb",
"Te",
"I",
"Xe",
"Cs",
"Ba",
"La",
"Ce",
"Pr",
"Nd",
"Pm",
"Sm",
"Eu",
"Gd",
"Tb",
"Dy",
"Ho",
"Er",
"Tm",
"Yb",
"Lu",
"Hf",
"Ta",
"W",
"Re",
"Os",
"Ir",
"Pt",
"Au",
"Hg",
"Tl",
"Pb",
"Bi",
"Po",
"At",
"Rn",
"Fr",
"Ra",
"Ac",
"Th",
"Pa",
"U",
"Np",
"Pu",
"Am",
"Cm",
"Bk",
"eles",
"assertIn",
"Mater",
]