BEFORE THE FLIP: Measuring Hidden Score Shifts In Quantized Vision Language Models Before The Answer Changes for Visual Question Answering
Organizations: University of Maryland, Baltimore County
Abstract
Quantization makes vision language models (VLMs) cheaper to store and run by using fewer bits to represent their weights. While unchanged answers on visual question answering (VQA) after compression are an expected behavior, they can still hide changes in the underlying scores (log probabilities). For example, a model may still answer yes after compression, even as the score gap between yes and no shrinks. We introduce BEFORE THE FLIP to measure these hidden changes. Our method compares the score change caused by compression with the change caused by replacing the image's internal representations, or image tokens, with one fixed average token. We then increase the precision of one weight group at a time to identify where extra bits help, and test whether choosing different groups for each question offers benefits beyond shuffled controls. Among 8,277 LLaVA questions where image token replacement measurably affects the scores, 4-bit compression shifts the yes or no score gap farther toward the replacement output than 8-bit compression. Qwen shows the same pattern, but with a smaller difference. Yet only 265 of 9,000 LLaVA answers change at 4 bits. In a separate study of 1,024 calibration questions, choosing weight groups separately for each question does not outperform both shuffled controls at any tested storage budget. These findings show that compression can alter the scores behind unchanged answers, but do not establish a reliable benefit from adjusting precision for each question.
Figures & tables
| Weights | F1 | Acc. | Mean PRS | PRS | Response ratio | Flip match real/shuffled | |
| 8-bit | 84.811 | 86.067 | .0094 | 63.7% | 1.008 | .455/.456 | .974 |
| 4-bit | 84.722 | 85.922 | .0760 | 72.7% | 1.058 | .426/.427 | .722 |
| Setting | Acc. | PRS + | Measured loss | Bits/weight for one question | Total stored GiB |
| All weights 4-bit | 85.92 | .241 | .514 | 4.00 | 3.17 |
| All weights 8-bit | 86.07 | .032 | .076 | 8.00 | 6.33 |
| Image encoder 8-bit | 85.62 | .167 | .295 | 4.18 | 3.31 |
| Fixed 10% average token plan | 85.76 | .176 | .307 | 4.39 | 3.48 |
| Selector choice, before VCD | 85.79 | .181 | .328 | 4.38 | 3.79 |
Appendix figures & tables16 assets
Supplementary material from the paper’s appendix.
Appendix
| Questions used | Weight bits | Avg. PRS | PRS + | Positive (%) | Kept (%) |
| W8 | 0.00940 | 0.01842 | 63.73 | 91.97 | |
| W4 | 0.07596 | 0.12701 | 72.66 | 91.97 | |
| All questions | W8 | 0.00081 | 0.03247 | 62.31 | 100.00 |
| All questions | W4 | 0.04582 | 0.24101 | 70.67 | 100.00 |
| Cutoff | Bits | Random | Kept | Popular | Kept | Adversarial | Kept |
| 5th pct. ( ) | W8 | .009 | 96 | .011 | 95 | .010 | 94 |
| W4 | .062 | 96 | .077 | 95 | .064 | 94 | |
| 10th pct. ( ) | W8 | .009 | 94 | .010 | 91 | .009 | 91 |
| W4 | .061 | 94 | .091 | 91 | .076 | 91 | |
| 20th pct. ( ) | W8 | .009 | 87 | .010 | 82 | .008 | 81 |
| W4 | .059 | 87 | .082 | 82 | .072 | 81 |
| How image information is replaced | Yes (%) | F1 | W4 random | W4 popular | W4 adversarial |
| Calibration mean token | 0.6 | 1.4 | .061 | .091 | .076 |
| Per-image mean token | 2.1 | 6.2 | .066 | .091 | .081 |
| Zero tokens | 100.0 | 66.7 | .049 | .070 | .068 |
| Shuffled-image tokens | 27.8 | 64.1 | .043 | .043 | .043 |
| Uniform gray image | 0.0 | 0.0 | .004 |
| Group | Model part | Loss drop | Acc. change | Group | Model part | Loss drop | Acc. change |
| vis.13 | vision | .0316 | .20 | dec.13 | decoder | .0223 | .10 |
| vis.06 | vision | .0292 | .29 | dec.10 | decoder | .0209 | |
| dec.01 | decoder | .0249 | dec.06 | decoder | .0197 | .00 | |
| vis.08 | vision | .0239 | .68 | dec.08 | decoder | .0193 | .10 |
| vis.14 | vision | .0189 | .10 | dec.20 | decoder | ||
| dec.14 | decoder | .00 | dec.28 | decoder | .59 |
| Block | Whole block | Token mixing | FFN | Parts minus whole | Larger gain |
| dec.00 | .0087 | .0088 | attention | ||
| dec.01 | .0249 | .0275 | .0025 | FFN | |
| dec.06 | .0197 | .0217 | attention | ||
| dec.08 | .0193 | .0100 | .0082 | shared | |
| dec.10 | .0209 | .0213 | .0005 | .0009 | attention |
| dec.13 | .0223 | .0049 | .0122 | FFN |
| Extra storage (% of W4) | One fixed plan | Hindsight best | Real advantage | Shuffle A | Shuffle B | Both? |
| 5% | .2595 | 1.3561 | 1.0966 | 1.4557 | .9579 | no |
| 10% | .3067 | 1.6602 | 1.3535 | 1.6616 | 1.2309 | no |
| 15% | .3276 | 1.8734 | 1.5458 | 1.8313 | 1.4778 | no |
| How weight bits are chosen | Mean extra bytes used (% of W4) | Loss (lower is better) | Coverage (%) | Gap to hindsight | Choice |
| W4 | 0.0 | .5502 | – | – | fixed |
| Best fixed K3_P3 | 7.0 | .3557 | – | – | fixed |
| Random reassignment | 9.4 | .4075 | – | – | same frequencies |
| Distribution-distance rule | 9.4 | .4075 | 0.0 | .2229 | 100% K3_P2 |
| Linear ridge model | 9.4 | .4075 | 0.0 | .2229 | 100% K3_P2 |
| Two-layer neural net | 9.4 | .4075 | 0.0 | .2229 | 100% K3_P2 |
| Precision plan | W8 groups | Extra storage (% of W4) | Loss | PRS + | Calibration accuracy | Skill change |
| W4 | 0 | 0.0 | .6021 | .2599 | 81.2 | .05 |
| P0 (capstep01) | 1 | .2 | .5694 | .2365 | 81.4 | |
| K3_P1 | 14 | 8.3 | .4629 | .1830 | 81.4 | .34 |
| K3_P2 | 20 | 9.4 | .4297 | .1865 | 81.2 | .21 |
| K3_P3 | 23 | 7.0 | .4003 | .1679 | 80.9 |
| Storage budget per question | Selection target | W8 groups | Calculated extra storage (% of W4) | Loss |
| 5% | average-token score | 21 | 3.9 | .4165 |
| general-skill score | 22 | 4.2 | .3732 | |
| 10% | average-token score | 23 | 9.8 | .3532 |
| general-skill score | 23 | 9.8 | .3281 | |
| 15% | average-token score | 24 | 12.8 | .3257 |
| general-skill score | 25 | 13.1 | .3266 |
| Protected groups | Count | Extra storage (% of W4) | Skill score | Avg. accuracy change | Worst raw change | Resolved drops |
| W4, empty set | 0 | 0.0 | .0088 | .05 | 0 | |
| Top 1 | 1 | .2 | .0087 | 0 | ||
| Top 2 | 2 | .4 | .0086 | 0 | ||
| Top 3 | 3 | .6 | .0086 | .04 | 0 | |
| Top 4 | 4 | .7 | .0084 | .03 | 0 | |
| Top 6 | 6 | 1.1 | .0081 | .16 | 0 |
| Precision plan | F1 random | F1 popular | F1 adversarial | Accuracy | Yes (%) | PRS + | Loss | Avg. weight bits |
| 16-bit reference | 86.1 | 85.0 | 83.0 | 86.0 | 41.7 | .000 | .0000 | 16.00 |
| Uniform W8 | 86.2 | 85.2 | 83.2 | 86.1 | 41.7 | .032 | .0761 | 8.00 |
| Uniform W4 | 86.5 | 84.9 | 82.9 | 85.9 | 42.1 | .241 | .5141 | 4.00 |
| Vision encoder W8 | 86.1 | 84.6 | 82.6 | 85.6 | 42.1 | .167 | .2952 | 4.18 |
| Vision encoder + connector W8 | 86.1 | 84.6 | 82.7 | 85.7 | 42.1 | .163 | .2846 | 4.19 |
| First 8 decoder blocks W8 | 86.6 | 84.9 | 82.8 | 85.9 | 42.3 | .201 | .4577 | 4.95 |
| Precision plan | Sent. err. | Wrong obj. | Recall | Words | Obj./cap. | sent. err. [95% CI] |
| 16-bit reference | 24.0 | 6.9 | 63.5 | 49.4 | 5.04 | [ ] |
| W8 | 24.6 | 7.0 | 63.9 | 49.4 | 5.08 | [ ] |
| W4 | 24.6 | 7.3 | 61.9 | 49.6 | 4.98 | reference |
| K3_P1 | 25.0 | 7.5 | 63.2 | 49.3 | 5.08 | [ ] |
| K3_P2 | 25.2 | 7.6 | 63.1 | 49.4 | 5.10 | [ ] |
| K3_P3 | 23.2 | 6.5 | 63.1 | 49.4 | 5.08 | [ ] |
| Model | Weight bits | F1 | Avg. PRS | Image-response ratio | Matching flips | Shuffled flips | |
| LLaVA-1.5-7B | W8 | 84.81 | .00940 | 1.0078 | .4545 | .4563 | .9740 |
| W4 | 84.72 | .07596 | 1.0578 | .4264 | .4269 | .7225 | |
| Qwen2.5-VL-7B | W8 | 88.94 | .00017 | 1.0000 | .2647 | .4451 | .9980 |
| W4 | 88.62 | .01397 | .9985 | .5766 | .5372 | .1979 |
| Image correction | Accuracy | F1 | Yes (%) | Avg. PRS | PRS + | Loss |
| W4, no VCD | 85.92 | 84.72 | 42.1 | .0458 | .241 | .514 |
| 999 steps, | – | 85.74 | 48.3 | – | .987 | |
| 999 steps, | – | 84.98 | 52.1 | – | 1.889 | |
| 999 steps, | 83.19 | 84.41 | 57.8 | 1.243 | 4.122 | |
| 500 steps, | – | 84.9 | 45.4 | – | .769 | |
| 500 steps, | – | 85.1 | 48.4 | – | 1.333 |
| Precision and correction plan | Acc. | F1 | Yes | Avg. PRS | Positive | PRS + | Loss | VCD used |
| 16-bit reference | 86.0 | 84.7 | 41.7 | .000 | 0 | .000 | .000 | 0 |
| W4, no VCD | 85.9 | 84.7 | 42.1 | .046 | 71 | .241 | .514 | 0 |
| W8, no VCD | 86.1 | 84.8 | 41.7 | .001 | 62 | .032 | .076 | 0 |
| W4 + always-on VCD | 83.2 | 84.4 | 57.8 | 32 | 1.243 | 4.122 | 100 | |
| Fixed K3_P3 | 85.6 | 84.4 | 42.2 | .044 | 66 | .161 | .295 | 0 |
| Fixed K3_P3 + VCD | 83.0 | 84.3 | 57.8 | 30 | 1.236 | 4.100 | 100 |
VLM Quantization
Vision-language model quantization reduces model precision to lower memory and computation while preserving multimodal capabilities.
See all 53 papers