date: 2024-12-25
title: ML-Cheat-Sheet
status: DONE
author:
- AllenYGY
tags:
- CheatSheet
- MachineLearing
publish: true
ML-Cheat-Sheet
Basic Rules
Constant Rule:
Power Rule:
Linear Combination:
Product Rule:
Quotient Rule:
Chain Rule:
Exponential:
Logarithmic
Mean Squared Error (MSE):
Log Loss:
Adds
The probability of class
If features are conditionally independent:
Hard SVM
Hyperplane:
Constraint:
Goal:
Lagrangian:
Partial derivative:
Solution:
Lagrangian becomes:
Weight vector:
Bias:
Soft SVM
Hyperplane:
Constraint:
Goal:
Lagrangian:
Partial Derivative:
Solution:
Dual Problem:
s.t.
Weight vector:
Bias:
The reason that ξ disappears: The slack variables
By taking the derivative of the Lagrangian with respect to
Consequently, the slack variables
Kernel SVM
Hyperplane:
Constraint:
Goal:
Lagrangian (Dual):
s.t.
Weight vector:
Decision Function:
Bias:
Kernel Functions:
Linear:
Polynomial:
Gaussian (RBF):
Sigmoid:
构建似然函数:联合分布
取对数简化计算:
求导并设为 0:
验证极值:通过二阶导数等方式确保是最大值。
结合先验构建后验概率:
取对数后验函数:
求导并设为 0:
验证极值:确保找到最大值。