LoRA parameter accounting
NumericalBeginner⏱ 15 minLLMsloraparameter countfine-tuning
Problem
For a transformer with , layers, adapting and in each layer with rank :
- Count the trainable parameters as a function of .
- Compare with full fine-tuning of those matrices, and with the full model at B parameters.
- Compute the checkpoint size for tasks at in fp16.
Compute the requested quantities and say what they mean. A number without an interpretation is not an answer.
Solution
Opening this before you have a real attempt on paper is the fastest way to feel like you understand something you cannot reproduce.
Related problems
All problems| Solved | Problem | Field | Type | Difficulty | Time |
|---|---|---|---|---|---|
| Adapter parameter counts | Fine-Tuning | Numerical | 15 min | ||
| The 6ND FLOP estimate | LLMs | Numerical | 15 min | ||
| Will this fine-tune fit? | Fine-Tuning | Numerical | 30 min | ||
| Derive the compute-optimal allocation | LLMs | Proof | 30 min | ||
| Mixture-of-experts sparsity accounting | LLMs | Numerical | 30 min |