generated from AntreasAntoniou/minimal-ml-template
-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpyproject.toml
197 lines (183 loc) · 4.58 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
[project]
name = "TALI"
version = "2.1.0"
description = "TALI: A quadra model dataset and transforms for PyTorch"
authors = [
{name = "Antreas Antoniou", email = "[email protected]"},
]
dependencies = [
"torch",
"torchvision",
"torchaudio",
"torchgeometry",
"torchmetrics",
"accelerate",
"transformers",
"datasets",
"huggingface-hub",
"orjson",
"torchtyping",
"wandb",
"rich",
"opencv-python",
"scipy",
"scikit-learn",
"decord",
"natsort",
"evaluate",
"einops",
"fire",
"timm",
"sentencepiece",
"pytorchvideo",
"torchtyping",
"rich",
"opencv-python",
"av",
"scipy",
"scikit-learn",
"einops",
"timm",
]
requires-python = ">=3.11"
readme = "README.md"
license = {text = "MIT"}
[project.optional-dependencies]
dev = [
"pytest>=8.2.2",
"pytest-cov>=5.0.0",
"pytest-mock>=3.14.0",
"pytest-rich>=0.1.1",
"pytest-sugar>=1.0.0",
"pytest-xdist>=3.6.1",
"autoflake>=2.3.1",
"isort>=5.13.2",
"black>=24.4.2",
"ruff>=0.3.4",
"jupyterlab>=4.2.2",
"nvitop>=1.3.2",
"gh>=0.0.4",
"sphinx>=8.1.3",
"sphinx-rtd-theme>=3.0.2",
"sphinx-autodoc-typehints>=2.5.0",
"sphinx-material>=0.0.36",
"matplotlib>=3.9.0",
"pdm",
]
[build-system]
requires = ["pdm-backend"]
build-backend = "pdm.backend"
[tool.pdm]
distribution = true
[tool.pdm.scripts]
format = { composite = ["format:black", "format:isort", "format:ruff"] }
"format:black" = "black ."
"format:isort" = "isort ."
"format:ruff" = "ruff check --fix ."
"format:check" = { composite = ["black --check .", "isort --check-only .", "ruff check ."] }
lint = "ruff check ."
test = "pytest -v -s --color=yes"
test-parallel = "pytest -v -s -n auto --color=yes"
test-cov = "pytest -v -s --color=yes --cov=vita --cov-report=term-missing"
[tool.black]
line-length = 88
target-version = ["py311"]
include = '\.pyi?$'
[tool.isort]
profile = "black"
line_length = 88
multi_line_output = 3
include_trailing_comma = true
force_grid_wrap = 0
use_parentheses = true
ensure_newline_before_comments = true
skip_gitignore = true
[tool.ruff]
line-length = 88
target-version = "py311"
[tool.ruff.lint]
select = [
"E", # pycodestyle errors
"F", # pyflakes
"B", # flake8-bugbear
"C4", # flake8-comprehensions
"I", # isort
"N", # pep8-naming
"UP", # pyupgrade
"W", # pycodestyle warnings
"YTT", # flake8-2020
"S", # flake8-bandit
"BLE", # flake8-blind-except
"FBT", # flake8-boolean-trap
"C", # flake8-comprehensions
"DTZ", # flake8-datetimez
"T10", # flake8-debugger
"ISC", # flake8-implicit-str-concat
"G", # flake8-logging-format
"PIE", # flake8-pie
"T20", # flake8-print
"PT", # flake8-pytest-style
"Q", # flake8-quotes
"RSE", # flake8-raise
"RET", # flake8-return
"SLF", # flake8-self
"SIM", # flake8-simplify
"TID", # flake8-tidy-imports
"ARG", # flake8-unused-arguments
"PTH", # flake8-use-pathlib
"ERA", # eradicate
"PD", # pandas-vet
"PGH", # pygrep-hooks
"PL", # pylint
"TRY", # tryceratops
"RUF", # ruff-specific rules
]
ignore = [
"E501", # line too long - let black handle this
"C901", # function too complex
"PLR0911", # too many return statements
"PLR0912", # too many branches
"PLR0913", # too many arguments
"PLR0915", # too many statements
"PLR2004", # magic numbers
"N806", # variable name style
"ERA001", # use of assert
"ARG002", # unused argument
"PLC0206", # extracting value without using .items()
"RET504", # remove unnecessary return statement
"N812", # unused variable
"S101", # use of assert
"TRY003", # raise without context
"T201", # use of assert
"SIM102", # use of assert
]
# Allow unused variables when underscore-prefixed.
dummy-variable-rgx = "^(_+|(_+[a-zA-Z0-9_]*[a-zA-Z0-9]+?))$"
[tool.ruff.lint.per-file-ignores]
"__init__.py" = ["F401"] # unused imports
"tests/**/*.py" = ["S101"] # use of assert
[tool.ruff.lint.mccabe]
max-complexity = 10
[tool.ruff.lint.isort]
known-first-party = ["vita"]
[tool.pdm.dev-dependencies]
dev = [
"pytest>=8.2.2",
"pytest-cov>=5.0.0",
"pytest-mock>=3.14.0",
"pytest-rich>=0.1.1",
"pytest-sugar>=1.0.0",
"pytest-xdist>=3.6.1",
"autoflake>=2.3.1",
"isort>=5.13.2",
"black>=24.4.2",
"jupyterlab>=4.2.2",
"nvitop>=1.3.2",
"gh>=0.0.4",
"sphinx>=7.3.7",
"sphinx-rtd-theme>=2.0.0",
"sphinx-autodoc-typehints>=2.2.1",
"sphinx-material>=0.0.36",
"matplotlib>=3.9.0",
"pdm",
]