atlas

Research map / Large language models / Instruction and fine-tuning

The Fine-Grained Complexity of Gradient Computation for Training Large Language Models

NeurIPS 2024 · Large language models › Instruction and fine-tuning · approach: Efficient LLM fine-tuning systems · 1 citations (OpenAlex)

Read the paperCheck your idea against 108,967 papers

AI-extracted summary. Written by AI from the paper's full text. Numbers and claims can be wrong or missing context, so check the paper before you cite or build on it.

Shows that computing the gradient of a one-layer attention loss has the same fine-grained complexity threshold as the forward pass: near-linear time when entries are bounded by o(sqrt(log n)), and SETH-hard beyond that.

Problem

Fine-grained time complexity of the backward (gradient) computation for training attention-based LLMs, and whether it shares the forward-pass threshold on entry magnitude B.

Approach

Derives a closed-form gradient of a one-layer attention regression loss, gives an almost-linear-time algorithm via low-rank polynomial approximation of the attention matrix for B=o(sqrt(log n)), and a SETH-based lower bound for B=omega(sqrt(log n)) by reducing from forward attention hardness through a derivative-based interpolation argument.

Key results

Measured effects reported in the paper

What was changedWhereMeasuredEffect
Use low-rank approximations and tensor techniques for gradient computationAAttLGC · d = O(log n), B = o(sqrt(log n))running time: O(n^2 d^2) -> n^{1+o(1)}Helped
Increase the parameter bound to B = omega(sqrt(log n))AAttLGC · d = O(log n), assuming SETHrunning time: no algorithm running in time O(n^{2-q}) for any q>0Hurt

Limitations

Experimental setup

Metrics: running time exponent approximation error

Baselines: naive quadratic gradient computation Hessian-based Newton attention optimization

Builds on: Alman and Song 2023 forward attention complexity polynomial method SETH

Closest papers by meaning

Writing a paper in this area? scime draft is a free LaTeX editor with AI included, real-time co-authors and a check of your references and venue rules before you submit. It also imports OpenAI Prism projects.

Open scime draft

Get the next scime Dispatch and a monthly field update

Free. We send a confirmation link first; every email has a one-click unsubscribe. Privacy