李宏毅2020机器学习2

10. Classification

分类应用很多,例如:
Credit scoring:Input: income, savings, profession, age, …, Output: accept or refuse
Medical Diagnosis: Input: current symptoms, age, gender, …, Output: which kind of diseases
Handwritten character recognition
Face recognition: Input: image of a face, Output: persion

10.1 Generative model 生成模型

高斯分布
贝叶斯概率
极大释然估计

11. Logistic Regression

Step 1: Function Set
f w , b ( x ) = P w , b ( C 1 ∣ x ) = σ ( z ) f_{w,b}(x)=P_{w,b}(C_1|x)=\sigma(z) fw,b(x)=Pw,b(C1x)=σ(z)
σ ( z ) = 1 1 + e − z \sigma (z) = \frac{1}{1+e^{-z}} σ(z)=1+ez1
z = w ⋅ x + b = ∑ i w i x i + b z=w \cdot x + b = \sum_i w_i x_i + b z=wx+b=iwixi+b

sigmoid 函数默认是高斯分布

Step 2: Goodness of a Function
损失函数可以判断函数的好坏

Step 3: Find the best function
梯度下降法找最佳函数

- Logistic Regression Linear Regression
Step 1 f w , b ( x ) = σ ( ∑ i w i x i + b ) Output: between 0 and 1 f_{w,b}(x)=\sigma(\sum_i w_i x_i + b) \\ \text{Output: between 0 and 1} fw,b(x)=σ(iwixi+b)Output: between 0 and 1 f w , b ( x ) = ∑ i w i x i + b Output: any value f_{w,b}(x)=\sum_i w_i x_i + b \\ \text{Output: any value} fw,b(x)=iwixi+bOutput: any value
Step 2 Training data: ( x n , y ^ n ) y ^ n : 1 for class 1, 0 for class 2 L ( f ) =
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值