-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathpyproject.toml
More file actions
183 lines (147 loc) · 5.1 KB
/
pyproject.toml
File metadata and controls
183 lines (147 loc) · 5.1 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
[project] # https://packaging.python.org/en/latest/specifications/pyproject-toml/
name = "stellatscale"
version = "0.0.0"
description = "MVA course project: experimental validation of key claims in _StelLA: Subspace Learning in Low-Rank Adaptation using Stiefel Manifold_, with controlled small-scale experiments."
readme = "README.md"
authors = [
{ name = "Alan Seroul" },
{ name = "Gary Klajer", email = "gary.klajer@outlook.com" },
]
requires-python = ">=3.12,<4.0"
dependencies = [
"expressivity>=0.6.0",
"matplotlib>=3.9.0",
"matplotlib-inline>=0.2.1",
"numpy>=2.4.3",
"peft==0.14.0",
"stella",
"torch>=2.10.0",
"transformers==4.48.0",
]
[tool.uv.sources]
stella = { git = "https://github.com/SonyResearch/stella" }
[build-system] # https://docs.astral.sh/uv/concepts/build-backend/
requires = ["uv_build>=0.9.18,<0.11.0"]
build-backend = "uv_build"
[project.urls] # https://packaging.python.org/en/latest/specifications/well-known-project-urls/#well-known-labels
homepage = "https://github.com/the-tuning-machine/SteLA_Project.git"
source = "https://github.com/the-tuning-machine/SteLA_Project.git"
changelog = "https://github.com/the-tuning-machine/SteLA_Project.git/blob/main/CHANGELOG.md"
releasenotes = "https://github.com/the-tuning-machine/SteLA_Project.git/releases"
documentation = "https://the-tuning-machine.github.io/SteLA_Project.git"
issues = "https://github.com/the-tuning-machine/SteLA_Project.git/issues"
[dependency-groups] # https://docs.astral.sh/uv/concepts/projects/dependencies/#development-dependencies
dev = [
"codespell (>=2.4.1)",
"commitizen (>=4.3.0)",
"coverage[toml] (>=7.6.10)",
"ipykernel (>=6.29.4)",
"ipython (>=8.18.0)",
"ipywidgets (>=8.1.2)",
"mkdocs-material (>=9.5.21)",
"mkdocstrings[python] (>=0.26.2)",
"nbstripout>=0.9.1",
"poethepoet (>=0.32.1)",
"pre-commit (>=4.0.1)",
"pytest (>=8.3.4)",
"pytest-mock (>=3.14.0)",
"pytest-xdist (>=3.6.1)",
"ruff (>=0.9.2)",
"ty (>=0.0.6)",
"typeguard (>=4.4.1)",
]
[tool.codespell] # https://github.com/codespell-project/codespell
builtin = "en-GB_to_en-US,clear,code,rare"
check-filenames = true
skip = "./*_cache/,./.venv,./reports,./*.ipynb,./*.pdf"
[tool.commitizen] # https://commitizen-tools.github.io/commitizen/config/
bump_message = "bump: v$current_version → v$new_version"
tag_format = "v$version"
update_changelog_on_bump = true
version_provider = "uv"
[tool.coverage.report] # https://coverage.readthedocs.io/en/latest/config.html#report
fail_under = 50
precision = 1
show_missing = true
skip_covered = true
[tool.coverage.run] # https://coverage.readthedocs.io/en/latest/config.html#run
branch = true
command_line = "--module pytest"
data_file = "reports/.coverage"
source = ["src"]
[tool.coverage.xml] # https://coverage.readthedocs.io/en/latest/config.html#xml
output = "reports/coverage.xml"
[tool.pytest.ini_options] # https://docs.pytest.org/en/latest/reference/reference.html#ini-options-ref
addopts = "--color=yes --doctest-modules --exitfirst --failed-first --strict-config --strict-markers --verbosity=2 --junitxml=reports/pytest.xml"
filterwarnings = ["error", "ignore::DeprecationWarning"]
testpaths = ["src", "tests"]
xfail_strict = true
[tool.ruff] # https://docs.astral.sh/ruff/settings/
fix = true
line-length = 100
src = ["src", "tests", "scripts"]
target-version = "py312"
[tool.ruff.format]
docstring-code-format = true
skip-magic-trailing-comma = true
[tool.ruff.lint]
select = ["ALL"]
ignore = ["CPY", "FIX", "ARG001", "COM812", "D203", "D213", "E501", "PD008", "PD009", "RET504", "S101", "TD003"]
unfixable = ["ERA001", "F401", "F841", "T201", "T203"]
[tool.ruff.lint.flake8-annotations]
allow-star-arg-any = true
[tool.ruff.lint.flake8-tidy-imports]
ban-relative-imports = "all"
[tool.ruff.lint.isort]
split-on-trailing-comma = false
[tool.ruff.lint.pycodestyle]
max-doc-length = 100
[tool.ruff.lint.pydocstyle]
convention = "numpy"
[tool.ty.environment]
python-platform = "all"
[tool.ty.src]
include = ["src", "tests", "scripts"]
[tool.ty.rules]
unused-ignore-comment = "warn"
[tool.ty.terminal]
error-on-warning = true
[tool.poe.executor] # https://github.com/nat-n/poethepoet
type = "simple"
[tool.poe.tasks]
[tool.poe.tasks.docs]
help = "Build or serve the documentation"
shell = """
if [ $serve ]
then {
mkdocs serve
} else {
mkdocs build
} fi
"""
[[tool.poe.tasks.docs.args]]
help = "Serve the documentation locally with live reload"
type = "boolean"
name = "serve"
options = ["--serve"]
[tool.poe.tasks.lint]
help = "Lint this package"
cmd = """
pre-commit run
--all-files
--color always
"""
[tool.poe.tasks.test]
help = "Test this package"
[[tool.poe.tasks.test.sequence]]
cmd = "coverage run"
[[tool.poe.tasks.test.sequence]]
cmd = "coverage report"
[[tool.poe.tasks.test.sequence]]
cmd = "coverage xml"
[tool.poe.tasks.bench]
help = "Run all benchmarks (efficiency and expressivity)"
[[tool.poe.tasks.bench.sequence]]
cmd = "python -m scripts.bench_efficiency"
[[tool.poe.tasks.bench.sequence]]
cmd = "python -m scripts.bench_expressivity"