-
Notifications
You must be signed in to change notification settings - Fork 894
Expand file tree
/
Copy pathpyproject.toml
More file actions
107 lines (91 loc) · 2.84 KB
/
pyproject.toml
File metadata and controls
107 lines (91 loc) · 2.84 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
[build-system]
requires = ["scikit-build-core>=0.8.0", "pybind11>=2.10.0"]
build-backend = "scikit_build_core.build"
[project]
name = "opensfm"
version = "0.5.2"
description = "A Structure from Motion library"
readme = "README.md"
requires-python = ">=3.8"
license = {text = "BSD"}
authors = [
{name = "Mapillary"},
]
dependencies = [
"cloudpickle>=0.4.0",
"exifread>=2.1.2",
"flask>=2.3.2",
"fpdf2>=2.4.6",
"joblib>=1.0.0",
"matplotlib",
"networkx>=2.5",
"numpy>=1.19",
"Pillow>=8.1.1",
"pyproj>=1.9.5.1",
"python-dateutil>=2.7",
"pyyaml>=5.4",
"scipy>=1.10.0",
"xmltodict>=0.10.2",
"opencv-python>=4.8.0",
]
[project.optional-dependencies]
dev = [
"pytest>=7.0.0",
"wheel",
]
docs = [
"Sphinx>=4.2.0",
"sphinx_rtd_theme>=1.0.0",
]
test = [
"pytest>=7.0.0",
]
# Note: The original bin/opensfm and bin/opensfm_run_all are bash scripts
# For Phase 1, we'll install them as scripts using scikit-build's script handling
# TODO Phase 2: Create proper Python entry points by moving bin/opensfm_main.py
# into the opensfm package (e.g., opensfm/__main__.py or opensfm/cli.py)
# [project.scripts]
# opensfm = "opensfm.cli:main"
# opensfm_run_all = "opensfm.cli:run_all"
[project.urls]
Homepage = "https://github.com/mapillary/OpenSfM"
Documentation = "https://docs.opensfm.org/"
[tool.scikit-build]
# CMake source directory containing CMakeLists.txt
cmake.source-dir = "opensfm/src"
cmake.build-type = "Release"
# Use a fixed build directory (useful for running C++ tests)
build-dir = "cmake_build"
# Minimum CMake version
cmake.version = ">=3.15"
# Specify where to install the Python package
wheel.install-dir = "opensfm"
# Package discovery - automatically find Python packages
wheel.packages = ["opensfm"]
# Package data (JSON, YAML, NPZ files in opensfm/data/) is automatically
# included because it's inside the opensfm package directory
# CMake only installs compiled .so files; Python packaging handles the rest
# Note: Script installation
# The bin/opensfm and bin/opensfm_run_all bash scripts need to be installed
# This will be handled via CMake install() commands or Python entry points
# Include files in the sdist (source distribution)
sdist.include = [
"opensfm/data/**", # sensor_data.json, camera_calibration.yaml, bow/*.npz
"opensfm/src/**", # CMake source files
"bin/**", # All utility scripts
]
# Exclude unnecessary files from sdist
sdist.exclude = [
".git/**",
".github/**",
"cmake_build/**",
"**/__pycache__/**",
"**/*.pyc",
]
# CMake configuration options
[tool.scikit-build.cmake.define]
# Build C++ tests (enabled for Docker/CI environments)
OPENSFM_BUILD_TESTS = "ON"
# Ensure we're using the correct Python executable
# This will be automatically set by scikit-build-core
# PYTHON_EXECUTABLE will be set automatically