-
Notifications
You must be signed in to change notification settings - Fork 50
/
pyproject.toml
147 lines (137 loc) · 5.67 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
[build-system]
requires = ["poetry-core>=1.7.0", "setuptools>=67.7.2"]
build-backend = "poetry.core.masonry.api"
[tool.poetry]
name = "kernel_tuner"
packages = [{ include = "kernel_tuner", from = "." }]
description = "An easy to use CUDA/OpenCL kernel tuner in Python"
version = "1.0" # adhere to PEP440 versioning: https://packaging.python.org/en/latest/guides/distributing-packages-using-setuptools/#id55
license = "Apache-2.0"
authors = [
"Ben van Werkhoven <[email protected]>",
"Alessio Sclocco <[email protected]>",
"Stijn Heldens <[email protected]>",
"Floris-Jan Willemsen <[email protected]>",
"Willem-Jan Palenstijn <[email protected]>",
"Bram Veenboer <[email protected]>",
"Richard Schoonhoven <[email protected]>",
"Leon Oostrum <[email protected]",
]
readme = "README.md"
keywords = [
"auto-tuning",
"gpu",
"computing",
"pycuda",
"cuda",
"pyopencl",
"opencl",
]
classifiers = [
"Environment :: Console",
"Environment :: GPU",
"Development Status :: 5 - Production/Stable",
"Intended Audience :: Developers",
"Intended Audience :: Education",
"Intended Audience :: Science/Research",
"License :: OSI Approved :: Apache Software License",
"Natural Language :: English",
"Operating System :: MacOS :: MacOS X",
"Operating System :: POSIX :: Linux",
"Topic :: Scientific/Engineering",
"Topic :: Software Development",
"Topic :: System :: Distributed Computing",
]
include = [
{ path = "test" },
] # this ensures that people won't have to clone the whole repo to include notebooks, they can just do `pip install kernel_tuner[tutorial,cuda]`
homepage = "https://KernelTuner.github.io/kernel_tuner/"
documentation = "https://KernelTuner.github.io/kernel_tuner/"
repository = "https://github.com/KernelTuner/kernel_tuner"
[tool.poetry.urls]
"Tracker" = "https://github.com/KernelTuner/kernel_tuner/issues"
[tool.poetry.build]
generate-setup-file = false
# ATTENTION: if anything is changed here, run `poetry update`
[tool.poetry.dependencies]
python = ">=3.9,<3.13" # NOTE when changing the supported Python versions, also change the test versions in the noxfile
numpy = "^1.26.0" # Python 3.12 requires numpy at least 1.26
scipy = ">=1.11.0"
packaging = "*" # required by file_utils
jsonschema = "*"
python-constraint2 = "^2.0.0b5"
xmltodict = "*"
pandas = ">=2.0.0"
scikit-learn = ">=1.0.2"
# Torch can be used with Kernel Tuner, but is not a dependency, should be up to the user to use it
# List of optional dependencies for user installation, e.g. `pip install kernel_tuner[cuda]`, used in the below `extras`.
# Please note that this is different from the dependency groups below, e.g. `docs` and `test`, those are for development.
# CUDA
pycuda = { version = "^2024.1", optional = true } # Attention: if pycuda is changed here, also change `session.install("pycuda")` in the Noxfile
nvidia-ml-py = { version = "^12.535.108", optional = true }
pynvml = { version = "^11.4.1", optional = true }
# cupy-cuda11x = { version = "*", optional = true } # Note: these are completely optional dependencies as described in CONTRIBUTING.rst
# cupy-cuda12x = { version = "*", optional = true }
# cuda-python = { version = "*", optional = true }
# OpenCL
pyopencl = { version = "*", optional = true } # Attention: if pyopencl is changed here, also change `session.install("pyopencl")` in the Noxfile
# HIP
pyhip-interface = { version = "*", optional = true }
# Tutorial (for the notebooks used in the examples)
jupyter = { version = "^1.0.0", optional = true }
matplotlib = { version = "^3.5.0", optional = true }
[tool.poetry.extras]
cuda = ["pycuda", "nvidia-ml-py", "pynvml"]
opencl = ["pyopencl"]
cuda_opencl = ["pycuda", "pyopencl"]
hip = ["pyhip-interface"]
tutorial = ["jupyter", "matplotlib", "nvidia-ml-py"]
# ATTENTION: if anything is changed here, run `poetry update` and `poetry export --with docs --without-hashes --format=requirements.txt --output doc/requirements.txt`
# Please note that there is overlap with the `dev` group
[tool.poetry.group.docs]
optional = true
[tool.poetry.group.docs.dependencies]
sphinx = "^7.3.7"
sphinx_rtd_theme = "^2.0.0"
sphinx-pyproject = "^0.3"
nbsphinx = "^0.9"
ipython = "*"
pytest = "^8.2.0" # TODO why do we need pytest here?
markupsafe = "^2.0.1" # TODO why do we need markupsafe here?
# sphinx-autodoc-typehints = "^1.24.0"
# ATTENTION: if anything is changed here, run `poetry update`
# Please also run `poetry export -f requirements.txt --output doc/requirements_test.txt --with test`
[tool.poetry.group.test]
optional = true
[tool.poetry.group.test.dependencies]
pytest = "^8.2.0"
pytest-cov = "^5.0.0"
mock = "^5.1.0"
nox = "^2024.4.15"
nox-poetry = "^1.0.3"
ruff = "^0.4.4"
pep440 = "^0.1.2"
tomli = "^2.0.1" # held back by Python <= 3.10, can be replaced by built-in [tomllib](https://docs.python.org/3.11/library/tomllib.html) from Python 3.11 onwards
# development dependencies are unused for now, as this is already covered by test and docs
# # ATTENTION: if anything is changed here, run `poetry update`
# [tool.poetry.group.dev.dependencies]
[tool.pytest.ini_options]
minversion = "7.4"
pythonpath = [
"kernel_tuner",
] # necessary to get coverage reports without installing with `-e`
addopts = "--cov --cov-config=.coveragerc --cov-report=html --cov-report=term-missing --cov-fail-under=60"
testpaths = ["test"]
[tool.black]
line-length = 120
[tool.ruff]
line-length = 120
respect-gitignore = true
exclude = ["doc", "examples"]
select = [
"E", # pycodestyle
"F", # pyflakes,
"D", # pydocstyle,
]
[tool.ruff.pydocstyle]
convention = "google"