Mohamed Dhouib, Davide Buscaldi, Sonia Vanier, Aymen Shabou, Datalab Groupe, Crédit Agricole
We lifted 2 functions out of this paper's own repositories and ran 1 of them in a sandbox. "Ran" means the function executed on a synthesized input and returned a value. It is not a reproduction of the paper's results.
| Repository | Role | Ran |
|---|---|---|
| orailix/PACT | — | 1 of 2 |
| Function | Status | Where it lives |
|---|---|---|
| normal_compute_pairwise_distances | Ran | orailix/PACT/transformers/PACT/utils.py code served (permissive licence) · get_code("3769d9961c84f781") |
| DBDPC | Not yet run | orailix/PACT/transformers/PACT/utils.py code served (permissive licence) · get_code("a6ea4ef4b9ae2205") |
Some links come from the archived Papers with Code dataset (CC BY-SA 4.0): attribution and licence.
Visual Language Models require substantial computational resources for inference due to the additional input tokens needed to represent visual information. However, these visual tokens often contain redundant and unimportant information, resulting in an unnecessarily high number of tokens. To address this, we introduce PACT, a method that reduces inference time and memory usage by pruning irrelevant tokens and merging visually redundant ones at an early layer of the language model. Our approach uses a novel importance metric to identify unimportant tokens without relying on attention scores, making it compatible with FlashAttention. We also propose a novel clustering algorithm, called Distance Bounded Density Peak Clustering, which efficiently clusters visual tokens while constraining the distances between elements within a cluster by a predefined threshold. We demonstrate the effectiveness of PACT through extensive experiments.
The same record, over MCP at https://syntology.ai/mcp:
get_harvested_code_for_paper("2504.08966")
get_code_for_paper("2504.08966")
have("2504.08966")
Connect an agent — have() is free.