-
Notifications
You must be signed in to change notification settings - Fork 84
Expand file tree
/
Copy pathfigure5-7-initial_gradient_values.tex
More file actions
79 lines (64 loc) · 3.81 KB
/
figure5-7-initial_gradient_values.tex
File metadata and controls
79 lines (64 loc) · 3.81 KB
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
72
73
74
75
76
77
78
79
\documentclass[border=1cm]{standalone}
\usepackage{tikz}
\usetikzlibrary{shapes.geometric, shapes.misc}
\usetikzlibrary{cd, fit, calc}
\usetikzlibrary{positioning}
\usetikzlibrary{decorations.markings}
\usepackage{medl_colors}
\begin{document}
\begin{tikzpicture}
%Nodes
\matrix[row sep=2.2cm,column sep=2cm] (m1) {
&
\node [align=center, xshift=-.5cm] (node11) {\large $\theta^{[1]}$}; &
\node [align=center, xshift=-.5cm] (node12) {\large $\theta^{[2]}$}; &
\node [align=center, xshift=-.5cm] (node13) {\large $\theta^{[L-1]}$}; &
\node [align=center, xshift=-.5cm] (node14) {\large $\theta^{[L]}$}; &
\\
\node [align=center] (node20) {\large $x = a^{[0]}$}; &
\node [align=center] (node21) {\large $a^{[1]}$}; &
\node [align=center] (node22) {\large $a^{[2]}$}; &
\node [align=center] (node23) {\large $a^{[L-1]}$}; &
\node [align=center] (node24) {\large $a^{[L]}$}; &
\\
&
\node [align=center, xshift=-.5cm] (node31) {\large $\zeta^{[1]}$}; &
\node [align=center, xshift=-.5cm] (node32) {\large $\zeta^{[2]}$}; &
\node [align=center, xshift=-.5cm] (node33) {\large $\zeta^{[L-1]}$}; &
\node [align=center, xshift=-.5cm] (node34) {\large $\zeta^{[L]}$}; &
\\
&
\node [align=center] (node41) {\large $\,\, g_{\theta}^{[1]}$}; &
\node [align=center] (node42) {\large $\,\, g_{\theta}^{[2]}$}; &
\node [align=center] (node43) {\large $\,\, g_{\theta}^{[L-1]}$}; &
\node [align=center] (node44) {\large $\,\, g_{\theta}^{[L]}$}; &
\\
};
\draw [dashed] ([xshift=.5cm]node12.east) -- ([xshift=-.5cm]node13.west) node[] {};
\draw [dashed] ([xshift=.5cm]node22.east) -- ([xshift=-.5cm]node23.west) node[] {};
\draw [dashed] ([xshift=.5cm]node32.east) -- ([xshift=-.5cm]node33.west) node[] {};
\draw [dashed] ([xshift=.5cm]node42.east) -- ([xshift=-.5cm]node43.west) node[] {};
\draw [-Triangle, thickline] ([xshift=1.8cm]node20.west) -- ([xshift=-1.2cm]node21.east);
\draw [-Triangle, thickline] ([xshift=1.1cm]node21.west) -- ([xshift=-1.1cm]node22.east);
\draw [-Triangle, thickline] ([xshift=1.4cm]node23.west) -- ([xshift=-1.4cm]node24.east);
\draw [-Triangle, thickline] ([xshift=-.5cm]node32.west) -- ([xshift=.5cm]node31.east);
\draw [-Triangle, thickline] ([xshift=-.5cm]node34.west) -- ([xshift=.5cm]node33.east);
\draw [-Triangle, thickline] ([yshift=-2mm]node11.south) -- ([yshift=2mm]node21.north);
\draw [-Triangle, thickline] ([yshift=-2mm]node12.south) -- ([yshift=2mm]node22.north);
\draw [-Triangle, thickline] ([yshift=-2mm]node13.south) -- ([yshift=2mm]node23.north);
\draw [-Triangle, thickline] ([yshift=-2mm]node14.south) -- ([yshift=2mm]node24.north);
\draw [-Triangle, thickline] ([yshift=-2mm]node31.south) -- ([yshift=2mm]node41.north);
\draw [-Triangle, thickline] ([yshift=-2mm]node32.south) -- ([yshift=2mm]node42.north);
\draw [-Triangle, thickline] ([yshift=-2mm]node33.south) -- ([yshift=2mm]node43.north);
\draw [-Triangle, thickline] ([yshift=-2mm]node34.south) -- ([yshift=2mm]node44.north);
\node[below right = .7cm and -10cm of m1, align=center] {\large Gradient Values};
\node[above right = .7cm and -10cm of m1, align=center] {\large Parameter Values};
\node[below right = 0mm and 1mm of node22, align=center] (textforward) {\large Forward};
\node[above right = 0mm and 5mm of node32, align=center] {\large Backward};
\node[rounded corners, bthickline, below right = 9mm and 1cm of node24] (nodec) {\large Loss : $C$};
\node[above left = 1.5cm and -1.85cm of nodec.west] (nodey) {\large $y, \, \hat{y}$};
\draw [-Triangle, thickline] ([yshift=-2mm]nodey.south) -- ([yshift=2mm, xshift=5mm]nodec.north);
\path (node24.east)edge [-Triangle, thickline, out=0,in=90] node [midway, anchor=center] {} (nodec.north);
\path (nodec.south)edge [-Triangle, thickline, out=270,in=0] node [midway, anchor=center] {} (node34.east);
\end{tikzpicture}
\end{document}