-
Notifications
You must be signed in to change notification settings - Fork 34
/
pyproject.toml
351 lines (333 loc) · 9.07 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
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
# This Software (Dioptra) is being made available as a public service by the
# National Institute of Standards and Technology (NIST), an Agency of the United
# States Department of Commerce. This software was developed in part by employees of
# NIST and in part by NIST contractors. Copyright in portions of this software that
# were developed by NIST contractors has been licensed or assigned to NIST. Pursuant
# to Title 17 United States Code Section 105, works of NIST employees are not
# subject to copyright protection in the United States. However, NIST may hold
# international copyright in software created by its employees and domestic
# copyright (or licensing rights) in portions of software that were assigned or
# licensed to NIST. To the extent that NIST holds copyright in this software, it is
# being made available under the Creative Commons Attribution 4.0 International
# license (CC BY 4.0). The disclaimers of the CC BY 4.0 license apply to all parts
# of the software developed or licensed by NIST.
#
# ACCESS THE FULL CC BY 4.0 LICENSE HERE:
# https://creativecommons.org/licenses/by/4.0/legalcode
[build-system]
requires = ["setuptools>=61.0", "wheel"]
build-backend = "setuptools.build_meta"
[project]
name = "dioptra"
version = "1.0.1"
authors = [
{ name="James Glasbrenner", email="[email protected]" },
{ name="Harold Booth", email="[email protected]" },
{ name="Keith Manville", email="[email protected]" },
{ name="Julian Sexton", email="[email protected]" },
{ name="Michael Andy Chisholm", email="[email protected]" },
{ name="Henry Choy", email="[email protected]" },
{ name="Andrew Hand", email="[email protected]" },
{ name="Bronwyn Hodges", email="[email protected]" },
{ name="Paul Scemama" },
{ name="Dmitry Cousin", email="[email protected]" },
{ name="Eric Trapnell", email="[email protected]" },
{ name="Mark Trapnell", email="[email protected]" },
{ name="Howard Huang", email="[email protected]" },
{ name="Paul Rowe" },
{ name="Alexander Byrne", email="[email protected]" },
{ name="Luke Barber" },
{ name="Cory Miniter" },
]
maintainers = [
{ name="James Glasbrenner", email="[email protected]" },
{ name="Keith Manville", email="[email protected]" },
{ name="Harold Booth", email="[email protected]" },
]
description = "Dioptra provides Machine Learning Security researchers with an environment for organizing and running experiments."
readme = "README.md"
requires-python = ">=3.11"
dependencies = [
"alembic>=1.13.0",
"boto3>=1.16.0",
"Click>=8.0.0,<9",
"entrypoints>=0.3",
"Flask>=2.0.0",
"flask-accepts>=0.17.0",
"Flask-Cors>=3.0.1",
"Flask-Login>=0.6.0",
"Flask-Migrate>=2.5.0",
"flask-restx>=0.5.1",
"Flask-SQLAlchemy>=2.4.0",
"injector>=0.18.0",
"jsonschema>=4.17.0",
"marshmallow>=3.9.0,<4",
"multimethod>=1.5",
"numpy>=1.22.0",
"pandas>=1.5.0",
"passlib>=1.7.0",
"pyparsing>=3.1.0",
"python-dateutil>=2.8.0",
"PyYAML>=6.0.0",
"redis>=3.5.0",
"requests>=2.25,<3",
"rq>=1.5.0",
"scipy>=1.4.1",
"structlog>=20.2.0",
"SQLAlchemy>=2",
"typing-extensions>=3.7.4.3",
"werkzeug>=3.0.0",
]
classifiers = [
"Development Status :: 5 - Production/Stable",
"Framework :: Flask",
"Intended Audience :: Science/Research",
"Operating System :: OS Independent",
"Programming Language :: Python :: 3 :: Only",
"Programming Language :: Python :: 3.11",
"Topic :: Scientific/Engineering :: Artificial Intelligence",
"Topic :: Security",
]
[project.urls]
repository = "https://github.com/usnistgov/dioptra"
documentation = "https://pages.nist.gov/dioptra"
Changelog = "https://github.com/usnistgov/dioptra/blob/main/CHANGELOG.md"
"Issue Tracker" = "https://github.com/usnistgov/dioptra/issues"
[project.scripts]
dioptra-db = "dioptra.restapi.db.alembic.run:cli"
run-experiment = "dioptra.task_engine.run_experiment:main"
validate-experiment = "dioptra.task_engine.validate:main"
s3-download = "dioptra.worker.s3_download_cli:main"
dioptra-worker-v1 = "dioptra.worker.dioptra_worker_v1:main"
[project.entry-points."dioptra.generics.estimator_predict"]
tf_keras_model = "dioptra.generics_plugins.estimator_predict.tf_keras_model"
[project.entry-points."dioptra.generics.fit_estimator"]
tf_keras_model = "dioptra.generics_plugins.fit_estimator.tf_keras_model"
[project.optional-dependencies]
cookiecutter = [
"cookiecutter>=2.0.0,<2.2.0",
]
mlflow-skinny = [
"mlflow-skinny>=2",
]
mlflow-full = [
"mlflow>=2",
]
examples = [
"aiohttp>=3.8.0",
"kaggle>=1.5.0",
"Pillow>=9.2.0",
"rich>=13.3.0",
"universal_pathlib>=0.0.23",
]
postgres = [
"psycopg2-binary>=2.9.0",
]
worker = [
"async_timeout",
"adversarial-robustness-toolbox>=1.9.0",
"imgaug>=0.4.0",
"matplotlib",
"nrtk>=0.3.0",
"opencv-python",
"Pillow>=9.2.0",
"prefect>=1.0.0,<2",
"pyarrow",
"pycocotools",
"python-json-logger>=2.0.0",
"rich>=13.3.0",
"scikit-learn>=1.0.0",
"simplejson",
"tensorboard",
]
dev = [
"autopep8",
"binaryornot>=0.4.0",
"build",
"entrypoints",
"esbonio",
"Faker>=24.0.0",
"flake8-bugbear",
"flake8>=3.8.0",
"freezegun",
"ipykernel",
"ipython",
"jupyter",
"jupyterlab",
"nbconvert",
"pip-tools",
"pycodestyle",
"pydocstyle",
"pytest-cookies",
"pytest>=7",
"pytoml",
"Sphinx>=4.5.0,<5",
"tomli",
"tox>=4.4.0",
"wheel",
]
[tool.black]
line-length = 88
target-version = ['py311']
include = '\.pyi?$'
exclude = '''
/(
\.eggs
| \.git
| \.hg
| \.mypy_cache
| \.tox
| \.venv
| _build
| buck-out
| build
| dist
)/
'''
[tool.bumpver]
current_version = "1.0.1"
version_pattern = "MAJOR.MINOR.PATCH[-TAG]"
commit_message = "release {old_version} → {new_version}"
commit = true
tag = true
push = false
[tool.bumpver.file_patterns]
"README.md" = [
"Release {version}",
]
"pyproject.toml" = [
'current_version = "{version}"',
'version = "{pep440_version}"',
]
"docs/source/conf.py" = [
'release = "{version}"',
]
"src/dioptra/client/__version__.py" = [
"{pep440_version}",
]
"src/dioptra/pyplugs/__version__.py" = [
"{pep440_version}",
]
"src/dioptra/restapi/__version__.py" = [
"{pep440_version}",
]
"src/dioptra/rq/__version__.py" = [
"{pep440_version}",
]
"src/dioptra/sdk/__version__.py" = [
"{pep440_version}",
]
[tool.commitizen]
name = "cz_conventional_commits"
version = "1.0.1"
changelog_file = "CHANGELOG.md"
style = [
["qmark", "fg:#ff9d00 bold"],
["question", "bold"],
["answer", "fg:#ff9d00 bold"],
["pointer", "fg:#ff9d00 bold"],
["highlighted", "fg:#ff9d00 bold"],
["selected", "fg:#cc5454"],
["separator", "fg:#cc5454"],
["instruction", ""],
["text", ""],
["disabled", "fg:#858585 italic"],
]
[tool.coverage.report]
exclude_lines = [
# Have to re-enable the standard pragma
"pragma: no cover",
# Don't complain about missing debug-only and type checking-only code:
"def __repr__",
"if TYPE_CHECKING:",
# Don't complain if non-runnable code isn't run:
'\.\.\.',
"if __name__ == .__main__.:",
]
[tool.coverage.run]
omit = [
# omit __init__.py files since they are just for mypy and pytest purposes
"*/__init__.py",
# omit __version__.py files since they contain no functionality
"*/__version__.py",
# omit config and models files in restapi module since these are just configurations and imports
"restapi/config.py",
"restapi/models.py",
# omit alembic directory since these files are just for migrating the database
"*/alembic/*.py",
"*/alembic/versions/*.py",
]
[tool.doc8]
ignore = ["D001"]
[tool.isort]
profile = "black"
honor_noqa = true
[tool.mypy]
python_version = "3.11"
platform = "linux"
mypy_path = "src,task-plugins"
explicit_package_bases = true
namespace_packages = true
show_column_numbers = true
follow_imports = "normal"
ignore_missing_imports = true
disallow_untyped_calls = true
warn_return_any = true
strict_optional = true
warn_no_return = true
warn_redundant_casts = true
warn_unused_ignores = true
show_error_codes = true
cache_dir = "/dev/null"
exclude = [
'alembic/.*$', # exclude all files, folders under alembic directory
]
plugins = "numpy.typing.mypy_plugin"
[tool.pyright]
include = ["src"]
exclude = [
"**/.ipynb_checkpoints",
"**/__pycache__",
"**/.tox"
]
[tool.pytest.ini_options]
minversion = "7.0"
addopts = "--import-mode=importlib -ra"
testpaths = [
"tests/unit",
]
log_cli = false
log_cli_level = "INFO"
markers = [
"info: marks tests as info (deselect with '-m \"not info\"')",
]
norecursedirs = [
"*.egg",
".*",
"_darcs",
"build",
"CVS",
"dist",
"node_modules",
"venv",
'{arch}',
"alembic",
]
[tool.rstcheck]
ignore_directives = [
"autoclass",
"autodecorator",
"autofunction",
"automodule",
"autoexception",
"dropdown",
"panels",
"margin",
"tab-set",
"tabbed",
]
ignore_messages = '(Hyperlink target ".*?" is not referenced\.)'
ignore_roles = [
"kbd",
]
report_level = "INFO"