NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

More Bits Won't Fix It: Diagnosing and Treating an Ill-Conditioned Backward Pass (A Case Study on Gemma-4)

Jeong Hyun LeearXiv 2026

Imagine you’re fine-tuning a massive language model late at night. You’re using bf16 precision because, well, that’s what everyone does to save memory. But something is wrong. The model is acting erratic. You decide to do the "responsible" thing: you re-run the gradient calculation in full fp32 precision to see if rounding errors are the culprit.

To your horror, you find that in the lower layers of the model, the bf16 gradient and the fp32 gradient aren't just slightly different—they are pointing in completely different directions. They are nearly orthogonal. Your first instinct might be to reach for even more precision—maybe fp64?

This paper, a fascinating case study on Gemma-4 by Jeong Hyun Lee, MD, suggests a different path: More bits won’t fix it. Sometimes, the math itself is just having a bad day, and you need a scalpel, not a bigger hammer.

TL;DR

When fine-tuning Gemma-4 on long prompts, the backward pass becomes "ill-conditioned," causing gradients in the lower layers to collapse into noise. The authors discovered that this sensitivity is localized to specific MLP layers triggered by image tokens; by surgically "detaching" these paths during the backward pass, they achieved more stable training and better performance than even full-precision fp32 could provide.

What Problem Does This Paper Address?

The standard wisdom in deep learning is that if bf16 (16-bit brain float) gives you precision issues, you move to fp32 (32-bit float). However, the authors found a case where the backward pass—the process of calculating how to update weights—is so fragile that even the tiny rounding errors inherent in bf16 are enough to completely destroy the gradient signal in the lower third of the model.

This isn't just a theoretical curiosity. It happens specifically on long prompts (over 2,000 tokens) and is particularly severe when those prompts include images (like CT scans). If your gradients are essentially random noise, your model isn't learning; it's just vibrating.

Figure 1: Agreement between bf16 and fp32 LoRA gradients by depth. Thin lines represent individual prompts and bold lines show medians; each block spans one-sixth of the language-model layers. Short text prompts contain 200–350 tokens, and long text prompts about 2,200. The Gemma-4-12B panels use full-precision weights; the others use 4-bit NF4 weights [6] with bf16 or fp32 arithmetic (Appendix A). “SFT task” uses the training prompts from §5.

Methods

The authors acted like mathematical detectives, using several clever diagnostic tools:

  1. Noise Injection: They added tiny amounts of random noise ($10^{-6}$ to $10^{-3}$) to the hidden states during the forward pass. They found that while fp32 is a "valid" reference, it is incredibly sensitive. A noise level of $10^{-4}$—which is smaller than the typical difference between bf16 and fp32 states—was enough to make the gradient lose its mind.
  2. State Swapping: To find the "broken" part of the machine, they ran the model in fp32 but swapped in bf16 values for specific layers. This allowed them to localize the sensitivity to the MLPs of layers 19–21.
  3. The "Detach" Fix: Instead of using more bits, they implemented a "backward-only detach." They let the forward pass run normally (so the model still "sees" the data), but they stopped the gradient from flowing through those specific MLPs at image-token positions during the backward pass.

Datasets

The study primarily focused on a specialized medical task:

  • CT Lesion-Grounding: A private dataset where the model must identify the center and bounding box of a liver lesion from a CT slice.
  • Control Sets: They also tested natural photos (RealWorldQA) and long text-only prompts (~2,200 tokens) to see if the effect was unique to medical imaging (it wasn't).

Key Insights and Ideas

  • The Dominant Token Problem: In the "ill-conditioned" state, the gradient isn't a collective signal from the whole image. Instead, a single, low-information patch (like a dark corner of a CT scan) can account for over 50% of the entire gradient norm. It’s like a single loud person drowning out a whole choir.
  • Mathematical Vertigo: The paper describes the backward pass as "ill-conditioned." This means small changes in the input lead to massive, unpredictable changes in the output. In this state, the "true" gradient is so sensitive that it's practically useless for learning.
  • Surgical Intervention > Brute Force: By detaching the problematic path, the authors essentially told the model: "Don't try to learn from these specific noisy signals in these specific layers." Surprisingly, this "biased" gradient worked better than the "true" gradient.
Figure 2: (a) shows how the gradient similarity collapses as noise increases. (b) shows the localization: the disagreement starts abruptly around layers 19-21.

Key Results

The "Detach" method didn't just stabilize the model; it made it smarter:

  • Validation Loss: Improved from $0.336 \pm 0.019$ (Standard) to $0.296 \pm 0.003$ (Detach).
  • Accuracy ("In Box"): The percentage of predictions hitting the target box rose from 75% to 88%.
  • Gradient Stability: The median gradient norm plummeted from 8.5 to 0.63, and the wild "spikes" (which reached norms of 23,000+) were virtually eliminated.
  • Beating fp32: Even a run using full fp32 precision couldn't match the performance of the "Detached" bf16 run. The fp32 run still suffered from gradient spikes (max norm 39,862).
Figure 6: Training curves. The orange lines (Detach) show much faster and more consistent convergence in validation loss compared to the blue lines (Standard).

Limitations and Future Work

  • Narrow Scope: The training results are based on one specific task (CT grounding) and one model family (Gemma-4). Whether this "MLP-detaching" trick works for other architectures remains to be seen.
  • The "Why" of Qwen: Interestingly, the Qwen3.8-27B model was much less affected by this issue. The authors don't yet have a full explanation for why some models are more "sturdy" than others.
  • Biased Gradients: The authors acknowledge that the detached gradient is technically "wrong" (it's biased). However, in the messy reality of deep learning, a stable, biased gradient is often better than a "correct" one that is jumping off a cliff.

Summary updated

BibTeX
@misc{lee2026more,
  author = {Jeong Hyun Lee},
  title = {{More Bits Won't Fix It: Diagnosing and Treating an Ill-Conditioned Backward Pass (A Case Study on Gemma-4)}},
  year = {2026},
  eprint = {2611.27243},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2611.27243},
}
Figure