M1-006M1: Mathematics & Statistics FundamentalsCommon DistributionsEasy
⚡Flashcard Drill➔Mastery:

Survey Core Discrete and Continuous Probability Distributions and Their Practical ML Use Cases

📐 Mathematical Definition
Binomial(n,p), Poisson(λ), N(μ,σ2), Beta(a,b), Gamma(α,β)\text{Binomial}(n,p),\ \text{Poisson}(\lambda),\ \mathcal N(\mu,\sigma^2),\ \text{Beta}(a,b),\ \text{Gamma}(\alpha,\beta)
⚡ One-Sentence Core Answer
Discrete distributions (Bernoulli, Binomial, Poisson, Categorical) model discrete counts and events; continuous distributions (Gaussian, Uniform, Exponential, Beta, Gamma) model continuous features, priors, and durations.

📌 Key Takeaways

  • •
    Bernoulli & Binomial: binary outcomes and independent trial counts (conversion rates, click modeling).
  • •
    Poisson: count of rare events in continuous time intervals (server request arrivals, fraud frequencies).
  • •
    Gaussian & Log-Normal: sums and products of random shocks (residual errors, user latency distributions).
  • •
    Beta & Dirichlet: conjugate priors over simplex probabilities (Bayesian bandit exploration, LDA topic modeling).

📐 Mathematical Derivations

Distribution mechanics: (1) Binomial: P(X=k)=(nk)pk(1−p)n−kP(X=k)=\binom{n}{k}p^k(1-p)^{n-k}. (2) Poisson: P(X=k)=λke−λk!P(X=k)=\frac{\lambda^k e^{-\lambda}}{k!}, derived as the continuous limit of Binomial as n→∞,p→0,np→λn\to\infty, p\to 0, np\to\lambda. (3) Gaussian: f(x)=12πσe−(x−μ)22σ2f(x)=\frac{1}{\sqrt{2\pi}\sigma}e^{-\frac{(x-\mu)^2}{2\sigma^2}}, the maximum entropy distribution given fixed mean and variance. (4) Beta: f(p;α,β)=1B(α,β)pα−1(1−p)β−1f(p; \alpha, \beta)=\frac{1}{B(\alpha, \beta)}p^{\alpha-1}(1-p)^{\beta-1}, the conjugate prior for Bernoulli trials yielding posterior Beta(α+successes,β+failures)\text{Beta}(\alpha + \text{successes}, \beta + \text{failures}).

🏭 Production Trade-offs

Selecting appropriate likelihood models directly dictates downstream loss functions: (1) Gaussian likelihood with homoscedastic variance directly implies Mean Squared Error (MSE). (2) Bernoulli likelihood yields Binary Cross-Entropy (BCE). (3) Poisson likelihood gives Poisson deviance loss for count and frequency modeling. Mis-specifying the output distribution (e.g., fitting Gaussian MSE to long-tailed response latency) causes model predictions to collapse and yield unstable gradients.
⚠️ Common Interview Pitfalls
  • ✕
    Using Gaussian MSE loss on count data with zeros, leading to negative predictions.
  • ✕
    Ignoring heavy tails in latency or financial returns by naively assuming Gaussianity.
🎯 Interviewer Follow-up Inquiries
  • ?
    Why is the Dirichlet distribution conjugate to the Multinomial / Categorical likelihood?
  • ?
    Under what scenario does a Negative Binomial distribution supersede Poisson for overdispersed counts?
⚡
Test muscle memory on this topic via 3-Layer Flashcards
Active Recall: Mentally formulate Prompt ➔ Math Derivation ➔ Benchmark Implementation in 3 minutes.
🎯 Drill This Card Now➔
📚

Associated Knowledge Base Guides & Mindmaps

Explore the comprehensive technical article, exam cards, and global architecture tree.

← PreviousM1-005: Formulate Markov's and Chebyshev's Inequalities, and Contrast Their Tightness and Applications📋Back to BankNext →M1-007: Analyze the Relationship Between the Binomial and Poisson Distributions and the Poisson Limit Theorem
中文速览与面试要点

列举常见离散/连续分布及其典型使用场景。

Bernoulli/Binomial/Poisson(离散),Uniform/Gaussian/Exponential/Beta/Gamma(连续)。

核心要点

  • 按'建模什么'分类更易记: 计数 用 Binomial(固定试验数的成功数)与 Poisson(单位时间/空间的稀有事件数); 等待时间 用 Exponential(Poisson 过程的间隔)与 Gamma(多个 Exponential 之和,即第 k 次事件的时间); 比例/概率 用 Beta([0,1] 上的分布,Bernoulli 的共轭先验); 噪声/求和 用 Gaussian(CLT 的极限); 极值 用 Gumbel/Frechet/Weibull(Fisher-Tippett 定理:极值的三种吸引子)。参数化的直觉——Beta(a,b) 中 a、b 可理解为'伪成功数'与'伪失败数',故后验更新只是把观测计数加到 a、b 上。
  • 工程上的选择往往由 共轭性与计算便利 决定,而非纯理论:① CTR/CVR 估计用 Beta-Bernoulli 共轭,使 Thompson Sampling 可直接从后验采样,无需数值积分;② 计数数据若方差远大于均值(过度离散),Poisson 不适用,应换 Negative Binomial(等价于 Gamma-Poisson 混合);③ 排序/采样的可微化需要 Gumbel-Max 技巧(argmax 采样等价于加 Gumbel 噪声后取 argmax),这是 Gumbel-Softmax 与离散潜变量 VAE 的基础。
  • Poisson 建模单位时间事件数(点击/请求)
  • Beta 是 Bernoulli 的共轭先验(CTR 平滑)
  • Gamma 是 Poisson/Exponential 率的共轭先验
  • Gumbel 出现在极值理论与 Gumbel-Softmax

常见陷阱

  • 对过度离散的计数数据仍用 Poisson
  • 混淆 Gamma(和的分布)与 Exponential(间隔的分布)