SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2510.25094 · NeurIPS · 2025

Visual Diversity and Region-aware Prompt Learning for Zero-shot HOI Detection

Hyunwoo Kim, Chanhyeong Yang, Taehoon Song, Jihwan Park

arXiv · PDF · Open in the Atlas

Code that ran

7 of 8 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; 1 honoured the contract we drafted, 1 violated it and 0 have no contract verdict; 5 failures of our instrument; 1 no recorded run), measured 2026-11-23; 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/2510.25094.json · badge: /api/ran/2510.25094.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
mlvlab/VDRP canonical (classifier label)
classifier basis: census
7 ran · 1 no recorded run
FunctionStatusWhere it lives
custom_collate Ran
ran; our contract draft was wrong, not the code
mlvlab/VDRP/utils_tip_cache_and_union_finetune.py
code served (permissive licence) · get_code("8c73b8b7646a5ae4")
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 tuple. 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

torch.manual_seed(0)

# Create a simple batch of (image, target) tuples
# Images: tiny tensors of shape (3, 4) - 3 channels, 4 spatial dims
# Targets: simple tensor or scalar labels
batch = [
    (torch.randn(3, 4), torch.tensor(1)),
    (torch.randn(3, 4), torch.tensor(0)),
]

ARGS = {
    "batch": batch
}
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 tuple — a tuple output has no array shape of its own; none is 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
isin_tensor Ran
ran, violated the contract we drafted
mlvlab/VDRP/upt_tip_cache_model_free_finetune_distill3.py
code served (permissive licence) · get_code("08dd759087549959")
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 2, dtype family float, shape (2, 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 small test tensors
values = torch.tensor([[1, 2, 3, 4], [5, 6, 7, 8]])  # shape: (2, 4)
test_elements = torch.tensor([2, 5, 9])  # shape: (3,)

ARGS = {
    "values": values,
    "test_elements": test_elements,
}
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 2, dtype family float, shape (2, 4) — shape (2, 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
shifted_window_attention Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
mlvlab/VDRP/transformer_layers.py
code served (permissive licence) · get_code("29395dbd34ec7691")
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 (2, 8, 8, 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 torch.nn.functional as F
import math

torch.manual_seed(0)

# Dimensions
batch_size = 2
height = 8
width = 8
channels = 4
num_heads = 2
head_dim = channels // num_heads

# Input tensor: [N, H, W, C]
input_tensor = torch.randn(batch_size, height, width, channels)

# QKV weight: projects from C -> 3*C (for Q, K, V)
qkv_out_dim = 3 * channels
qkv_weight = torch.randn(qkv_out_dim, channels)

# Projection weight: projects from C -> C
proj_weight = torch.randn(channels, channels)

# Relative position bias: [num_heads, window_height * window_width, window_height * window_width]
window_size = [4, 4]
window_area = window_size[0] * window_size[1]
relative_position_bias = torch.randn(num_heads, window_area, window_area)

# Optional biases
qkv_bias = torch.randn(qkv_out_dim)
proj_bias = torch.randn(channels)

# Shift size
shift_size = [0, 0]

# Attention dropout and dropout
attention_dropout = 0.0
dropout = 0.0

# Logit scale (optional, for Swin V2)
logit_scale = None

ARGS = {
    "input": input_tensor,
    "qkv_weight": qkv_weight,
    "proj_weight": proj_weight,
    "relative_position_bias": relative_position_bias,
    "window_size": window_size,
    "num_heads": num_heads,
    "shift_size": shift_size,
    "attention_dropout": attention_dropout,
    "dropout": dropout,
    "qkv_bias": qkv_bias,
    "proj_bias": proj_bias,
    "logit_scale": logit_scale,
}
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 (2, 8, 8, 4) — shape (2, 8, 8, 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
sparsemax Ran
ran; our contract draft was wrong, not the code
mlvlab/VDRP/upt_tip_cache_model_free_finetune_distill3.py
code served (permissive licence) · get_code("6cd404dc879a8ae6")
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 2, dtype family float, shape (2, 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 a small logits tensor: batch_size=2, num_classes=4
logits = torch.randn(2, 4)

ARGS = {
    "logits": logits,
    "dim": -1,
    "temperature": 10.0,
}
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 2, dtype family float, shape (2, 4) — shape (2, 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
stochastic_depth Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
mlvlab/VDRP/transformer_layers.py
code served (permissive licence) · get_code("256ec3ee8631f23b")
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 (2, 4, 3, 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
from torch import nn, Tensor

torch.manual_seed(0)

# Create a small input tensor with batch size 2 and arbitrary dimensions
input_tensor = torch.randn(2, 4, 3, 3)

# Define arguments for the stochastic_depth function
ARGS = {
    'input': input_tensor,
    'p': 0.5,
    'mode': 'batch',
    'training': True
}
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 (2, 4, 3, 3) — shape (2, 4, 3, 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
tranverse_and_get_hoi_cooccurence Ran
ran, honoured the contract we drafted
mlvlab/VDRP/main_tip_finetune.py
code served (permissive licence) · get_code("47aecf9da63178bf")
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 2, dtype family float, shape (5, 5) 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
from torch import nn

torch.manual_seed(0)

class MockDataset:
    def __init__(self):
        self.num_interation_cls = 5
        self._anno = [
            {
                'hoi': [0, 1, 2],
                'boxes_h': [
                    [10.0, 10.0, 20.0, 20.0],
                    [15.0, 15.0, 25.0, 25.0],
                    [50.0, 50.0, 60.0, 60.0]
                ],
                'boxes_o': [
                    [11.0, 11.0, 21.0, 21.0],
                    [16.0, 16.0, 26.0, 26.0],
                    [51.0, 51.0, 61.0, 61.0]
                ]
            },
            {
                'hoi': [1, 3],
                'boxes_h': [
                    [30.0, 30.0, 40.0, 40.0],
                    [35.0, 35.0, 45.0, 45.0]
                ],
                'boxes_o': [
                    [31.0, 31.0, 41.0, 41.0],
                    [36.0, 36.0, 46.0, 46.0]
                ]
            }
        ]

dataset = MockDataset()

ARGS = {
    'dataset': dataset
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch, torchvision — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Tensor, ndim 2, dtype family float, shape (5, 5) — shape (5, 5) 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
vcoco_object_n_verb_to_interaction Ran
ran; our contract draft was wrong, not the code
mlvlab/VDRP/main_tip_finetune.py
code served (permissive licence) · get_code("918857a5573a14b1")
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 numpy as np

# Create small test data for vcoco_object_n_verb_to_interaction
num_object_cls = 5
num_action_cls = 4

# class_corr format: list of (interaction_idx, object_idx, action_idx) tuples
# These represent valid object-action pairs that map to interaction classes
class_corr = [
    (0, 0, 0),   # interaction 0: object 0, action 0
    (1, 0, 1),   # interaction 1: object 0, action 1
    (2, 1, 0),   # interaction 2: object 1, action 0
    (3, 1, 2),   # interaction 3: object 1, action 2
    (4, 2, 1),   # interaction 4: object 2, action 1
    (5, 3, 3),   # interaction 5: object 3, action 3
    (6, 4, 0),   # interaction 6: object 4, action 0
]

ARGS = {
    "num_object_cls": num_object_cls,
    "num_action_cls": num_action_cls,
    "class_corr": class_corr,
}
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 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
multi_head_attention_forward Not yet run
unverified (harvested, no recorded run)
mlvlab/VDRP/attention.py
code served (permissive licence) · get_code("7653b4a0a7557b30")
How it ran

no invocation recorded.

Also present in other papers' code

Of 8 samples lifted from this paper's linked repositories, 8 carry a function identity and 0 do not. Of the 8 distinct functions with an identity, 6 are also present in other papers whose code we hold (6 with at least one paper dated earlier, 0 the same month, 0 later) and 2 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
custom_collate 5 other papers
5 dated earlier
2112.01838 (2021-12)
Efficient Two-Stage Detection of Human-Object Interactions with a Novel Unary-Pairwise Transformer
2308.06202 (2023-08)
Exploring Predicate Visual Context in Detecting of Human-Object Interactions
2309.03696 (2023-09)
Efficient Adaptive Human-Object Interaction Detection with Concept-guided Memory
and 2 more not named here
tranverse_and_get_hoi_cooccurence 3 other papers
3 dated earlier
2309.03696 (2023-09)
Efficient Adaptive Human-Object Interaction Detection with Concept-guided Memory
2408.02484 (2024-08)
Exploring Conditional Multi-Modal Prompts for Zero-shot HOI Detection
2410.23904 (2024-10)
EZ-HOI: VLM Adaptation via Guided Prompt Learning for Zero-Shot HOI Detection
vcoco_object_n_verb_to_interaction 3 other papers
3 dated earlier
2309.03696 (2023-09)
Efficient Adaptive Human-Object Interaction Detection with Concept-guided Memory
2408.02484 (2024-08)
Exploring Conditional Multi-Modal Prompts for Zero-shot HOI Detection
2410.23904 (2024-10)
EZ-HOI: VLM Adaptation via Guided Prompt Learning for Zero-Shot HOI Detection
multi_head_attention_forward 1 other paper
1 dated earlier
2308.06202 (2023-08)
Exploring Predicate Visual Context in Detecting of Human-Object Interactions
shifted_window_attention 1 other paper
1 dated earlier
2308.06202 (2023-08)
Exploring Predicate Visual Context in Detecting of Human-Object Interactions
stochastic_depth 1 other paper
1 dated earlier
2308.06202 (2023-08)
Exploring Predicate Visual Context in Detecting of Human-Object Interactions

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

Repositories linked to this paper

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

Abstract

Zero-shot Human-Object Interaction detection aims to localize humans and objects in an image and recognize their interaction, even when specific verb-object pairs are unseen during training. Recent works have shown promising results using prompt learning with pretrained vision-language models such as CLIP, which align natural language prompts with visual features in a shared embedding space. However, existing approaches still fail to handle the visual complexity of interaction-including (1) intra-class visual diversity, where instances of the same verb appear in diverse poses and contexts, and (2) inter-class visual entanglement, where distinct verbs yield visually similar patterns. To address these challenges, we propose VDRP, a framework for Visual Diversity and Region-aware Prompt learning. First, we introduce a visual diversity-aware prompt learning strategy that injects group-wise visual variance into the context embedding. We further apply Gaussian perturbation to encourage the prompts to capture diverse visual variations of a verb. Second, we retrieve region-specific concepts from the human, object, and union regions. These are used to augment the diversity-aware prompt embeddings, yielding region-aware prompts that enhance verb-level discrimination. Experiments on the HICO-DET benchmark demonstrate that our method achieves state-of-the-art performance under four zero-shot evaluation settings, effectively addressing both intra-class diversity and inter-class visual entanglement. Code is available at https://github.com/mlvlab/VDRP.

For agents

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

get_harvested_code_for_paper("2510.25094")
get_code_for_paper("2510.25094")
have("2510.25094")

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

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

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

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

Connect an agent — have() is free.