SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2108.04219 · 2021

Pragmatic Image Compression for Human-in-the-Loop Decision-Making

arXiv · PDF · Open in the Atlas

Code that ran

1 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 1 has no contract verdict; 0 failures of our instrument; 4 no recorded run), measured 2026-11-22; 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/2108.04219.json · badge: /api/ran/2108.04219.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
rddy/pico canonical (classifier label)
classifier basis: census
1 ran · 4 no recorded run
FunctionStatusWhere it lives
sweep_mask_limits Ran
ran on a synthesized input
rddy/pico/pico/viz.py
code served (permissive licence) · get_code("5d572f3c4fb40f1a")
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
from collections import defaultdict

torch.manual_seed(0)

# Define mask_limits as a list of numeric values
mask_limits = [0.1, 0.5, 0.9]

# Define a mock environment (not directly used in the function, but required)
class MockEnv:
    pass

env = MockEnv()

# Define mask_policy_of_model as a dict mapping model names to policies
# Policies can be simple objects or callables
mask_policy_of_model = {
    "model_a": {"policy_type": "type_a"},
    "model_b": {"policy_type": "type_b"}
}

# Define eval_policy as a function that takes (policy, mask_limit, model_name)
# and returns a dict of metrics
def eval_policy(policy, mask_limit, model_name=None):
    """Mock evaluation function that returns metrics."""
    return {
        "accuracy": 0.8 + mask_limit * 0.1,
        "loss": 0.5 - mask_limit * 0.05,
        "f1_score": 0.75 + mask_limit * 0.15
    }

ARGS = {
    "mask_limits": mask_limits,
    "env": env,
    "mask_policy_of_model": mask_policy_of_model,
    "eval_policy": eval_policy
}
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
build_mlp Not yet run
unverified (harvested, no recorded run)
rddy/pico/pico/utils.py
code served (permissive licence) · get_code("7450b431c8e9354d")
How it ran

no invocation recorded.

get_tf_vars_in_scope Not yet run
unverified (harvested, no recorded run)
rddy/pico/pico/utils.py
code served (permissive licence) · get_code("ac4ed795d74a6fb6")
How it ran

no invocation recorded.

make_tf_session Not yet run
unverified (harvested, no recorded run)
rddy/pico/pico/utils.py
code served (permissive licence) · get_code("abd8ae82a1619b9e")
How it ran

no invocation recorded.

sweep_and_sample Not yet run
unverified (harvested, no recorded run)
rddy/pico/pico/viz.py
code served (permissive licence) · get_code("154e1dbcbc1f2f4e")
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, 2 are also present in other papers whose code we hold (2 with at least one paper dated earlier, 0 the same month, 0 later) and 3 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
get_tf_vars_in_scope 1 other paper
1 dated earlier
1912.05652 (2019-12)
Learning Human Objectives by Evaluating Hypothetical Behavior
make_tf_session 1 other paper
1 dated earlier
1912.05652 (2019-12)
Learning Human Objectives by Evaluating Hypothetical Behavior

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

Repositories linked to this paper

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

Abstract

Standard lossy image compression algorithms aim to preserve an image's appearance, while minimizing the number of bits needed to transmit it. However, the amount of information actually needed by a user for downstream tasks -- e.g., deciding which product to click on in a shopping website -- is likely much lower. To achieve this lower bitrate, we would ideally only transmit the visual features that drive user behavior, while discarding details irrelevant to the user's decisions. We approach this problem by training a compression model through human-in-the-loop learning as the user performs tasks with the compressed images. The key insight is to train the model to produce a compressed image that induces the user to take the same action that they would have taken had they seen the original image. To approximate the loss function for this model, we train a discriminator that tries to distinguish whether a user's action was taken in response to the compressed image or the original. We evaluate our method through experiments with human participants on four tasks: reading handwritten digits, verifying photos of faces, browsing an online shopping catalogue, and playing a car racing video game. The results show that our method learns to match the user's actions with and without compression at lower bitrates than baseline methods, and adapts the compression model to the user's behavior: it preserves the digit number and randomizes handwriting style in the digit reading task, preserves hats and eyeglasses while randomizing faces in the photo verification task, preserves the perceived price of an item while randomizing its color and background in the online shopping task, and preserves upcoming bends in the road in the car racing game.

For agents

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

get_harvested_code_for_paper("2108.04219")
get_code_for_paper("2108.04219")
have("2108.04219")

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

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

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

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

Connect an agent — have() is free.