-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpyproject.toml
114 lines (106 loc) · 3.22 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
[build-system]
requires = ["setuptools>=61.0"]
build-backend = "setuptools.build_meta"
[project]
name = "scrstudio"
version = "0.0.0"
description = "A Unified Framework for Scene Coordinate Regression"
readme = "README.md"
license = { text="Apache 2.0"}
requires-python = ">=3.8.0"
classifiers = [
"Programming Language :: Python",
]
dependencies = [
"torch<2.6",
"torchvision",
"tyro",
"jaxtyping",
"PyYAML",
"tensorboard",
"opencv-python",
"lmdb",
"scikit-learn",
"matplotlib",
"blosc2",
"kornia",
"pandas",
"ruff",
"nanopq",
"colorama",
"kapture",
"gdown",
"imagesize",
"scikit-image",
"poselib",
"torch_geometric",
"hloc@git+https://github.com/cvg/Hierarchical-Localization",
]
[project.optional-dependencies]
dev = [
"pytest",
"cuml-cu12==25.2.*",
"ruff",
]
[project.scripts]
# Note, add entrypoint name to nerfstudio/scripts/completions/install.py to include CLI completion
scr-install-cli = "scrstudio.scripts.completions.install:entrypoint"
scr-download-data = "scrstudio.scripts.downloads.download_data:entrypoint"
scr-train = "scrstudio.scripts.train:entrypoint"
scr-eval = "scrstudio.scripts.eval:entrypoint"
scr-overlap-score = "scrstudio.scripts.overlap_score:entrypoint"
scr-encoding-pca = "scrstudio.scripts.encoding_pca:entrypoint"
scr-retrieval-feat = "scrstudio.scripts.retrieval_feat:entrypoint"
[tool.setuptools.packages.find]
include = ["scrstudio*"]
[tool.pytest.ini_options]
testpaths = [
"tests",
]
[tool.pyright]
include = ["scrstudio"]
exclude = ["**/node_modules",
"**/__pycache__",
]
defineConstant = { DEBUG = true }
reportMissingImports = "warning"
reportMissingTypeStubs = false
reportPrivateImportUsage = false
reportIncompatibleVariableOverride = false
reportIncompatibleMethodOverride = false
pythonVersion = "3.11"
pythonPlatform = "Linux"
[tool.ruff]
line-length = 120
respect-gitignore = false
lint.select = [
"E", # pycodestyle errors.
"F", # Pyflakes rules.
"I", # isort formatting.
"PLC", # Pylint convention warnings.
"PLE", # Pylint errors.
"PLR", # Pylint refactor recommendations.
"PLW", # Pylint warnings.
"NPY201" # NumPY 2.0 migration https://numpy.org/devdocs/numpy_2_0_migration_guide.html#ruff-plugin
]
lint.ignore = [
"E501", # Line too long.
"F722", # Forward annotation false positive from jaxtyping. Should be caught by pyright.
"F821", # Forward annotation false positive from jaxtyping. Should be caught by pyright.
"PLR2004", # Magic value used in comparison.
"PLR0915", # Too many statements.
"PLR0913", # Too many arguments.
"PLC0414", # Import alias does not rename variable. (this is used for exporting names)
"PLC1901", # Use falsey strings.
"PLR5501", # Use `elif` instead of `else if`.
"PLR0911", # Too many return statements.
"PLR0912", # Too many branches.
"PLW0603", # Globa statement updates are discouraged.
"PLW2901", # For loop variable overwritten.
"PLR1730", # Replace if statement with min/max
"PLC0206", # Extracting value from dictionary without calling `.items()`
]
[tool.ruff.lint.isort]
combine-as-imports = true
known-first-party = ["scrstudio"]
split-on-trailing-comma = false