引导式测验 · 中等 等级

KL 散度测验

计算位 KL 散度并推理不对称性,支持不匹配、交叉熵和参考分布方向。

相关引导路径Kl 散度
问题 1 的 8

在 D_KL(p||q) 中,哪个分布为对数比率项加权?

预览每个问题8 问题

当您参加测验时,就会出现答案和解释。

  1. 在 D_KL(p||q) 中,哪个分布为对数比率项加权?
    • p
    • q
    • Their unweighted average
    • The distribution with larger entropy
  2. 为什么 KL 散度不是普通的对称距离?
    • It can only be negative
    • Swapping p and q generally changes the value
    • It has no logarithms
    • It is always exactly one
  3. 当 p(x)>0 且 q(x)=0 时,对应的前向 KL 贡献会怎样?
    • It is always one bit
    • 就变成零了
    • 它发散至无穷大
    • It is omitted regardless of p
  4. 在公平硬币与偏置硬币的例子中,为什么某一项可以为负而整体 KL 仍保持非负?
    • The log base makes negative terms invalid
    • Every term is required to be positive
    • The formula takes an absolute value after summing
    • Individual log ratios can be negative, though the weighted total is nonnegative
  5. 使用以二为底的对数得到的单位是什么?
    • Nats
    • Bits
    • Meters
    • Percent points
  6. How does cross-entropy relate to entropy and forward KL?
    • It is always zero when q differs
    • It equals D_KL(Q||P) minus entropy
    • H(P,Q) = H(P) + D_KL(P||Q)
    • It is the reciprocal of KL
  7. In SciPy's entropy(pk, qk), what does supplying qk request?
    • A test of whether probabilities are independent
    • Only Shannon entropy of qk
    • A symmetric distance between both arrays
    • Relative entropy using pk relative to qk
  8. Which statement about continuous KL is accurate?
    • It integrates a log density ratio under P and is infinite if P puts positive mass where Q has zero density
    • It sums point probabilities at every real-valued outcome
    • It is always finite whenever both distributions have densities
    • It has no support condition for the compared distributions