Papers › UniFormer: Unified Transformer for Efficient Spatiotemporal Representation Learning
UniFormer: Unified Transformer for Efficient Spatiotemporal Representation Learning
Kunchang Li, Yali Wang, Peng Gao, Guanglu Song, Yu Liu, Hongsheng Li, Yu Qiao
It is a challenging task to learn rich and multi-scale spatiotemporal semantics from high-dimensional videos, due to large local redundancy and complex global dependency between video frames. The recent advances in this research have been mainly driven by 3D convolutional neural networks and vision transformers. Although 3D convolution can efficiently aggregate local context to suppress local redundancy from a small 3D neighborhood, it lacks the capability to capture global dependency because of the limited receptive field. Alternatively, vision transformers can effectively capture long-range dependency by self-attention mechanism, while having the limitation on reducing local redundancy with blind similarity comparison among all the tokens in each layer. Based on these observations, we propose a novel Unified transFormer (UniFormer) which seamlessly integrates merits of 3D convolution and spatiotemporal self-attention in a concise transformer format, and achieves a preferable balance between computation and accuracy. Different from traditional transformers, our relation aggregator can tackle both spatiotemporal redundancy and dependency, by learning local and global token affinity respectively in shallow and deep layers. We conduct extensive experiments on the popular video benchmarks, e.g., Kinetics-400, Kinetics-600, and Something-Something V1&V2. With only ImageNet-1K pretraining, our UniFormer achieves 82.9%/84.8% top-1 accuracy on Kinetics-400/Kinetics-600, while requiring 10x fewer GFLOPs than other state-of-the-art methods. For Something-Something V1 and V2, our UniFormer achieves new state-of-the-art performances of 60.9% and 71.2% top-1 accuracy respectively. Code is available at https://github.com/Sense-X/UniFormer.
In Syntology View this paper on Syntology, its page in Syntology's graph. That page adds which of its functions are also present in other papers' code Syntology holds, with dates, and its dated run record as JSON and a README badge. It also lists the repositories linked to the paper, the abstract and the calls for agents.
Open this paper in Syntology's Atlas, the map of the papers in Syntology's graph and their citations.
For agents, on Syntology's MCP service (how to connect):
get_harvested_code_for_paper(arxiv_id="2201.04676")get_code(code_sha256="…")with a sample'scode_sha256from the list belowget_citation_path(paper_1="2201.04676", paper_2="…")with another paper's arXiv id or titleget_concepts_for_paper(arxiv_id="2201.04676")
Code
Syntology 37 code samples harvested from 3 repositories linked to this paper: 27 ran (of which 14 constructed an object rather than computing a result; 16 with no instrument failure: 1 honoured, 0 violated, 15 with no contract checked; 11 where Syntology's instrument failed) · 10 unverified. Where Syntology's instrument failed: 8 where our contract draft was wrong; 3 where the contract check could not run; failures of Syntology's instrument, not of the code.
By repository: official repository: 5 samples from 1 repository, 4 ran (4 with no instrument failure; 0 where Syntology's instrument failed); community (archive-listed): 30 samples from 1 repository, 23 ran (12 with no instrument failure; 11 where Syntology's instrument failed); community: 2 samples from 1 repository, 0 ran (0 with no instrument failure; 0 where Syntology's instrument failed). The run record, sample by sample. “Ran” means executed on a synthesized input, not that the code is correct or reproduces the paper.
Levels written between 2026-09-22 and 2026-09-24 (UTC): the dates Syntology's graph wrote each sample's verification level, not when the code executed.
Repository list and official/mentioned flags are the archive's, frozen 2025-07-28. Reachability, where shown, is from one Syntology probe window (2026-09-16 to 2026-09-18); repositories not probed show nothing. GitHub stars are not tracked.
Code Syntology ran Syntology
37 samples harvested: 27 ran (of which 14 constructed an object rather than computing a result; 16 with no instrument failure: 1 honoured, 0 violated, 15 with no contract checked; 11 where Syntology's instrument failed) · 10 unverified. “Where Syntology's instrument failed” counts failures of Syntology's instrument, not of the code. Syntology's record for this page has not changed since , the first build that kept a record date for it; when this build read Syntology's graph is in the build record. That date is not when the samples ran.
Licence: 0 of the 37 samples are pointer only, meaning Syntology does not serve that copy's text. This page shows no code text for any sample; each one links to its file in the repository.
Harvested from 3 repositories linked to this paper, official or community; the list below is grouped by repository, each group headed by its name and what it is to the paper. “Ran” means the sample executed on a synthesized input. It does not mean the output is correct, and nothing here reproduces the paper's results. A line beginning “fixture:” under a sample that ran gives the arguments Syntology's fixture called the sample with, each as name:type/rank/element kind (? where none was recorded), and the type of what the fixture's run returned, exactly as the harness recorded them; the arguments and the returned type were recorded by two separate runs of the same fixture. No output value is shown, and a returned type says nothing about whether the output was right. “Level recorded” gives the UTC date when Syntology's graph wrote the sample's verification level, not when the code executed; where the level was written before Syntology's graph kept that date, the row says “level recorded, date not recorded”. For 6 samples that ran, the graph records a signature this page does not show: for a class the fixture built without calling, the harness called the object with inputs it made up itself, so the recorded signature is the harness's probe, not the fixture's arguments. “Honoured” and “violated” refer to a contract Syntology drafted from the code itself. “Our draft was wrong” and “the contract check could not run” are failures of Syntology's instrument, not of the code: the sample ran on Syntology's synthesized input, and then the drafted contract did not describe it, or the check itself raised an error (RAISES), lacked a dependency (DEP_MISSING) or ran out of time (TIMEOUT); hover the label for which. A metamorphic tier, where shown, is evidence of the output's shape, not that the sample implements the method.
Each sample ends with its code_sha256. A sample's code_sha256 is Syntology's identity for that exact code. It is printed in full (16 hexadecimal characters for every sample in this build), and get_code(code_sha256="…") takes it exactly as printed. An agent calls it on Syntology's MCP service (how to connect); click an identity to copy that call.
Repository labels, per sample. official repository: The archive marks this repository official for the paper. named in the paper: The archive records that the paper mentions this repository; it is not marked official. community (archive-listed): In the archive's code links for this paper, not marked official and not recorded as mentioned in the paper. found in paper text by Syntology: Syntology found this repository in the paper's own text; whether it is the authors' implementation is not asserted. community: Not in the archive's code links for this paper; a community repository Syntology harvested. Samples are grouped by repository: a repository marked official first, then by how directly the repository is tied to the paper, then in the archive's order; never by how many ran. Licence labels name the repository's licence as recorded at harvest. “Pointer only” means Syntology does not serve that copy's text, for one of six reasons: no licence file was found; the licence was not identified; the licence is recorded as permissive but that copy's record is not marked cleared; the licence is outside the permissive list Syntology serves text under (MIT, Apache-2.0, BSD and similar); this paper's copy was not located, so its licence is not recorded; or this paper's copy is cleared, but the stored copy of the same code that Syntology serves is not. Some licences outside that list permit redistribution, such as WTFPL, and GPL-3.0 under its conditions; they are simply not on the list. Hover a licence label for the reason. File links open the file on GitHub at the default branch, which may have changed since the harvest.
A function or class name links to its page when the name occurs in the harvested code of at least 5 papers; the name is a string, not an identity. A census tag appears when Syntology's census ran implementations with that name on one shared input per bucket: it gives how many were compared, from how many papers, and how many distinct outputs they produced, and names this sample's bucket when this sample was one of them.
e8faab56f5f8df9b · report
fixture: returned CBlock · level recorded 2026-09-22 8a8dcc08ab9bfa65 · report
fixture: returned SABlock · level recorded 2026-09-22 0c3842c98c1ef897 · report
fixture: returned head_embedding · level recorded 2026-09-22 8f5a6c1aca9ba4de · report
fixture: returned middle_embedding · level recorded 2026-09-22 199ff8d54ab96603 · report
f8b18bc5e8ba3ac5 · report
fixture: returned CBlock · level recorded 2026-09-22 3fca321b162e5063 · report
fixture: returned CMlp · level recorded 2026-09-22 census: 17 implementations from 17 papers, 8 distinct outputs across 3 buckets, one shared input per bucket towhee/models/uniformer/uniformer.py ran · metamorphic tier: deterministic fingerprinted Apache-2.0 (permissive) ·
8f059bf3db11537b · report
fixture: returned DropPath · level recorded 2026-09-22 6b2146395f61d804 · report
fixture: returned Dropout · level recorded 2026-09-22 d2f31546ef368292 · report
fixture: returned Einsum · level recorded 2026-09-22 d4114dbf5943332c · report
fixture: returned GELU · level recorded 2026-09-22 82f963c4eb1876d4 · report
fixture: returned Linear · level recorded 2026-09-22 865f8893e93aa461 · report
fixture: returned Mlp · level recorded 2026-09-22 census: 9 implementations from 9 papers, 6 distinct outputs on one shared input towhee/models/uniformer/uniformer.py ran · metamorphic tier: deterministic Apache-2.0 (permissive) ·
e23cb083b2438d3d · report
fixture: returned PatchEmbed · level recorded 2026-09-22 15c57dc641cf3d74 · report
fixture: returned Softmax · level recorded 2026-09-22 68e7dd5cd494241b · report
fixture: signature x:Tensor/5/float · returned Tensor · level recorded 2026-09-24 census: 16 implementations from 16 papers, 1 distinct output on one shared input this sample: bucket 1 of 1, arg 1: rank 2, kind float, dtype float32 towhee/models/uniformer/uniformer.py ran; the contract check could not run (RAISES) · metamorphic tier: invariant Apache-2.0 (permissive) ·
607038475fdc388b · report
fixture: signature tensor:Tensor/2/float, mean:float/0/float, std:float/0/float, a:float/0/float, b:float/0/float · returned Tensor · level recorded 2026-09-22 2f3cf06bc7cb9815 · report
fixture: signature n:int/0/int · returned function · level recorded 2026-09-22 5e851f59c9824316 · report
fixture: signature dim:int/0/int · returned BatchNorm3d · level recorded 2026-09-22 84e3e49d2ae685c9 · report
fixture: signature inp:int/0/int, oup:int/0/int, groups:int/0/int · returned Conv3d · level recorded 2026-09-22 0120a7f1a1e50907 · report
fixture: signature inp:int/0/int, oup:int/0/int, kernel_size:int/0/int, stride:int/0/int, groups:int/0/int · returned Conv3d · level recorded 2026-09-22 b7ed0955d5e0c6f0 · report
fixture: signature inp:int/0/int, oup:int/0/int, groups:int/0/int · returned Conv3d · level recorded 2026-09-22 813d5682c2f6b672 · report
fixture: signature inp:int/0/int, oup:int/0/int, kernel_size:int/0/int, stride:int/0/int, groups:int/0/int · returned Conv3d · level recorded 2026-09-22 7e0fda53f432a9bd · report
fixture: signature inp:int/0/int, oup:int/0/int, kernel_size:int/0/int, stride:int/0/int, groups:int/0/int · returned Conv3d · level recorded 2026-09-22 b2472041187c554f · report
fixture: signature inp:int/0/int, oup:int/0/int, groups:int/0/int · returned Conv3d · level recorded 2026-09-22 census: 27 implementations from 61 papers, 5 distinct outputs across 2 buckets, one shared input per bucket this sample: bucket 1 of 2, arg 1: rank 4, kind float, dtype float32 towhee/models/uniformer/uniformer.py ran; the contract check could not run (RAISES) · metamorphic tier: invariant Apache-2.0 (permissive) ·
39eace7e2822504f · report
fixture: signature x:Tensor/4/float, drop_prob:float/0/float, training:bool/0/bool · returned Tensor · level recorded 2026-09-22 census: 3 implementations from 5 papers, 2 distinct outputs on one shared input this sample: bucket 1 of 1, arg 1: rank 2, kind float, dtype float32 · arg 2: rank 2, kind float, dtype float32 towhee/models/uniformer/uniformer.py ran · honoured contract fingerprinted Apache-2.0 (permissive) ·
507e144112f81dc6 · report
fixture: signature a:Tensor/2/float, b:Tensor/2/float · returned Tensor · level recorded 2026-09-22 census: 37 implementations from 54 papers, 4 distinct outputs on one shared input this sample: bucket 1 of 1, arg 1: rank 2, kind float, dtype float32 towhee/models/uniformer/uniformer.py ran; the contract check could not run (RAISES) · metamorphic tier: invariant Apache-2.0 (permissive) ·
f3e47c6e3250d13b · report
fixture: signature tensor:Tensor/2/float, mean:float/0/float, std:float/0/float, a:float/0/float, b:float/0/float · returned Tensor · level recorded 2026-09-22 census: 9 implementations from 7 papers, 9 distinct outputs across 3 buckets, one shared input per bucket towhee/models/uniformer/uniformer.py unverified Apache-2.0 (permissive) ·
e00c355740a3cab6 · report
e04c66afc6a652b1 · report
1bc2938f5a5b8e2e · report
2e84a2e6147c7e87 · report
79921eebe00978bd · report
2e4559833b1c24b6 · report
f1b1138b372a9b03 · report
298b1968dc3403b8 · report
census: 5 implementations from 103 papers, 1 distinct output on one shared input uniformer_pytorch/uniformer_pytorch.py unverified MIT (permissive) ·
570499cd4f300cb8 · report
Method as code Syntology
What Syntology's graph records as this paper's claimed method, lifted into code: each assembly names its bricks (functions and classes), each with its own role and its own verification level. An assembly is not a check that the code implements the method correctly or reproduces the paper's results. Levels are each brick's own verification level in Syntology's graph (level 0: no recorded run), listed brick by brick and never combined into one level; “ran” means the brick executed on a synthesized input, not that its output is correct, and the instrument figure counts failures of Syntology's instrument, not of the code. Where a model read the code against the paper's claim, each assembly's label verdict is one model's judgement, kept in this page's JSON twin; it is not calibrated, so no card prints it. Siblings are assemblies lifted from this paper in the same batch for the same method: alternative readings kept side by side; none replaces or supersedes another.
2 assemblies on this paper: 2 harvested, 0 generated, listed in 1 groups (siblings lifted in one batch form one group).
2 sibling assemblies for UniFormer (harvested), lifted in the same batch on 2026-09-09: alternative readings kept side by side; none replaces or supersedes another.
harvested Assembly for UniFormer (graph method: UniFormer). 30 bricks; individually on a fixture: 23 ran (of which 10 constructed an object rather than computing a result; 12 with no instrument failure: 1 honoured, 0 violated, 11 with no contract checked; 11 where Syntology's instrument failed) · 7 unverified. The assembly has not been run end-to-end.
one of 2 siblings
- Uniformer entry · level 0 · unverified ·
2e4559833b1c24b6 - CBlock model · level 1 · ran ·
f8b18bc5e8ba3ac5 - PatchEmbed model · level 1 · ran ·
e23cb083b2438d3d - SABlock model · level 0 · unverified ·
2e84a2e6147c7e87 - SpeicalPatchEmbed model · level 1 · ran ·
68e7dd5cd494241b - SplitSABlock model · level 0 · unverified ·
79921eebe00978bd - bn_3d helper · level 1 · ran · our draft was wrong ·
5e851f59c9824316 - trunc_normal_ helper · level 1 · ran; the contract check could not run (RAISES) ·
f3e47c6e3250d13b - CMlp helper · level 1 · ran ·
3fca321b162e5063 - DropPath helper · level 1 · ran ·
8f059bf3db11537b - conv_1x1x1 helper · level 1 · ran · our draft was wrong ·
84e3e49d2ae685c9 - conv_3x3x3 helper · level 1 · ran · our draft was wrong ·
b7ed0955d5e0c6f0 - conv_5x5x5 helper · level 1 · ran · our draft was wrong ·
b2472041187c554f - drop_path helper · level 1 · ran; the contract check could not run (RAISES) ·
39eace7e2822504f - conv_1xnxn helper · level 1 · ran · our draft was wrong ·
0120a7f1a1e50907 - conv_3xnxn_std helper · level 1 · ran · our draft was wrong ·
7e0fda53f432a9bd - Mlp helper · level 1 · ran ·
865f8893e93aa461 - MultiHeadAttention helper · level 0 · unverified ·
e00c355740a3cab6 - conv_3xnxn helper · level 1 · ran · our draft was wrong ·
813d5682c2f6b672 - _no_grad_trunc_normal_ helper · level 1 · ran; the contract check could not run (RAISES) ·
607038475fdc388b - Dropout helper · level 1 · ran ·
6b2146395f61d804 - GELU helper · level 1 · ran ·
d4114dbf5943332c - Linear helper · level 1 · ran ·
82f963c4eb1876d4 - Einsum helper · level 1 · ran ·
d2f31546ef368292 - Softmax helper · level 1 · ran ·
15c57dc641cf3d74 - RelProp helper · level 0 · unverified ·
e04c66afc6a652b1 - safe_divide helper · level 1 · ran · honoured contract ·
507e144112f81dc6 - RelPropSimple helper · level 0 · unverified ·
1bc2938f5a5b8e2e - forward_hook helper · level 0 · unverified ·
f1b1138b372a9b03 - _ntuple helper · level 1 · ran · our draft was wrong ·
2f3cf06bc7cb9815
harvested Assembly for UniFormer (graph method: UniFormer). 9 bricks; individually on a fixture: 8 ran (of which 8 constructed an object rather than computing a result; 8 with no instrument failure: 0 honoured, 0 violated, 8 with no contract checked; 0 where Syntology's instrument failed) · 1 unverified; every one of the 8 samples that ran constructed an object rather than computing a result. The assembly has not been run end-to-end.
one of 2 siblings
- UniFormer entry · level 0 · unverified ·
199ff8d54ab96603 - CBlock model · level 1 · ran ·
e8faab56f5f8df9b - PatchEmbed model · level 1 · ran ·
4c61832d00a1f67e - SABlock model · level 1 · ran ·
8a8dcc08ab9bfa65 - head_embedding model · level 1 · ran ·
0c3842c98c1ef897 - middle_embedding model · level 1 · ran ·
8f5a6c1aca9ba4de - CMlp helper · level 1 · ran ·
0e0efb67773d6946 - Attention model · level 1 · ran ·
9af3eb132594e510 - Mlp helper · level 1 · ran ·
a1715055832f71fd
Each brick ends with its code_sha256, Syntology's identity for that exact code; click one to copy the get_code call that returns it. For agents, on Syntology's MCP service: assembly(arxiv_id="2201.04676") returns these assemblies with each brick's role and wiring (how to connect).
Tasks
Results from the paper archive 2025-07-28
No leaderboard rows for this paper in the archive.
Methods
Report a problem or propose a change · a person checks every report against the paper or source before anything changes; decisions are listed on /corrections