SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · Cai_HIPTrack_Visual_Tracking_with_Historical_Prompts_CVPR_2024_paper · CVPR · 2024

HIPTrack: Visual Tracking with Historical Prompts

Qingjie Liu, Yunhong Wang, Wenrui Cai

Open in the Atlas

Code that ran

5 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 0 have no contract verdict; 5 failures of our instrument; 0 no recorded run), measured 2026-11-24; 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/Cai_HIPTrack_Visual_Tracking_with_Historical_Prompts_CVPR_2024_paper.json · badge: /api/ran/Cai_HIPTrack_Visual_Tracking_with_Historical_Prompts_CVPR_2024_paper.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
WenRuiCai/HIPTrack canonical (classifier label)
classifier basis not recorded on the link
5 ran · 0 no recorded run
FunctionStatusWhere it lives
checkpoint_filter_fn Ran
ran; our contract draft was wrong, not the code
WenRuiCai/HIPTrack/lib/models/hiptrack/vit.py
code served (permissive licence) · get_code("2a55b64f08787da8")
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 torch
import torch.nn as nn
import math

torch.manual_seed(0)

class PatchEmbed(nn.Module):
    def __init__(self):
        super().__init__()
        # proj weight shape: (out_channels, in_channels, kernel_h, kernel_w)
        self.proj = nn.Conv2d(3, 16, kernel_size=2, stride=2)
        # grid_size for a 4x4 image with 2x2 kernel and stride 2 gives 2x2
        self.grid_size = (2, 2)

class SimpleModel(nn.Module):
    def __init__(self):
        super().__init__()
        self.patch_embed = PatchEmbed()
        # pos_embed shape: (batch, num_tokens + grid_h*grid_w, embed_dim)
        # num_tokens=1 (class token), grid is 2x2, so 1 + 4 = 5 tokens
        self.pos_embed = nn.Parameter(torch.randn(1, 5, 8))
        self.num_tokens = 1

model = SimpleModel()

# state_dict with pos_embed that has different shape (e.g., smaller grid 1x1)
# Original pos_embed: 1 class token + 1x1 grid = 2 tokens total, embed_dim=8
state_dict = {
    'pos_embed': torch.randn(1, 2, 8),
    'patch_embed.proj.weight': torch.randn(16, 3, 2, 2),
}

ARGS = {
    'state_dict': state_dict,
    'model': model,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — 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
combine_tokens Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
WenRuiCai/HIPTrack/lib/models/hiptrack/utils.py
pointer only (licence: Apache-2.0); the stored copy get_code serves, from XiaokunFeng/ATCTrack, is pointer only (licence: NONE) · get_code("b779b94daf1058d8")
How it ran

The body of this sample is withheld: this paper's link allows the body inline (Apache-2.0), but get_code serves the stored copy, first harvested from XiaokunFeng/ATCTrack, and GitHub detected no licence in that repository when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

recover_tokens Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
WenRuiCai/HIPTrack/lib/models/hiptrack/utils.py
code served (permissive licence) · get_code("989cd980f532ba2a")
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 Tensor, ndim 3, dtype family float, shape (2, 10, 4) 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 torch

torch.manual_seed(0)

# Create test tensors with distinct dimensions for clarity
# batch_size=2, sequence_length=10, embedding_dim=4
merged_tokens = torch.randn(2, 10, 4)

len_template_token = 3
len_search_token = 7
mode = 'template_central'

ARGS = {
    'merged_tokens': merged_tokens,
    'len_template_token': len_template_token,
    'len_search_token': len_search_token,
    'mode': mode
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Tensor, ndim 3, dtype family float, shape (2, 10, 4) — shape (2, 10, 4) 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
resize_pos_embed Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
WenRuiCai/HIPTrack/lib/models/hiptrack/vit.py
code served (permissive licence) · get_code("515af787204e2dfb")
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 Tensor, ndim 3, dtype family float, shape (1, 37, 4) 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 torch
import math

torch.manual_seed(0)

# Create a position embedding tensor with shape (batch, num_positions, embedding_dim)
# We'll use a 16x16 grid (256 tokens) + 1 class token = 257 total tokens
# embedding_dim = 4
batch_size = 1
num_class_tokens = 1
grid_size_old = 4
embedding_dim = 4
num_grid_tokens_old = grid_size_old * grid_size_old  # 16
num_tokens_total_old = num_class_tokens + num_grid_tokens_old  # 17

# posemb shape: (1, 17, 4) - 1 class token + 16 grid tokens
posemb = torch.randn(1, num_tokens_total_old, embedding_dim)

# Create posemb_new with a different grid size (6x6 = 36 grid tokens + 1 class token = 37 total)
grid_size_new = 6
num_grid_tokens_new = grid_size_new * grid_size_new  # 36
num_tokens_total_new = num_class_tokens + num_grid_tokens_new  # 37

# posemb_new shape: (1, 37, 4)
posemb_new = torch.randn(1, num_tokens_total_new, embedding_dim)

num_tokens = num_class_tokens
gs_new = (grid_size_new, grid_size_new)

ARGS = {
    'posemb': posemb,
    'posemb_new': posemb_new,
    'num_tokens': num_tokens,
    'gs_new': gs_new,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Tensor, ndim 3, dtype family float, shape (1, 37, 4) — shape (1, 37, 4) 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
window_partition Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
WenRuiCai/HIPTrack/lib/models/hiptrack/utils.py
code served (permissive licence) · get_code("80c66c535be6f491")
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 Tensor, ndim 4, dtype family float, shape (12, 2, 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 torch
import torch.nn as nn

torch.manual_seed(0)

# Create a small tensor with shape (B, H, W, C)
# B=2 (batch), H=4 (height), W=6 (width), C=3 (channels)
# Choose window_size=2 so that H and W are divisible by it
x = torch.randn(2, 4, 6, 3)

# Define window_size parameter
window_size = 2

ARGS = {
    'x': x,
    'window_size': window_size
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Tensor, ndim 4, dtype family float, shape (12, 2, 2, 3) — shape (12, 2, 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

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, 5 are also present in other papers whose code we hold (5 with at least one paper dated earlier, 0 the same month, 5 later) and 0 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.

FunctionAlso present inEarliest-datedOthers named
checkpoint_filter_fn 37 other papers
20 dated earlier, 3 later, 14 same year, order not determinable · 1 only as an assembly brick
2105.12723 (2021-05)
Nested Hierarchical Transformer: Towards Accurate, Data-Efficient and Interpretable Visual Understanding
2112.07658 (2021-12)
AdaViT: Adaptive Tokens for Efficient Vision Transformer
and 34 more not named here
window_partition 31 other papers
17 dated earlier, 5 later, 9 same year, order not determinable
2111.11418 (2021-11)
MetaFormer Is Actually What You Need for Vision
2203.12119 (2022-03)
Visual Prompt Tuning
2204.03645 (2022-04)
DaViT: Dual Attention Vision Transformers
and 28 more not named here
combine_tokens 7 other papers
2 dated earlier, 2 later, 3 same year, order not determinable
Hui_Bridging_Search_Region_Interaction_With_Template_for_RGB-T_Tracking_CVPR_2023_paper (2023 (year only))
Bridging Search Region Interaction with Template for RGB-T Tracking
Sun_Pixel-level_Semantic_Correspondence_through_Layout-aware_Representation_Learning_and_Multi-scale_Matching_CVPR_2024_paper (2024 (year only))
Pixel-level Semantic Correspondence through Layout-aware Representation Learning and Multi-scale Matching Integration
and 4 more not named here
recover_tokens 6 other papers
2 dated earlier, 1 later, 3 same year, order not determinable
Hui_Bridging_Search_Region_Interaction_With_Template_for_RGB-T_Tracking_CVPR_2023_paper (2023 (year only))
Bridging Search Region Interaction with Template for RGB-T Tracking
Sun_Pixel-level_Semantic_Correspondence_through_Layout-aware_Representation_Learning_and_Multi-scale_Matching_CVPR_2024_paper (2024 (year only))
Pixel-level Semantic Correspondence through Layout-aware Representation Learning and Multi-scale Matching Integration
and 3 more not named here
resize_pos_embed 5 other papers
2 dated earlier, 1 later, 2 same year, order not determinable
Hui_Bridging_Search_Region_Interaction_With_Template_for_RGB-T_Tracking_CVPR_2023_paper (2023 (year only))
Bridging Search Region Interaction with Template for RGB-T Tracking
aaai_27852 (2024 (year only))
Bi-directional Adapter for Multimodal Tracking
and 2 more not named here

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-24.

Repositories linked to this paper

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

Abstract

Trackers that follow Siamese paradigm utilize similarity matching between template and search region features for tracking. Many methods have been explored to enhance tracking performance by incorporating tracking history to better handle scenarios involving target appearance variations such as deformation and occlusion. However, the utilization of historical information in existing methods is insufficient and incomprehensive, which typically requires repetitive training and introduces a large amount of computation. In this paper, we show that by providing a tracker that follows Siamese paradigm with precise and updated historical information, a significant performance improvement can be achieved with completely unchanged parameters. Based on this, we propose a historical prompt network that uses refined historical foreground masks and historical visual features of the target to provide comprehensive and precise prompts for the tracker. We build a novel tracker called HIPTrack based on the historical prompt network, which achieves considerable performance improvements without the need to retrain the entire model. We conduct experiments on seven datasets and experimental results demonstrate that our method surpasses the current state-ofthe-art trackers on LaSOT, LaSOT ext , GOT-10k and NfS. Furthermore, the historical prompt network can seamlessly integrate as a plug-and-play module into existing trackers, providing performance enhancements. The source code is available at https://github.com/WenRuiCai/HIPTrack.

For agents

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

get_harvested_code_for_paper("Cai_HIPTrack_Visual_Tracking_with_Historical_Prompts_CVPR_2024_paper")
get_code_for_paper("Cai_HIPTrack_Visual_Tracking_with_Historical_Prompts_CVPR_2024_paper")
have("Cai_HIPTrack_Visual_Tracking_with_Historical_Prompts_CVPR_2024_paper")

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

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

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

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

Connect an agent — have() is free.