-
-
Notifications
You must be signed in to change notification settings - Fork 6
Expand file tree
/
Copy pathpyproject.toml
More file actions
198 lines (175 loc) · 4.92 KB
/
Copy pathpyproject.toml
File metadata and controls
198 lines (175 loc) · 4.92 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
[build-system]
requires = ["hatchling", "hatch-vcs"]
build-backend = "hatchling.build"
[project]
name = "pySPFM"
description = "Sparse hemodynamic deconvolution of fMRI data with scikit-learn compatible estimators."
readme = "README.md"
authors = [{name = "Eneko Uruñuela"}]
classifiers = [
"Development Status :: 4 - Beta",
"Intended Audience :: Science/Research",
"Topic :: Scientific/Engineering :: Information Analysis",
"Topic :: Scientific/Engineering :: Medical Science Apps.",
"License :: OSI Approved :: GNU Library or Lesser General Public License (LGPL)",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
]
license = {file = "LICENSE"}
requires-python = ">=3.10"
keywords = [
"fmri",
"deconvolution",
"hemodynamic",
"neuroimaging",
"sparse",
"paradigm-free-mapping",
]
dependencies = [
"dask",
"dask_jobqueue",
"distributed",
# Pinned: unconstrained, jax/jaxlib resolved to an incompatible pair in the
# lockfile (import failed) and to different versions per Python (jaxlib 0.6.2
# on 3.10 vs 0.10.2 on 3.11/3.12). Newer jaxlib also shifts FISTA float32
# output past the atol=1e-6 reference tests. 0.6.2 matches the references and
# supports 3.10-3.12; bump together with regenerated references (see #154).
"jax==0.6.2",
"jaxlib==0.6.2",
"nibabel",
"nilearn>=0.10.0",
"numpy>=1.22",
"pylops>=1.18.2",
"pyproximal>=0.4.0",
"pywavelets",
"scipy>=1.9.0",
]
dynamic = ["version"]
[project.urls]
Homepage = "https://github.com/Paradigm-Free-Mapping/pySPFM"
Documentation = "https://pySPFM.readthedocs.io"
Repository = "https://github.com/Paradigm-Free-Mapping/pySPFM"
Changelog = "https://github.com/Paradigm-Free-Mapping/pySPFM/blob/main/CHANGELOG.md"
[project.optional-dependencies]
dev = ["pre-commit"]
doc = [
"ipykernel",
"matplotlib",
"myst_nb",
"sphinx",
"sphinx_copybutton",
"sphinx_rtd_theme>=1.2.2",
"sphinx-argparse",
"sphinxcontrib-bibtex",
"sphinx_design",
"sphinx_gallery",
"sphinx-book-theme",
"sphinxcontrib-jquery",
]
tests = [
"codecov",
"coverage",
"pytest",
"pytest-cov>=4.0.0",
"pytest-console-scripts",
"requests",
"ruff>=0.4.0",
]
# Aliases
all = ["pySPFM[dev,doc,tests]"]
[project.scripts]
# Main CLI command with subcommands (sparse, lowrank, stability)
pySPFM = "pySPFM.cli.run:main"
# AUC to estimates workflow
auc_to_estimates = "pySPFM.cli.auc_to_estimates:_main"
#
# Hatch configurations
#
[tool.hatch.metadata]
allow-direct-references = true
[tool.hatch.build.targets.sdist]
exclude = [".git_archival.txt"] # No longer needed in sdist
[tool.hatch.build.targets.wheel]
exclude = [
"pySPFM/tests/data", # Large test data directory
]
## The following two sections configure setuptools_scm in the hatch way
[tool.hatch.version]
source = "vcs"
[tool.hatch.build.hooks.vcs]
version-file = "pySPFM/_version.py"
#
# Developer tool configurations
#
[tool.ruff]
line-length = 99
target-version = "py310"
exclude = [
".eggs",
".git",
".github",
".hg",
".pytest_cache",
".testing_data_cache",
"_build",
"build",
"dist",
"pySPFM/_version.py",
]
[tool.ruff.lint]
select = [
"E", # pycodestyle errors
"W", # pycodestyle warnings
"F", # Pyflakes
"I", # isort
"N", # pep8-naming
"D", # pydocstyle
"UP", # pyupgrade
"B", # flake8-bugbear
"C4", # flake8-comprehensions
"SIM", # flake8-simplify
]
ignore = [
"E203", # whitespace before ':'
"E402", # module level import not at top of file
"N802", # function name should be lowercase
"N803", # argument name should be lowercase (X is standard in sklearn)
"N806", # variable in function should be lowercase
"N999", # invalid module name (pySPFM is intentional)
"D100", # missing docstring in public module
"D104", # missing docstring in public package
"D401", # first line should be in imperative mood
"D403", # first word of first line should be capitalized
"B006", # mutable default argument (used intentionally in some cases)
"SIM102", # nested if statements (sometimes clearer)
"SIM108", # ternary operator (sometimes less readable)
]
[tool.ruff.lint.per-file-ignores]
"*/__init__.py" = ["F401"]
"pySPFM/tests/*" = ["D"]
"pySPFM/due.py" = ["D", "E", "W"]
[tool.ruff.lint.pydocstyle]
convention = "numpy"
[tool.ruff.lint.isort]
known-first-party = ["pySPFM"]
[tool.pydocstringformatter]
write = true
strip-whitespaces = true
max-summary-lines = 1
[tool.coverage.run]
branch = true
omit = [
"pySPFM/tests/*",
"*/__init__.py",
"pySPFM/_version.py",
"pySPFM/due.py",
]
[tool.coverage.report]
# Regexes for lines to exclude from consideration
exclude_lines = [
'raise NotImplementedError',
'warnings\.warn',
]
[tool.pytest]
log_cli = true