File: pyproject.toml

package info (click to toggle)
colmap 4.0.2-2
  • links: PTS, VCS
  • area: main
  • in suites:
  • size: 15,408 kB
  • sloc: cpp: 142,920; ansic: 17,774; python: 3,613; sh: 428; makefile: 160
file content (90 lines) | stat: -rw-r--r-- 2,764 bytes parent folder | download | duplicates (4)
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
[build-system]
requires = [
    "scikit-build-core>=0.3.3",
    "pybind11==3.0.1",
    "pybind11_stubgen @ git+https://github.com/sarlinpe/pybind11-stubgen@sarlinpe/fix-2025-08-20",
    "numpy",
    "ruff==0.15.0",
    "clang-format==21.1.8",
]
build-backend = "scikit_build_core.build"

[project]
name = "pycolmap"
# WARNING: This version must follow the MAJOR.MINOR.PATCH format. If only
# MAJOR.MINOR is used, cibuildwheel will add a .dev0 patch version, which
# results in releasing a pre-release version on PyPI.
version = "4.0.2"
description = "COLMAP bindings"
readme = "python/README.md"
authors = [
  { name = "Johannes Schönberger", email = "jsch@demuc.de" },
  { name = "Mihai Dusmanu", email = "mihai.dusmanu@gmail.com" },
  { name = "Paul-Edouard Sarlin", email = "paul.edouard.sarlin@gmail.com" },
  { name = "Shaohui Liu", email = "b1ueber2y@gmail.com" },
  { name = "Philipp Lindenberger", email = "plindenbe@ethz.ch" },
]
license = {text = "BSD-3-Clause"}
urls = {Repository = "https://github.com/colmap/colmap"}
requires-python = ">=3.10"
dependencies = ["numpy"]
classifiers = [
  "License :: OSI Approved :: BSD License",
  "Programming Language :: Python :: 3 :: Only",
]

[tool.scikit-build]
wheel.expand-macos-universal-tags = true
cmake.source-dir = "python/"
wheel.packages = ["python/pycolmap"]

[tool.cibuildwheel]
build = "cp3{10,11,12,13,14}-{macosx,manylinux,win}*"
archs = ["auto64"]
test-requires = "pytest>=8.0 mypy==1.19.1 enlighten==1.14.1"
test-command = """\
    python -c "import pycolmap; print(pycolmap.__version__)" && \
    cd {project} && \
    mypy --package pycolmap && \
    mypy --install-types --non-interactive python benchmark && \
    pytest\
"""

[tool.cibuildwheel.linux]
before-all = "{project}/python/ci/install-colmap-almalinux.sh"

[tool.cibuildwheel.macos]
before-all = "{project}/python/ci/install-colmap-macos.sh"

[tool.cibuildwheel.windows]
before-all = "pwsh -File {project}/python/ci/install-colmap-windows.ps1"
before-build = "pip install delvewheel"
test-command = "pwsh -File {project}/python/ci/test-colmap-windows.ps1"

# Skip mypy on source files for Python 3.10. There's a bug in numpy's type
# annotations that was fixed in version 2.3.0, but numpy stopped shipping
# wheels for Python 3.10 in 2.3.0. This causes mypy to fail.
[[tool.cibuildwheel.overrides]]
select = "cp310-{macosx,manylinux}*"
test-command = """\
    python -c "import pycolmap; print(pycolmap.__version__)" && \
    cd {project} && \
    mypy --package pycolmap && \
    pytest\
"""

[tool.pytest.ini_options]
minversion = "8.0"
addopts = ["-ra", "-q"]
testpaths = [
    "python",
    "benchmark",
]
norecursedirs = [
    "build",
    "python/build",
]

[tool.mypy]
implicit_optional = true
ignore_missing_imports = true