forked from DeepLabCut/DeepLabCut
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpyproject.toml
More file actions
243 lines (234 loc) · 7.03 KB
/
Copy pathpyproject.toml
File metadata and controls
243 lines (234 loc) · 7.03 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
[build-system]
build-backend = "setuptools.build_meta"
requires = [ "setuptools>=61" ]
[project]
name = "deeplabcut"
version = "3.0.0"
description = "Markerless pose-estimation of user-defined features with deep learning"
readme = { file = "README.md", content-type = "text/markdown" }
keywords = [
"animal behavior",
"markerless tracking",
"neuroscience",
"pose estimation",
]
license = { text = "LGPL-3.0-or-later" }
requires-python = ">=3.10"
classifiers = [
"Intended Audience :: Science/Research",
"License :: OSI Approved :: GNU Lesser General Public License v3 (LGPLv3)",
"Natural Language :: English",
"Operating System :: OS Independent",
"Programming Language :: Python :: 3 :: Only",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Topic :: Scientific/Engineering",
"Topic :: Scientific/Engineering :: Artificial Intelligence",
"Topic :: Scientific/Engineering :: Image Processing",
]
dependencies = [
"albumentations<=1.4.3",
"dlclibrary>=0.0.12",
"einops",
"filelock>=3.12,<3.16",
"filterpy>=1.4.4",
"h5py>=3.15.1; platform_system=='Darwin'",
"huggingface-hub>=0.23",
"imageio-ffmpeg",
"imgaug>=0.4",
"matplotlib>=3.3,<3.9,!=3.7,!=3.7.1",
"networkx>=2.6",
"numba>=0.54",
"numpy>=1.18.5,<2",
"packaging>=26",
# Migration to pandas 3.0 is tracked in https://github.com/DeepLabCut/DeepLabCut/issues/3362.
"pandas[hdf5,performance]>=2.2,<3",
"pillow>=7.1",
"pycocotools",
"pydantic>=2,<3",
"pyyaml",
"ruamel-yaml>=0.15",
"scikit-image>=0.17",
"scikit-learn>=1",
"scipy>=1.9",
"statsmodels>=0.11",
"tables>3.8",
"timm",
"torch>=2",
"torchvision",
"tqdm",
]
[[project.authors]]
name = "M-Lab of Adaptive Intelligence"
email = "mackenzie@deeplabcut.org"
[[project.authors]]
name = "Mathis Group for Computational Neuroscience and AI"
email = "alexander@deeplabcut.org"
[project.optional-dependencies]
gui = [
"napari-deeplabcut>=0.3.1",
"pyside6; platform_system!='Linux' or platform_machine!='x86_64'",
# Avoid 6.10.0 only on Linux x86_64 (fails for older glib versions)
"pyside6<6.10; platform_system=='Linux' and platform_machine=='x86_64'",
"qdarkstyle==3.1",
]
openvino = [ "openvino-dev==2022.1" ]
docs = [
"jupyter-book==1.0.4.post1",
"sphinxcontrib-mermaid",
]
dev-docs = [
"black>=24",
"mike>=2.1",
"mkdocs>=1.6",
"mkdocs-api-autonav>=0.1",
"mkdocs-autorefs>=1.2",
"mkdocs-jupyter>=0.25",
"mkdocs-material[imaging]>=9.5",
"mkdocstrings[python]>=0.27",
]
fmpose3d = [ "fmpose3d>=0.0.8" ]
# Use only one of [tf, tf-cu11, tf-cu12, tf-latest]. Do not combine extras.
tf = [
"protobuf<7",
"tensorflow>=2.12,<2.16; python_version<'3.12'",
"tensorflow>=2.16.1,<2.18; python_version>='3.12'",
"tensorflow-io-gcs-filesystem==0.31; platform_system=='Windows' and python_version<'3.12'",
"tensorflow-metal==1.2; platform_system=='Darwin' and python_version<'3.12'",
"tensorflow-metal>=1.2; platform_system=='Darwin' and python_version>='3.12'",
"tensorpack>=0.11",
"tf-keras<2.15; python_version<'3.12'",
"tf-keras>=2.15,<2.18; python_version>='3.12'",
"tf-slim>=1.1",
]
tf-cu11 = [
"protobuf<7",
"tensorflow==2.14",
"tensorflow-io-gcs-filesystem==0.31; platform_system=='Windows'",
"tensorflow-metal==1.2; platform_system=='Darwin'",
"tensorpack==0.11",
"tf-keras==2.14.1",
"tf-slim==1.1",
"torch<2.1",
"torchvision<0.16",
]
tf-cu12 = [
"protobuf<7",
"tensorflow==2.18",
"tensorflow-metal==1.2; platform_system=='Darwin'",
"tensorpack==0.11",
"tf-keras==2.18",
"tf-slim==1.1",
"torch<2.11",
"torchvision<0.26",
]
tf-latest = [
"protobuf<7",
"tensorflow>=2.18",
"tensorflow-metal>=1.2; platform_system=='Darwin'",
"tensorpack>=0.11",
"tf-keras",
"tf-slim>=1.1",
]
# apple_mchips is kept for older systems, prefer [tf] in new projects.
apple_mchips = [
"protobuf<7; platform_system=='Darwin'",
"tensorflow>=2.12,<2.15; platform_system=='Darwin' and python_version<'3.12'",
"tensorflow>=2.15,<2.18; platform_system=='Darwin' and python_version>='3.12'",
"tensorflow-metal==1.2; platform_system=='Darwin' and python_version<'3.12'",
"tensorflow-metal>=1.2; platform_system=='Darwin' and python_version>='3.12'",
"tensorpack>=0.11; platform_system=='Darwin'",
"tf-keras; platform_system=='Darwin'",
"tf-slim>=1.1; platform_system=='Darwin'",
]
modelzoo = [ "huggingface-hub" ]
wandb = [ "wandb" ]
[project.scripts]
dlc = "deeplabcut.__main__:main"
[project.urls]
Homepage = "https://www.deeplabcut.org"
Repository = "https://github.com/DeepLabCut/DeepLabCut"
Documentation = "https://deeplabcut.github.io/DeepLabCut/README.html"
[dependency-groups]
dev = [
"coverage",
"nbformat>5",
"pre-commit",
"pytest",
"pytest-cov",
"ruff",
]
[tool.setuptools]
include-package-data = false
[tool.setuptools.package-data]
"*" = [ "*.yaml", "*.yml", "*.json", "*.qss", "*.png", "*.md", "*.sh" ]
[tool.setuptools.packages.find]
include = [ "deeplabcut*" ]
exclude = [ "tests*", "docs*", "examples*" ]
[tool.uv]
# One of tf / tf-cu12 / tf-latest. apple_mchips matches [tf] on macOS but conflicts with
# [tf-cu12] and [tf-latest] (overlapping tensorflow pins cannot be unified with uv's lock).
conflicts = [
[
{ extra = "tf" },
{ extra = "tf-cu11" },
{ extra = "tf-cu12" },
{ extra = "tf-latest" },
{ extra = "apple_mchips" },
],
[
{ extra = "tf-cu11" },
{ extra = "tf-cu12" },
{ extra = "fmpose3d" },
],
]
[[tool.uv.dependency-metadata]]
name = "openvino-dev"
version = "2022.1.0"
requires-dist = []
[tool.uv.pip]
torch-backend = "auto"
[tool.ruff]
target-version = "py310"
line-length = 120
fix = true
[tool.ruff.format]
docstring-code-format = true
[tool.ruff.lint]
select = [ "E", "F", "B", "I", "UP", "PIE" ]
ignore = [ "E741", "B007" ]
[tool.ruff.lint.per-file-ignores]
"__init__.py" = [ "F401", "E402" ]
"deeplabcut/**/__init__.py" = [ "F403" ]
"deeplabcut/gui/window.py" = [ "F403" ]
"deeplabcut/pose_estimation_tensorflow/lib/crossvalutils.py" = [ "F403" ]
"deeplabcut/pose_estimation_tensorflow/lib/inferenceutils.py" = [ "F403" ]
"deeplabcut/pose_estimation_tensorflow/lib/trackingutils.py" = [ "F403" ]
"*.ipynb" = [ "E402" ]
[tool.ruff.lint.pydocstyle]
convention = "google"
# Config for the docformatter pre-commit hook (currently disabled in favour of ruff).
# Re-enable the hook in .pre-commit-config.yaml when large-scale docstring
# reformatting is needed.
[tool.docformatter]
wrap-descriptions = 88
wrap-summaries = 88
black = true
[tool.pyproject-fmt]
max_supported_python = "3.12"
generate_python_version_classifiers = true
# Avoid collapsing tables to field.key = value format (less readable)
table_format = "long"
[tool.pytest.ini_options]
markers = [
"require_models: mark test as requiring models to run",
"fmpose3d: tests for fmpose3d integration",
"unittest: fast unit-level tests",
"functional: functional/integration-style tests",
"deprecated: tests for deprecated APIs kept for backward-compatibility",
]
[tool.mdformat]
# Preserve prose line breaks; avoid spurious diffs from reflowing paragraphs.
wrap = "no"
end_of_line = "lf"