SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2111.12294 · 2021

An Image Patch is a Wave: Phase-Aware Vision MLP

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, 1 violated it and 1 has no contract verdict; 2 failures of our instrument; 1 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/2111.12294.json · badge: /api/ran/2111.12294.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
kingcong/models community (classifier label)
classifier basis not recorded on the link
3 ran · 1 no recorded run
copy not recorded community
not in the paper's declared repositories
1 ran · 0 no recorded run
FunctionStatusWhere it lives
merge Ran
ran; our contract draft was wrong, not the code
kingcong/models/MGN/model_utils/config.py
code served (permissive licence) · get_code("b9e24c3e3e0e88a7")
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) 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 argparse

torch.manual_seed(0)

# Create a mock args object with some attributes
args = argparse.Namespace(
    learning_rate=0.001,
    batch_size=32,
    epochs=10,
    model_name="test_model",
    debug=True,
    seed=42
)

# Create a base configuration dictionary
cfg = {
    "default_lr": 0.0001,
    "default_batch": 16,
    "dataset": "cifar10"
}

ARGS = {
    "args": args,
    "cfg": cfg
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1
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
parse_cli_to_yaml Ran
ran; our contract draft was wrong, not the code
kingcong/models/MGN/model_utils/config.py
code served (permissive licence) · get_code("96d37c643b26e9d8")
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 Namespace. 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 argparse
import ast

def parse_cli_to_yaml(parser, cfg, helper=None, choices=None, cfg_path='default_config.yaml'):
    """
    Parse command line arguments to the configuration according to the default yaml.

    Args:
        parser: Parent parser.
        cfg: Base configuration.
        helper: Helper description.
        cfg_path: Path to the default yaml config.
    """
    parser = argparse.ArgumentParser(description='[REPLACE THIS at config.py]', parents=[parser])
    helper = {} if helper is None else helper
    choices = {} if choices is None else choices
    for item in cfg:
        if not isinstance(cfg[item], list) and (not isinstance(cfg[item], dict)):
            help_description = helper[item] if item in helper else 'Please reference to {}'.format(cfg_path)
            choice = choices[item] if item in choices else None
            if isinstance(cfg[item], bool):
                parser.add_argument('--' + item, type=ast.literal_eval, default=cfg[item], choices=choice, help=help_description)
            else:
                parser.add_argument('--' + item, type=type(cfg[item]), default=cfg[item], choices=choice, help=help_description)
    args = parser.parse_args()
    return args


# Setup code to construct valid arguments
import sys

# Create a parent parser
parent_parser = argparse.ArgumentParser(add_help=False)

# Create a base configuration dictionary with various types
cfg = {
    'learning_rate': 0.001,
    'batch_size': 32,
    'epochs': 100,
    'use_cuda': False,
    'model_name': 'resnet50',
    'dropout': 0.5,
}

# Create helper descriptions for some parameters
helper = {
    'learning_rate': 'Learning rate for optimizer',
    'batch_size': 'Batch size for training',
    'epochs': 'Number of training epochs',
    'use_cuda': 'Whether to use CUDA',
    'model_name': 'Name of the model to use',
}

# Create choices for some parameters
choices = {
    'model_name': ['resnet50', 'vgg16', 'efficientnet'],
}

# Set up sys.argv to simulate command line arguments
sys.argv = ['script.py']

ARGS = {
    'parser': parent_parser,
    'cfg': cfg,
    'helper': helper,
    'choices': choices,
    'cfg_path': 'default_config.yaml'
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
none outside the standard library — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Namespace — a Namespace output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a Namespace 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
parse_yaml Ran
ran on a synthesized input
kingcong/models/MGN/model_utils/config.py
code served (permissive licence) · get_code("2565f644bc83302b")
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, ndim 1, 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 tempfile
import os
import yaml

# Create a temporary YAML file with valid configuration
temp_dir = tempfile.mkdtemp()
yaml_path = os.path.join(temp_dir, 'config.yaml')

# Write a valid multi-document YAML file with 3 documents:
# 1. Main config
# 2. Config helper (descriptions)
# 3. Config choices

yaml_content = """
model: resnet50
learning_rate: 0.001
batch_size: 32
---
model: "Type of model to use"
learning_rate: "Learning rate for optimization"
batch_size: "Number of samples per batch"
---
model: [resnet50, vgg16, inception]
learning_rate: [0.0001, 0.001, 0.01]
batch_size: [16, 32, 64]
"""

with open(yaml_path, 'w') as f:
    f.write(yaml_content)

ARGS = {
    'yaml_path': yaml_path
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
yaml — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type tuple, ndim 1, dtype family float — a tuple 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
to_2tuple Ran
ran, violated the contract we drafted
this paper's copy was not recorded; identical code first harvested from vita-group/m3vit
pointer only · get_code("c0d3b80fb37a74d6")
How it ran

The body of this sample is withheld: this paper's copy of the code was not recorded (its link names no repository or source path), so no licence was read for it. 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.

calculate_psnr Not yet run
unverified (harvested, no recorded run)
kingcong/models/brdnet/cal_psnr.py
code served (permissive licence) · get_code("17861669c3cd2ba9")
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, 3 are also present in other papers whose code we hold (3 with at least one paper dated earlier, 0 the same month, 3 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
merge 28 other papers
27 dated earlier, 1 later
1406.1078 (2014-06)
Learning Phrase Representations using RNN Encoder-Decoder for Statistical Machine Translation
1409.3215 (2014-09)
Sequence to Sequence Learning with Neural Networks
1512.00567 (2015-12)
Rethinking the Inception Architecture for Computer Vision
and 25 more not named here
parse_cli_to_yaml 20 other papers
19 dated earlier, 1 later
1406.1078 (2014-06)
Learning Phrase Representations using RNN Encoder-Decoder for Statistical Machine Translation
1409.3215 (2014-09)
Sequence to Sequence Learning with Neural Networks
1512.00567 (2015-12)
Rethinking the Inception Architecture for Computer Vision
and 17 more not named here
to_2tuple 3 other papers
2 dated earlier, 1 later
2107.06263 (2021-07)
CMT: Convolutional Neural Networks Meet Vision Transformers
2108.13341 (2021-08)
Hire-MLP: Vision MLP via Hierarchical Rearrangement
2210.14793 (2022-10)
M$^3$ViT: Mixture-of-Experts Vision Transformer for Efficient Multi-task Learning with Model-Accelerator Co-design

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

In the field of computer vision, recent works show that a pure MLP architecture mainly stacked by fully-connected layers can achieve competing performance with CNN and transformer. An input image of vision MLP is usually split into multiple tokens (patches), while the existing MLP models directly aggregate them with fixed weights, neglecting the varying semantic information of tokens from different images. To dynamically aggregate tokens, we propose to represent each token as a wave function with two parts, amplitude and phase. Amplitude is the original feature and the phase term is a complex value changing according to the semantic contents of input images. Introducing the phase term can dynamically modulate the relationship between tokens and fixed weights in MLP. Based on the wave-like token representation, we establish a novel Wave-MLP architecture for vision tasks. Extensive experiments demonstrate that the proposed Wave-MLP is superior to the state-of-the-art MLP architectures on various vision tasks such as image classification, object detection and semantic segmentation. The source code is available at https://github.com/huawei-noah/CV-Backbones/tree/master/wavemlp_pytorch and https://gitee.com/mindspore/models/tree/master/research/cv/wave_mlp.

For agents

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

get_harvested_code_for_paper("2111.12294")
get_code_for_paper("2111.12294")
have("2111.12294")

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

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

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

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

Connect an agent — have() is free.