What is the Machine Learning?
Experience E , Task T, Performance measure P
If its performance on T as measured by P , improves with experience E。
经验 E, 任务 T, 性能度量 P。
由 P 定义的关于 T 的性能随着 E经验而提高。
Machine Learning Algorithm
- Supervised learning (监督学习, 告诉计算机什么是正确的, 什么是错误的)
- Unsupervised learning (由计算机自己学习如何正确)
- Reinforcement learning (增强学习)
- Recommender Systems (推荐系统)
Supervised Learning
“right answers” Given
Regression: Predict continuous valued output
回归问题: 预测一个连续的输出值。
Classification: Discrete valued output(0 or 1)
分类问题: 预测离散的输出值。
Unsupervised Learning
cluster 聚类.
聚类问题。
Clustering algorithm
Linear regression with one variable
Model representation
fit a model 拟合模型
···
hθ(x)=θ0+θ1x
Linear regression with one variable or univariate linear regression
单变量线性回归。
hθ(x)=θ0+θ1x
θi‘ : Parameters 模型参数。
Cost function
squared error cost function J(θ0,θ1)=12m∑mi=1(hθ(x(i)−y(i))2 minimazeθ0,θ1J(θ0,θ1)
Gradient descent
梯度下降算法, 找到
Min{J(θ0,θ1)}
Correct : Simultaneous update
Gradient descent algorithm
“Batch” : Each step of gradient descent uses all the training examples.
每一次梯度下降,都使用所有的训练集合。