Machine Learning-Andrew Ng 课程第六周——Advice for Applying Machine Learning

这一周的课程没涉及什么特别“硬”的知识,都是在说如何使学习算法表现得更好,但是这些知识也很重要,有助于提高“软”实力,特别是在调试算法的时候,尤其有帮助。

1. Learning Curve和Validation Curve

所谓的Learning Curve就是指参数theta分别在training set和validation set上的error随训练集规模变化的曲线,其他的不多说,就说一点在编程时需要注意的地方:在计算training error和validation error时, λ \lambda λ值需要设置为0。也就是说,在计算这两个error的时候,是不加正则项的,用社区助教的话来说,就是:

We want to measure the error in the hypothesis, without including any additional penalties for the theta values.
Regularization is built-in to theta when you train the system. We do not need to include it twice. When we measure J t r a i n J_{train} Jtrain, J c v J_{cv} Jcv, and J t e s t J_{test} Jtest, we want to measure the true error, without any additional penalties.

2. quiz的一道题

原题是判断对错,有一个选项比较迷,这里贴出来:

It is okay to use data from the test set to choose the regularization parameter λ, but not the model parameters.

这个选项应该是错误的。

模型参数和正则化参数 λ \lambda λ都是通过validation set选出来的。

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值