Papers › Dynamic-LLaVA: Efficient Multimodal Large Language Models via Dynamic Vision-language...

Dynamic-LLaVA: Efficient Multimodal Large Language Models via Dynamic Vision-language Context Sparsification

1 Dec 2024arXiv:2412.00876archive 2025-07-28

Wenxuan Huang, Zijie Zhai, Yunhang Shen, Shaosheng Cao, Fei Zhao, Xiangfeng Xu, Zheyu Ye, Shaohui Lin

Multimodal Large Language Models (MLLMs) have achieved remarkable success in vision understanding, reasoning, and interaction. However, the inference computation and memory increase progressively with the generation of output tokens during decoding, directly affecting the efficacy of MLLMs. Existing methods attempt to reduce the vision context redundancy to achieve efficient MLLMs. Unfortunately, the efficiency benefits of the vision context reduction in the prefill stage gradually diminish during the decoding stage. To address this problem, we proposed a dynamic vision-language context sparsification framework Dynamic-LLaVA, which dynamically reduces the redundancy of vision context in the prefill stage and decreases the memory and computation overhead of the generated language context during decoding. Dynamic-LLaVA designs a tailored sparsification inference scheme for different inference modes, i.e., prefill, decoding with and without KV cache, to achieve efficient inference of MLLMs. In practice, Dynamic-LLaVA can reduce computation consumption by ∼75% in the prefill stage. Meanwhile, throughout the entire generation process of MLLMs, Dynamic-LLaVA reduces the ∼50% computation consumption under decoding without KV cache, while saving ∼50% GPU memory overhead when decoding with KV cache, due to the vision-language context sparsification. Extensive experiments also demonstrate that Dynamic-LLaVA achieves efficient inference for MLLMs with negligible understanding and generation ability degradation or even performance gains compared to the full-context inference baselines. Code is available at https://github.com/Osilly/dynamic_llava .

PaperPDFCodeCode Syntology ranMethod as code

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):

Code

Syntology 18 code samples harvested from 1 repository linked to this paper: 13 ran (of which 4 constructed an object rather than computing a result; 5 with no instrument failure: 0 honoured, 1 violated, 4 with no contract checked; 8 where Syntology's instrument failed) · 5 unverified. Where Syntology's instrument failed: 7 where our contract draft was wrong; 1 where the contract check could not run; failures of Syntology's instrument, not of the code.

By repository: official repository: 18 samples from 1 repository, 13 ran (5 with no instrument failure; 8 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 on 2026-09-22 (UTC): the dates Syntology's graph wrote each sample's verification level, not when the code executed. 4 of the 13 samples that ran have no recorded date.

osilly/dynamic_llava officialmentioned in paperpytorchApache-2.0Syntology: 18 samples, 13 ran (8 instrument-failed) · 5 unverified report

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

18 samples harvested: 13 ran (of which 4 constructed an object rather than computing a result; 5 with no instrument failure: 0 honoured, 1 violated, 4 with no contract checked; 8 where Syntology's instrument failed) · 5 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.

1ran · violated contract
7ran · our draft was wrong
1ran; the contract check could not run
4ran
5unverified

Licence: 0 of the 18 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 osilly/dynamic_llava. “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 1 sample 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.

osilly/dynamic_llava official repository 18 samples, 13 ran (8 instrument-failed) · 5 unverified
LlamaDynamicNTKScalingRotaryEmbedding in 6 papers llava/model/language_model/dynamic_modeling_llama.py ran · metamorphic tier: deterministic Apache-2.0 (permissive) · 68bd42b9c09a9dd1 · report fixture: returned LlamaDynamicNTKScalingRotaryEmbedding · level recorded 2026-09-22
LlamaLinearScalingRotaryEmbedding in 6 papers llava/model/language_model/dynamic_modeling_llama.py ran · metamorphic tier: deterministic Apache-2.0 (permissive) · 1287c98591685f54 · report fixture: returned LlamaLinearScalingRotaryEmbedding · level recorded 2026-09-22
LlamaMLP in 13 papers llava/model/language_model/dynamic_modeling_llama.py ran · metamorphic tier: deterministic fingerprinted Apache-2.0 (permissive) · c5d348f0b0059642 · report fixture: returned LlamaMLP · level recorded 2026-09-22
LlamaRotaryEmbedding in 13 papers llava/model/language_model/dynamic_modeling_llama.py ran · metamorphic tier: deterministic Apache-2.0 (permissive) · 7541f97d86797bda · report fixture: returned LlamaRotaryEmbedding · level recorded 2026-09-22
collate_fn in 500 papers llava/dynamic_eval/model_vqa_loader.py ran · our draft was wrong Apache-2.0 (permissive) · 20e4f665698a3d18 · report fixture: signature batch:list/1/tuple · returned tuple · level recorded 2026-09-22
convert_caps llava/dynamic_eval/eval_science_qa.py ran · our draft was wrong Apache-2.0 (permissive) · 94fda0761ce0d5b9 · report fixture: signature results:list/1/dict · returned list · level recorded, date not recorded
get_chunk in 197 papers llava/dynamic_eval/model_lvis_for_meteor.py ran · our draft was wrong fingerprinted Apache-2.0 (permissive) · 42a46570620cd9fa · report fixture: signature lst:list/1/int, n:int/0/int, k:int/0/int · returned list · level recorded, date not recorded
get_pred_idx llava/dynamic_eval/eval_science_qa.py ran · violated contract fingerprinted Apache-2.0 (permissive) · 36e875f85baa4565 · report fixture: signature prediction:str/0/str, choices:list/1/str, options:list/1/str · returned int · level recorded 2026-09-22
prompt_processor llava/dynamic_eval/eval_textvqa.py ran · our draft was wrong Apache-2.0 (permissive) · 1e68840d6bbdface · report fixture: signature prompt:str/0/str · returned str · level recorded 2026-09-22
scaled_dot_product_attention_with_policy llava/model/language_model/dynamic_modeling_llama.py ran · our draft was wrong Apache-2.0 (permissive) · bc218bfbe73e286b · report fixture: signature query:Tensor/4/float, key:Tensor/4/float, value:Tensor/4/float, attn_mask:NoneType/0/?, dropout_p:float/0/float, is_causal:bool/0/bool, scale:NoneType/0/?, policy:Tensor/3/float · returned Tensor · level recorded 2026-09-22
softmax_with_policy llava/model/language_model/dynamic_modeling_llama.py ran · our draft was wrong Apache-2.0 (permissive) · aa7e8923d37f93a8 · report fixture: signature attn:Tensor/4/float, policy:Tensor/3/float, eps:float/0/float · returned Tensor · level recorded 2026-09-22
split_list in 223 papers llava/dynamic_eval/model_lvis_for_meteor.py ran · our draft was wrong fingerprinted Apache-2.0 (permissive) · 076c252c52cbb161 · report fixture: signature lst:list/1/int, n:int/0/int · returned list · level recorded, date not recorded
unpad_image in 72 papers
census: 4 implementations from 34 papers, 2 distinct outputs on one shared input this sample: bucket 1 of 1, arg 1: rank 3, kind float, dtype float32
llava/model/dynamic_llava_arch.py ran; the contract check could not run (RAISES) · metamorphic tier: invariant fingerprinted Apache-2.0 (permissive) · 55c32993da87759b · report fixture: signature tensor:Tensor/3/float, original_size:tuple/1/int · returned Tensor · level recorded, date not recorded
Cache in 5 papers llava/model/language_model/dynamic_modeling_llama.py unverified Apache-2.0 (permissive) · d866787c2702613f · report
DynamicLlamaDecoderLayer llava/model/language_model/dynamic_modeling_llama.py unverified Apache-2.0 (permissive) · 2ee5fbf088ba5b7e · report
DynamicLlamaSdpaAttention llava/model/language_model/dynamic_modeling_llama.py unverified Apache-2.0 (permissive) · c0464d1e0119ec7f · report
LlamaAttention in 15 papers llava/model/language_model/dynamic_modeling_llama.py unverified Apache-2.0 (permissive) · 64c5b45fc73cecfd · report
LlamaFlashAttention2 llava/model/language_model/dynamic_modeling_llama.py unverified Apache-2.0 (permissive) · 58c176deebe204d2 · 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.

1 assembly on this paper: 1 harvested, 0 generated.

harvested Assembly for Dynamic-LLaVA (graph method: Dynamic-LLaVA). 16 bricks; individually on a fixture: 11 ran (of which 5 constructed an object rather than computing a result; 5 with no instrument failure: 0 honoured, 0 violated, 5 with no contract checked; 6 where Syntology's instrument failed) · 5 unverified. The assembly has not been run end-to-end.

  1. DynamicLlamaDecoderLayer entry · level 0 · unverified · 2ee5fbf088ba5b7e
  2. LlamaMLP helper · level 1 · ran · c5d348f0b0059642
  3. LlamaRMSNorm helper · level 1 · ran · 50ff7976d78544ac
  4. Cache helper · level 0 · unverified · d866787c2702613f
  5. LlamaAttention helper · level 0 · unverified · 64c5b45fc73cecfd
  6. LlamaFlashAttention2 helper · level 0 · unverified · 58c176deebe204d2
  7. LlamaRotaryEmbedding helper · level 1 · ran · 7541f97d86797bda
  8. _get_unpad_data helper · level 1 · ran · our draft was wrong · 1df4c4c3e8d2767d
  9. apply_rotary_pos_emb helper · level 1 · ran; the contract check could not run · 0fe82a947dc39b42
  10. repeat_kv helper · level 2 · ran; the contract check could not run · 3c76e52815c5401d
  11. rotate_half helper · level 1 · ran · our draft was wrong · e03d53ba9d4f9ae5
  12. scaled_dot_product_attention_with_policy helper · level 1 · ran · our draft was wrong · bc218bfbe73e286b
  13. softmax_with_policy helper · level 1 · ran · our draft was wrong · aa7e8923d37f93a8
  14. DynamicLlamaSdpaAttention helper · level 0 · unverified · c0464d1e0119ec7f
  15. LlamaDynamicNTKScalingRotaryEmbedding helper · level 1 · ran · 68bd42b9c09a9dd1
  16. LlamaLinearScalingRotaryEmbedding helper · level 1 · ran · 1287c98591685f54

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="2412.00876") returns these assemblies with each brick's role and wiring (how to connect).

Tasks

Visual Question Answering

1 archive task tag without a task page not shown.

Results from the paper archive 2025-07-28

TaskDatasetModelMetricValueRank at snapshotLeaderboardReport
Visual Question Answering MM-Vet Dynamic-LLaVA-13B GPT-4 score 37.3 #135 of 231 Archive leaderboard report
Visual Question Answering MM-Vet Dynamic-LLaVA-7B GPT-4 score 32.2 #184 of 231 Archive leaderboard report

Ranks are positions in the archive's leaderboards as they stood at the 2025-07-28 snapshot. Results published since then are not among these rows, so a rank here is not a current standing.

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