forked from pytorch/helion
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpyproject.toml
More file actions
148 lines (134 loc) · 3.92 KB
/
Copy pathpyproject.toml
File metadata and controls
148 lines (134 loc) · 3.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
[build-system]
requires = ["hatchling", "hatch-vcs"]
build-backend = "hatchling.build"
[project]
name = "helion"
authors = [
{ name="Jason Ansel", email="jansel@meta.com" },
]
description = "A Python-embedded DSL that makes it easy to write ML kernels"
readme = "README.md"
dynamic = ["version"]
classifiers = [
"Programming Language :: Python :: 3",
"Operating System :: OS Independent",
]
license = { file = "LICENSE" }
requires-python = ">=3.10"
dependencies = [
"typing_extensions>=4.0.0",
"filecheck",
"psutil",
"rich",
"numpy",
"scikit-learn>=1.3.0",
]
[project.optional-dependencies]
dev = [
"expecttest",
"pytest",
"pytest-timeout",
"pre-commit",
"hypothesis",
"tabulate",
]
# Helion integrates tightly with the cutlass DSL's internal APIs; each
# upstream release tends to break the cute backend. The pin tracked in
# .github/ci_commit_pins/nvidia_cutlass_dsl.txt is the single source of
# truth — keep these extras in sync with that pin, and prefer
# scripts/install_cute.sh in CI/dev environments.
cute = [
"nvidia-cutlass-dsl[cu13]==4.5.2",
"apache-tvm-ffi",
]
pallas-tpu = [
"jax[tpu]",
"absl-py",
]
pallas-cpu = [
"jax",
"absl-py",
]
docs = [
"docutils==0.18.1,<0.21",
"linkify-it-py",
"myst-parser",
"pillow",
"pytorch_sphinx_theme2==0.2.0",
"sphinx==7.2.6",
"sphinx-autobuild",
"sphinx-autodoc-typehints",
"sphinx-design==0.6.1",
"sphinx-gallery==0.14.0",
"sphinx-sitemap==2.7.1",
"sphinxcontrib-mermaid==1.0.0",
"sphinxcontrib.katex==0.9.10",
"sphinxext-opengraph",
"torch"
]
[project.urls]
Homepage = "https://github.com/pytorch/helion"
Issues = "https://github.com/pytorch/helion/issues"
[tool.ruff]
target-version = "py310"
line-length = 88
src = ["helion"]
extend-exclude = ["**/_helion_aot_*.py"]
force-exclude = true
[tool.ruff.format]
docstring-code-format = true
quote-style = "double"
line-ending = "lf"
exclude = [".github/*", "notebooks/**/*.ipynb"]
[tool.ruff.lint]
select = [
"A", "ANN", "B", "C4", "COM", "D419", "E", "ERA001", "EXE", "F", "FA", "FLY", "FURB",
"G", "I", "ISC", "LOG", "NPY", "PERF", "PGH", "PIE", "PLC0131", "PLC0132",
"PLC0205", "PLC0208", "PLC2401", "PLC3002", "PLE", "PLR0133", "PLR0206",
"PLR1722", "PLR1736", "PLW0129", "PLW0131", "PLW0133", "PLW0245", "PLW0406",
"PLW0711", "PLW1501", "PLW1509", "PLW2101", "PLW3301", "PYI", "Q", "RET",
"RSE", "RUF005", "RUF007", "RUF008", "RUF009", "RUF010", "RUF012", "RUF013",
"RUF015", "RUF016", "RUF017", "RUF018", "RUF019", "RUF020", "RUF022", "RUF024",
"RUF026", "RUF030", "RUF034", "RUF036", "RUF037", "RUF041", "RUF047", "RUF051",
"RUF056", "RUF100", "RUF200", "S324", "SIM", "SLOT", "TCH", "TD001", "TD002",
"TD004", "TRY002", "TRY203", "TRY401", "UP", "W", "YTT",
]
ignore = [
"C409", "C419", "COM812", "E501", "ERA001", "FURB189", "G004", "PERF203", "PERF401",
"RET501", "SIM102", "SIM108", "SIM115", "UP035",
]
extend-safe-fixes = ["TC", "UP045", "RUF013", "RSE102"]
preview = true
exclude = ["test/data/*", ".github/*", "notebooks/**/*.ipynb", "_helion_aot_*.py"]
[tool.ruff.lint.per-file-ignores]
"test/*" = ["ANN"]
[tool.ruff.lint.isort]
extra-standard-library = ["typing_extensions"]
known-local-folder = ["helion"]
known-third-party = ["torch"]
required-imports = ["from __future__ import annotations"]
force-single-line = true # better merge conflicts
force-sort-within-sections = true
[tool.hatch.build.targets.wheel]
packages = ["helion"]
[tool.hatch.build]
include = [
"helion/**/*.py",
"helion/**/*.pyi",
"helion/**/*.json",
"LICENSE",
]
exclude = [
"test/**/*",
]
[tool.hatch.metadata]
allow-direct-references = true
[tool.hatch.version]
source = "vcs"
[tool.pyrefly]
project-includes = ["helion", "benchmarks", "docs", "examples"]
project-excludes = ["test", "_helion_aot_*.py"]
python-version = "3.10"
search-path = ["../pytorch"]
[tool.codespell]
ignore-words = "scripts/dictionary.txt"