Module 6. Source coding: from entropy to real bits
Choose your answers and select “Check”. Numbers accept a decimal point, comma, or simple fraction. Answers and drafts are saved in this browser and shared between RU/EN.
Checked: 0 / 29 · Correct: 0
Question 6.1.1
6.1. Engineering setup: the probabilistic model and the entropy coder
Under ideal coding of data from P using model Q, how is DKL,2(P∥Q) interpreted?
Question 6.2.1
6.2. Prefix codes and the Kraft–McMillan inequality
Which property defines a prefix code?
Question 6.2.2
6.2. Prefix codes and the Kraft–McMillan inequality
Which lengths can be the lengths of a binary prefix code?
Question 6.3.1
6.3. The one-symbol source coding theorem
What does the lower bound L≥H2(P) state for lossless coding?
Question 6.3.2
6.3. The one-symbol source coding theorem
When can a one-symbol prefix code attain L=H2(P) exactly?
Question 6.4.1
6.4. Huffman coding, arithmetic coding, and range coding
What does Huffman's algorithm optimize?
Question 6.4.2
6.4. Huffman coding, arithmetic coding, and range coding
For the binary source P=(0.99,0.01), a one-symbol binary prefix code has L=1 although H2(P)≈0.0808. Which conclusion is correct?
Question 6.4.3
6.4. Huffman coding, arithmetic coding, and range coding
What is the width of the final ideal arithmetic-coding interval for x1:n?
Question 6.4.5
6.4. Huffman coding, arithmetic coding, and range coding
Which statement about a practical range coder or ANS is most accurate?
Question 6.5.1
6.5. Long sequences: block coding, AEP, and entropy rate
What follows from encoding i.i.d. blocks of length n as supersymbols?
Question 6.5.2
6.5. Long sequences: block coding, AEP, and entropy rate
What does the AEP state for an i.i.d. source?
Question 6.5.3
6.5. Long sequences: block coding, AEP, and entropy rate
How does a typical-set code usually differ from a zero-error variable-length code?
Question 6.5.4
6.5. Long sequences: block coding, AEP, and entropy rate
Which quantity determines the asymptotic coding cost of a stationary dependent source?
Question 6.6.1
6.6. Language-model metrics: PPL, BPC, and BPB
Why can token perplexity usually not be compared directly across tokenizers?
Question 6.6.2
6.6. Language-model metrics: PPL, BPC, and BPB
Which statement about BPC and BPB is correct?
Question 6.6.3
6.6. Language-model metrics: PPL, BPC, and BPB
If a fixed text probability is merely regrouped from single tokens into pairs, without changing q(x), what happens?
Question 6.7.1
6.7. A language model as part of a compressor
Which limitation matters for the raw compression ratios reported for Chinchilla 70B by Delétang et al.?
Question 6.8.1
6.8. Model size, scaling laws, and total description length
What cannot be inferred solely from a smooth scaling-law decrease in test cross-entropy?
Question 6.8.2
6.8. Model size, scaling laws, and total description length
Which length corresponds to a self-contained two-part compressor?
Question 6.10.1
6.10. Compression quality and model capabilities
Which final statement about compression and intelligence is most defensible?
Question 6.4.4
6.4. Huffman coding, arithmetic coding, and range coding
Why is the five-bit prefix 01111 not a valid termination for [0.45,0.48)?
Question 6.5.5
6.5. Long sequences: block coding, AEP, and entropy rate
How should the Shannon–McMillan–Breiman theorem be read?
Question 6.9.1
6.9. Mathematical deepening: universal coding, online log-loss, and ICL
For a Bayesian mixture Q=∑jwjPj, what is the regret relative to model Pj on a particular sequence?
Question 6.9.2
6.9. Mathematical deepening: universal coding, online log-loss, and ICL
What is the careful connection between universal prediction and in-context learning?
Question 6.11.1
6.11. A practical protocol for evaluating an LLM as a compressor
Why must a sliding-window causal-LM evaluator count targets after the label shift?
Question 6.C.1
Computational block
For P=(0.40,0.20,0.15,0.15,0.10) an optimal Huffman code has lengths (1,3,3,3,3). Compute the expected code length in bits per symbol. (tolerance 0.005)
Question 6.C.2
Computational block
Data come from P=(0.5,0.25,0.25) but ideal fractional code lengths are built from the model Q=(0.25,0.25,0.5). Compute the expected length in bits per symbol. (tolerance 0.002)
Question 6.C.3
Computational block
With p(A)=0.5, p(B)=0.3 and p(C)=0.2, compute the ideal arithmetic-code length of the string ACB in bits. (tolerance 0.005)
Question 6.C.4
Computational block
(optional)
A Bayesian mixture assigns weight wj=1/64 to model Pj. What is the worst-case regret of the mixture relative to Pj on any sequence, in bits? (tolerance 0.005)