惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

MyScale Blog
MyScale Blog
P
Privacy International News Feed
Hugging Face - Blog
Hugging Face - Blog
U
Unit 42
博客园 - 叶小钗
月光博客
月光博客
Microsoft Security Blog
Microsoft Security Blog
Apple Machine Learning Research
Apple Machine Learning Research
The Cloudflare Blog
Project Zero
Project Zero
Cisco Talos Blog
Cisco Talos Blog
The Hacker News
The Hacker News
T
Tor Project blog
阮一峰的网络日志
阮一峰的网络日志
Google DeepMind News
Google DeepMind News
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
Help Net Security
Help Net Security
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
Security Latest
Security Latest
I
Intezer
L
LINUX DO - 最新话题
Blog — PlanetScale
Blog — PlanetScale
T
The Exploit Database - CXSecurity.com
Hacker News - Newest:
Hacker News - Newest: "LLM"
酷 壳 – CoolShell
酷 壳 – CoolShell
Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
Webroot Blog
Webroot Blog
WordPress大学
WordPress大学
A
About on SuperTechFans
P
Proofpoint News Feed
T
Tailwind CSS Blog
I
InfoQ
The Register - Security
The Register - Security
cs.AI updates on arXiv.org
cs.AI updates on arXiv.org
AWS News Blog
AWS News Blog
博客园 - Franky
Simon Willison's Weblog
Simon Willison's Weblog
Last Week in AI
Last Week in AI
博客园 - 聂微东
Application and Cybersecurity Blog
Application and Cybersecurity Blog
Google Online Security Blog
Google Online Security Blog
cs.CL updates on arXiv.org
cs.CL updates on arXiv.org
Attack and Defense Labs
Attack and Defense Labs
T
Tenable Blog
大猫的无限游戏
大猫的无限游戏
K
Kaspersky official blog
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
W
WeLiveSecurity
S
Security @ Cisco Blogs
MongoDB | Blog
MongoDB | Blog

RAIS

LSTM - 长短期记忆网络 - RAIS 三种梯度下降算法的区别(BGD, SGD, MBGD) - RAIS PCA - 主成分分析法 - RAIS Sigmoid 函数 - RAIS | Blog 深度学习中的正则化(一) - RAIS | Blog 深度前馈网络 - RAIS | Blog 构建机器学习算法 - RAIS | Blog 随机梯度下降 - RAIS | Blog 无监督学习算法 - RAIS | Blog 监督学习算法 - RAIS | Blog 最大似然估计与最大后验估计 - RAIS | Blog 超参数、验证集和K-折交叉验证 - RAIS | Blog 过拟合和欠拟合 - RAIS | Blog 机器学习算法 - RAIS | Blog 深度学习中的数值计算 - RAIS | Blog 深度学习中的信息论 - RAIS | Blog 深度学习中的概率论 - RAIS | Blog 深度学习中的线性代数 - RAIS | Blog 深度学习最佳实践 - RAIS | Blog
估计、偏差和方差 - RAIS | Blog
2020-04-02 · via RAIS
  • 本文首发自公众号:RAIS

前言

本系列文章为 《Deep Learning》 读书笔记,可以参看原书一起阅读,效果更佳。

估计

统计的目的是为了推断,大量的统计是为了更好的推断,这就是一种估计,一种根据现有信息对可能性的一种猜测。

  • 点估计:点估计指的是用样本数据估计总体的参数,估计的结果是一个点的数值,因此叫做点估计。这个定义非常宽泛,$\hat{\theta}_m=g(x_1, x_2, …, x_m)$,其中几乎对 g 没有什么限制,只是说比较好的 g 会接近真实的 θ。
  • 函数估计:是一种映射关系,如 $y=f(x)+\epsilon$,其中 ϵ 是从 x 中预测不出来的,我们不关心,我们关心的是函数估计 f,函数估计是一种从输入到输出的映射关系。

偏差

估计的偏差定义为:$bias(\hat{\theta}_m)=E(\hat{\theta_m})-\theta$,这很好理解,估计与实际值之间的距离就是偏差,如果偏差为 0,则 $\hat{\theta}$是$\theta$ 的无偏估计,如果在 m 趋近于无穷大时,偏差趋近于 0,则 $\hat{\theta}$ 是 $\theta$ 的渐进无偏。

方差

上面我们用估计量的期望来计算偏差,我们还可以用估计量的方差度量估计的变化程度,我们希望期望这两个值都较小。

对于高斯分布来说,我们有:

  • 样本均值 $\hat \mu_m=\frac{1}{m}\sum_{i=1}^mx^{(i)}$ 是高斯均值参数 μ 的无偏估计;
  • 样本方差 $\hat \sigma_m^2=\frac{1}{m}\sum_{i=1}^m(x^{(i)}-\hat \mu_m)^2$ 是 $\sigma^2$ 的有偏估计;
  • 无偏样本方差 $\hat \sigma_m^2=\frac{1}{m-1}\sum_{i=1}^m(x^{(i)}-\hat \mu_m)^2$ 是 $\sigma^2$ 的无偏估计;

无偏样本方差显然是比较不错的,但是并不总是最好的,有时候某一些有偏估计也是很好的。比如在机器学习中,均值标准差就非常有用:

$$
SE(\hat \mu_m)=\sqrt{Var[\frac{1}{m}\sum_{i=1}^mx^{(i)}]}=\frac{\sigma}{\sqrt{m}}
$$

或者写成

$$
\sigma_{\overline X}=\sqrt{Var(\overline X)}=\sqrt{\frac{1}{m}Var(X)}=\frac{\sigma}{\sqrt{m}}
$$

均方误差(MSE)

$$
MSE=E[(\hat \theta_m-\mu)^2]=Bias(\hat \theta_m)^2+Var(\hat \theta_m)
$$

鱼和熊掌不可得兼,偏差和方差度量着估计量的两个不同误差来源,偏差度量着偏离真实函数或参数的误差,方差度量着数据上任意特定采样可能导致的估计期望的偏差,两个估计,一个偏差大,一个方差大,怎么选择?选择 MSE 较小的,因为 MSE 是用来度量泛化误差的。偏差和方差之和就是均方误差:

均方误差

总结

本篇主要介绍了估计、偏差和方差,可以用来正式的刻画过拟合。