-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpyproject.toml
More file actions
79 lines (71 loc) · 1.65 KB
/
pyproject.toml
File metadata and controls
79 lines (71 loc) · 1.65 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
[project]
name = "project-name"
version = "0.1.0"
description = "Default template for PDM package"
authors = [
{name = "Yicheng Luo", email = "ethanluoyc@gmail.com"},
]
dependencies = [
"absl-py>=2.0.0",
# Uncomment this if you use JAX
# "jax[cuda12_pip]>=0.4.23",
]
requires-python = ">=3.10"
readme = "README.md"
license = {text = "MIT"}
[build-system]
requires = ["pdm-backend"]
build-backend = "pdm.backend"
# Uncomment this if use use JAX
# [[tool.pdm.source]]
# name = "jax_cuda"
# url = "https://storage.googleapis.com/jax-releases/jax_cuda_releases.html"
# verify_ssl = true
# type = "find_links"
[tool.pdm.scripts]
test.cmd = "pytest -n auto --maxprocesses 8 --dist loadfile"
# test.env = { JAX_PLATFORM_NAME = "cpu", JAX_DISABLE_MOST_OPTIMIZATIONS = "1" }
lint.shell = "ruff . && black --check ."
fmt.shell = "ruff --fix . && black ."
[tool.pdm.dev-dependencies]
dev = [
"lxm3>=0.4.0",
"ruff>=0.1.11",
"black>=23.12.1",
"pytest>=7.4.4",
"pytest-xdist>=3.5.0",
"pre-commit>=3.6.0",
]
# Ruff configuration
# https://docs.astral.sh/ruff/configuration/
[tool.ruff]
line-length = 120
select = [
"E", # pycodestyle
"F", # pyflakes
"I", # isort
]
ignore = ["E731"]
[tool.ruff.extend-per-file-ignores]
"__init__.py" = ["F401"]
[tool.ruff.isort]
force-single-line = true
force-sort-within-sections = true
single-line-exclusions = ["typing"]
# Black configuration
# https://black.readthedocs.io/en/stable/usage_and_configuration/the_basics.html
[tool.black]
line-length = 88
target-version = ['py310']
include = '\.pyi?$'
exclude = '''
/(
\.eggs
| \.git
| \.github
| \.venv
| docs
| third_party
| scratch
)/
'''