/
nn_3in_3_h_3_out+neuralnet.tex
71 lines (53 loc) · 1.59 KB
/
nn_3in_3_h_3_out+neuralnet.tex
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
% https://newbiettn.github.io/2016/12/16/tikz/
% Unit circle
% Author: The Author
% What this does
\documentclass[landscape]{article}
\usepackage{tikz}
% DON'T FORGET TO ADD THOSE IN THE HEADER OF LATEX FILES
%\usepackage{tikz}
\usetikzlibrary{arrows,backgrounds}
\usepgflibrary{shapes.multipart}
%%%<
\usepackage{verbatim}
\usepackage[active,tightpage]{preview}
\PreviewEnvironment{tikzpicture}
\setlength\PreviewBorder{5pt}%
%%%>
\begin{comment}
:Title: the title
Describe the application
\end{comment}
\usepackage[top=1in,bottom=1in,right=1in,left=1in]{geometry}
\begin{document}
\begin{tikzpicture}
\tikzstyle{place}=[circle, draw=black, minimum size = 8mm]
% Input
\draw node at (0, -1.25) [place] (first_1) {$x^{(1)}_0$};
\draw node at (0, -2*1.25) [place] (first_2) {$x^{(1)}_1$};
\draw node at (0, -3*1.25) [place] (first_3) {$x^{(1)}_2$};
% Hidden 1
\foreach \x in {1,...,3}
\node at (4, -\x*1.25) [place] (second_\x){$a^{(2)}_\x$};
% Output
\foreach \x in {2,...,2}
\node at (8, -\x*1.25) [place] (fourth_\x){$a^{(3)}_\x$};
\foreach \x in {2,...,2}
\node at (10, -\x*1.25) [circle, ] (output_\x){$y_\x$};
% Input -> Hidden
\foreach \i in {1,...,3}
\foreach \j in {1,...,3}
\draw [->] (first_\i) to (second_\j);
% Hidden -> Output
\foreach \i in {1,...,3}
\foreach \j in {2,...,2}
\draw [->] (second_\i) to (fourth_\j);
\foreach \i in {2,...,2}
\draw [->] (fourth_\i) to (output_\i);
%Parameters theta
\node at (2, 0) [black, ] {$\Theta^{(1)}$};
\node at (6, 0) [black, ] {$\Theta^{(2)}$};
\node at (4, 0) [black, ] {$a^{(2)}$};
\node at (8, 0) [black, ] {$a^{(3)}$};
\end{tikzpicture}
\end{document}