← ~/visualizations

machine-learning-introduction

Shows the ML pipeline as three blocky panels: a dataset (with labels y in supervised mode, no labels in unsupervised), a parameterized model f(x; θ) with learnable parameters, and an empirical risk R(θ) that training minimizes. Animation cycles between supervised and unsupervised, and within each mode it shows θ updating over time while the risk decreases.

canvasclick to interact
t=0s

practical uses

  • 01.Explain what a parameterized hypothesis f(x;θ) means before introducing specific model families (linear models, neural nets).
  • 02.Motivate training as optimization by visualizing empirical risk decreasing with parameter updates.
  • 03.Clarify the core distinction between supervised and unsupervised learning by showing how labels y change the objective.

technical notes

Pure Canvas2D, green-on-black retro grid with snapped coordinates for a blocky feel. Time-based animation uses (t/duration)%1 cycles: mode toggles every 3.6s and training progress runs on a 2.6s loop with cubic easing via ease(). Deterministic pseudo-random point placement uses a sine hash for stable visuals without external state.