-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpyproject.toml
More file actions
160 lines (145 loc) · 4.08 KB
/
Copy pathpyproject.toml
File metadata and controls
160 lines (145 loc) · 4.08 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
[project]
name = "edge_tta"
version = "0.0.1"
description = "A system level benchmark of online test-time adaptation methods from the literature on resource-constrained hardware."
readme = "README.md"
requires-python = ">=3.10,<3.13"
license = {text = "Apache-2.0"}
authors = [
{name = "Mateusz Piechocki", email = "mateusz.piechocki@put.poznan.pl"},
]
keywords = ["python", "test-time adaptation", "online learning", "resource-constrained hardware"]
classifiers = [
"License :: OSI Approved :: Apache Software License",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
]
dependencies = [
"click",
"numpy",
"opencv-contrib-python",
"pandas",
"pvlib",
"tqdm",
"scikit-learn",
"psutil", # For performance monitoring (CPU/memory tracking)
]
[project.optional-dependencies]
test = [
"pytest",
"ruff",
"pre-commit",
]
dev = [
"edge_tta[test]",
# --------- pytorch --------- #
"torch==2.8.0",
"torchvision==0.23.0",
"lightning==2.5.3",
"torchmetrics==1.8.1",
"timm==1.0.19",
"torchinfo==1.8.0",
# --------- loggers --------- #
"neptune",
# --------- dvc --------- #
"dvc",
# --------- performance monitoring --------- #
"emt",
"nvidia-ml-py",
# --------- misc --------- #
"cma",
"python-dotenv",
"matplotlib",
"ptflops",
"pyRAPL",
"nvidia-ml-py",
"pymongo",
# --------- Discrete Wavelet Transform for L-TTA --------- #
"PyWavelets",
"pytorch-wavelets",
]
[project.urls]
Repository = "https://github.com/MatPiech/edge-tta"
[build-system]
requires = ["setuptools>=61.0", "wheel"]
build-backend = "setuptools.build_meta"
[tool.setuptools.packages.find]
where = ["."]
include = ["edge_tta*"]
exclude = ["tests*", "scripts*", "notebooks*"]
# Pytest configuration
[tool.pytest.ini_options]
minversion = "7.0"
addopts = [
"--strict-markers",
"--strict-config",
"--cov=src",
"--cov-report=term-missing",
"--cov-report=html",
"--cov-report=xml",
]
testpaths = ["tests"]
python_files = ["test_*.py", "*_test.py"]
python_classes = ["Test*"]
python_functions = ["test_*"]
markers = [
"slow: marks tests as slow (deselect with '-m \"not slow\"')",
"integration: marks tests as integration tests",
"unit: marks tests as unit tests",
]
# Ruff configuration
[tool.ruff]
target-version = "py312"
line-length = 127
indent-width = 4
exclude = [
"notebooks/*",
]
[tool.ruff.lint]
# Enable Pyflakes (`F`) and a subset of the pycodestyle (`E`) codes by default.
select = [
"E4", # pycodestyle errors
"E7",
"E9",
"F", # Pyflakes
"W", # pycodestyle warnings
"I", # isort
"N", # pep8-naming
"UP", # pyupgrade
"B", # flake8-bugbear
"A", # flake8-builtins
"C4", # flake8-comprehensions
"T20", # flake8-print
"SIM", # flake8-simplify
"ARG", # flake8-unused-arguments
"PTH", # flake8-use-pathlib
"RUF", # Ruff-specific rules
]
ignore = [
"E501", # Line too long (handled by formatter)
"B008", # Do not perform function calls in argument defaults
"B904", # Allow `raise` without `from` inside `except`
"ARG002", # Allow unused arguments in function definitions
"T201", # Allow print statements
"N812", # Lowercase imported as non-lowercase
"C419", # Allow unnecessary list comprehension
]
# Allow fix for all enabled rules (when `--fix`) is provided.
fixable = ["ALL"]
unfixable = []
[tool.ruff.format]
# Like Black, use double quotes for strings.
quote-style = "double"
# Like Black, indent with spaces, rather than tabs.
indent-style = "space"
# Like Black, respect magic trailing commas.
skip-magic-trailing-comma = false
# Like Black, automatically detect the appropriate line ending.
line-ending = "auto"
[tool.ruff.lint.per-file-ignores]
"tests/**/*" = ["T20", "ARG", "SIM"] # Allow prints and unused args in tests
[tool.ruff.lint.isort]
known-first-party = ["edge_tta"]
force-sort-within-sections = true