Repository navigation
Conversation
sarlinpe
force-pushed
the
refresh/7-code-quality-typing-tests
branch
from
November 22, 2026 14:05
0a38355 to
76808dd
Compare
sarlinpe
force-pushed
the
refresh/7-code-quality-typing-tests
branch
from
November 22, 2026 14:17
76808dd to
46aa1c2
Compare
sarlinpe
force-pushed
the
refresh/7-code-quality-typing-tests
branch
from
November 22, 2026 14:27
46aa1c2 to
4136abd
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Stacked on #522 (
refresh/6-slim-localizer) in Stack #525. Modernizes code quality tooling, adds full Python 3.10+ type annotations acrosshloc, and introduces a fast hermetic unit + Sacre Coeur end-to-end test suite.What changed
py.typed:hloc/(0 untyped defs remaining), including@overloadsignatures forget_keypoints,parse_image_lists, andparse_relocalization, plusconfs: dict[str, dict[str, Any]]inextract_features.py,match_features.py, andmatch_dense.py.hloc/py.typedand[tool.setuptools.package-data]so downstream typed consumers receive package types..flake8and.isort.cfgwith[tool.ruff](E, F, UP, B, SIM, I),[tool.mypy](disallow_untyped_defs = true), and[tool.pytest.ini_options]inpyproject.toml, plus[project.optional-dependencies] dev..github/workflows/code-quality.ymlwithlint(ruff check,ruff format --check,mypy hloc tests) andtest(CPU PyTorch +pytest -v) jobs.isinstance(ref_list, Iterable)inhloc/pairs_from_exhaustive.py,matplotlib.colormaps["jet"]inhloc/visualization.py, mutable default arguments inmatch_dense.py/visualization.py/4Seasons/utils.py, andassign_matches/get_unique_matchesinhloc/match_dense.py.tests/):tests/test_parsers_and_io.py: parsers, HDF5 IO round-trip, reversed matches, pose formatting.tests/test_pairing.py:pairs_from_exhaustive,pairs_from_covisibility,pairs_from_poses,pairs_from_retrieval.tests/test_colmap_from_nvm.py: NVM conversion (unnormalized quaternions, camera center recovery), RobotCar NVM, Cambridge & 7Scenes model/depth helpers (auto-discovering both.binand.txt).tests/test_triangulation_and_localization.py:parse_option_args, synthetic multi-viewtriangulation.main(skip_geometric_verificationTrue/False) +localize_sfm(covisibility_clusteringTrue/False, error cases) +localize_inloc.tests/test_extractors_and_sacre_coeur_e2e.py: DoG blank-image & NN matcher unit test + full end-to-end SfM -> guided-GV triangulation -> query localization on the bundled 10-imagedatasets/sacre_coeur/mapping/dataset (no external weight downloads).Verification
ruff check hloc tests *.ipynb: passedruff format --check hloc tests *.ipynb: 65 files formattedmypy hloc tests(both with.venvdeps and--no-site-packages): 0 issues in 53 filespytest -v: 16 passed in ~11s on CPUhloc/py.typedis packaged inhloc-1.5-py3-none-any.whlStack (#525)
pyproject.toml, remove submodules, vendor SuperGlueread_write_model.pyand rawsqlite3pycolmaplocalize_sfmandlocalize_inlocruff/mypyCI, andpytestsuite