Last active
January 10, 2017 09:10
Star
You must be signed in to star a gist
機械学習を1ヵ月で実践レベルにする #11 (ニューラルネットワーク #1) ref: http://qiita.com/junichiro/items/7794cedf834a4f6ef52c
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
x = | |
\begin{bmatrix} | |
x_1 \\ | |
x_2 \\ | |
x_3 | |
\end{bmatrix} | |
, | |
\theta = | |
\begin{bmatrix} | |
\theta_0 \\ | |
\theta_1 \\ | |
\theta_2 \\ | |
\theta_3 | |
\end{bmatrix} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
x = | |
\begin{bmatrix} | |
x_0 \\ | |
x_1 \\ | |
x_2 \\ | |
x_3 | |
\end{bmatrix} | |
, | |
\theta = | |
\begin{bmatrix} | |
\theta_0 \\ | |
\theta_1 \\ | |
\theta_2 \\ | |
\theta_3 | |
\end{bmatrix} | |
, | |
x_0 = 1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
h_\theta(x) = g(\theta^Tx) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
g(z) = \frac{1}{1+e^{-z}} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
a_1^{(2)} = g(\Theta_{10}^{(1)}x_0 + \Theta_{11}^{(1)}x_1 + \Theta_{12}^{(1)}x_2 + \Theta_{13}^{(1)}x_3) \\ | |
a_2^{(2)} = g(\Theta_{20}^{(1)}x_0 + \Theta_{21}^{(1)}x_1 + \Theta_{22}^{(1)}x_2 + \Theta_{23}^{(1)}x_3) \\ | |
a_3^{(2)} = g(\Theta_{30}^{(1)}x_0 + \Theta_{31}^{(1)}x_1 + \Theta_{32}^{(1)}x_2 + \Theta_{33}^{(1)}x_3) \\ | |
h_\Theta(x) = a_1^{(3)} = g(\Theta_{10}^{(2)}a_0^{(2)} + \Theta_{11}^{(2)}a_1^{(2)} + \Theta_{12}^{(2)}a_2^{(2)} + \Theta_{13}^{(2)}a_3^{(2)}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
\Theta^{(1)} = | |
\begin{bmatrix} | |
-30 & 10\\ | |
20 & -20 \\ | |
20 & -10 | |
\end{bmatrix} | |
, | |
\Theta^{(2)} = | |
\begin{bmatrix} | |
-10 \\ | |
20 \\ | |
20 | |
\end{bmatrix} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
a_1^{(2)} = g(\Theta_{10}^{(1)}x_0 + \Theta_{11}^{(1)}x_1 + \Theta_{12}^{(1)}x_2) \\ | |
a_2^{(2)} = g(\Theta_{20}^{(1)}x_0 + \Theta_{21}^{(1)}x_1 + \Theta_{22}^{(1)}x_2) \\ | |
h_\Theta(x) = a_1^{(3)} = g(\Theta_{10}^{(2)}a_0^{(2)} + \Theta_{11}^{(2)}a_1^{(2)} + \Theta_{12}^{(2)}a_2^{(2)}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
a_1^{(2)} = g(-30 + 20x_1 + 20x_2) \\ | |
a_2^{(2)} = g(10 - 20x_1 - 10x_2) \\ | |
h_\Theta(x) = a_1^{(3)} = g(-10 + \Theta_{11}^{(2)}a_1^{(2)} + \Theta_{12}^{(2)}a_2^{(2)}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment