KL divergence D_KL(P‖Q) = Σ p_i log(p_i/q_i) measures how much information is lost when using Q to approximate P. It is not symmetric: D_KL(P‖Q) ≠ D_KL(Q‖P). Forward KL penalizes placing zero mass where P has mass (zero-avoiding). Reverse KL causes mode-seeking. These differences matter for VAEs, RL, and distribution matching.
Part of the EngineersOfAI Interactive 3D - free interactive visualizations covering every major concept in machine learning and AI engineering. Hover any element for a plain-English explanation. No code required.