forked from prob-ml/bliss
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpyproject.toml
More file actions
120 lines (106 loc) · 2.87 KB
/
Copy pathpyproject.toml
File metadata and controls
120 lines (106 loc) · 2.87 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
[project]
authors = [{ name = "Ismael Mendoza", email = "imendoza@umich.edu" }]
description = "Bayesian Light Source Separator"
keywords = ["cosmology", "blending", "weak lensing", "bayesian", "ml", "pytorch"]
name = "bliss"
readme = "README.md"
version = "0.1.1"
requires-python = ">=3.10,<3.13"
dependencies = [
"astropy>=6.0",
"blending-toolkit>=1.0.8",
"einops>=0.6.0",
"surveycodex>=1.2.0",
"matplotlib>=3.7.2",
"numpy>=1.25.2",
"scikit-learn>=1.3.0",
"scipy>=1.11.1",
"torch>=2.0.0",
"tensorboard>=2.16.2",
"typer>=0.15.1",
"sep>=1.4.0",
"pytorch-lightning>=2.2.1",
"jupyter>=1.0.0",
"nbstripout>=0.6.0",
"pytest>=8.0.0",
"tqdm>=4.66.2",
"pre-commit>=3.6.2",
"ruff >= 0.12.0",
]
[tool.setuptools]
packages = ["bliss", "bliss.datasets", "bliss.encoders", "experiment"]
[build-system]
requires = ["setuptools >= 61.0"]
build-backend = "setuptools.build_meta"
[tool.ruff]
fix = true
exclude = [
".bzr",
".direnv",
".eggs",
".git",
".git-rewrite",
".hg",
".ipynb_checkpoints",
".mypy_cache",
".nox",
".pants.d",
".pyenv",
".pytest_cache",
".pytype",
".ruff_cache",
".svn",
".tox",
".venv",
".vscode",
"__pypackages__",
"_build",
"buck-out",
"build",
"dist",
"node_modules",
"site-packages",
"venv",
]
# Same as Black.
line-length = 100
indent-width = 4
# Assume Python 3.12
target-version = "py312"
[tool.ruff.format]
# Like Black, use double quotes for strings.
quote-style = "double"
# Like Black, indent with spaces, rather than tabs.
indent-style = "space"
# Like Black, respect magic trailing commas.
skip-magic-trailing-comma = false
# Like Black, automatically detect the appropriate line ending.
line-ending = "auto"
exclude = ["*.ipynb"]
[tool.ruff.lint]
select = ["E", "F", "I", "W", "B", "SIM", "PLE", "PLC", "PLW", "RUF"]
ignore = [
"C901", # I want to decide what is 'too' complex
"E501", # I don't care about formatting docstrings
"E731", # I like lambda's sometimes
"PLC0206", # too picky, not always useful
"RUF027", # does not account for shell scripts correctly
"RUF052", # I find underscore variables useful
]
preview = true
exclude = ["*.ipynb", "scripts/one_galaxy_shear.py", "scripts/benchmarks/*.py"]
# pyproject.toml
[tool.pytest.ini_options]
addopts = "-ra"
filterwarnings = [
"ignore:.*does not have many workers which may be a bottleneck.*:UserWarning",
"ignore:GPU available but not used.*:UserWarning",
"ignore:numpy.ndarray size changed:RuntimeWarning",
"ignore:.*when logging on epoch level in distributed setting.*",
"ignore:.*Deprecated call to `pkg_resources.declare_namespace.*:DeprecationWarning",
"ignore:.*distutils Version classes are deprecated.*:DeprecationWarning",
"ignore:.*pkg_resources is deprecated as an API.*:DeprecationWarning",
"ignore:.*Calling from_dlpack with a DLPack tensor is deprecated.",
]
minversion = "6.0"
testpaths = ["tests"]