Covering a finite function class
Penguin learning project
The project uses 342 complete Palmer penguin records: 240 training-pool and 102 held-out rows. The selected training rows determine feature scaling and model parameters. Source CSV
This project trains weights with softmax, unlike the homepage lab, which uses nearest species averages. Same penguin measurements; different classification methods. Predictions can differ.
Generalization and risk bounds · Relate sample behavior to population risk under stated assumptions.
The project supplies finite observations and fitted parameters. A held-out sample does not establish population bounds or prove a theorem.
Consider this concept alongside the project; its source assumptions may differ. These observations do not prove a theorem.
Input: 12 × 2; Held-out evaluation: 102 · #58 · 40.6 mm, 193 mm. Known answer: Adélie; Prediction: Adélie · [≈0.7383, ≈0.2444, ≈0.01737].
Used in these source sections: 1.2 Learning from examples
Select functions as centers so that every function in the class is within distance α of a center. The covering number is the smallest number of centers that works.
The toy class has three values at one sample point: 0, 1, and 2. It enumerates every subset and uses open balls, so distance must be strictly less than α.
Covering numbers describe how many representatives are needed at a chosen accuracy.
Source formula example
exact · The search is exact only for this finite class and the displayed distance. It cannot enumerate a general infinite function class.
Symbols
- Positive ball radius.
- Distance defined using the sample S.
- A set of centers chosen from the function class.
Source formula example
This source example uses its own inputs and assumptions. Editing it does not change the project.
Edit a value or the code, then run the example. This is a finite demonstration, not a proof of the paper’s theorem.
This example’s data flow
Code changed. Reset to restore this example’s data flow.
You choose
input.radius= 0.6
Initial values in code
values=[0, 1, 2]best=null
Calculated here
Result expression: { centers: best, coveringNumber: best.length }
for (let mask = 1; mask < 8; mask++) { const centers = values.filter((_, i) => mask & (1 << i)); const covered = values.every((value) => centers.some((center) => Math.abs(value - center) < input.radius), ); if (covered && (be...Uses:values,input.radius,best
Returns
centers- array (3 items): [0, 1, 2]
coveringNumber- 3
Some runtime paths or values are not resolved here.
Read numbers from input and return the result. JavaScript basics.
Result
Technical statement
Change the input and run the same code again. The displayed result uses the values shown above.
Source: Source expression