SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2007.13867 · 2020

Robust Image Retrieval-based Visual Localization using Kapture

arXiv · PDF · Open in the Atlas

Code that ran

4 of 5 samples (functions and classes) lifted from this paper's linked repositories executed on a synthesized input in Syntology's jail (0 of them constructed an object rather than computing a result; 0 honoured the contract we drafted, 0 violated it and 4 have no contract verdict; 0 failures of our instrument; 1 no recorded run), measured 2026-11-21; repository links from the Papers with Code archive attributed under CC BY-SA, no affiliation; bodies inline only under a permissive licence as GitHub detects it. Not a reproduction of the paper's results.

"Ran" means the function executed on a synthesized input and returned a value. It is not a reproduction of the paper's results. This record, dated, as JSON: /api/ran/2007.13867.json · badge: /api/ran/2007.13867.svg

Each repository's role is a label: a classifier's output recorded on the link, or, where no role is recorded, what the Papers with Code archive marked. The line under it names its basis. Neither says who wrote the code.

RepositoryRoleRan
naver/kapture-localization canonical (classifier label)
classifier basis: census
4 ran · 0 no recorded run
naver/kapture canonical (classifier label)
classifier basis: classifier_2025
0 ran · 1 no recorded run
FunctionStatusWhere it lives
get_position_diff Ran
ran on a synthesized input
naver/kapture-localization/kapture_localization/pairing/distance.py
code served (permissive licence) · get_code("7efada4e4a38d8b9")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned ndarray, ndim 2, dtype family float, shape (2, 3) as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import numpy as np

class Pose:
    def __init__(self, t_raw):
        self.t_raw = t_raw

class Image:
    def __init__(self, data, pose):
        self.data = data
        self.pose = pose

# Create query images with poses
query_pose_1 = Pose(np.array([1.0, 2.0, 3.0], dtype=np.float32))
query_pose_2 = Pose(np.array([4.0, 5.0, 6.0], dtype=np.float32))

query_img_1 = (np.zeros((3, 64, 64)), query_pose_1)
query_img_2 = (np.zeros((3, 64, 64)), query_pose_2)

imgs_query = [query_img_1, query_img_2]

# Create map images with poses
map_pose_1 = Pose(np.array([0.0, 0.0, 0.0], dtype=np.float32))
map_pose_2 = Pose(np.array([2.0, 3.0, 4.0], dtype=np.float32))
map_pose_3 = Pose(np.array([5.0, 6.0, 7.0], dtype=np.float32))

map_img_1 = (np.zeros((3, 64, 64)), map_pose_1)
map_img_2 = (np.zeros((3, 64, 64)), map_pose_2)
map_img_3 = (np.zeros((3, 64, 64)), map_pose_3)

imgs_map = [map_img_1, map_img_2, map_img_3]

ARGS = {
    "imgs_query": imgs_query,
    "imgs_map": imgs_map
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type ndarray, ndim 2, dtype family float, shape (2, 3) — shape (2, 3) as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
get_similarity Ran
ran on a synthesized input
naver/kapture-localization/kapture_localization/image_retrieval/pairing.py
code served (permissive licence) · get_code("8991644fb922c76b")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned dict. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import numpy as np
from typing import List, Tuple, Union, Dict, Optional

class StackedGlobalFeatures:

    def __init__(self, stacked_features_index: np.ndarray, stacked_features: np.ndarray) -> None:
        self.index = stacked_features_index
        self.stacked_features = stacked_features

# Create query features with 2 queries and 4-dimensional features
query_index = np.array(['query_0', 'query_1'])
query_stacked_features = np.array([
    [1.0, 2.0, 3.0, 4.0],
    [2.0, 3.0, 4.0, 5.0]
], dtype=np.float32)
query_features = StackedGlobalFeatures(query_index, query_stacked_features)

# Create map features with 3 maps and 4-dimensional features
map_index = np.array(['map_0', 'map_1', 'map_2'])
map_stacked_features = np.array([
    [1.5, 2.5, 3.5, 4.5],
    [2.5, 3.5, 4.5, 5.5],
    [0.5, 1.5, 2.5, 3.5]
], dtype=np.float32)
map_features = StackedGlobalFeatures(map_index, map_stacked_features)

ARGS = {
    'query_features': query_features,
    'map_features': map_features
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type dict — a dict output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a dict output the recorded ndim 0 and dtype family float describe that coercion, not the output, and are not stated
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
get_similarity_matrix Ran
ran on a synthesized input
naver/kapture-localization/kapture_localization/image_retrieval/pairing.py
code served (permissive licence) · get_code("fc768ea8fb5f195d")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned ndarray, ndim 2, dtype family float, shape (2, 3) as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import numpy as np

class StackedGlobalFeatures:
    def __init__(self, stacked_features_index: np.ndarray, stacked_features: np.ndarray) -> None:
        self.index = stacked_features_index
        self.stacked_features = stacked_features

# Create query features
query_index = np.array([0, 1])
query_stacked = np.array([[1.0, 2.0, 3.0, 4.0],
                          [5.0, 6.0, 7.0, 8.0]])
query_features = StackedGlobalFeatures(query_index, query_stacked)

# Create map features
map_index = np.array([0, 1, 2])
map_stacked = np.array([[1.0, 0.0, 0.0, 0.0],
                        [0.0, 1.0, 0.0, 0.0],
                        [0.5, 0.5, 0.0, 0.0]])
map_features = StackedGlobalFeatures(map_index, map_stacked)

ARGS = {
    "query_features": query_features,
    "map_features": map_features
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type ndarray, ndim 2, dtype family float, shape (2, 3) — shape (2, 3) as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
round_robin_from_similarity_dicts Ran
ran on a synthesized input
naver/kapture-localization/kapture_localization/image_retrieval/fusion.py
code served (permissive licence) · get_code("ce50f292cc2c610a")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned list, ndim 2, dtype family float; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch
import numpy as np
from typing import List, Optional, Dict, Tuple

# Construct similarity_dicts
# Each dict maps query names to lists of (image_name, similarity_score) tuples
similarity_dict_1 = {
    "query_a": [
        ("image_1", 0.95),
        ("image_2", 0.87),
        ("image_3", 0.76),
    ],
    "query_b": [
        ("image_4", 0.92),
        ("image_5", 0.81),
    ],
}

similarity_dict_2 = {
    "query_a": [
        ("image_2", 0.88),
        ("image_6", 0.79),
        ("image_1", 0.72),
    ],
    "query_b": [
        ("image_5", 0.85),
        ("image_7", 0.78),
    ],
}

similarity_dict_3 = {
    "query_a": [
        ("image_8", 0.90),
        ("image_1", 0.83),
    ],
    "query_c": [
        ("image_9", 0.91),
        ("image_10", 0.80),
    ],
}

similarity_dicts = [similarity_dict_1, similarity_dict_2, similarity_dict_3]

ARGS = {
    "similarity_dicts": similarity_dicts,
    "topk": 5,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type list, ndim 2, dtype family float — a list output has no array shape of its own; none is stated
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
ask_confirmation Not yet run
unverified (harvested, no recorded run)
naver/kapture/tools/kapture_download_dataset.py
code served (permissive licence) · get_code("17a28c4e8fd74928")
How it ran

no invocation recorded.

Also present in other papers' code

Of 5 samples lifted from this paper's linked repositories, 5 carry a function identity and 0 do not. Of the 5 distinct functions with an identity, 0 are also present in other papers whose code we hold (0 with at least one paper dated earlier, 0 the same month, 0 later) and 5 are only here among the 52,977 papers whose code Syntology holds (as of 2026-09-26).

Only here means: among the 52,977 papers whose code Syntology holds (51,887 with lifted samples, 1,090 through their assemblies only), as of 2026-09-26, no other paper's lifted samples or current assembly bricks contain an identical function body after normalisation.

Presence, not direction: an identical function body in two papers' repositories does not say who wrote it, which came from which, or that either paper's method rests on it. Matching is exact after normalisation, so a renamed or edited function is not matched. Dates are when papers appeared, not when code was written. Only .py files the harvester lifted are covered; notebooks are not read. A new-style arXiv id YYMM.NNNN dates a paper to the month 20YY-MM; otherwise Paper.year dates it to the year; otherwise it is undated. Dates are when the paper appeared, not when the code was written. Read 2026-11-21.

Repositories linked to this paper

Some links come from the archived Papers with Code dataset (CC BY-SA 4.0): attribution and licence.

Abstract

Visual localization tackles the challenge of estimating the camera pose from images by using correspondence analysis between query images and a map. This task is computation and data intensive which poses challenges on thorough evaluation of methods on various datasets. However, in order to further advance in the field, we claim that robust visual localization algorithms should be evaluated on multiple datasets covering a broad domain variety. To facilitate this, we introduce kapture, a new, flexible, unified data format and toolbox for visual localization and structure-from-motion (SFM). It enables easy usage of different datasets as well as efficient and reusable data processing. To demonstrate this, we present a versatile pipeline for visual localization that facilitates the use of different local and global features, 3D data (e.g. depth maps), non-vision sensor data (e.g. IMU, GPS, WiFi), and various processing algorithms. Using multiple configurations of the pipeline, we show the great versatility of kapture in our experiments. Furthermore, we evaluate our methods on eight public datasets where they rank top on all and first on many of them. To foster future research, we release code, models, and all datasets used in this paper in the kapture format open source under a permissive BSD license. github.com/naver/kapture, github.com/naver/kapture-localization

For agents

The same record, over MCP at https://syntology.ai/mcp:

get_harvested_code_for_paper("2007.13867")
get_code_for_paper("2007.13867")
have("2007.13867")

The run record, dated, one paper per request, free:

curl https://syntology.ai/api/ran/2007.13867.json

A badge for a README (the split and the date, never a ratio):

[![Syntology run record](https://syntology.ai/api/ran/2007.13867.svg)](https://syntology.ai/paper/2007.13867)

Connect an agent — have() is free.