[build-system]
requires = ["setuptools", "wheel"]
build-backend = "setuptools.build_meta"

[project]
name = "splatfactory"
version = "1.0"
description = "General training library for gaussian splatting related projects."
authors = [{ name = "Alexander Veicht" }]
requires-python = ">=3.10,<=3.13"
urls = { Repository = "https://github.com/veichta/SplatFactory" }

# NOTE: can't use dynamic deps from requirements.txt together with static deps (added by poetry).
# Use `pip install -e . --no-deps` if this causes issues.
# dynamic = ["dependencies"]
dependencies = ["torch (>=2.8.0,<3.0.0)", "torchvision (>=0.23.0,<0.24.0)", "opencv-python", "kornia", "matplotlib", "omegaconf", "albumentations", "h5py", "hydra-core", "pandas", "tqdm", "tensorboard", "wandb", "viser", "cuda-toolkit", "ipykernel", "scikit-learn", "numpy (<2)", "pycolmap @ git+https://github.com/rmbrualla/pycolmap", "torchmetrics", "nerfview", "splines", "segment-anything @ git+https://github.com/facebookresearch/segment-anything.git", "open-clip-torch", "einops", "tabulate", "transformers", "sam-2 @ git+https://github.com/facebookresearch/sam2.git", "imageio[ffmpeg] (>=2.37.0,<3.0.0)", "plotly (>=6.4.0,<7.0.0)", "tensordict", "kaleido (>=1.2.0,<2.0.0)", "depth-anything-3 @ git+https://github.com/ByteDance-Seed/Depth-Anything-3.git", "jaxtyping (>=0.3.3,<0.4.0)", "lpips (>=0.1.4,<0.2.0)", "safetensors (>=0.7.0,<0.8.0)", "webdataset (>=1.0.2,<2.0.0)", "pillow-jxl-plugin (>=1.3.7,<2.0.0)", "imagecodecs (==2024.12.30)"]

[project.optional-dependencies]
dev = ["black==23.9.1", "flake8", "isort==5.12.0"]

# pyproject now lives inside the package dir (mirrors GeoCalib's siclib/). Discover subpackages
# relative to it; training is always run from the repo root (e.g. `python -m splatfactory.train`),
# so `import splatfactory` resolves via the repo root on sys.path.
[tool.setuptools.packages.find]
where = ["."]

[tool.black]
line-length = 100
exclude = "(venv/|docs/|third_party/)"

[tool.isort]
profile = "black"
line_length = 100
atomic = true

[tool.flake8]
max-line-length = 100
docstring-convention = "google"
ignore = ["E203", "W503", "E402"]
exclude = [".git", "__pycache__", "venv", "docs", "third_party", "scripts"]
