04_Computing Parameters Analytically
Computing Parameters Analytically
Normal Equation
Normal Equation is the second way of minimizing Cost Function
Method:
explicitly taking its derivatives with respect to the θj ’s, and setting them to zero.
The normal equation formula is given below:
there is something matter Matrix Derivative
Ng’s notes
Andrew的notes的公式推导,已经将 偏导数=0 纳入考虑。
- 不同于
- 两边左乘
得到derivative, - 对两边乘上
的逆
直观理解
但是用matlab的 pinv一定能够得到,最优解(不管是否可逆
In practice, when n exceeds 10,000 it might be a good time to go from a normal solution to an iterative process.
这里可能会需要一些 矩阵论 的知识。
Normal Equation Noninvertibility
If
- Redundant features, where two features are very closely related (i.e. they are linearly dependent)
- Too many features (e.g. m ≤ n). In this case, delete some features or use “regularization” (to be explained in a later lesson).
Solutions to the above problems include deleting a feature that is linearly dependent with another or deleting one or more features when there are too many features.
- Post title: 04_Computing Parameters Analytically
- Create time: 2022-01-02 01:03:59
- Post link: Machine-Learning/04-computing-parameters-analytically/
- Copyright notice: All articles in this blog are licensed under BY-NC-SA unless stating additionally.