forked from lvyufeng/einops
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpyproject.toml
108 lines (87 loc) · 2.63 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
[build-system]
requires = ["hatchling>=1.10.0"]
build-backend = "hatchling.build"
[project]
name = "einops"
description = "A new flavour of deep learning operations"
readme = "README.md"
requires-python = ">=3.8"
keywords = [
'deep learning',
'neural networks',
'tensor manipulation',
'machine learning',
'scientific computations',
'einops',
]
license = { text = 'MIT' }
classifiers = [
'Intended Audience :: Science/Research',
'Programming Language :: Python :: 3',
'License :: OSI Approved :: MIT License',
]
dependencies = [
# no run-time or installation-time dependencies
]
dynamic = ["version"]
authors = [{ name = 'Alex Rogozhnikov' }]
[project.urls]
Homepage = 'https://github.com/arogozhnikov/einops'
[tool.setuptools]
packages = ['einops', 'einops.layers']
[tool.hatch.version]
path = "einops/__init__.py"
[tool.hatch.build.targets.sdist]
exclude = [
"/.github",
"/.idea",
"/.pytest_cache",
"/build",
"/dist",
"/docs",
"/docs_src",
"/log",
]
[tool.hatch.build.targets.wheel]
# should use packages from main section
[tool.hatch.envs.docs]
dependencies = [
"mkdocs~=1.4.0",
"mkdocs-material~=8.5.5",
"mkdocstrings[python-legacy]~=0.19.0",
"mkdocs-jupyter~=0.22.0",
# required by codehilite (highlithing in mkdocs)
"pygments~=2.13.0",
]
[tool.hatch.envs.docs.scripts]
# For examples to build one has to run:
# hatch run docs:build
convert = "python scripts/convert_readme.py"
build = "convert && mkdocs build --clean --strict {args}"
serve = "convert && mkdocs serve --dev-addr localhost:8000 {args}"
deploy = "convert && mkdocs build --clean --strict && mkdocs gh-deploy"
[tool.hatch.envs.pypi.scripts]
# hatch run pypi:deploy_test
deploy_test = "hatch build --clean && hatch publish -r test"
deploy = "hatch build --clean && hatch publish"
[tool.hatch.envs.testing.scripts]
# hatch run testing:test
test = "python test.py"
[tool.pytest.ini_options]
# suppressing irrelevant warnings from google's tensorflow and pb2 on m1 mac
# should be removed in 2023
filterwarnings = [
"ignore:Call to deprecated create function FieldDescriptor",
"ignore:Call to deprecated create function Descriptor",
"ignore:Call to deprecated create function EnumDescriptor",
"ignore:Call to deprecated create function EnumValueDescriptor",
"ignore:Call to deprecated create function FileDescriptor",
"ignore:Call to deprecated create function OneofDescriptor",
]
[tool.ruff]
line-length = 120
target-version = 'py311'
cache-dir = "/tmp/ruff_cache" # move cache out of workdir
lint.select = ["E4", "E7", "E9", "F", "W"]
[tool.ruff.format]
docstring-code-format = false