Commit cf885060 by 孟霞

合并分支 'caorunzhe' 到 'mengxia'

Caorunzhe

查看合并请求 !725
parents cdd3d463 64600e61
...@@ -36,7 +36,7 @@ ...@@ -36,7 +36,7 @@
\node [anchor=north] (enc2) at (h2.south) {\scriptsize{编码器输出}}; \node [anchor=north] (enc2) at (h2.south) {\scriptsize{编码器输出}};
\node [anchor=north] (enc22) at ([yshift=0.5em]enc2.south) {\scriptsize{(位置$2$)}}; \node [anchor=north] (enc22) at ([yshift=0.5em]enc2.south) {\scriptsize{(位置$2$)}};
\node [anchor=north] (enc4) at (h4.south) {\scriptsize{编码器输出}}; \node [anchor=north] (enc4) at (h4.south) {\scriptsize{编码器输出}};
\node [anchor=north] (enc42) at ([yshift=0.5em]enc4.south) {\scriptsize{(位置$4$)}}; \node [anchor=north] (enc42) at ([yshift=0.5em]enc4.south) {\scriptsize{(位置$m$)}};
{ {
\node [anchor=west] (math1) at ([xshift=5em,yshift=1em]th2.east) {$\mathbi{C}_j = \sum_{i} \alpha_{i,j} \mathbi{h}_i $ \ \ \ \ }; \node [anchor=west] (math1) at ([xshift=5em,yshift=1em]th2.east) {$\mathbi{C}_j = \sum_{i} \alpha_{i,j} \mathbi{h}_i $ \ \ \ \ };
......
...@@ -38,14 +38,14 @@ ...@@ -38,14 +38,14 @@
\node[elementnode,minimum size=0.6*\hnode*\c,inner sep=0.1pt,fill=blue] (a\i\j) at (0.5*\hnode*\i-5.4*0.5*\hnode,0.5*\hnode*\j-1.05*\hnode) {}; \node[elementnode,minimum size=0.6*\hnode*\c,inner sep=0.1pt,fill=blue] (a\i\j) at (0.5*\hnode*\i-5.4*0.5*\hnode,0.5*\hnode*\j-1.05*\hnode) {};
%attention score labels %attention score labels
\node[align=center] (l17) at (a17) {\scriptsize{{\color{white} .4}}}; \node[align=center,scale=0.8] (l17) at (a17) {\scriptsize{{\color{white} 0.4}}};
\node[align=center] (l26) at (a06) {\scriptsize{{\color{white} .3}}}; \node[align=center,scale=0.7] (l26) at (a06) {\tiny{{\color{white} 0.3}}};
\node[align=center] (l26) at (a16) {\scriptsize{{\color{white} .4}}}; \node[align=center,scale=0.8] (l26) at (a16) {\scriptsize{{\color{white} 0.4}}};
\node[align=center] (l17) at (a35) {\scriptsize{{\color{white} .3}}}; \node[align=center,scale=0.7] (l17) at (a35) {\tiny{{\color{white} 0.3}}};
\node[align=center] (l17) at (a34) {\tiny{{\color{white} .3}}}; \node[align=center,scale=0.7] (l17) at (a34) {\tiny{{\color{white} 0.3}}};
\node[align=center] (l17) at (a23) {\small{{\color{white} .8}}}; \node[align=center] (l17) at (a23) {\small{{\color{white} 0.8}}};
\node[align=center] (l17) at (a41) {\small{{\color{white} .8}}}; \node[align=center] (l17) at (a41) {\small{{\color{white} 0.8}}};
\node[align=center] (l17) at (a50) {\small{{\color{white} .7}}}; \node[align=center,scale=0.9] (l17) at (a50) {\small{{\color{white} 0.7}}};
% source % source
\node[srcnode] (src1) at (-5.4*0.5*\hnode,-1.05*\hnode+7.5*0.5*\hnode) {\scriptsize{Have}}; \node[srcnode] (src1) at (-5.4*0.5*\hnode,-1.05*\hnode+7.5*0.5*\hnode) {\scriptsize{Have}};
......
...@@ -30,14 +30,14 @@ ...@@ -30,14 +30,14 @@
\node[elementnode,minimum size=0.6*1.2cm*\c,inner sep=0.1pt,fill=blue] (a\i\j) at (0.5*1.2cm*\i-5.4*0.5*1.2cm,0.5*1.2cm*\j-1.05*1.2cm) {}; \node[elementnode,minimum size=0.6*1.2cm*\c,inner sep=0.1pt,fill=blue] (a\i\j) at (0.5*1.2cm*\i-5.4*0.5*1.2cm,0.5*1.2cm*\j-1.05*1.2cm) {};
%attention score labels %attention score labels
\node[align=center] (l17) at (a17) {\scriptsize{{\color{white} .4}}}; \node[align=center,scale=0.8] (l17) at (a17) {\scriptsize{{\color{white} 0.4}}};
\node[align=center] (l26) at (a06) {\scriptsize{{\color{white} .3}}}; \node[align=center,scale=0.8] (l26) at (a06) {\scriptsize{{\color{white} 0.3}}};
\node[align=center] (l26) at (a16) {\scriptsize{{\color{white} .4}}}; \node[align=center,scale=0.8] (l26) at (a16) {\scriptsize{{\color{white} 0.4}}};
\node[align=center] (l17) at (a35) {\scriptsize{{\color{white} .3}}}; \node[align=center,scale=0.8] (l17) at (a35) {\scriptsize{{\color{white} 0.3}}};
\node[align=center] (l17) at (a34) {\tiny{{\color{white} .3}}}; \node[align=center,scale=0.8] (l17) at (a34) {\scriptsize{{\color{white} 0.3}}};
\node[align=center] (l17) at (a23) {\small{{\color{white} .8}}}; \node[align=center] (l17) at (a23) {\small{{\color{white} 0.8}}};
\node[align=center] (l17) at (a41) {\small{{\color{white} .8}}}; \node[align=center] (l17) at (a41) {\small{{\color{white} 0.8}}};
\node[align=center] (l17) at (a50) {\small{{\color{white} .7}}}; \node[align=center] (l17) at (a50) {\small{{\color{white} 0.7}}};
% source % source
\node[srcnode] (src1) at (-5.4*0.5*1.2cm,-1.05*1.2cm+7.5*0.5*1.2cm) {\scriptsize{Have}}; \node[srcnode] (src1) at (-5.4*0.5*1.2cm,-1.05*1.2cm+7.5*0.5*1.2cm) {\scriptsize{Have}};
......
...@@ -2,11 +2,11 @@ ...@@ -2,11 +2,11 @@
\tikzstyle{node} =[font=\scriptsize] \tikzstyle{node} =[font=\scriptsize]
\tikzstyle{sentence} =[font=\scriptsize,fill=blue!5!white] \tikzstyle{sentence} =[font=\scriptsize,fill=blue!5!white]
\node[sentence] (node1) at (0,0) {[`low', `lower', `newest', `widest']}; \node[sentence] (node1) at (0,0) {['low', 'lower', 'newest', 'widest']};
\node[sentence,anchor = north] (node2) at ([yshift = -1em]node1.south) {[`l o w $<$e$>$':5, `l o w e r $<$e$>$':2, `n e w e s t $<$e$>$':6, `w i d e s t $<$e$>$':3]}; \node[sentence,anchor = north] (node2) at ([yshift = -1em]node1.south) {['l o w $<$e$>$':5, 'l o w e r $<$e$>$':2, 'n e w e s t $<$e$>$':6, 'w i d e s t $<$e$>$':3]};
\node[sentence,anchor = north] (node3) at ([yshift = -1.5em]node2.south) {[`l o w $<$e$>$':5, `l o w e r $<$e$>$':2, `n e w {\red es} t $<$e$>$':6, `w i d {\red es} t $<$e$>$':3]}; \node[sentence,anchor = north] (node3) at ([yshift = -1.5em]node2.south) {['l o w $<$e$>$':5, 'l o w e r $<$e$>$':2, 'n e w {\red es} t $<$e$>$':6, 'w i d {\red es} t $<$e$>$':3]};
\node[sentence,anchor = north] (node4) at ([yshift = -1em]node3.south) {[`l o w $<$e$>$':5, `l o w e r $<$e$>$':2, `n e w {\red est} $<$e$>$':6, `w i d {\red est} $<$e$>$':3]}; \node[sentence,anchor = north] (node4) at ([yshift = -1em]node3.south) {['l o w $<$e$>$':5, 'l o w e r $<$e$>$':2, 'n e w {\red est} $<$e$>$':6, 'w i d {\red est} $<$e$>$':3]};
\node[sentence,anchor = north] (node5) at ([yshift = -1em]node4.south) {[`l o w $<$e$>$':5, `l o w e r $<$e$>$':2, `n e w {\red est$<$e$>$}':6, `w i d {\red est$<$e$>$}':3]}; \node[sentence,anchor = north] (node5) at ([yshift = -1em]node4.south) {['l o w $<$e$>$':5, 'l o w e r $<$e$>$':2, 'n e w {\red est$<$e$>$}':6, 'w i d {\red est$<$e$>$}':3]};
\node[sentence,anchor = north] (node6) at ([yshift = -1em]node5.south) {$\cdots$}; \node[sentence,anchor = north] (node6) at ([yshift = -1em]node5.south) {$\cdots$};
\node[node,anchor = north] (node7) at ([yshift = -1.6em]node6.south) {直到达到预设的子词词表大小或下一个最高频的字节对出现频率为1。}; \node[node,anchor = north] (node7) at ([yshift = -1.6em]node6.south) {直到达到预设的子词词表大小或下一个最高频的字节对出现频率为1。};
......
...@@ -14,7 +14,7 @@ ...@@ -14,7 +14,7 @@
\node [neuronnode] (neuron_z) at (1.2 * \nodespace,-1.5 * \neuronsep) {\scriptsize{$z_{i}^{l+1}$}}; \node [neuronnode] (neuron_z) at (1.2 * \nodespace,-1.5 * \neuronsep) {\scriptsize{$z_{i}^{l+1}$}};
\node [neuronnode] (neuron_y') at (2.4 * \nodespace,-1.5 * \neuronsep) {\scriptsize{$x_{i}^{l+1}$}}; \node [neuronnode] (neuron_y') at (2.4 * \nodespace,-1.5 * \neuronsep) {\scriptsize{$x_{i}^{l+1}$}};
\node [anchor=north,ublue] (standard) at ([yshift=-4em]neuron_z.south) {\scriptsize{standard}}; \node [anchor=north,ublue] (standard) at ([yshift=-4em]neuron_z.south) {\scriptsize{标准网络}};
\node [ublue] (standard) at ([xshift=-1em]neuron_z.west) {\scriptsize{$\mathbf{w}_{i}^{l}$}}; \node [ublue] (standard) at ([xshift=-1em]neuron_z.west) {\scriptsize{$\mathbf{w}_{i}^{l}$}};
\node [ublue] (standard) at ([xshift=0.6em,yshift=0.3em]neuron_z.east) {\scriptsize{$f$}}; \node [ublue] (standard) at ([xshift=0.6em,yshift=0.3em]neuron_z.east) {\scriptsize{$f$}};
...@@ -40,7 +40,7 @@ ...@@ -40,7 +40,7 @@
\node [neuronnode] (drop_neuron_r2) at (4.4*\nodespace,-1.5*\neuronsep) {\scriptsize{$r_{2}^{l}$}}; \node [neuronnode] (drop_neuron_r2) at (4.4*\nodespace,-1.5*\neuronsep) {\scriptsize{$r_{2}^{l}$}};
\node [neuronnode] (drop_neuron_r1) at (4.4*\nodespace,-2.5*\neuronsep) {\scriptsize{$r_{1}^{l}$}}; \node [neuronnode] (drop_neuron_r1) at (4.4*\nodespace,-2.5*\neuronsep) {\scriptsize{$r_{1}^{l}$}};
\node [anchor=north,ublue] (standard) at ([yshift=-4em]drop_neuron_z.south) {\scriptsize{dropout}}; \node [anchor=north,ublue] (standard) at ([xshift=2em,yshift=-4em]drop_neuron_z.south) {\scriptsize{应用Dropout后的网络}};
\node [ublue] (standard) at ([xshift=-1em]drop_neuron_z.west) {\scriptsize{$\mathbf{w}_{i}^{l}$}}; \node [ublue] (standard) at ([xshift=-1em]drop_neuron_z.west) {\scriptsize{$\mathbf{w}_{i}^{l}$}};
\node [ublue] (standard) at ([xshift=0.6em,yshift=0.3em]drop_neuron_z.east) {\scriptsize{$f$}}; \node [ublue] (standard) at ([xshift=0.6em,yshift=0.3em]drop_neuron_z.east) {\scriptsize{$f$}};
%structure %structure
...@@ -59,10 +59,10 @@ ...@@ -59,10 +59,10 @@
\draw [-,line width=0.3mm] (drop_neuron_r1.south) -- ([yshift=-1em]drop_neuron_r1.south); \draw [-,line width=0.3mm] (drop_neuron_r1.south) -- ([yshift=-1em]drop_neuron_r1.south);
%equ %equ
\node [anchor=west,inner sep = 2pt] (line1) at (9*\nodespace,0) {未应用dropout:}; \node [anchor=west,inner sep = 2pt] (line1) at (9*\nodespace,0) {未应用Dropout:};
\node [anchor=north west,inner sep = 2pt] (line2) at (line1.south west) {$z_{i}^{l+1}=\mathbf{w}_{i}^{l} \mathbf{x}+b_{i}^{l}$}; \node [anchor=north west,inner sep = 2pt] (line2) at (line1.south west) {$z_{i}^{l+1}=\mathbf{w}_{i}^{l} \mathbf{x}+b_{i}^{l}$};
\node [anchor=north west,inner sep = 2pt] (line3) at (line2.south west) {$x_{i}^{l+1}=f\left(x_{i}^{l}\right)$}; \node [anchor=north west,inner sep = 2pt] (line3) at (line2.south west) {$x_{i}^{l+1}=f\left(x_{i}^{l}\right)$};
\node [anchor=north west,inner sep = 2pt] (line4) at (line3.south west) {应用dropout:}; \node [anchor=north west,inner sep = 2pt] (line4) at (line3.south west) {应用Dropout:};
\node [anchor=north west,inner sep = 2pt] (line5) at (line4.south west) {$r_{j}^{l} \sim$ Bernoulli $(1-p)$}; \node [anchor=north west,inner sep = 2pt] (line5) at (line4.south west) {$r_{j}^{l} \sim$ Bernoulli $(1-p)$};
\node [anchor=north west,inner sep = 2pt] (line6) at (line5.south west) {$\tilde{\mathbf{x}}=\mathbf{r} * \mathbf{x}$}; \node [anchor=north west,inner sep = 2pt] (line6) at (line5.south west) {$\tilde{\mathbf{x}}=\mathbf{r} * \mathbf{x}$};
\node [anchor=north west,inner sep = 2pt] (line7) at (line6.south west) {$z_{i}^{l+1}=\mathbf{w}_{i}^{l} \widetilde{\mathbf{x}}+b_{i}^{l}$}; \node [anchor=north west,inner sep = 2pt] (line7) at (line6.south west) {$z_{i}^{l+1}=\mathbf{w}_{i}^{l} \widetilde{\mathbf{x}}+b_{i}^{l}$};
......
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
\setlength{\YShift}{0.8\base} \setlength{\YShift}{0.8\base}
\setlength{\XShift}{0.8\base} \setlength{\XShift}{0.8\base}
\tikzstyle{modelnode} = [rectangle,draw,rounded corners=2pt,inner sep=0pt,minimum height=4.2em,minimum width=2em,font=\small,anchor=north] \tikzstyle{modelnode} = [rectangle,draw,rounded corners=2pt,inner sep=0pt,minimum height=4.5em,minimum width=2em,font=\small,anchor=north]
\coordinate (stu01) at (0,0); \coordinate (stu01) at (0,0);
\coordinate (stu02) at ([xshift=3em]stu01); \coordinate (stu02) at ([xshift=3em]stu01);
...@@ -20,27 +20,27 @@ ...@@ -20,27 +20,27 @@
\foreach \curr / \prev in {1/0,2/1,3/2} \foreach \curr / \prev in {1/0,2/1,3/2}
{ {
% models % models
\node[modelnode,fill=yellow!20] (stu\curr1) at ([yshift=-2em]stu\prev1.south) {\rotatebox{90}{Student $1$}}; \node[modelnode,fill=yellow!20] (stu\curr1) at ([yshift=-2em]stu\prev1.south) {\rotatebox{90}{学生模型 $1$}};
\node[modelnode,fill=yellow!20] (stu\curr2) at ([yshift=-2em]stu\prev2.south) {\rotatebox{90}{Student $2$}}; \node[modelnode,fill=yellow!20] (stu\curr2) at ([yshift=-2em]stu\prev2.south) {\rotatebox{90}{学生模型 $2$}};
\node[modelnode,fill=yellow!20] (stu\curr3) at ([yshift=-2em]stu\prev3.south) {\rotatebox{90}{Student $3$}}; \node[modelnode,fill=yellow!20] (stu\curr3) at ([yshift=-2em]stu\prev3.south) {\rotatebox{90}{学生模型 $3$}};
\node[modelnode,fill=yellow!20] (stu\curr4) at ([yshift=-2em]stu\prev4.south) {\rotatebox{90}{Student $4$}}; \node[modelnode,fill=yellow!20] (stu\curr4) at ([yshift=-2em]stu\prev4.south) {\rotatebox{90}{学生模型 $4$}};
\node[modelnode,fill=yellow!20] (stu\curr5) at ([yshift=-2em]stu\prev5.south) {\rotatebox{90}{Student $5$}}; \node[modelnode,fill=yellow!20] (stu\curr5) at ([yshift=-2em]stu\prev5.south) {\rotatebox{90}{学生模型 $5$}};
\node[modelnode] (tea\curr1) at ([yshift=-2em]tea\prev1.south) {\rotatebox{90}{\color{red!60} Teacher $1$}}; \node[modelnode] (tea\curr1) at ([yshift=-2em]tea\prev1.south) {\rotatebox{90}{\color{red!60} 教师模型 $1$}};
\node[modelnode] (tea\curr2) at ([yshift=-2em]tea\prev2.south) {\rotatebox{90}{\color{blue!60} Teacher $2$}}; \node[modelnode] (tea\curr2) at ([yshift=-2em]tea\prev2.south) {\rotatebox{90}{\color{blue!60} 教师模型 $2$}};
% ensemble labels % 集成 labels
\draw[-latex'] ([xshift=2pt]stu\curr5.east) to node [auto] {\small Ensemble} ([xshift=-2pt]tea\curr1.west); \draw[-latex'] ([xshift=2pt]stu\curr5.east) to node [auto] {\small 集成} ([xshift=-2pt]tea\curr1.west);
} }
% iteration labels % iteration labels
\node[font=\small,anchor=east,purple!80] (iterate1) at ([xshift=-1em]stu21.west) {\rotatebox{90}{Iteration $1$}}; \node[font=\small,anchor=east,purple!80] (iterate1) at ([xshift=-1em]stu21.west) {\rotatebox{90}{轮数 $1$}};
\node[font=\small,anchor=east,purple!80] (iterate2) at ([xshift=-1em]stu31.west) {\rotatebox{90}{Iteration $2$}}; \node[font=\small,anchor=east,purple!80] (iterate2) at ([xshift=-1em]stu31.west) {\rotatebox{90}{轮数 $2$}};
% distillation labels % distillation labels
\node[font=\small,anchor=south west] (distill1) at ([yshift=0.2em]iterate1.north west) {Distillation}; \node[font=\small,anchor=south west] (distill1) at ([yshift=0.8em]iterate1.north west) {知识蒸馏};
\node[font=\small,anchor=south west] (distill2) at ([yshift=0.2em]iterate2.north west) {Distillation}; \node[font=\small,anchor=south west] (distill2) at ([yshift=0.8em]iterate2.north west) {知识蒸馏};
% student groups % 学生模型 groups
\begin{pgfonlayer}{background} \begin{pgfonlayer}{background}
\node[rectangle,draw,very thick,red!60,densely dotted,inner sep=2pt,rounded corners=2pt,fill=red!20] [fit = (stu21) (stu22) (stu23) ] (group21) {}; \node[rectangle,draw,very thick,red!60,densely dotted,inner sep=2pt,rounded corners=2pt,fill=red!20] [fit = (stu21) (stu22) (stu23) ] (group21) {};
\node[rectangle,draw,very thick,blue!60,densely dotted,inner sep=2pt,rounded corners=2pt,fill=blue!20] [fit = (stu24) (stu25) ] (group22) {}; \node[rectangle,draw,very thick,blue!60,densely dotted,inner sep=2pt,rounded corners=2pt,fill=blue!20] [fit = (stu24) (stu25) ] (group22) {};
......
\begin{tikzpicture} \begin{tikzpicture}
\node[font=\scriptsize] (model) at (0,0) {Model Output:}; \node[font=\scriptsize,align=left] (model) at (0,0) {模型输出:\\(未使用\\标签平滑)};
\node[anchor=north west,font=\scriptsize] (label_smooth) at ([yshift=-1.8em]model.south west) {Label Smoothing:}; \node[anchor=north west,font=\scriptsize,align=left] (label_smooth) at ([yshift=-0.3em]model.south west) {模型输出:\\(使用标\\签平滑)};
\node[anchor=south west,font=\scriptsize] (one-hot) at ([yshift=2em]model.north west) {One-hot:}; \node[anchor=south west,font=\scriptsize] (one-hot) at ([yshift=1em]model.north west) {One-hot分布:};
%model out %model out
\node [anchor=west,minimum width=1.2em,minimum height=0.2em,fill=ublue!80,inner sep=0pt] (model_label1) at ([xshift=1.5em,yshift=-0.5em]model.east) {}; \node [anchor=west,minimum width=1.2em,minimum height=0.2em,fill=ublue!80,inner sep=0pt] (model_label1) at ([xshift=1.5em,yshift=-0.8em]model.east) {};
\node [anchor=south,font=\scriptsize] (model_w1) at (model_label1.north) {$p_{1}$}; \node [anchor=south,font=\scriptsize] (model_w1) at (model_label1.north) {$p_{1}$};
\node [anchor=south west,minimum width=1.2em,minimum height=0.1em,fill=ublue!80,inner sep=0pt] (model_label2) at (model_label1.south east) {}; \node [anchor=south west,minimum width=1.2em,minimum height=0.1em,fill=ublue!80,inner sep=0pt] (model_label2) at (model_label1.south east) {};
\node [anchor=south,font=\scriptsize] (model_w2) at (model_label2.north) {$p_{2}$}; \node [anchor=south,font=\scriptsize] (model_w2) at (model_label2.north) {$p_{2}$};
...@@ -21,7 +21,7 @@ ...@@ -21,7 +21,7 @@
\node [anchor=south west,minimum width=1.2em,minimum height=0.2em,fill=ublue!80,inner sep=0pt] (model_label7) at (model_label6.south east) {}; \node [anchor=south west,minimum width=1.2em,minimum height=0.2em,fill=ublue!80,inner sep=0pt] (model_label7) at (model_label6.south east) {};
\node [anchor=south,font=\scriptsize] (model_w8) at (model_label7.north) {$p_{7}$}; \node [anchor=south,font=\scriptsize] (model_w8) at (model_label7.north) {$p_{7}$};
%no label smooth %no label smooth
\node [anchor=west,minimum width=1.2em,minimum height=0.05em,fill=orange!50,inner sep=0pt,font=\tiny] (one_hot_label1) at ([xshift=1.5em,yshift=3em]model.east) {}; \node [anchor=west,minimum width=1.2em,minimum height=0.05em,fill=orange!50,inner sep=0pt,font=\tiny] (one_hot_label1) at ([xshift=1.5em,yshift=2.5em]model.east) {};
\node [anchor=south,font=\scriptsize] (one_hot_w1) at (one_hot_label1.north) {$0$}; \node [anchor=south,font=\scriptsize] (one_hot_w1) at (one_hot_label1.north) {$0$};
\node [anchor=south west,minimum width=1.2em,minimum height=0.05em,fill=orange!50,inner sep=0pt,font=\tiny] (one_hot_label2) at (one_hot_label1.south east) {}; \node [anchor=south west,minimum width=1.2em,minimum height=0.05em,fill=orange!50,inner sep=0pt,font=\tiny] (one_hot_label2) at (one_hot_label1.south east) {};
\node [anchor=south,font=\scriptsize] (one_hot_w2) at (one_hot_label2.north) {$0$}; \node [anchor=south,font=\scriptsize] (one_hot_w2) at (one_hot_label2.north) {$0$};
...@@ -38,7 +38,7 @@ ...@@ -38,7 +38,7 @@
\node [anchor=south,font=\scriptsize] (one_hot_w7) at (one_hot_label7.north) {$0$}; \node [anchor=south,font=\scriptsize] (one_hot_w7) at (one_hot_label7.north) {$0$};
%label smoothing %label smoothing
\node [anchor=west,minimum width=1.2em,minimum height=0.2em,fill=red!50,inner sep=0pt] (label1) at ([xshift=1.5em,yshift=-3.2em]model.east) {}; \node [anchor=west,minimum width=1.2em,minimum height=0.2em,fill=red!50,inner sep=0pt] (label1) at ([xshift=1.5em,yshift=-4.4em]model.east) {};
\node [anchor=south,font=\scriptsize] (w1) at (label1.north) {$0.1$}; \node [anchor=south,font=\scriptsize] (w1) at (label1.north) {$0.1$};
\node [anchor=south west,minimum width=1.2em,minimum height=0.2em,fill=red!50,inner sep=0pt] (label2) at (label1.south east) {}; \node [anchor=south west,minimum width=1.2em,minimum height=0.2em,fill=red!50,inner sep=0pt] (label2) at (label1.south east) {};
\node [anchor=south,font=\scriptsize] (w2) at (label2.north) {$0.1$}; \node [anchor=south,font=\scriptsize] (w2) at (label2.north) {$0.1$};
...@@ -55,18 +55,18 @@ ...@@ -55,18 +55,18 @@
\node [anchor=south,font=\scriptsize] (w8) at (label7.north) {$0.1$}; \node [anchor=south,font=\scriptsize] (w8) at (label7.north) {$0.1$};
\node[font=\scriptsize] (line1) at ([xshift=9em,yshift=-1.5em]model_label7.east) {$loss =-0.3 \log p_{3}-\sum_{i=1}^{7} 0.1 \log p_{i}$}; \node[font=\scriptsize] (line1) at ([xshift=9em,yshift=-1.5em]model_label7.east) {$Loss =-0.3 \log p_{3}-\sum_{i=1}^{7} 0.1 \log p_{i}$};
\node[font=\scriptsize] (line2) at ([xshift=5.9em,yshift=3.5em]model_label7.east) {$loss =-\log p_{3}$}; \node[font=\scriptsize] (line2) at ([xshift=5.9em,yshift=3em]model_label7.east) {$Loss =-\log p_{3}$};
\begin{pgfonlayer}{background} \begin{pgfonlayer}{background}
\node [rectangle,inner sep=0.1em,rounded corners=1pt,very thick,dotted,draw=red] [fit = (one_hot_label1) (one_hot_w3) (one_hot_label7) (model_label1) (model_label7)] (box1) {}; \node [rectangle,inner sep=0.5em,rounded corners=1pt,very thick,dotted,draw=red] [fit =(model_w3) (model_label1) (model_label7)] (box1) {};
\node [rectangle,inner sep=0.2em,rounded corners=1pt,fill=purple!10,drop shadow,draw=purple] [fit = (line2)] (box3) {}; \node [rectangle,inner sep=0.2em,rounded corners=1pt,fill=purple!10,drop shadow,draw=purple] [fit = (line2)] (box3) {};
\draw [->,dotted,very thick,red] ([yshift=-1em]box1.east) .. controls +(east:1) and +(west:1) .. (box3.west); \draw [->,dotted,very thick,red] ([yshift=-0.5em]box1.east) .. controls +(east:1) and +(west:1) .. (box3.west);
\node [rectangle,inner sep=0.1em,rounded corners=1pt,very thick,dotted,draw=ugreen] [fit = (label1) (label7) (model_label1) (model_label7) (model_w3)] (box2) {}; \node [rectangle,inner sep=0.5em,rounded corners=1pt,very thick,dotted,draw=ugreen] [fit =(w3) (label1) (label7) ] (box2) {};
\node [rectangle,inner sep=0.2em,rounded corners=1pt,fill=green!10,drop shadow,draw=ugreen] [fit = (line1)] (box4) {}; \node [rectangle,inner sep=0.2em,rounded corners=1pt,fill=green!10,drop shadow,draw=ugreen] [fit = (line1)] (box4) {};
\draw [->,dotted,very thick,ugreen] ([yshift=1em]box2.east) .. controls +(east:1) and +(west:1) .. (box4.west); \draw [->,dotted,very thick,ugreen] ([yshift=-0.5em]box2.east) .. controls +(east:1) and +(west:1) .. (box4.west);
\end{pgfonlayer} \end{pgfonlayer}
......
%%% outline
%-------------------------------------------------------------------------
\begin{tikzpicture}
\tikzstyle{opt}=[draw,minimum height=2em,minimum width=4em,rounded corners=2pt,thick]
\node[circle,minimum size=2em,draw,fill=red!20] (x1) at (0,0) {\small\bfnew{X}};
\node[circle,minimum size=2em,draw,fill=red!20] (x2) at (0,4em) {\small\bfnew{X}};
\node[circle,minimum size=2em,draw,fill=red!20] (x3) at (0,-5em) {\small\bfnew{X}};
\node[anchor=west,opt,fill=yellow!20] (unary1) at ([xshift=3em]x1.east){\small\bfnew{Unary}};
\node[anchor=west,opt,fill=yellow!20] (unary2) at ([xshift=3em]x2.east){\small\bfnew{Unary}};
\node[opt,fill=blue!20] (binary1) at (12em,2em){\small\bfnew{Binary}};
\node[opt,fill=blue!20] (binary2) at (25em,-1.5em){\small\bfnew{Binary}};
\node[anchor=west,opt,fill=yellow!20] (unary3) at ([xshift=3em]binary1.east){\small\bfnew{Unary}};
\node[anchor=west,opt,fill=yellow!20] (unary4) at ([xshift=16em]x3.east){\small\bfnew{Unary}};
\draw[-latex,very thick] (x1.0) -- (unary1.180);
\draw[-latex,very thick] (x2.0) -- (unary2.180);
\draw[-latex,very thick] (x3.0) -- (unary4.180);
\draw[-latex,very thick] (unary1.0) -- ([yshift=-0.2em]binary1.180);
\draw[-latex,very thick] (unary2.0) -- ([yshift=0.2em]binary1.180);
\draw[-latex,very thick] (binary1.0) -- (unary3.180);
\draw[-latex,very thick] (unary3.0) -- ([yshift=0.2em]binary2.180);
\draw[-latex,very thick] (unary4.0) -- ([yshift=-0.2em]binary2.180);
\begin{pgfonlayer}{background}
\node[draw=lightgray,fill=lightgray!50,rounded corners=2pt,inner sep=8pt][fit=(x2)(x1)(binary1)]{};
\end{pgfonlayer}
\node[anchor=south] at ([yshift=1em]binary1.north){\small\bfnew{Core Unit}};
\end{tikzpicture}
...@@ -3,22 +3,22 @@ ...@@ -3,22 +3,22 @@
%left %left
\begin{scope} \begin{scope}
\foreach \x/\d in {1/2em, 2/8em, 3/18em, 4/24em} \foreach \x/\d in {1/2em, 2/8em}
\node[unit,fill=yellow!20] at (0,\d) (ln_\x) {层正则}; \node[unit,fill=yellow!20] at (0,\d) (ln_\x) {层正则};
\foreach \x/\d in {1/4em, 2/20em} \foreach \x/\d in {1/4em}
\node[unit,fill=green!20] at (0,\d) (sa_\x) {8头自注意力:512}; \node[unit,fill=green!20] at (0,\d) (sa_\x) {8头自注意力:512};
\foreach \x/\d in {1/6em, 2/16em, 3/22em, 4/32em} \foreach \x/\d in {1/6em, 2/16em}
\node[draw,circle,minimum size=1em,inner sep=1pt] at (0,\d) (add_\x) {\scriptsize\bfnew{+}}; \node[draw,circle,minimum size=1em,inner sep=1pt] at (0,\d) (add_\x) {\scriptsize\bfnew{+}};
\foreach \x/\d in {2/14em, 4/30em} \foreach \x/\d in {2/14em}
\node[unit,fill=red!20] at (0,\d) (conv_\x) {卷积$1 \times 1$:512}; \node[unit,fill=red!20] at (0,\d) (conv_\x) {卷积$1 \times 1$:512};
\foreach \x/\d in {1/10em,3/26em} \foreach \x/\d in {1/10em}
\node[unit,fill=red!20] at (0,\d) (conv_\x) {卷积$1 \times 1$:2048}; \node[unit,fill=red!20] at (0,\d) (conv_\x) {卷积$1 \times 1$:2048};
\foreach \x/\d in {1/12em, 2/28em} \foreach \x/\d in {1/12em}
\node[unit,fill=blue!20] at (0,\d) (relu_\x) {RELU}; \node[unit,fill=blue!20] at (0,\d) (relu_\x) {RELU};
\draw[->,thick] ([yshift=-1.4em]ln_1.-90) -- ([yshift=-0.1em]ln_1.-90); \draw[->,thick] ([yshift=-1.4em]ln_1.-90) -- ([yshift=-0.1em]ln_1.-90);
...@@ -29,80 +29,55 @@ ...@@ -29,80 +29,55 @@
\draw[->,thick] ([yshift=0.1em]conv_1.90) -- ([yshift=-0.1em]relu_1.-90); \draw[->,thick] ([yshift=0.1em]conv_1.90) -- ([yshift=-0.1em]relu_1.-90);
\draw[->,thick] ([yshift=0.1em]relu_1.90) -- ([yshift=-0.1em]conv_2.-90); \draw[->,thick] ([yshift=0.1em]relu_1.90) -- ([yshift=-0.1em]conv_2.-90);
\draw[->,thick] ([yshift=0.1em]conv_2.90) -- ([yshift=-0.1em]add_2.-90); \draw[->,thick] ([yshift=0.1em]conv_2.90) -- ([yshift=-0.1em]add_2.-90);
\draw[->,thick] ([yshift=0.1em]add_2.90) -- ([yshift=-0.1em]ln_3.-90); \draw[->,thick] ([yshift=0.1em]add_2.90) -- ([yshift=1em]add_2.90);
\draw[->,thick] ([yshift=0.1em]ln_3.90) -- ([yshift=-0.1em]sa_2.-90);
\draw[->,thick] ([yshift=0.1em]sa_2.90) -- ([yshift=-0.1em]add_3.-90);
\draw[->,thick] ([yshift=0.1em]add_3.90) -- ([yshift=-0.1em]ln_4.-90);
\draw[->,thick] ([yshift=0.1em]ln_4.90) -- ([yshift=-0.1em]conv_3.-90);
\draw[->,thick] ([yshift=0.1em]conv_3.90) -- ([yshift=-0.1em]relu_2.-90);
\draw[->,thick] ([yshift=0.1em]relu_2.90) -- ([yshift=-0.1em]conv_4.-90);
\draw[->,thick] ([yshift=0.1em]conv_4.90) -- ([yshift=-0.1em]add_4.-90);
\draw[->,thick] ([yshift=0.1em]add_4.90) -- ([yshift=1em]add_4.90);
\draw[->,thick] ([yshift=-0.8em]ln_1.-90) .. controls ([xshift=5em,yshift=-0.8em]ln_1.-90) and ([xshift=5em]add_1.0) .. (add_1.0); \draw[->,thick] ([yshift=-0.8em]ln_1.-90) .. controls ([xshift=5em,yshift=-0.8em]ln_1.-90) and ([xshift=5em]add_1.0) .. (add_1.0);
\draw[->,thick] (add_1.0) .. controls ([xshift=5em]add_1.0) and ([xshift=5em]add_2.0) .. (add_2.0); \draw[->,thick] (add_1.0) .. controls ([xshift=5em]add_1.0) and ([xshift=5em]add_2.0) .. (add_2.0);
\draw[->,thick] (add_2.0) .. controls ([xshift=5em]add_2.0) and ([xshift=5em]add_3.0) .. (add_3.0);
\draw[->,thick] (add_3.0) .. controls ([xshift=5em]add_3.0) and ([xshift=5em]add_4.0) .. (add_4.0);
\node[font=\scriptsize] at (0em, -1em){(a) Transformer编码器中若干块的结构}; \node[font=\scriptsize] at (0em, -1em){(a) Transformer编码器中若干块的结构};
\end{scope} \end{scope}
%right %right
\begin{scope}[xshift=14em] \begin{scope}[xshift=14em]
\foreach \x/\d in {1/2em, 2/8em, 3/16em, 4/22em, 5/28em} \foreach \x/\d in {1/2em, 2/8em, 3/14em}
\node[unit,fill=yellow!20] at (0,\d) (ln_\x) {层正则}; \node[unit,fill=yellow!20] at (0,\d) (ln_\x) {层正则化};
\node[unit,fill=green!20] at (0,24em) (sa_1) {8头自注意力:512};
\foreach \x/\d in {1/6em, 2/14em, 3/20em, 4/26em, 5/36em} \foreach \x/\d in {1/6em, 2/12em, 3/22em}
\node[draw,circle,minimum size=1em,inner sep=1pt] at (0,\d) (add_\x) {\scriptsize\bfnew{+}}; \node[draw,circle,minimum size=1em,inner sep=1pt] at (0,\d) (add_\x) {\scriptsize\bfnew{+}};
\node[unit,fill=red!20] at (0,30em) (conv_4) {卷积$1 \times 1$:2048}; \node[unit,fill=red!20] at (0,16em) (conv_4) {卷积$1 \times 1$:2048};
\node[unit,fill=red!20] at (0,34em) (conv_5) {卷积$1 \times 1$:512}; \node[unit,fill=red!20] at (0,20em) (conv_5) {卷积$1 \times 1$:512};
\node[unit,fill=blue!20] at (0,18em) (relu_3) {RELU};
\node[unit,fill=cyan!20] at (0,4em) (conv_3) {Sep卷积$9 \times 1$:256};
\node[unit,fill=green!20] at (0,10em) (sa_1) {8头自注意力:512};
\node[unit,fill=blue!20] at (0,32em) (relu_3) {RELU};
\node[unit,fill=red!20] at (0,4em) (glu_1) {门控线性单元:512};
\node[unit,fill=red!20] at (-3em,10em) (conv_1) {卷积$1 \times 1$:2048};
\node[unit,fill=cyan!20] at (3em,10em) (conv_2) {卷积$3 \times 1$:256};
\node[unit,fill=blue!20] at (-3em,12em) (relu_1) {RELU};
\node[unit,fill=blue!20] at (3em,12em) (relu_2) {RELU};
\node[unit,fill=cyan!20] at (0em,18em) (conv_3) {Sep卷积$9 \times 1$:256};
\draw[->,thick] ([yshift=-1.4em]ln_1.-90) -- ([yshift=-0.1em]ln_1.-90); \draw[->,thick] ([yshift=-1.4em]ln_1.-90) -- ([yshift=-0.1em]ln_1.-90);
\draw[->,thick] ([yshift=0.1em]ln_1.90) -- ([yshift=-0.1em]glu_1.-90); \draw[->,thick] ([yshift=0.1em]ln_1.90) -- ([yshift=-0.1em]conv_3.-90);
\draw[->,thick] ([yshift=0.1em]glu_1.90) -- ([yshift=-0.1em]add_1.-90); \draw[->,thick] ([yshift=0.1em]conv_3.90) -- ([yshift=-0.1em]add_1.-90);
\draw[->,thick] ([yshift=0.1em]add_1.90) -- ([yshift=-0.1em]ln_2.-90); \draw[->,thick] ([yshift=0.1em]add_1.90) -- ([yshift=-0.1em]ln_2.-90);
\draw[->,thick] ([,yshift=0.1em]ln_2.135) -- ([yshift=-0.1em]conv_1.-90); \draw[->,thick] ([,yshift=0.1em]ln_2.90) -- ([yshift=-0.1em]sa_1.-90);
\draw[->,thick] ([yshift=0.1em]ln_2.45) -- ([yshift=-0.1em]conv_2.-90); \draw[->,thick] ([yshift=0.1em]sa_1.90) -- ([yshift=-0.1em]add_2.-90);
\draw[->,thick] ([yshift=0.1em]conv_1.90) -- ([yshift=-0.1em]relu_1.-90);
\draw[->,thick] ([yshift=0.1em]conv_2.90) -- ([yshift=-0.1em]relu_2.-90);
\draw[->,thick] ([yshift=0.1em]relu_1.90) -- ([yshift=-0.1em]add_2.-135);
\draw[->,thick] ([yshift=0.1em]relu_2.90) -- ([yshift=-0.1em]add_2.-45);
\draw[->,thick] ([yshift=0.1em]add_2.90) -- ([yshift=-0.1em]ln_3.-90); \draw[->,thick] ([yshift=0.1em]add_2.90) -- ([yshift=-0.1em]ln_3.-90);
\draw[->,thick] ([yshift=0.1em]ln_3.90) -- ([yshift=-0.1em]conv_3.-90); \draw[->,thick] ([yshift=0.1em]ln_3.90) -- ([yshift=-0.1em]conv_4.-90);
\draw[->,thick] ([yshift=0.1em]conv_3.90) -- ([yshift=-0.1em]add_3.-90);
\draw[->,thick] ([yshift=0.1em]add_3.90) -- ([yshift=-0.1em]ln_4.-90);
\draw[->,thick] ([yshift=0.1em]ln_4.90) -- ([yshift=-0.1em]sa_1.-90);
\draw[->,thick] ([yshift=0.1em]sa_1.90) -- ([yshift=-0.1em]add_4.-90);
\draw[->,thick] ([yshift=0.1em]add_4.90) -- ([yshift=-0.1em]ln_5.-90);
\draw[->,thick] ([yshift=0.1em]ln_5.90) -- ([yshift=-0.1em]conv_4.-90);
\draw[->,thick] ([yshift=0.1em]conv_4.90) -- ([yshift=-0.1em]relu_3.-90); \draw[->,thick] ([yshift=0.1em]conv_4.90) -- ([yshift=-0.1em]relu_3.-90);
\draw[->,thick] ([yshift=0.1em]relu_3.90) -- ([yshift=-0.1em]conv_5.-90); \draw[->,thick] ([yshift=0.1em]relu_3.90) -- ([yshift=-0.1em]conv_5.-90);
\draw[->,thick] ([yshift=0.1em]conv_5.90) -- ([yshift=-0.1em]add_5.-90); \draw[->,thick] ([yshift=0.1em]conv_5.90) -- ([yshift=-0.1em]add_3.-90);
\draw[->,thick] ([yshift=0.1em]add_5.90) -- ([yshift=1em]add_5.90); \draw[->,thick] ([yshift=0.1em]add_3.90) -- ([yshift=1em]add_3.90);
\draw[->,thick] ([yshift=-0.8em]ln_1.-90) .. controls ([xshift=5em,yshift=-0.8em]ln_1.-90) and ([xshift=5em]add_1.0) .. (add_1.0); \draw[->,thick] ([yshift=-0.8em]ln_1.-90) .. controls ([xshift=5em,yshift=-0.8em]ln_1.-90) and ([xshift=5em]add_1.0) .. (add_1.0);
\draw[->,thick] (add_1.0) .. controls ([xshift=8em]add_1.0) and ([xshift=8em]add_3.0) .. (add_3.0); \draw[->,thick] (add_1.0) .. controls ([xshift=5em]add_1.0) and ([xshift=5em]add_2.0) .. (add_2.0);
\draw[->,thick] (add_3.0) .. controls ([xshift=5em]add_3.0) and ([xshift=5em]add_4.0) .. (add_4.0); \draw[->,thick] (add_2.0) .. controls ([xshift=5em]add_2.0) and ([xshift=5em]add_3.0) .. (add_3.0);
\draw[->,thick] (add_4.0) .. controls ([xshift=5em]add_4.0) and ([xshift=5em]add_5.0) .. (add_5.0);
\node[font=\scriptsize,align=center] at (0em, -1.5em){(b) 使用结构搜索方法优化后的 \\ Transformer编码器中若干块的结构}; \node[font=\scriptsize,align=center] at (0em, -1.5em){(b) 使用结构搜索方法优化后的 \\ Transformer编码器中若干块的结构};
\node[minimum size=0.8em,inner sep=0pt,rounded corners=1pt,draw,fill=blue!20] (act) at (5.5em, 38em){}; \node[minimum size=0.8em,inner sep=0pt,rounded corners=1pt,draw,fill=blue!20] (act) at (5.5em, 20em){};
\node[anchor=west,font=\footnotesize] at ([xshift=0.1em]act.east){激活函数}; \node[anchor=west,font=\footnotesize] at ([xshift=0.1em]act.east){激活函数};
\node[anchor=north,minimum size=0.8em,inner sep=0pt,rounded corners=1pt,draw,fill=yellow!20] (nor) at ([yshift=-0.6em]act.south){}; \node[anchor=north,minimum size=0.8em,inner sep=0pt,rounded corners=1pt,draw,fill=yellow!20] (nor) at ([yshift=-0.6em]act.south){};
\node[anchor=west,font=\footnotesize] at ([xshift=0.1em]nor.east){正则化}; \node[anchor=west,font=\footnotesize] at ([xshift=0.1em]nor.east){正则化};
\node[anchor=north,minimum size=0.8em,inner sep=0pt,rounded corners=1pt,draw,fill=cyan!20] (wc) at ([yshift=-0.6em]nor.south){}; \node[anchor=north,minimum size=0.8em,inner sep=0pt,rounded corners=1pt,draw,fill=cyan!20] (wc) at ([yshift=-0.6em]nor.south){};
\node[anchor=west,font=\footnotesize] at ([xshift=0.1em]wc.east){宽卷积}; \node[anchor=west,font=\footnotesize] at ([xshift=0.1em]wc.east){宽卷积};
\node[anchor=north,minimum size=0.8em,inner sep=0pt,rounded corners=1pt,draw,fill=green!20] (at) at ([yshift=-0.6em]wc.south){}; \node[anchor=north,minimum size=0.8em,inner sep=0pt,rounded corners=1pt,draw,fill=green!20] (at) at ([yshift=-0.6em]wc.south){};
......
...@@ -17,7 +17,7 @@ ...@@ -17,7 +17,7 @@
\node [anchor=west,rectangle,minimum height=1.5em,minimum width=2.5em,rounded corners=5pt] (n6) at ([xshift=1em,yshift=0em]n5.east) {$\ldots$}; \node [anchor=west,rectangle,minimum height=1.5em,minimum width=2.5em,rounded corners=5pt] (n6) at ([xshift=1em,yshift=0em]n5.east) {$\ldots$};
\node [anchor=west,encnode,draw=red!60!black!80,fill=red!20] (n7) at ([xshift=1em,yshift=0em]n6.east) {$\mathbi{h}_{N-1}$}; \node [anchor=west,encnode,draw=red!60!black!80,fill=red!20] (n7) at ([xshift=1em,yshift=0em]n6.east) {$\mathbi{h}_{L-1}$};
\node [anchor=north,rectangle,draw=teal!80, inner sep=0mm,minimum height=2em,minimum width=8em,fill=teal!17,rounded corners=5pt,thick] (n8) at ([xshift=3em,yshift=-1.2em]n4.south) {权重聚合$\mathbi{g}$}; \node [anchor=north,rectangle,draw=teal!80, inner sep=0mm,minimum height=2em,minimum width=8em,fill=teal!17,rounded corners=5pt,thick] (n8) at ([xshift=3em,yshift=-1.2em]n4.south) {权重聚合$\mathbi{g}$};
......
%%% outline
%-------------------------------------------------------------------------
\begin{tikzpicture}
\tikzstyle{opt}=[minimum height=1em,minimum width=5em,rounded corners=2pt,thick]
\node[opt] (opt1_0) at (0,0) {固定操作};
\node[draw,anchor=south,opt,fill=green!20] (opt1_1) at ([yshift=0.8em]opt1_0.north) {操作3};
\node[draw,anchor=south,opt,fill=cyan!20] (opt1_2) at ([yshift=0.8em]opt1_1.north) {操作2};
\node[anchor=south,opt] (opt1_3) at ([yshift=0.8em]opt1_2.north) {固定操作};
\node[draw,anchor=south,opt,fill=yellow!20] (opt1_4) at ([yshift=0.8em]opt1_3.north) {操作4};
\node[anchor=south,opt] (opt1_5) at ([yshift=0.8em]opt1_4.north) {$\cdots$};
\node[draw,anchor=south,opt,fill=blue!10] (opt1_6) at ([yshift=0.8em]opt1_5.north) {操作1};
\node[anchor=south,opt] (opt1_7) at ([yshift=0.8em]opt1_6.north) {};
\node[opt] (opt2_0) at (3,0) {固定操作};
\node[draw,anchor=south,opt,fill=blue!10] (opt2_1) at ([yshift=0.8em]opt2_0.north) {操作1};
\node[draw,anchor=south,opt,fill=green!20] (opt2_2) at ([yshift=0.8em]opt2_1.north) {操作3};
\node[anchor=south,opt] (opt2_3) at ([yshift=0.8em]opt2_2.north) {固定操作};
\node[draw,anchor=south,opt,fill=red!20] (opt2_4) at ([yshift=0.8em]opt2_3.north) {操作5};
\node[anchor=south,opt] (opt2_5) at ([yshift=0.8em]opt2_4.north) {$\cdots$};
\node[draw,anchor=south,opt,fill=cyan!20] (opt2_6) at ([yshift=0.8em]opt2_5.north) {操作2};
\node[anchor=south,opt] (opt2_7) at ([yshift=0.8em]opt2_6.north) {};
\node[opt] (opt3_0) at (6,0) {固定操作};
\node[draw,anchor=south,opt,fill=yellow!20] (opt3_1) at ([yshift=0.8em]opt3_0.north) {操作4};
\node[draw,anchor=south,opt,fill=cyan!20] (opt3_2) at ([yshift=0.8em]opt3_1.north) {操作2};
\node[anchor=south,opt] (opt3_3) at ([yshift=0.8em]opt3_2.north) {固定操作};
\node[draw,anchor=south,opt,fill=yellow!20] (opt3_4) at ([yshift=0.8em]opt3_3.north) {操作4};
\node[anchor=south,opt] (opt3_5) at ([yshift=0.8em]opt3_4.north) {$\cdots$};
\node[draw,anchor=south,opt,fill=red!20] (opt3_6) at ([yshift=0.8em]opt3_5.north) {操作5};
\node[anchor=south,opt] (opt3_7) at ([yshift=0.8em]opt3_6.north) {};
\begin{pgfonlayer}{background}
\node[draw,fill=yellow!20,rounded corners=6pt,inner ysep=2.6em,inner xsep=2.6em] [fit=(opt1_0) (opt3_7)](box4){};
\node[draw,fill=gray!10,rounded corners=2pt,inner sep=8pt] [fit=(opt1_0) (opt1_7)](box1){};
\node[draw,fill=gray!10,rounded corners=2pt,inner sep=8pt] [fit=(opt2_0) (opt2_7)](box2){};
\node[draw,fill=gray!10,rounded corners=2pt,inner sep=8pt] [fit=(opt3_0) (opt3_7)](box3){};
\end{pgfonlayer}
\draw[->,thick] (opt1_0) -- (opt1_1);
\draw[->,thick] (opt1_1) -- (opt1_2);
\draw[->,thick] (opt1_2) -- (opt1_3);
\draw[->,thick] (opt1_3) -- (opt1_4);
\draw[->,thick] (opt1_4) -- (opt1_5);
\draw[->,thick] (opt1_5) -- (opt1_6);
\draw[->,thick] (opt2_0) -- (opt2_1);
\draw[->,thick] (opt2_1) -- (opt2_2);
\draw[->,thick] (opt2_2) -- (opt2_3);
\draw[->,thick] (opt2_3) -- (opt2_4);
\draw[->,thick] (opt2_4) -- (opt2_5);
\draw[->,thick] (opt2_5) -- (opt2_6);
\draw[->,thick] (opt3_0) -- (opt3_1);
\draw[->,thick] (opt3_1) -- (opt3_2);
\draw[->,thick] (opt3_2) -- (opt3_3);
\draw[->,thick] (opt3_3) -- (opt3_4);
\draw[->,thick] (opt3_4) -- (opt3_5);
\draw[->,thick] (opt3_5) -- (opt3_6);
\node[] at ([xshift=-1.2em,yshift=0.2em]opt1_7){\small\bfnew{分支1}};
\node[] at ([xshift=-1.2em,yshift=0.2em]opt2_7){\small\bfnew{分支2}};
\node[] at ([xshift=-1.2em,yshift=0.2em]opt3_7){\small\bfnew{分支3}};
\node[] (input) at ([yshift=-5em]opt2_0){\small\bfnew{输入}};
\node[] (output) at ([yshift=5em]opt2_7){\small\bfnew{输出}};
\draw[->,thick,out=140,in=-30] (box4.-90) to (box1.-90);
\draw[->,thick,out=40,in=-150] (box4.-90) to (box3.-90);
\draw[->,thick] (box4.-90) -- (box2.-90);
\draw[->,thick,out=50,in=-130] (box1.90) to (box4.90);
\draw[->,thick,out=130,in=-50] (box3.90) to (box4.90);
\draw[->,thick] (box2.90) -- (box4.90);
\draw[->,thick] (input.90) -- (box4.-90);
\draw[->,thick] (box4.90) -- (output.-90);
\node[] at ([xshift=-2.8em,yshift=1.1em]box1.90){\small\bfnew{模型结构}};
\node[] at ([xshift=-0.8em]box4.0){$\cdots$};
\end{tikzpicture}
%%% outline \begin{tikzpicture}
%------------------------------------------------------------------------- \tikzstyle{node}=[draw,minimum height=1.4em,minimum width=2em,rounded corners=1pt,thick]
\begin{tikzpicture}[scale=0.8]
\tikzstyle{every node}=[scale=0.8]
\tikzstyle{node}=[draw,minimum height=1.4em,minimum width=2em,rounded corners=3pt,thick]
\begin{scope}[scale=0.36]
\tikzstyle{every node}=[scale=0.36]
\node[draw=ublue,very thick,drop shadow,fill=white,minimum width=40em,minimum height=25em] (rec3) at (2.25,0){};
\node[draw=ublue,very thick,drop shadow,fill=white,minimum width=22em,minimum height=25em] (rec2) at (-12.4,0){};
\node[draw=ublue,very thick,drop shadow,fill=white,minimum width=24em,minimum height=25em] (rec1) at (-24,0){};
%left
\node[text=ublue] (label1) at (-26.4,4){\Huge\bfnew{结构空间}};
\node[align=left] at (-24,-0.5){\Huge\bfnew{1.前馈神经网络} \\ [4ex] \Huge\bfnew{2.卷积神经网络} \\ [4ex] \Huge\bfnew{3.循环神经网络} \\ [4ex] \Huge\bfnew{4. Transformer网络} \\ [4ex] \Huge\bfnew{...}};
\draw[ublue,very thick,-latex] (rec1.0) -- node[align=center,above,text=violet]{\huge{设计} \\ \huge{搜索} \\ \huge{空间}}(rec2.180);
%mid
\node[text=ublue] (label2) at (-14.4,4){\Huge\bfnew{搜索空间}};
\node[align=left] at (-12.4,-0.5){\Huge\bfnew{循环神经网络} \\ [4ex] \Huge\bfnew{1.普通RNN网络} \\ [4ex] \Huge\bfnew{2. LSTM网络} \\ [4ex] \Huge\bfnew{3. GRU网络} \\ [4ex] \Huge\bfnew{...}};
\draw[ublue,very thick,-latex] (rec2.0) -- node[align=center,above,text=violet]{\huge{选择} \\ \huge{搜索} \\ \huge{策略}}(rec3.180);
\draw[ublue,very thick,-latex,out=-150,in=-30] (rec3.-90) to node[above,text=violet,yshift=1em]{\huge{迭代结构搜索的过程}}(rec2.-90);
\draw[ublue,very thick,-latex,out=60,in=130] ([xshift=-8em]rec3.90) to node[above,text=violet]{\huge{性能评估}}([xshift=8em]rec3.90);
%right
\node[node] (n1) at (0,0){}; \node[node] (n1) at (0,0){};
\node[node] (n2) at (1.5,0){}; \node[node] (n2) at (1.5,0){};
\node[node] (n3) at (3,0){}; \node[node] (n3) at (3,0){};
...@@ -32,16 +52,9 @@ ...@@ -32,16 +52,9 @@
\node[font=\Huge] at (9,0){$\cdots$}; \node[font=\Huge] at (9,0){$\cdots$};
\node[font=\Huge] at (-4.5,0){$\cdots$}; \node[font=\Huge] at (-4.5,0){$\cdots$};
\node[minimum width=3em,minimum height=2em,fill=red!20,rounded corners=6pt] (b1) at (6,-3.8){}; \node[text=ublue] (label3) at (-2,4){\Huge\bfnew{找到的模型结构}};
\node[] (w1) at (7.8,-3.8){\Large 整体框架};
\node[minimum width=3em,minimum height=2em,fill=yellow!30,rounded corners=6pt] (b2) at (6,-4.8){};
\node[] (w2) at (7.8,-4.8){\Large 内部结构};
\begin{pgfonlayer}{background} \node[draw,rounded corners=6pt,very thick,minimum width=16em,minimum height=15em] (box1) at (2.25,0){};
\node[draw,rounded corners=6pt,very thick,fill=yellow!30,minimum width=16em,minimum height=15em] (box1) at (2.25,0){};
\node[draw=ublue,very thick,drop shadow,inner sep=1.2em,fill=white,xshift=-0.1em] [fit=(b1)(w2)]{};
\draw[fill=red!20,red!20,rounded corners=6pt] ([yshift=2.4em,xshift=1em]ht-1.east) -- ([yshift=2.4em,xshift=-0.1em]box1.west) -- ([xshift=-8em,xshift=-0.1em]box1.south) -- ([xshift=2em]box1.south) -- ([xshift=2em,yshift=-5em]box1.south) -- ([xshift=0em,yshift=-5em]box1.south) .. controls ([xshift=-12em,yshift=-5em]box1.south) and ([yshift=-2em]ht-1.east) ..([yshift=2.4em]ht-1.east) -- ([yshift=2.4em,xshift=1em]ht-1.east) ;
\end{pgfonlayer}
\draw[->,very thick] (ht-1.0) -- (box1.180); \draw[->,very thick] (ht-1.0) -- (box1.180);
\draw[->,very thick] (box1.0) -- (ht+1.180); \draw[->,very thick] (box1.0) -- (ht+1.180);
...@@ -51,10 +64,5 @@ ...@@ -51,10 +64,5 @@
\draw[->,very thick] ([yshift=-2em]ht-1.-90) -- (ht-1.-90); \draw[->,very thick] ([yshift=-2em]ht-1.-90) -- (ht-1.-90);
\draw[->,very thick] ([yshift=-2em]ht+1.-90) -- (ht+1.-90); \draw[->,very thick] ([yshift=-2em]ht+1.-90) -- (ht+1.-90);
\draw[->,very thick] ([yshift=-2em]box1.-90) -- (box1.-90); \draw[->,very thick] ([yshift=-2em]box1.-90) -- (box1.-90);
\end{scope}
\end{tikzpicture}
\end{tikzpicture} \ No newline at end of file
...@@ -39,8 +39,8 @@ ...@@ -39,8 +39,8 @@
\node [rectangle,inner sep=0.3em,fill=blue!10] [fit = (x3) (F2) (n2) (ln2) (x4) (k2)] (box1) {}; \node [rectangle,inner sep=0.3em,fill=blue!10] [fit = (x3) (F2) (n2) (ln2) (x4) (k2)] (box1) {};
\end{pgfonlayer} \end{pgfonlayer}
\node [anchor=north] (c1) at (box0.south){\footnotesize {(a)后作方式的残差连接}}; \node [anchor=north] (c1) at (box0.south){\footnotesize {(a)Post-Norm方式的残差连接}};
\node [anchor=north] (c2) at (box1.south){\footnotesize {(b)前作方式的残差连接}}; \node [anchor=north] (c2) at (box1.south){\footnotesize {(b)Pre-Norm方式的残差连接}};
\end{scope} \end{scope}
\end{tikzpicture} \end{tikzpicture}
\end{center} \end{center}
\ No newline at end of file
...@@ -31,8 +31,8 @@ ...@@ -31,8 +31,8 @@
\node[anchor=north,lan,minimum width=9.8em] (box7) at ([yshift=-4em]train3.south) {}; \node[anchor=north,lan,minimum width=9.8em] (box7) at ([yshift=-4em]train3.south) {};
\begin{pgfonlayer}{background} \begin{pgfonlayer}{background}
\node[fill=red!20,draw=black,rounded corners=2pt,inner ysep=6pt,line width=1pt][fit=(train)(train4)(train1)(train2)(train3)]{}; \node[draw=ugreen,rounded corners=2pt,inner ysep=6pt,line width=1pt][fit=(train)(train4)(train1)(train2)(train3)]{};
\node[fill=blue!20,,draw=black,rounded corners=2pt,inner ysep=6pt,line width=1pt][fit=(decode)(output)(decode2)(decode3)(box7)]{}; \node[draw=purple,rounded corners=2pt,inner ysep=6pt,line width=1pt][fit=(decode)(output)(decode2)(decode3)(box7)]{};
\end{pgfonlayer} \end{pgfonlayer}
\end{tikzpicture} \end{tikzpicture}
......
...@@ -9,7 +9,7 @@ ...@@ -9,7 +9,7 @@
\node(bilingual_D_shadow)[data_shadow, right of = monolingual_X_shadow, xshift=5cm]{}; \node(bilingual_D_shadow)[data_shadow, right of = monolingual_X_shadow, xshift=5cm]{};
\node(monolingual_Y_shadow)[data_shadow, right of = bilingual_D_shadow, xshift=5cm]{}; \node(monolingual_Y_shadow)[data_shadow, right of = bilingual_D_shadow, xshift=5cm]{};
\node(monolingual_X)[data,right of = monolingual_X_shadow,xshift=-0.08cm,yshift=0.08cm]{单语语料X}; \node(monolingual_X)[data,right of = monolingual_X_shadow,xshift=-0.08cm,yshift=0.08cm]{单语语料X};
\node(bilingual_D)[data, right of = monolingual_X, xshift=5cm, fill=green!30]{双语语料D}; \node(bilingual_D)[data, right of = monolingual_X, xshift=5cm, fill=ugreen!30]{双语语料D};
\node(monolingual_Y)[data, right of = bilingual_D, xshift=5cm, fill=blue!25]{单语语料Y}; \node(monolingual_Y)[data, right of = bilingual_D, xshift=5cm, fill=blue!25]{单语语料Y};
\node(process_1_1)[process, right of = monolingual_X, xshift=2.5cm, yshift=-1.5cm]{\textbf{$M^0_{x\to y}$}}; \node(process_1_1)[process, right of = monolingual_X, xshift=2.5cm, yshift=-1.5cm]{\textbf{$M^0_{x\to y}$}};
...@@ -35,7 +35,7 @@ ...@@ -35,7 +35,7 @@
\node(text_2)[left of = process_5_1, xshift=-4cm,scale=0.8]{第1轮迭代}; \node(text_2)[left of = process_5_1, xshift=-4cm,scale=0.8]{第1轮迭代};
\node(text_3)[left of = ellipsis_2, xshift=-4cm, scale=0.8]{第2轮迭代}; \node(text_3)[left of = ellipsis_2, xshift=-4cm, scale=0.8]{第2轮迭代};
\draw[->, very thick, color=color1!40](monolingual_X.south)--(ellipsis_1.north); \draw[->, very thick, color=color1!40](monolingual_X.south)--(ellipsis_1.north);
\draw[->, very thick, color=green!30](bilingual_D.south)--(ellipsis_3.north); \draw[->, very thick, color=ugreen!30](bilingual_D.south)--(ellipsis_3.north);
\draw[->, very thick, color=blue!55](monolingual_Y.south)--(ellipsis_5.north); \draw[->, very thick, color=blue!55](monolingual_Y.south)--(ellipsis_5.north);
\draw[->, very thick, color=color1!40]([xshift=-1.5cm]process_2_1.west)--(process_2_1.west); \draw[->, very thick, color=color1!40]([xshift=-1.5cm]process_2_1.west)--(process_2_1.west);
\draw[->, very thick, color=color1!40]([xshift=-1.5cm]process_5_1.west)--(process_5_1.west); \draw[->, very thick, color=color1!40]([xshift=-1.5cm]process_5_1.west)--(process_5_1.west);
...@@ -55,13 +55,13 @@ ...@@ -55,13 +55,13 @@
\draw[->, very thick, color=color1!40](process_3_2.west)--([yshift=0.35cm]process_4_1.east); \draw[->, very thick, color=color1!40](process_3_2.west)--([yshift=0.35cm]process_4_1.east);
\draw[->, very thick, color=color1!40](process_6_1.east)--([yshift=0.35cm]process_7_2.west); \draw[->, very thick, color=color1!40](process_6_1.east)--([yshift=0.35cm]process_7_2.west);
\draw[->, very thick, color=color1!40](process_6_2.west)--([yshift=0.35cm]process_7_1.east); \draw[->, very thick, color=color1!40](process_6_2.west)--([yshift=0.35cm]process_7_1.east);
\draw[->, very thick, color=green!30,in=0,out=270]([xshift=-0.3cm]bilingual_D.south)to(process_1_1.east); \draw[->, very thick, color=ugreen!30,in=0,out=270]([xshift=-0.3cm]bilingual_D.south)to(process_1_1.east);
\draw[->, very thick, color=green!30,in=180,out=270]([xshift=0.3cm]bilingual_D.south)to(process_1_2.west); \draw[->, very thick, color=ugreen!30,in=180,out=270]([xshift=0.3cm]bilingual_D.south)to(process_1_2.west);
\draw[->, very thick, color=green!30,in=0,out=270]([yshift=-3.7cm]bilingual_D.south)to(process_4_1.east); \draw[->, very thick, color=ugreen!30,in=0,out=270]([yshift=-3.7cm]bilingual_D.south)to(process_4_1.east);
\draw[->, very thick, color=green!30,in=180,out=270]([yshift=-3.7cm]bilingual_D.south)to(process_4_2.west); \draw[->, very thick, color=ugreen!30,in=180,out=270]([yshift=-3.7cm]bilingual_D.south)to(process_4_2.west);
\draw[->, very thick, color=green!30,in=0,out=270]([yshift=-7.3cm]bilingual_D.south)to(process_7_1.east); \draw[->, very thick, color=ugreen!30,in=0,out=270]([yshift=-7.3cm]bilingual_D.south)to(process_7_1.east);
\draw[->, very thick, color=green!30,in=180,out=270]([yshift=-7.3cm]bilingual_D.south)to(process_7_2.west); \draw[->, very thick, color=ugreen!30,in=180,out=270]([yshift=-7.3cm]bilingual_D.south)to(process_7_2.west);
\draw[->, very thick, color=green!30,in=180,out=270]([yshift=-7.3cm]bilingual_D.south)to(process_7_2.west); \draw[->, very thick, color=ugreen!30,in=180,out=270]([yshift=-7.3cm]bilingual_D.south)to(process_7_2.west);
\draw[-, very thick, dashed, color=blue!55]([xshift=-1cm,yshift=-0.35cm]text_1.south)--([xshift=12.7cm,yshift=-0.35cm]text_1.south); \draw[-, very thick, dashed, color=blue!55]([xshift=-1cm,yshift=-0.35cm]text_1.south)--([xshift=12.7cm,yshift=-0.35cm]text_1.south);
\draw[-, very thick, dashed, color=blue!55]([xshift=-1cm,yshift=-0.35cm]text_2.south)--([xshift=12.7cm,yshift=-0.35cm]text_2.south); \draw[-, very thick, dashed, color=blue!55]([xshift=-1cm,yshift=-0.35cm]text_2.south)--([xshift=12.7cm,yshift=-0.35cm]text_2.south);
......
This source diff could not be displayed because it is too large. You can view the blob instead.
...@@ -17,11 +17,11 @@ ...@@ -17,11 +17,11 @@
\node[layer,anchor=south,fill=red!20] (de_ca) at ([yshift=1.4em]de_sa.north){Multi-Head \\ Attention}; \node[layer,anchor=south,fill=red!20] (de_ca) at ([yshift=1.4em]de_sa.north){Multi-Head \\ Attention};
\node[layer,anchor=south,fill=green!20] (de_ffn) at ([yshift=1.4em]de_ca.north){Feed Forward \\ Network}; \node[layer,anchor=south,fill=green!20] (de_ffn) at ([yshift=1.4em]de_ca.north){Feed Forward \\ Network};
\node[layer,anchor=south,fill=blue!20] (sf) at ([yshift=2em]de_ffn.north){Softmax}; \node[layer,anchor=south,fill=blue!20] (sf) at ([yshift=1.6em]de_ffn.north){Softmax};
\node[layer,anchor=south,fill=orange!20] (output) at ([yshift=1.4em]sf.north){STLoss}; %\node[layer,anchor=south,fill=orange!20] (output) at ([yshift=1.4em]sf.north){STLoss};
\node[anchor=north,font=\scriptsize,align=center] (en_input) at ([yshift=-1em]en_cnn.south){语音特征\\(FilterBank/MFCC)}; \node[anchor=north,font=\scriptsize,align=center] (en_input) at ([yshift=-1em]en_cnn.south){Speech Feature\\(FBank/MFCC)};
\node[anchor=north,font=\scriptsize,align=center] (de_input) at ([yshift=-1em]de_add.south){目标文本\\(Embedding)}; \node[anchor=north,font=\scriptsize,align=center] (de_input) at ([yshift=-1.1em]de_add.south){Target Text\\(Embedding)};
\node[anchor=east,font=\scriptsize,align=center] (en_pos) at ([xshift=-2em]en_add.west){Position\\(Embedding)}; \node[anchor=east,font=\scriptsize,align=center] (en_pos) at ([xshift=-2em]en_add.west){Position\\(Embedding)};
\node[anchor=west,font=\scriptsize,align=center] (de_pos) at ([xshift=2em]de_add.east){Position\\(Embedding)}; \node[anchor=west,font=\scriptsize,align=center] (de_pos) at ([xshift=2em]de_add.east){Position\\(Embedding)};
...@@ -35,13 +35,13 @@ ...@@ -35,13 +35,13 @@
\draw[->] ([yshift=0.1em]de_sa.90) -- ([yshift=-0.1em]de_ca.-90); \draw[->] ([yshift=0.1em]de_sa.90) -- ([yshift=-0.1em]de_ca.-90);
\draw[->] ([yshift=0.1em]de_ca.90) -- ([yshift=-0.1em]de_ffn.-90); \draw[->] ([yshift=0.1em]de_ca.90) -- ([yshift=-0.1em]de_ffn.-90);
\draw[->] ([yshift=0.1em]de_ffn.90) -- ([yshift=-0.1em]sf.-90); \draw[->] ([yshift=0.1em]de_ffn.90) -- ([yshift=-0.1em]sf.-90);
\draw[->] ([yshift=0.1em]sf.90) -- ([yshift=-0.1em]output.-90); \draw[->] ([yshift=0.1em]sf.90) -- ([yshift=1.5em]sf.90);
\draw[->] ([xshift=0.1em]en_pos.0) -- ([xshift=-0.1em]en_add.180); \draw[->] ([xshift=0.1em]en_pos.0) -- ([xshift=-0.1em]en_add.180);
\draw[->] ([xshift=-0.1em]de_pos.180) -- ([xshift=0.1em]de_add.0); \draw[->] ([xshift=-0.1em]de_pos.180) -- ([xshift=0.1em]de_add.0);
\draw[->,rounded corners=2pt] ([yshift=0.1em]en_ffn.90) -- ([yshift=2em]en_ffn.90) -- ([xshift=4em,yshift=2em]en_ffn.90) -- ([xshift=-1.5em]de_ca.west) -- ([xshift=-0.1em]de_ca.west); \draw[->,rounded corners=2pt] ([yshift=0.1em]en_ffn.90) -- ([yshift=2em]en_ffn.90) -- ([xshift=4em,yshift=2em]en_ffn.90) -- ([xshift=-1.5em]de_ca.west) -- ([xshift=-0.1em]de_ca.west);
\begin{pgfonlayer}{background} \begin{pgfonlayer}{background}
\node[draw=ugreen,rounded corners=2pt,inner xsep=6pt,inner ysep=8pt][fit=(en_sa)(en_ffn)]{}; \node[draw=ugreen,rounded corners=2pt,inner xsep=6pt,inner ysep=8pt,dashed,thick][fit=(en_sa)(en_ffn)]{};
\node[draw=red,rounded corners=2pt,inner xsep=6pt,inner ysep=8pt][fit=(de_sa)(de_ca)(de_ffn)]{}; \node[draw=red,rounded corners=2pt,inner xsep=6pt,inner ysep=8pt,dashed,thick][fit=(de_sa)(de_ca)(de_ffn)]{};
\end{pgfonlayer} \end{pgfonlayer}
\node[anchor=east,font=\scriptsize,text=ugreen] at ([xshift=-0.1em]box1.west){$N \times$}; \node[anchor=east,font=\scriptsize,text=ugreen] at ([xshift=-0.1em]box1.west){$N \times$};
......
\tikzstyle{coder} = [rectangle,thick,rounded corners,minimum width=2.3cm,minimum height=1cm,text centered,draw=black,fill=red!25] \tikzstyle{coder} = [rectangle,rounded corners,minimum height=2.2em,minimum width=4.3em,text centered,draw=black,fill=red!25]
\begin{tikzpicture}[node distance = 0,scale = 1] \begin{tikzpicture}[node distance = 0,scale = 1]
\tikzstyle{every node}=[scale=1] \tikzstyle{every node}=[scale=1]
\node(x)[]{x}; \node(x)[]{x};
\node(encoder)[coder, above of = x,yshift=4em]{{编码器}}; \node(encoder)[coder, above of = x,yshift=4em]{{编码器}};
\node(decoder_left)[coder, above of = encoder, yshift=6em,fill=blue!25]{{解码器}}; \node(decoder_left)[coder, above of = encoder, yshift=6em,fill=ugreen!25]{{解码器}};
\node(y_hat)[above of = decoder_left, yshift=4em]{{$\rm y'$}}; \node(y_hat)[above of = decoder_left, yshift=4em]{{$\rm y'$}};
\node(y)[above of = decoder_left, xshift=-6em]{{$\rm y$}}; \node(y)[above of = decoder_left, xshift=-6em]{{$\rm y$}};
\node(decoder_right)[coder, above of = encoder, xshift=12em,fill=yellow!25]{{解码器}}; \node(decoder_right)[coder, above of = encoder, xshift=11em,fill=yellow!25]{{解码器}};
\node(figure)[draw=white,above of = decoder_right,yshift=6.5em,scale=0.25] {\includegraphics[width=0.62\textwidth]{./Chapter17/Figures/figure-bank-without-attention.png}}; \node(figure)[draw=white,above of = decoder_right,yshift=6.5em,scale=0.25] {\includegraphics[width=0.62\textwidth]{./Chapter17/Figures/figure-bank-without-attention.png}};
...@@ -14,6 +14,6 @@ ...@@ -14,6 +14,6 @@
\draw[->,thick](encoder)to(decoder_left)node[right,xshift=-0.1cm,yshift=-1.25cm,scale=1.0]{翻译}; \draw[->,thick](encoder)to(decoder_left)node[right,xshift=-0.1cm,yshift=-1.25cm,scale=1.0]{翻译};
\draw[->,thick](decoder_left)to(y_hat); \draw[->,thick](decoder_left)to(y_hat);
\draw[->,thick](y)to(decoder_left); \draw[->,thick](y)to(decoder_left);
\draw[->,thick](encoder)to(decoder_right)node[left,xshift=-3.8em,yshift=0.25cm,scale=1.0]{生成图片}; \draw[->,thick](encoder)to(decoder_right)node[left,xshift=-3.1em,yshift=0.25cm,scale=1.0]{生成图片};
\draw[->,thick](decoder_right)to(figure); \draw[->,thick](decoder_right)to(figure);
\end{tikzpicture} \end{tikzpicture}
\ No newline at end of file
...@@ -21,7 +21,7 @@ ...@@ -21,7 +21,7 @@
\draw [very thick,rounded corners=10pt]([xshift=-2.2cm,yshift=-1cm]process_1.center)--([xshift=-1.8cm,yshift=1cm]process_1.center)--([xshift=-1.4cm,yshift=0cm]process_1.center)--([xshift=-1.1cm,yshift=0.8cm]process_1.center)--([xshift=-0.8cm,yshift=-0.4cm]process_1.center)--([xshift=-0.5cm,yshift=0.4cm]process_1.center); \draw [very thick,rounded corners=10pt]([xshift=-2.2cm,yshift=-1cm]process_1.center)--([xshift=-1.8cm,yshift=1cm]process_1.center)--([xshift=-1.4cm,yshift=0cm]process_1.center)--([xshift=-1.1cm,yshift=0.8cm]process_1.center)--([xshift=-0.8cm,yshift=-0.4cm]process_1.center)--([xshift=-0.5cm,yshift=0.4cm]process_1.center);
\draw [->,very thick]([xshift=-0.3cm]process_1.center)to([xshift=0.3cm]process_1.center); \draw [->,very thick]([xshift=-0.3cm]process_1.center)to([xshift=0.3cm]process_1.center);
\draw [very thick,rounded corners=10pt,densely dotted]([xshift=0.5cm,yshift=-1cm]process_1.center)--([xshift=0.9cm,yshift=1cm]process_1.center)--([xshift=1.3cm,yshift=0cm]process_1.center)--([xshift=1.6cm,yshift=0.8cm]process_1.center)--([xshift=1.9cm,yshift=-0.4cm]process_1.center)--([xshift=2.2cm,yshift=0.4cm]process_1.center); \draw [very thick,rounded corners=10pt,densely dotted]([xshift=0.5cm,yshift=-1cm]process_1.center)--([xshift=0.9cm,yshift=1cm]process_1.center)--([xshift=1.3cm,yshift=0cm]process_1.center)--([xshift=1.6cm,yshift=0.8cm]process_1.center)--([xshift=1.9cm,yshift=-0.4cm]process_1.center)--([xshift=2.2cm,yshift=0.4cm]process_1.center);
\node(process_2)[process,right of = process_1,xshift=6.6cm]{}; \node(process_2)[process,fill=ugreen!20,right of = process_1,xshift=6.6cm]{};
\node(text_2)[below of = process_2,yshift=-2cm,scale=1.3]{量化}; \node(text_2)[below of = process_2,yshift=-2cm,scale=1.3]{量化};
\draw [very thick,rounded corners=10pt,densely dotted]([xshift=-2.2cm,yshift=-1cm]process_2.center)--([xshift=-1.8cm,yshift=1cm]process_2.center)--([xshift=-1.4cm,yshift=0cm]process_2.center)--([xshift=-1.1cm,yshift=0.8cm]process_2.center)--([xshift=-0.8cm,yshift=-0.4cm]process_2.center)--([xshift=-0.5cm,yshift=0.4cm]process_2.center); \draw [very thick,rounded corners=10pt,densely dotted]([xshift=-2.2cm,yshift=-1cm]process_2.center)--([xshift=-1.8cm,yshift=1cm]process_2.center)--([xshift=-1.4cm,yshift=0cm]process_2.center)--([xshift=-1.1cm,yshift=0.8cm]process_2.center)--([xshift=-0.8cm,yshift=-0.4cm]process_2.center)--([xshift=-0.5cm,yshift=0.4cm]process_2.center);
\draw [->,very thick]([xshift=-0.3cm]process_2.center)to([xshift=0.3cm]process_2.center); \draw [->,very thick]([xshift=-0.3cm]process_2.center)to([xshift=0.3cm]process_2.center);
......
...@@ -7,9 +7,9 @@ ...@@ -7,9 +7,9 @@
\draw[-,thick]([xshift=-1.2cm]process_1.center)--([xshift=1.2cm]process_1.center); \draw[-,thick]([xshift=-1.2cm]process_1.center)--([xshift=1.2cm]process_1.center);
\draw[-,thick]([xshift=-1cm,yshift=-0.8cm]process_1.center)--([xshift=-0.9cm,yshift=0.4cm]process_1.center)--([xshift=-0.8cm,yshift=-0.3cm]process_1.center)--([xshift=-0.7cm,yshift=0.7cm]process_1.center)--([xshift=-0.6cm,yshift=-0.1cm]process_1.center)--([xshift=-0.5cm,yshift=0.3cm]process_1.center)--([xshift=-0.4cm,yshift=-0.5cm]process_1.center)--([xshift=-0.3cm,yshift=0.7cm]process_1.center)--([xshift=-0.2cm,yshift=-0.2cm]process_1.center)--([xshift=-0.1cm,yshift=0.4cm]process_1.center)--([xshift=0cm,yshift=-0.9cm]process_1.center)--([xshift=0.1cm,yshift=0.5cm]process_1.center)--([xshift=0.2cm,yshift=-0.4cm]process_1.center)--([xshift=0.3cm,yshift=0.3cm]process_1.center)--([xshift=0.4cm,yshift=-0.2cm]process_1.center)--([xshift=0.5cm,yshift=0.1cm]process_1.center)--([xshift=0.6cm,yshift=-0.8cm]process_1.center)--([xshift=0.7cm,yshift=0.4cm]process_1.center)--([xshift=0.8cm,yshift=-0.6cm]process_1.center)--([xshift=0.9cm,yshift=0.7cm]process_1.center)--([xshift=1cm,yshift=-0.2cm]process_1.center); \draw[-,thick]([xshift=-1cm,yshift=-0.8cm]process_1.center)--([xshift=-0.9cm,yshift=0.4cm]process_1.center)--([xshift=-0.8cm,yshift=-0.3cm]process_1.center)--([xshift=-0.7cm,yshift=0.7cm]process_1.center)--([xshift=-0.6cm,yshift=-0.1cm]process_1.center)--([xshift=-0.5cm,yshift=0.3cm]process_1.center)--([xshift=-0.4cm,yshift=-0.5cm]process_1.center)--([xshift=-0.3cm,yshift=0.7cm]process_1.center)--([xshift=-0.2cm,yshift=-0.2cm]process_1.center)--([xshift=-0.1cm,yshift=0.4cm]process_1.center)--([xshift=0cm,yshift=-0.9cm]process_1.center)--([xshift=0.1cm,yshift=0.5cm]process_1.center)--([xshift=0.2cm,yshift=-0.4cm]process_1.center)--([xshift=0.3cm,yshift=0.3cm]process_1.center)--([xshift=0.4cm,yshift=-0.2cm]process_1.center)--([xshift=0.5cm,yshift=0.1cm]process_1.center)--([xshift=0.6cm,yshift=-0.8cm]process_1.center)--([xshift=0.7cm,yshift=0.4cm]process_1.center)--([xshift=0.8cm,yshift=-0.6cm]process_1.center)--([xshift=0.9cm,yshift=0.7cm]process_1.center)--([xshift=1cm,yshift=-0.2cm]process_1.center);
\node(text_1)[below of = process_1,yshift=-2cm,scale=1.5]{语音信号}; \node(text_1)[below of = process_1,yshift=-2cm,scale=1.5]{语音信号};
\node(process_2)[process,right of = process_1,xshift=7.0cm,text width=4cm,align=center]{\baselineskip=4pt\LARGE{[[0.2,...,0.3], \qquad ..., \qquad 0.3,...,0.5]]}\par}; \node(process_2)[process,fill=blue!20,right of = process_1,xshift=7.0cm,text width=4cm,align=center]{\baselineskip=4pt\LARGE{[[0.2,...,0.3], \qquad ..., \qquad 0.3,...,0.5]]}\par};
\node(text_2)[below of = process_2,yshift=-2cm,scale=1.5]{语音特征}; \node(text_2)[below of = process_2,yshift=-2cm,scale=1.5]{语音特征};
\node(process_3)[process,,minimum width=6cm,minimum height=5cm,right of = process_2,xshift=8.2cm,text width=4cm,align=center]{}; \node(process_3)[process,fill=orange!20,minimum width=6cm,minimum height=5cm,right of = process_2,xshift=8.2cm,text width=4cm,align=center]{};
\node(text_3)[below of = process_3,yshift=-3cm,scale=1.5]{源语文本及其词格}; \node(text_3)[below of = process_3,yshift=-3cm,scale=1.5]{源语文本及其词格};
\node(cir_s)[cir,very thick, below of = process_3,xshift=-2.2cm,yshift=1.1cm]{\LARGE S}; \node(cir_s)[cir,very thick, below of = process_3,xshift=-2.2cm,yshift=1.1cm]{\LARGE S};
\node(cir_a)[cir,right of = cir_s,xshift=1cm,yshift=0.8cm]{\LARGE a}; \node(cir_a)[cir,right of = cir_s,xshift=1cm,yshift=0.8cm]{\LARGE a};
...@@ -33,7 +33,7 @@ ...@@ -33,7 +33,7 @@
\node(text)[below of = process_3,yshift=-1.8cm,scale=1.8]{你是谁}; \node(text)[below of = process_3,yshift=-1.8cm,scale=1.8]{你是谁};
\node(process_4)[process,right of = process_3,xshift=8.2cm,text width=4cm,align=center]{\Large\textbf{Who are you?}}; \node(process_4)[process,fill=ugreen!20,right of = process_3,xshift=8.2cm,text width=4cm,align=center]{\Large\textbf{Who are you?}};
\node(text_4)[below of = process_4,yshift=-2cm,scale=1.5]{翻译译文}; \node(text_4)[below of = process_4,yshift=-2cm,scale=1.5]{翻译译文};
\draw[->,very thick](process_1.east)to(process_2.west); \draw[->,very thick](process_1.east)to(process_2.west);
......
...@@ -14,7 +14,7 @@ ...@@ -14,7 +14,7 @@
\node[anchor=west,minimum width=1.2em,minimum height=2.2em] (w8) at ([xshift=0.2em]w7.east){{l}}; \node[anchor=west,minimum width=1.2em,minimum height=2.2em] (w8) at ([xshift=0.2em]w7.east){{l}};
\node[anchor=west,minimum width=1.2em,minimum height=2.2em] (w9) at ([xshift=0.2em]w8.east){{o}}; \node[anchor=west,minimum width=1.2em,minimum height=2.2em] (w9) at ([xshift=0.2em]w8.east){{o}};
\node[anchor=west,minimum width=1.2em,minimum height=2.2em] (w10) at ([xshift=0.2em]w9.east){{o}}; \node[anchor=west,minimum width=1.2em,minimum height=2.2em] (w10) at ([xshift=0.2em]w9.east){{o}};
\node[anchor=west,minimum width=1.2em,minimum height=2.2em] (w11) at ([xshift=0.2em]w10.east){{!}}; \node[anchor=west,minimum width=1.2em,minimum height=2.2em] (w11) at ([xshift=0.2em]w10.east){{}};
\draw[very thick] (w1.south west) -- (w1.south east); \draw[very thick] (w1.south west) -- (w1.south east);
\draw[very thick] (w2.south west) -- (w2.south east); \draw[very thick] (w2.south west) -- (w2.south east);
...@@ -24,7 +24,7 @@ ...@@ -24,7 +24,7 @@
\draw[very thick] (w8.south west) -- (w8.south east); \draw[very thick] (w8.south west) -- (w8.south east);
\draw[very thick] (w9.south west) -- (w9.south east); \draw[very thick] (w9.south west) -- (w9.south east);
\draw[very thick] (w10.south west) -- (w10.south east); \draw[very thick] (w10.south west) -- (w10.south east);
\draw[very thick] (w11.south west) -- (w11.south east); %\draw[very thick] (w11.south west) -- (w11.south east);
\node[anchor=north,minimum width=1.2em,minimum height=1.4em,fill=gray!30] (m1) at ([yshift=-1em]w1.south){{h}}; \node[anchor=north,minimum width=1.2em,minimum height=1.4em,fill=gray!30] (m1) at ([yshift=-1em]w1.south){{h}};
\node[anchor=north,minimum width=2.64em,minimum height=1.4em,fill=gray!30] (m2) at ([yshift=-1em,xshift=0.72em]w2.south){{e}}; \node[anchor=north,minimum width=2.64em,minimum height=1.4em,fill=gray!30] (m2) at ([yshift=-1em,xshift=0.72em]w2.south){{e}};
...@@ -33,14 +33,14 @@ ...@@ -33,14 +33,14 @@
\node[anchor=north,minimum width=1.2em,minimum height=1.4em,fill=gray!30] (m5) at ([yshift=-1em]w6.south){}; \node[anchor=north,minimum width=1.2em,minimum height=1.4em,fill=gray!30] (m5) at ([yshift=-1em]w6.south){};
\node[anchor=north,minimum width=2.64em,minimum height=1.4em,fill=gray!30] (m6) at ([yshift=-1em,xshift=0.72em]w7.south){{l}}; \node[anchor=north,minimum width=2.64em,minimum height=1.4em,fill=gray!30] (m6) at ([yshift=-1em,xshift=0.72em]w7.south){{l}};
\node[anchor=north,minimum width=2.64em,minimum height=1.4em,fill=gray!30] (m7) at ([yshift=-1em,xshift=0.72em]w9.south){{o}}; \node[anchor=north,minimum width=2.64em,minimum height=1.4em,fill=gray!30] (m7) at ([yshift=-1em,xshift=0.72em]w9.south){{o}};
\node[anchor=north,minimum width=1.2em,minimum height=1.4em,fill=gray!30] (m8) at ([yshift=-1em]w11.south){{!}}; \node[anchor=north,minimum width=1.2em,minimum height=1.4em,fill=gray!30] (m8) at ([yshift=-1em]w11.south){};
\node[anchor=north,minimum width=1.2em,minimum height=1.4em,fill=gray!30] (o1) at ([yshift=-3.8em]w1.south){{h}}; \node[anchor=north,minimum width=1.2em,minimum height=1.4em,fill=gray!30] (o1) at ([yshift=-3.8em]w1.south){{h}};
\node[anchor=north,minimum width=1.2em,minimum height=1.4em,fill=gray!30] (o2) at ([yshift=-3.8em]w2.south){{e}}; \node[anchor=north,minimum width=1.2em,minimum height=1.4em,fill=gray!30] (o2) at ([yshift=-3.8em]w2.south){{e}};
\node[anchor=north,minimum width=1.2em,minimum height=1.4em,fill=gray!30] (o3) at ([yshift=-3.8em]w3.south){{l}}; \node[anchor=north,minimum width=1.2em,minimum height=1.4em,fill=gray!30] (o3) at ([yshift=-3.8em]w3.south){{l}};
\node[anchor=north,minimum width=1.2em,minimum height=1.4em,fill=gray!30] (o4) at ([yshift=-3.8em]w4.south){{l}}; \node[anchor=north,minimum width=1.2em,minimum height=1.4em,fill=gray!30] (o4) at ([yshift=-3.8em]w4.south){{l}};
\node[anchor=north,minimum width=1.2em,minimum height=1.4em,fill=gray!30] (o5) at ([yshift=-3.8em]w5.south){{o}}; \node[anchor=north,minimum width=1.2em,minimum height=1.4em,fill=gray!30] (o5) at ([yshift=-3.8em]w5.south){{o}};
\node[anchor=north,minimum width=1.2em,minimum height=1.4em,fill=gray!30] (o6) at ([yshift=-3.8em]w6.south){{!}}; \node[anchor=north,minimum width=1.2em,minimum height=1.4em,fill=gray!30] (o6) at ([yshift=-3.8em]w6.south){};
\node[anchor=north,minimum width=1.2em,minimum height=1.4em,fill=gray!30] at ([yshift=-3.8em]w7.south){}; \node[anchor=north,minimum width=1.2em,minimum height=1.4em,fill=gray!30] at ([yshift=-3.8em]w7.south){};
\node[anchor=north,minimum width=1.2em,minimum height=1.4em,fill=gray!30] at ([yshift=-3.8em]w8.south){}; \node[anchor=north,minimum width=1.2em,minimum height=1.4em,fill=gray!30] at ([yshift=-3.8em]w8.south){};
\node[anchor=north,minimum width=1.2em,minimum height=1.4em,fill=gray!30] at ([yshift=-3.8em]w9.south){}; \node[anchor=north,minimum width=1.2em,minimum height=1.4em,fill=gray!30] at ([yshift=-3.8em]w9.south){};
...@@ -52,7 +52,7 @@ ...@@ -52,7 +52,7 @@
\draw[blue!40,fill=blue!30,opacity=0.7] (w5.south west) -- (w5.south east) -- (m4.south east) .. controls ([yshift=-0.3em]m4.south east) and ([yshift=0.3em]o3.north east) .. (o3.north east) -- (o3.south east) -- (o3.south west) -- (o3.north west) .. controls ([yshift=0.3em]o3.north west) and ([yshift=-0.3em]m4.south west) .. (m4.south west) -- (w5.south west); \draw[blue!40,fill=blue!30,opacity=0.7] (w5.south west) -- (w5.south east) -- (m4.south east) .. controls ([yshift=-0.3em]m4.south east) and ([yshift=0.3em]o3.north east) .. (o3.north east) -- (o3.south east) -- (o3.south west) -- (o3.north west) .. controls ([yshift=0.3em]o3.north west) and ([yshift=-0.3em]m4.south west) .. (m4.south west) -- (w5.south west);
\draw[blue!40,fill=blue!30,opacity=0.7] (w7.south west) -- (w8.south east) -- (m6.south east) .. controls ([yshift=-0.3em]m6.south east) and ([yshift=0.3em]o4.north east) .. (o4.north east) -- (o4.south east) -- (o4.south west) -- (o4.north west) .. controls ([yshift=0.3em]o4.north west) and ([yshift=-0.3em]m6.south west) .. (m6.south west) -- (w7.south west); \draw[blue!40,fill=blue!30,opacity=0.7] (w7.south west) -- (w8.south east) -- (m6.south east) .. controls ([yshift=-0.3em]m6.south east) and ([yshift=0.3em]o4.north east) .. (o4.north east) -- (o4.south east) -- (o4.south west) -- (o4.north west) .. controls ([yshift=0.3em]o4.north west) and ([yshift=-0.3em]m6.south west) .. (m6.south west) -- (w7.south west);
\draw[blue!40,fill=blue!30,opacity=0.7] (w9.south west) -- (w10.south east) -- (m7.south east) .. controls ([yshift=-0.1em]m7.south east) and ([yshift=0.2em]o5.north east) .. (o5.north east) -- (o5.south east) -- (o5.south west) -- (o5.north west) .. controls ([yshift=0.1em]o5.north west) and ([yshift=-0.5em]m7.south west) .. (m7.south west) -- (w9.south west); \draw[blue!40,fill=blue!30,opacity=0.7] (w9.south west) -- (w10.south east) -- (m7.south east) .. controls ([yshift=-0.1em]m7.south east) and ([yshift=0.2em]o5.north east) .. (o5.north east) -- (o5.south east) -- (o5.south west) -- (o5.north west) .. controls ([yshift=0.1em]o5.north west) and ([yshift=-0.5em]m7.south west) .. (m7.south west) -- (w9.south west);
\draw[blue!40,fill=blue!30,opacity=0.7] (w11.south west) -- (w11.south east) -- (m8.south east) .. controls ([yshift=-0.4em]m8.south east) and ([yshift=0.1em]o6.north east) .. (o6.north east) -- (o6.south east) -- (o6.south west) -- (o6.north west) .. controls ([yshift=0.1em]o6.north west) and ([yshift=-0.5em]m8.south west) .. (m8.south west) -- (w11.south west); %\draw[blue!40,fill=blue!30,opacity=0.7] (w11.south west) -- (w11.south east) -- (m8.south east) .. controls ([yshift=-0.4em]m8.south east) and ([yshift=0.1em]o6.north east) .. (o6.north east) -- (o6.south east) -- (o6.south west) -- (o6.north west) .. controls ([yshift=0.1em]o6.north west) and ([yshift=-0.5em]m8.south west) .. (m8.south west) -- (w11.south west);
\node[anchor=north,font=\scriptsize,align=center] (a2) at ([yshift=-1.4em]a1.south) {预测字母序列}; \node[anchor=north,font=\scriptsize,align=center] (a2) at ([yshift=-1.4em]a1.south) {预测字母序列};
\node[anchor=north,font=\scriptsize,align=center] (a3) at ([yshift=-1.8em]a2.south) {合并重复字母 \\ 并丢弃$\epsilon$}; \node[anchor=north,font=\scriptsize,align=center] (a3) at ([yshift=-1.8em]a2.south) {合并重复字母 \\ 并丢弃$\epsilon$};
......
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
\begin{tikzpicture}[node distance = 0,scale = 1] \begin{tikzpicture}[node distance = 0,scale = 1]
\tikzstyle{every node}=[scale=1] \tikzstyle{every node}=[scale=1]
\node [anchor=center](ori) at (-0.2,-0.2) {$O$}; \node [anchor=center](ori) at (-0.2,-0.2) {$O$};
\draw[->,thick](-0.5,0)--(5,0)node[below]{$t$}; \draw[->,thick](-0.5,0)--(5,0)node[below,scale=0.8]{时间};
\draw[->,thick](0,-2)--(0,2)node[left,scale=0.8]{量化值}; \draw[->,thick](0,-2)--(0,2)node[left,scale=0.8]{量化值};
\draw[-,thick](0,0)sin(0.7,1.5)cos(1.4,0)sin(2.1,-1.5)cos(2.8,0)sin(3.5,1.5)cos(4.2,0); \draw[-,thick](0,0)sin(0.7,1.5)cos(1.4,0)sin(2.1,-1.5)cos(2.8,0)sin(3.5,1.5)cos(4.2,0);
\draw[-,thick,dashed](0.5,-1.8)--(0.5,1.8); \draw[-,thick,dashed](0.5,-1.8)--(0.5,1.8);
...@@ -12,5 +12,5 @@ ...@@ -12,5 +12,5 @@
\draw[-,thick,dashed](1.9,-1.8)--(1.9,1.8); \draw[-,thick,dashed](1.9,-1.8)--(1.9,1.8);
\draw[<->,thick](0,-1.1)--(1.2,-1.1)node[left,xshift=-0.05cm,yshift=0.15cm,scale=0.6]{帧长}; \draw[<->,thick](0,-1.1)--(1.2,-1.1)node[left,xshift=-0.05cm,yshift=0.15cm,scale=0.6]{帧长};
\draw[<->,thick](0,-1.4)--(0.5,-1.4)node[left,xshift=0.05cm,yshift=-0.25cm,scale=0.6]{帧移}; \draw[<->,thick](0,-1.4)--(0.5,-1.4)node[left,xshift=0.05cm,yshift=-0.25cm,scale=0.6]{帧移};
\draw[<->,thick](0.5,-1.4)--(1.9,-1.4); %\draw[<->,thick](0.5,-1.4)--(1.9,-1.4);
\end{tikzpicture} \end{tikzpicture}
\ No newline at end of file
...@@ -20,11 +20,11 @@ ...@@ -20,11 +20,11 @@
\foreach \x in {1,2}{ \foreach \x in {1,2}{
\draw[-,line width=2pt] (A\x) -- ([xshift=3.6em]A\x) -- ([xshift=3.6em,yshift=-3em]A\x) -- ([yshift=-3em]A\x) -- (A\x) -- ([xshift=1em]A\x); \draw[-,line width=2pt] (A\x) -- ([xshift=3.6em]A\x) -- ([xshift=3.6em,yshift=-3em]A\x) -- ([yshift=-3em]A\x) -- (A\x) -- ([xshift=1em]A\x);
\draw[-, very thick] (B\x) -- (C\x) -- (D\x) -- (B\x); \draw[-, thick] (B\x) -- (C\x) -- (D\x) -- (B\x);
\draw[-, very thick,fill=black] ([xshift=-0.6em,yshift=-1.2em]B\x) -- ([xshift=-0.3em,yshift=-1em]B\x) -- ([yshift=-1.2em]B\x) --([xshift=0.3em,yshift=-1em]B\x) -- ([xshift=0.6em,yshift=-1.2em]B\x) -- (D\x) -- (C\x) -- ([xshift=-0.6em,yshift=-1.2em]B\x); \draw[-, thick,fill=black] ([xshift=-0.6em,yshift=-1.2em]B\x) -- ([xshift=-0.3em,yshift=-1em]B\x) -- ([yshift=-1.2em]B\x) --([xshift=0.3em,yshift=-1em]B\x) -- ([xshift=0.6em,yshift=-1.2em]B\x) -- (D\x) -- (C\x) -- ([xshift=-0.6em,yshift=-1.2em]B\x);
\draw[-, very thick,fill=black] (E\x) -- ([xshift=0.2em,yshift=0.3em]E\x) -- ([xshift=0.33em]F\x) -- (F\x) -- (E\x); \draw[-, thick,fill=black] (E\x) -- ([xshift=0.2em,yshift=0.3em]E\x) -- ([xshift=0.33em]F\x) -- (F\x) -- (E\x);
\node[circle,inner sep=0pt,minimum size=0.4em,fill=black] at ([xshift=-0.7em,yshift=-0.2em]B\x){}; \node[circle,inner sep=0pt,minimum size=0.4em,fill=black] at ([xshift=-0.7em,yshift=-0.2em]B\x){};
\node[draw,rounded corners=2pt,fill=yellow!20,minimum width=2.3cm,minimum height=1cm](cnn\x) at ([xshift=9.5em,yshift=-1.5em]A\x){CNN}; \node[draw,rounded corners=2pt,fill=yellow!20,minimum height=2.2em,minimum width=4.3em](cnn\x) at ([xshift=9.5em,yshift=-1.5em]A\x){CNN};
\node[draw,circle,fill=green!20,font=\footnotesize,anchor=west,inner sep=3pt] (h\x_2) at ([xshift=3em,yshift=0.66em]cnn\x.east){$h_2$}; \node[draw,circle,fill=green!20,font=\footnotesize,anchor=west,inner sep=3pt] (h\x_2) at ([xshift=3em,yshift=0.66em]cnn\x.east){$h_2$};
\node[draw,circle,fill=green!20,font=\footnotesize,anchor=south,inner sep=3pt] (h\x_1) at ([yshift=1em]h\x_2.north){$h_1$}; \node[draw,circle,fill=green!20,font=\footnotesize,anchor=south,inner sep=3pt] (h\x_1) at ([yshift=1em]h\x_2.north){$h_1$};
\node[font=\footnotesize,anchor=north] (h\x_c) at ([yshift=-0.6em]h\x_2.south){$\cdots$}; \node[font=\footnotesize,anchor=north] (h\x_c) at ([yshift=-0.6em]h\x_2.south){$\cdots$};
...@@ -36,11 +36,11 @@ ...@@ -36,11 +36,11 @@
\node[draw,thick,rounded corners=2pt,densely dashed,inner ysep=1.2em,inner xsep=0.4em,label={above:图像特征向量}][fit=(h2_1)(h2_2)(h2_n)](box2){}; \node[draw,thick,rounded corners=2pt,densely dashed,inner ysep=1.2em,inner xsep=0.4em,label={above:图像特征向量}][fit=(h2_1)(h2_2)(h2_n)](box2){};
\end{pgfonlayer} \end{pgfonlayer}
\node[anchor=west,draw,rounded corners=2pt,fill=blue!20,minimum width=2.3cm,minimum height=1cm] (decoder1)at ([xshift=3em]box1.east){解码器}; \node[anchor=west,draw,rounded corners=2pt,fill=red!20,minimum height=2.2em,minimum width=4.3em] (decoder1)at ([xshift=3em]box1.east){解码器};
\node[anchor=west,draw,circle,inner sep=0pt,minimum size=1.4em] (add)at ([xshift=2em,yshift=1.6em]box2.east){}; \node[anchor=west,draw,circle,inner sep=0pt,minimum size=1.4em] (add)at ([xshift=2em,yshift=1.6em]box2.east){};
\draw[] (add.0) -- (add.180); \draw[] (add.0) -- (add.180);
\draw[] (add.90) -- (add.-90); \draw[] (add.90) -- (add.-90);
\node[anchor=west,draw,rounded corners=2pt,fill=blue!20,minimum width=2.3cm,minimum height=1cm] (decoder2)at ([xshift=6em]box2.east){解码器}; \node[anchor=west,draw,rounded corners=2pt,fill=red!20,minimum height=2.2em,minimum width=4.3em] (decoder2)at ([xshift=6em]box2.east){解码器};
\draw[->,thick] ([xshift=-2.7em]cnn1.180) -- ([xshift=-0.1em]cnn1.180); \draw[->,thick] ([xshift=-2.7em]cnn1.180) -- ([xshift=-0.1em]cnn1.180);
......
...@@ -94,10 +94,10 @@ ...@@ -94,10 +94,10 @@
\node [draw,single arrow,minimum height=2.4em,single arrow head extend=0.4em] (arrow3) at ([xshift=-2.4em,yshift=-1.5em]A4) {}; \node [draw,single arrow,minimum height=2.4em,single arrow head extend=0.4em] (arrow3) at ([xshift=-2.4em,yshift=-1.5em]A4) {};
\node [draw,single arrow,minimum height=2.4em,single arrow head extend=0.4em] (arrow4) at ([xshift=-2.5em,yshift=-1.5em]A5) {}; \node [draw,single arrow,minimum height=2.4em,single arrow head extend=0.4em] (arrow4) at ([xshift=-2.5em,yshift=-1.5em]A5) {};
\node[anchor=north,font=\small,scale=1.5] at ([yshift=-6em]arrow1.south){(a)多模态机器翻译}; \node[anchor=north,font=\small,scale=1.5] at ([yshift=-6em]arrow1.south){(a) 多模态机器翻译};
\node[anchor=north,font=\small,scale=1.5] at ([yshift=-6em]arrow2.south){(b)图像到文本翻译}; \node[anchor=north,font=\small,scale=1.5] at ([yshift=-6em]arrow2.south){(b) 图像到文本翻译};
\node[anchor=north,font=\small,scale=1.5] at ([yshift=-6em]arrow3.south){(c)图像到图像翻译}; \node[anchor=north,font=\small,scale=1.5] at ([yshift=-6em]arrow3.south){(c) 图像到图像翻译};
\node[anchor=north,font=\small,scale=1.5] at ([yshift=-6em]arrow4.south){(d)文本到图像翻译}; \node[anchor=north,font=\small,scale=1.5] at ([yshift=-6em]arrow4.south){(d) 文本到图像翻译};
\end{tikzpicture} \end{tikzpicture}
%------------------------------------------------------------------------------------------------------------ %------------------------------------------------------------------------------------------------------------
...@@ -24,13 +24,12 @@ ...@@ -24,13 +24,12 @@
\draw[-, very thick,fill=black] ([xshift=-0.6em,yshift=-1.2em]B\x) -- ([xshift=-0.3em,yshift=-1em]B\x) -- ([yshift=-1.2em]B\x) --([xshift=0.3em,yshift=-1em]B\x) -- ([xshift=0.6em,yshift=-1.2em]B\x) -- (D\x) -- (C\x) -- ([xshift=-0.6em,yshift=-1.2em]B\x); \draw[-, very thick,fill=black] ([xshift=-0.6em,yshift=-1.2em]B\x) -- ([xshift=-0.3em,yshift=-1em]B\x) -- ([yshift=-1.2em]B\x) --([xshift=0.3em,yshift=-1em]B\x) -- ([xshift=0.6em,yshift=-1.2em]B\x) -- (D\x) -- (C\x) -- ([xshift=-0.6em,yshift=-1.2em]B\x);
\draw[-, very thick,fill=black] (E\x) -- ([xshift=0.2em,yshift=0.3em]E\x) -- ([xshift=0.33em]F\x) -- (F\x) -- (E\x); \draw[-, very thick,fill=black] (E\x) -- ([xshift=0.2em,yshift=0.3em]E\x) -- ([xshift=0.33em]F\x) -- (F\x) -- (E\x);
\node[circle,inner sep=0pt,minimum size=0.4em,fill=black] at ([xshift=-0.7em,yshift=-0.2em]B\x){}; \node[circle,inner sep=0pt,minimum size=0.4em,fill=black] at ([xshift=-0.7em,yshift=-0.2em]B\x){};
\node[draw,rounded corners=2pt,fill=yellow!20,minimum width=2.3cm,minimum height=1cm](cnn\x) at ([xshift=1.8em,yshift=3.6em]A\x){CNN}; \node[draw,rounded corners=2pt,fill=yellow!20,minimum width=2.3cm,minimum height=2.2em](cnn\x) at ([xshift=1.8em,yshift=3.6em]A\x){CNN};
} }
\node[draw,anchor=south,rounded corners=2pt,minimum width=4.0cm,minimum height=2.2em,fill=red!20](encoder) at ([yshift=2.6em,xshift=2.2em]cnn1.north){编码器};
\node[draw,anchor=south,rounded corners=2pt,minimum width=4.0cm,minimum height=1cm,fill=red!20](encoder) at ([yshift=2.6em,xshift=2.2em]cnn1.north){编码器};
\node[anchor=north,font=\Large](x) at ([xshift=2.5em,yshift=-3.4em]encoder.south){$\seq{x}$}; \node[anchor=north,font=\Large](x) at ([xshift=2.5em,yshift=-3.4em]encoder.south){$\seq{x}$};
\node[draw,anchor=south,rounded corners=2pt,minimum width=4.0cm,minimum height=1cm,fill=blue!20](decoder) at ([yshift=2.6em,xshift=2.2em]cnn2.north){解码器}; \node[draw,anchor=south,rounded corners=2pt,minimum width=4.0cm,minimum height=2.2em,fill=ugreen!20](decoder) at ([yshift=2.6em,xshift=2.2em]cnn2.north){解码器};
\node[anchor=north,font=\Large](y) at ([xshift=2.5em,yshift=-3.4em]decoder.south){$\seq{y}$}; \node[anchor=north,font=\Large](y) at ([xshift=2.5em,yshift=-3.4em]decoder.south){$\seq{y}$};
\node[anchor=south,font=\Large](y_1) at ([yshift=3em]decoder.north){$\seq{y}'$}; \node[anchor=south,font=\Large](y_1) at ([yshift=3em]decoder.north){$\seq{y}'$};
......
...@@ -17,11 +17,11 @@ ...@@ -17,11 +17,11 @@
\node[layer,anchor=south,fill=red!20] (de_ca) at ([yshift=1.4em]de_sa.north){Multi-Head \\ Attention}; \node[layer,anchor=south,fill=red!20] (de_ca) at ([yshift=1.4em]de_sa.north){Multi-Head \\ Attention};
\node[layer,anchor=south,fill=green!20] (de_ffn) at ([yshift=1.4em]de_ca.north){Feed Forward \\ Network}; \node[layer,anchor=south,fill=green!20] (de_ffn) at ([yshift=1.4em]de_ca.north){Feed Forward \\ Network};
\node[layer,anchor=south,fill=blue!20] (sf) at ([yshift=2em]de_ffn.north){Softmax}; \node[layer,anchor=south,fill=blue!20] (sf) at ([yshift=1.6em]de_ffn.north){Softmax};
\node[layer,anchor=south,fill=orange!20] (output) at ([yshift=1.4em]sf.north){Output Probabilities}; %\node[layer,anchor=south,fill=orange!20] (output) at ([yshift=1.4em]sf.north){Output Probabilities};
\node[anchor=north,font=\scriptsize,align=center] (en_input) at ([yshift=-1em]en_cnn.south){Speech Feature\\(FilterBank/MFCC)}; \node[anchor=north,font=\scriptsize,align=center] (en_input) at ([yshift=-1em]en_cnn.south){Speech Feature\\(FBank/MFCC)};
\node[anchor=north,font=\scriptsize,align=center] (de_input) at ([yshift=-1em]de_add.south){Transcription\\(Embedding)}; \node[anchor=north,font=\scriptsize,align=center] (de_input) at ([yshift=-1.1em]de_add.south){Transcription\\(Embedding)};
\node[anchor=east,font=\scriptsize,align=center] (en_pos) at ([xshift=-2em]en_add.west){Position\\(Embedding)}; \node[anchor=east,font=\scriptsize,align=center] (en_pos) at ([xshift=-2em]en_add.west){Position\\(Embedding)};
\node[anchor=west,font=\scriptsize,align=center] (de_pos) at ([xshift=2em]de_add.east){Position\\(Embedding)}; \node[anchor=west,font=\scriptsize,align=center] (de_pos) at ([xshift=2em]de_add.east){Position\\(Embedding)};
...@@ -35,13 +35,13 @@ ...@@ -35,13 +35,13 @@
\draw[->] ([yshift=0.1em]de_sa.90) -- ([yshift=-0.1em]de_ca.-90); \draw[->] ([yshift=0.1em]de_sa.90) -- ([yshift=-0.1em]de_ca.-90);
\draw[->] ([yshift=0.1em]de_ca.90) -- ([yshift=-0.1em]de_ffn.-90); \draw[->] ([yshift=0.1em]de_ca.90) -- ([yshift=-0.1em]de_ffn.-90);
\draw[->] ([yshift=0.1em]de_ffn.90) -- ([yshift=-0.1em]sf.-90); \draw[->] ([yshift=0.1em]de_ffn.90) -- ([yshift=-0.1em]sf.-90);
\draw[->] ([yshift=0.1em]sf.90) -- ([yshift=-0.1em]output.-90); \draw[->] ([yshift=0.1em]sf.90) -- ([yshift=1.5em]sf.90);
\draw[->] ([xshift=0.1em]en_pos.0) -- ([xshift=-0.1em]en_add.180); \draw[->] ([xshift=0.1em]en_pos.0) -- ([xshift=-0.1em]en_add.180);
\draw[->] ([xshift=-0.1em]de_pos.180) -- ([xshift=0.1em]de_add.0); \draw[->] ([xshift=-0.1em]de_pos.180) -- ([xshift=0.1em]de_add.0);
\draw[->,rounded corners=2pt] ([yshift=0.1em]en_ffn.90) -- ([yshift=2em]en_ffn.90) -- ([xshift=4em,yshift=2em]en_ffn.90) -- ([xshift=-1.5em]de_ca.west) -- ([xshift=-0.1em]de_ca.west); \draw[->,rounded corners=2pt] ([yshift=0.1em]en_ffn.90) -- ([yshift=2em]en_ffn.90) -- ([xshift=4em,yshift=2em]en_ffn.90) -- ([xshift=-1.5em]de_ca.west) -- ([xshift=-0.1em]de_ca.west);
\begin{pgfonlayer}{background} \begin{pgfonlayer}{background}
\node[draw=ugreen,rounded corners=2pt,inner xsep=6pt,inner ysep=8pt][fit=(en_sa)(en_ffn)](box1){}; \node[draw=ugreen,rounded corners=2pt,inner xsep=6pt,inner ysep=8pt,dashed,thick][fit=(en_sa)(en_ffn)](box1){};
\node[draw=red,rounded corners=2pt,inner xsep=6pt,inner ysep=8pt][fit=(de_sa)(de_ca)(de_ffn)](box2){}; \node[draw=red,rounded corners=2pt,inner xsep=6pt,inner ysep=8pt,dashed,thick][fit=(de_sa)(de_ca)(de_ffn)](box2){};
\end{pgfonlayer} \end{pgfonlayer}
\node[anchor=east,font=\scriptsize,text=ugreen] at ([xshift=-0.1em]box1.west){$N \times$}; \node[anchor=east,font=\scriptsize,text=ugreen] at ([xshift=-0.1em]box1.west){$N \times$};
......
...@@ -19,11 +19,11 @@ ...@@ -19,11 +19,11 @@
\node[layer,anchor=south,fill=blue!20] (en_sf) at ([yshift=3em]en_ffn.north){Softmax}; \node[layer,anchor=south,fill=blue!20] (en_sf) at ([yshift=3em]en_ffn.north){Softmax};
\node[layer,anchor=south,fill=blue!20] (sf) at ([yshift=2em]de_ffn.north){Softmax}; \node[layer,anchor=south,fill=blue!20] (sf) at ([yshift=2em]de_ffn.north){Softmax};
\node[layer,anchor=south,fill=orange!20] (en_output) at ([yshift=1.4em]en_sf.north){CTC输出}; \node[layer,anchor=south,fill=orange!20] (en_output) at ([yshift=1.4em]en_sf.north){CTC Output};
\node[layer,anchor=south,fill=orange!20] (output) at ([yshift=1.4em]sf.north){语音翻译输出}; %\node[layer,anchor=south,fill=orange!20] (output) at ([yshift=1.4em]sf.north){ST Output};
\node[anchor=north,font=\scriptsize,align=center] (en_input) at ([yshift=-1em]en_cnn.south){语音特征\\(FilterBank/MFCC)}; \node[anchor=north,font=\scriptsize,align=center] (en_input) at ([yshift=-1em]en_cnn.south){Speech Feature\\(FBank/MFCC)};
\node[anchor=north,font=\scriptsize,align=center] (de_input) at ([yshift=-1em]de_add.south){目标文本\\(Embedding)}; \node[anchor=north,font=\scriptsize,align=center] (de_input) at ([yshift=-1em]de_add.south){Target Text\\(Embedding)};
\node[anchor=east,font=\scriptsize,align=center] (en_pos) at ([xshift=-2em]en_add.west){Position\\(Embedding)}; \node[anchor=east,font=\scriptsize,align=center] (en_pos) at ([xshift=-2em]en_add.west){Position\\(Embedding)};
\node[anchor=west,font=\scriptsize,align=center] (de_pos) at ([xshift=2em]de_add.east){Position\\(Embedding)}; \node[anchor=west,font=\scriptsize,align=center] (de_pos) at ([xshift=2em]de_add.east){Position\\(Embedding)};
...@@ -39,18 +39,18 @@ ...@@ -39,18 +39,18 @@
\draw[->] ([yshift=0.1em]en_ffn.90) -- ([yshift=-0.1em]en_sf.-90); \draw[->] ([yshift=0.1em]en_ffn.90) -- ([yshift=-0.1em]en_sf.-90);
\draw[->] ([yshift=0.1em]en_sf.90) -- ([yshift=-0.1em]en_output.-90); \draw[->] ([yshift=0.1em]en_sf.90) -- ([yshift=-0.1em]en_output.-90);
\draw[->] ([yshift=0.1em]de_ffn.90) -- ([yshift=-0.1em]sf.-90); \draw[->] ([yshift=0.1em]de_ffn.90) -- ([yshift=-0.1em]sf.-90);
\draw[->] ([yshift=0.1em]sf.90) -- ([yshift=-0.1em]output.-90); \draw[->] ([yshift=0.1em]sf.90) -- ([yshift=1.5em]sf.90);
\draw[->] ([xshift=0.1em]en_pos.0) -- ([xshift=-0.1em]en_add.180); \draw[->] ([xshift=0.1em]en_pos.0) -- ([xshift=-0.1em]en_add.180);
\draw[->] ([xshift=-0.1em]de_pos.180) -- ([xshift=0.1em]de_add.0); \draw[->] ([xshift=-0.1em]de_pos.180) -- ([xshift=0.1em]de_add.0);
\draw[->,rounded corners=2pt] ([yshift=2em]en_ffn.90) -- ([xshift=4em,yshift=2em]en_ffn.90) -- ([xshift=-1.5em]de_ca.west) -- ([xshift=-0.1em]de_ca.west); \draw[->,rounded corners=2pt] ([yshift=2em]en_ffn.90) -- ([xshift=4em,yshift=2em]en_ffn.90) -- ([xshift=-1.5em]de_ca.west) -- ([xshift=-0.1em]de_ca.west);
\begin{pgfonlayer}{background} \begin{pgfonlayer}{background}
\node[draw=ugreen,rounded corners=2pt,inner xsep=6pt,inner ysep=8pt][fit=(en_sa)(en_ffn)]{}; \node[draw=ugreen,rounded corners=2pt,inner xsep=6pt,inner ysep=8pt,dashed,thick][fit=(en_sa)(en_ffn)]{};
\node[draw=red,rounded corners=2pt,inner xsep=6pt,inner ysep=8pt][fit=(de_sa)(de_ca)(de_ffn)]{}; \node[draw=red,rounded corners=2pt,inner xsep=6pt,inner ysep=8pt,dashed,thick][fit=(de_sa)(de_ca)(de_ffn)]{};
\end{pgfonlayer} \end{pgfonlayer}
\node[anchor=east,font=\scriptsize,text=ugreen] at ([xshift=-0.1em]box1.west){$N \times$}; \node[anchor=east,font=\scriptsize,text=ugreen] at ([xshift=-0.1em]box1.west){$N \times$};
\node[anchor=west,font=\scriptsize,text=red] at ([xshift=0.1em]box2.east){$\times N$}; \node[anchor=west,font=\scriptsize,text=red] at ([xshift=0.1em]box2.east){$\times N$};
\node[anchor=east,font=\scriptsize] at ([xshift=-0.1em]en_cnn.west){$2 \times$}; \node[anchor=east,font=\scriptsize] at ([xshift=-0.1em]en_cnn.west){$2 \times$};
\node[anchor=east,font=\scriptsize,align=center,text=ugreen] at ([xshift=-0.1em,yshift=3em]box1.west){语音翻译\\编码器}; \node[anchor=east,font=\scriptsize,align=center,text=ugreen] at ([xshift=-0.1em,yshift=3em]box1.west){ST\\Encoder};
\node[anchor=west,font=\scriptsize,align=center,text=red] at ([xshift=0.1em,yshift=5em]box2.east){语音翻译\\解码器}; \node[anchor=west,font=\scriptsize,align=center,text=red] at ([xshift=0.1em,yshift=5em]box2.east){ST\\Decoder};
\end{tikzpicture} \end{tikzpicture}
\ No newline at end of file
...@@ -2,32 +2,32 @@ ...@@ -2,32 +2,32 @@
\begin{tikzpicture}[node distance = 0,scale = 0.9] \begin{tikzpicture}[node distance = 0,scale = 0.9]
\tikzstyle{every node}=[scale=0.9] \tikzstyle{every node}=[scale=0.9]
\node(figure)[draw=white,scale=0.4] {\includegraphics[width=0.62\textwidth]{./Chapter17/Figures/figure-bank-without-attention.png}}; \node(figure)[draw=white,scale=0.4] {\includegraphics[width=0.62\textwidth]{./Chapter17/Figures/figure-bank-without-attention.png}};
\node(river)[word, right of = figure, xshift=5cm, yshift=0.35cm, fill=blue!45]{river}; \node(river)[word, right of = figure, xshift=5cm, yshift=0.35cm, fill=ugreen!45]{river};
\node(mountain)[word, above of = river, yshift=0.75cm, fill=blue!45]{mountain}; \node(mountain)[word, above of = river, yshift=0.75cm, fill=ugreen!45]{mountain};
\node(child)[word, above of = mountain, yshift=0.75cm, fill=blue!15]{child}; \node(child)[word, above of = mountain, yshift=0.75cm, fill=ugreen!15]{child};
\node(man)[word, above of = child, yshift=0.75cm, fill=blue!25]{man}; \node(man)[word, above of = child, yshift=0.75cm, fill=ugreen!25]{man};
\node(jump)[word, below of = river, yshift=-0.75cm, fill=blue!30]{jump}; \node(jump)[word, below of = river, yshift=-0.75cm, fill=ugreen!30]{jump};
\node(bank)[word, below of = jump, yshift=-0.75cm, fill=blue!65]{bank}; \node(bank)[word, below of = jump, yshift=-0.75cm, fill=ugreen!65]{bank};
\node(sky)[word, below of = bank, yshift=-0.75cm, fill=blue!30]{sky}; \node(sky)[word, below of = bank, yshift=-0.75cm, fill=ugreen!30]{sky};
\node(tree)[word, below of = sky, yshift=-0.75cm, fill=blue!15]{tree}; \node(tree)[word, below of = sky, yshift=-0.75cm, fill=ugreen!15]{tree};
\node(cir)[circle,very thick, minimum width=0.6cm, xshift=8cm, draw=black]{}; \node(cir)[circle,thick, minimum width=0.6cm, xshift=8cm, draw=black]{};
\node(decoder)[rectangle, rounded corners, minimum width=2.5cm, minimum height=1.2cm, right of = cir,xshift=3cm, draw=black, fill=blue!25]{\large{解码器}}; \node(decoder)[rectangle, rounded corners, minimum height=2.2em,minimum width=4.3em, right of = cir,xshift=3cm, draw=black, fill=ugreen!25]{\large{解码器}};
\node(yn_1)[below of = decoder,yshift=-2cm,scale=1.2]{$\rm y_{n-1}$}; \node(yn_1)[below of = decoder,yshift=-2cm,scale=1.2]{$\rm y_{n-1}$};
\node(yn_2)[above of = decoder,yshift=2cm,scale=1.2]{$\rm y'_{n-1}$(bank)}; \node(yn_2)[above of = decoder,yshift=2cm,scale=1.2]{$\rm y'_{n-1}$(bank)};
\draw[->, very thick]([xshift=0.1cm]figure.east)to([xshift=2cm]figure.east); \draw[->, thick]([xshift=0.1cm]figure.east)to([xshift=2cm]figure.east);
\draw[-,very thick]([xshift=-0.03cm]cir.east)to([xshift=0.03cm]cir.west); \draw[-,thick]([xshift=-0.03cm]cir.east)to([xshift=0.03cm]cir.west);
\draw[-,very thick]([yshift=0.03cm]cir.south)to([yshift=-0.03cm]cir.north); \draw[-,thick]([yshift=0.03cm]cir.south)to([yshift=-0.03cm]cir.north);
\draw[->, very thick]([xshift=0.1cm]cir.east)to([xshift=-0.1cm]decoder.west); \draw[->, thick]([xshift=0.1cm]cir.east)to([xshift=-0.1cm]decoder.west);
\draw[->, very thick](yn_1)to([yshift=-0.1cm]decoder.south); \draw[->, thick](yn_1)to([yshift=-0.1cm]decoder.south);
\draw[->, very thick]([yshift=0.1cm]decoder.north)to(yn_2); \draw[->, thick]([yshift=0.1cm]decoder.north)to(yn_2);
\draw[->, thick, color=blue!45]([xshift=0.05cm]river.east)to([xshift=-0.05cm]cir.west); \draw[->, thick, color=ugreen!45]([xshift=0.05cm]river.east)to([xshift=-0.05cm]cir.west);
\draw[->, thick, color=blue!45]([xshift=0.05cm]mountain.east)to([xshift=-0.05cm]cir.west); \draw[->, thick, color=ugreen!45]([xshift=0.05cm]mountain.east)to([xshift=-0.05cm]cir.west);
\draw[->, thick, color=blue!15]([xshift=0.05cm]child.east)to([xshift=-0.05cm]cir.west); \draw[->, thick, color=ugreen!15]([xshift=0.05cm]child.east)to([xshift=-0.05cm]cir.west);
\draw[->, thick, color=blue!25]([xshift=0.05cm]man.east)to([xshift=-0.05cm]cir.west); \draw[->, thick, color=ugreen!25]([xshift=0.05cm]man.east)to([xshift=-0.05cm]cir.west);
\draw[->, thick, color=blue!30]([xshift=0.05cm]jump.east)to([xshift=-0.05cm]cir.west); \draw[->, thick, color=ugreen!30]([xshift=0.05cm]jump.east)to([xshift=-0.05cm]cir.west);
\draw[->, thick, color=blue!65]([xshift=0.05cm]bank.east)to([xshift=-0.05cm]cir.west); \draw[->, very thick, color=ugreen!65]([xshift=0.05cm]bank.east)to([xshift=-0.05cm]cir.west);
\draw[->, thick, color=blue!30]([xshift=0.05cm]sky.east)to([xshift=-0.05cm]cir.west); \draw[->, thick, color=ugreen!30]([xshift=0.05cm]sky.east)to([xshift=-0.05cm]cir.west);
\draw[->, thick, color=blue!15]([xshift=0.05cm]tree.east)to([xshift=-0.05cm]cir.west); \draw[->, thick, color=ugreen!15]([xshift=0.05cm]tree.east)to([xshift=-0.05cm]cir.west);
\end{tikzpicture} \end{tikzpicture}
\ No newline at end of file
\tikzstyle{coder} = [rectangle,thick,rounded corners,minimum width=2.3cm,minimum height=1cm,text centered,draw=black!70,fill=red!20] \tikzstyle{coder} = [rectangle,thick,rounded corners,minimum height=2.2em,minimum width=4.3em,text centered,draw=black!70,fill=red!20]
\begin{tikzpicture}[node distance = 0,scale = 0.75] \begin{tikzpicture}[node distance = 0,scale = 0.75]
\tikzstyle{every node}=[scale=0.75] \tikzstyle{every node}=[scale=0.75]
\node(encoder)[coder]at (0,0){\large{编码器}}; \node(encoder)[coder]at (0,0){\large{编码器}};
\node(decoder_1)[coder,above of =encoder,xshift=-1.6cm,yshift=2.8cm,fill=blue!20]{\large{解码器}}; \node(decoder_1)[coder,above of =encoder,xshift=-1.6cm,yshift=2.8cm,fill=ugreen!20]{\large{解码器}};
\node(decoder_2)[coder,above of =encoder, xshift=1.6cm,yshift=2.8cm,fill=yellow!20]{\large{解码器}}; \node(decoder_2)[coder,above of =encoder, xshift=1.6cm,yshift=2.8cm,fill=yellow!20]{\large{解码器}};
\node(s)[below of = encoder,yshift=-1.8cm,scale=1.6]{$s$}; \node(s)[below of = encoder,yshift=-1.8cm,scale=1.2]{$s$};
\node(x)[above of = decoder_1,yshift=1.8cm,scale=1.6]{$x$}; \node(x)[above of = decoder_1,yshift=1.8cm,scale=1.2]{$x$};
\node(y)[above of = decoder_2,yshift=1.8cm,scale=1.6]{$y$}; \node(y)[above of = decoder_2,yshift=1.8cm,scale=1.2]{$y$};
\draw[->,thick](s.north)to(encoder.south); \draw[->,thick](s.north)to(encoder.south);
\draw[->,thick](decoder_1.north)to(x.south); \draw[->,thick](decoder_1.north)to(x.south);
\draw[->,thick](decoder_2.north)to(y.south); \draw[->,thick](decoder_2.north)to(y.south);
\draw[->,thick](encoder.north)--([yshift=0.7cm]encoder.north)--([xshift=-4.16em,yshift=0.7cm]encoder.north)--(decoder_1.south); \draw[->,thick](encoder.north)--([yshift=0.7cm]encoder.north)--([xshift=-4.16em,yshift=0.7cm]encoder.north)--(decoder_1.south);
\draw[->,thick](encoder.north)--([yshift=0.7cm]encoder.north)--([xshift=4.16em,yshift=0.7cm]encoder.north)--(decoder_2.south); \draw[->,thick](encoder.north)--([yshift=0.7cm]encoder.north)--([xshift=4.16em,yshift=0.7cm]encoder.north)--(decoder_2.south);
\node [anchor=north,scale = 1.2](pos1) at (s.south) {(a) 单编码器-双解码器方式}; \node [anchor=north,scale = 1.2](pos1) at (s.south) {(a) 单编码器-双解码器};
\node [anchor=south,scale=1.2] (node1) at ([xshift=-2.0em,yshift=6em]decoder_1.north) {{$x,y$:语言数据}}; \node [anchor=south,scale=1.2] (node1) at ([xshift=-2.0em,yshift=6em]decoder_1.north) {{$x,y$:语言数据}};
\node [anchor=north,scale=1.2] (node2) at ([xshift=0.6em]node1.south){{$s$:语音数据}}; \node [anchor=north,scale=1.2] (node2) at ([xshift=0.6em]node1.south){{$s$:语音数据}};
%%%%%%%%%%%%%%%%%%%%%%%%级联 %%%%%%%%%%%%%%%%%%%%%%%%级联
\node(encoder-2)[coder]at ([xshift=10.0em]encoder.east){\large{编码器}}; \node(encoder-2)[coder]at ([xshift=12.0em]encoder.east){\large{编码器}};
\node(decoder_1-2)[coder,above of =encoder-2,yshift=1.4cm,fill=blue!20]{\large{解码器}}; \node(decoder_1-2)[coder,above of =encoder-2,yshift=1.4cm,fill=ugreen!20]{\large{解码器}};
\node(decoder_2-2)[coder,above of =decoder_1-2, yshift=1.4cm,fill=yellow!20]{\large{解码器}}; \node(decoder_2-2)[coder,above of =decoder_1-2, yshift=1.4cm,fill=yellow!20]{\large{解码器}};
\node(s-2)[below of = encoder-2,yshift=-1.8cm,scale=1.6]{$s$}; \node(s-2)[below of = encoder-2,yshift=-1.8cm,scale=1.2]{$s$};
\node(y-2)[above of = decoder_2-2,yshift=1.8cm,scale=1.6]{$y$}; \node(y-2)[above of = decoder_2-2,yshift=1.8cm,scale=1.2]{$y$};
\draw[->,thick](s-2.north)to(encoder-2.south); \draw[->,thick](s-2.north)to(encoder-2.south);
\draw[->,thick](encoder-2.north)to(decoder_1-2.south); \draw[->,thick](encoder-2.north)to(decoder_1-2.south);
\draw[->,thick](decoder_1-2.north)to(decoder_2-2.south); \draw[->,thick](decoder_1-2.north)to(decoder_2-2.south);
\draw[->,thick](decoder_2-2.north)to(y-2.south); \draw[->,thick](decoder_2-2.north)to(y-2.south);
\node [anchor=north,scale = 1.2](pos2) at (s-2.south) {(b) 级联编码器方式}; \node [anchor=north,scale = 1.2](pos2) at (s-2.south) {(b) 级联编码器};
%%%%%%%%%%%%%%%%%%%%%%%%联合 %%%%%%%%%%%%%%%%%%%%%%%%联合
\node(encoder-3)[coder]at([xshift=10.0em]encoder-2.east){\large{编码器}}; \node(encoder-3)[coder]at([xshift=10.0em]encoder-2.east){\large{编码器}};
\node(decoder_1-3)[coder,above of =encoder-3,xshift=-1.6cm,yshift=2.8cm,fill=blue!20]{\large{解码器}}; \node(decoder_1-3)[coder,above of =encoder-3,xshift=-1.6cm,yshift=2.8cm,fill=ugreen!20]{\large{解码器}};
\node(decoder_2-3)[coder,above of =encoder-3, xshift=1.6cm,yshift=2.8cm,fill=yellow!20]{\large{解码器}}; \node(decoder_2-3)[coder,above of =encoder-3, xshift=1.6cm,yshift=2.8cm,fill=yellow!20]{\large{解码器}};
\node(s-3)[below of = encoder-3,yshift=-1.8cm,scale=1.6]{$s$}; \node(s-3)[below of = encoder-3,yshift=-1.8cm,scale=1.2]{$s$};
\node(y-3)[above of = decoder_2-3,yshift=1.8cm,scale=1.6]{$y$}; \node(y-3)[above of = decoder_2-3,yshift=1.8cm,scale=1.2]{$y$};
\draw[->,thick](s-3.north)to(encoder-3.south); \draw[->,thick](s-3.north)to(encoder-3.south);
\draw[->,thick](decoder_1-3.east)to(decoder_2-3.west); \draw[->,thick](decoder_1-3.east)to(decoder_2-3.west);
\draw[->,thick](decoder_2-3.north)to(y-3.south); \draw[->,thick](decoder_2-3.north)to(y-3.south);
\draw[->,thick](encoder-3.north)--([yshift=0.7cm]encoder-3.north)--([xshift=-4.16em,yshift=0.7cm]encoder-3.north)--(decoder_1-3.south); \draw[->,thick](encoder-3.north)--([yshift=0.7cm]encoder-3.north)--([xshift=-4.16em,yshift=0.7cm]encoder-3.north)--(decoder_1-3.south);
\draw[->,thick](encoder-3.north)--([yshift=0.7cm]encoder-3.north)--([xshift=4.16em,yshift=0.7cm]encoder-3.north)--(decoder_2-3.south); \draw[->,thick](encoder-3.north)--([yshift=0.7cm]encoder-3.north)--([xshift=4.16em,yshift=0.7cm]encoder-3.north)--(decoder_2-3.south);
\node [anchor=north,scale = 1.2](pos3) at (s-3.south) {(c) 联合编码器方式}; \node [anchor=north,scale = 1.2](pos3) at (s-3.south) {(c) 联合编码器};
\end{tikzpicture} \end{tikzpicture}
\ No newline at end of file
...@@ -17,16 +17,16 @@ ...@@ -17,16 +17,16 @@
\node(surd-1)[right of = text_3-1, xshift=2cm,scale=1.5]{\textcolor{red}{$\surd$}}; \node(surd-1)[right of = text_3-1, xshift=2cm,scale=1.5]{\textcolor{red}{$\surd$}};
\node(text_4-1)[description, right of = figure-1, xshift=5.2cm,yshift=-0.9cm,fill=color_blue]{\textcolor{white}{男人戴着眼镜。}}; \node(text_4-1)[description, right of = figure-1, xshift=5.2cm,yshift=-0.9cm,fill=color_blue]{\textcolor{white}{男人戴着眼镜。}};
\node(point-1)[right of = figure-1, xshift=5cm,yshift=-1.4cm,scale=1.5]{...}; \node(point-1)[right of = figure-1, xshift=5cm,yshift=-1.4cm,scale=1.5]{...};
\draw[->,very thick](figure-1)to([xshift=-0.1cm]ground-1.west); \draw[->,thick](figure-1)to([xshift=-0.1cm]ground-1.west);
\node(figure)[draw=white,scale=0.25]at ([xshift=20.0em]figure-1.east){\includegraphics[width=0.62\textwidth]{./Chapter17/Figures/figure-dog-with-hat.png}}; \node(figure)[draw=white,scale=0.25]at ([xshift=20.0em]figure-1.east){\includegraphics[width=0.62\textwidth]{./Chapter17/Figures/figure-dog-with-hat.png}};
\node(ground)[rectangle,rounded corners, minimum width=5cm, minimum height=1.5cm,right of = figure, xshift=5cm,yshift=-2.6em,fill=blue!20]{\large{图片中有\underline{\textcolor{red}{}}\underline{\textcolor{red}{帽子}}\underline{\quad\ }}}; \node(ground)[rectangle,rounded corners, minimum width=5cm, minimum height=1.5cm,right of = figure, xshift=5cm,yshift=-2.6em,fill=blue!20]{\large{图片中有\underline{\textcolor{red}{}}\underline{\textcolor{red}{帽子}}\underline{\quad\ }}};
\node(dog)[rectangle,rounded corners, minimum width=1cm, minimum height=0.7cm,right of = figure, xshift=3cm,yshift=1.5cm,thick, draw=color_orange,fill=color_orange!50]{}; \node(dog)[rectangle,rounded corners, minimum width=1cm, minimum height=0.7cm,right of = figure, xshift=3cm,yshift=1.5cm,thick, draw=color_orange,fill=color_orange!50]{};
\node(hat)[rectangle,rounded corners, minimum width=1.5cm, minimum height=0.7cm,right of = figure, xshift=4.5cm,yshift=1.5cm,thick, draw=color_green,fill=color_green!50]{帽子}; \node(hat)[rectangle,rounded corners, minimum width=1.5cm, minimum height=0.7cm,right of = figure, xshift=4.5cm,yshift=1.5cm,thick, draw=color_green,fill=color_green!50]{帽子};
\draw[->, very thick,color=black!60](figure.east)to([xshift=-0.1cm]dog.west)node[left,xshift=-0.2cm,yshift=-0.1cm,color=black]{图片检测}; \draw[->, thick,color=black!60](figure.east)to([xshift=-0.1cm]dog.west)node[left,xshift=-0.2cm,yshift=-0.1cm,color=black]{图片检测};
\draw[->, very thick,color=black!60]([yshift=-0.1cm]hat.south)to([yshift=0.1cm]ground.north)node[right,xshift=-0.2cm,yshift=0.5cm,color=black]{模板填充}; \draw[->, thick,color=black!60]([yshift=-0.1cm]hat.south)to([yshift=0.1cm]ground.north)node[right,xshift=-0.2cm,yshift=0.5cm,color=black]{模板填充};
\node [anchor=north](pos1)at ([xshift=-3.8em,yshift=-0.5em]ground-1.south){(a)基于检索的图像描述生成范式}; \node [anchor=north](pos1)at ([xshift=-3.8em,yshift=-0.5em]ground-1.south){(a) 基于检索的图像描述生成范式};
\node [anchor=north](pos2)at ([xshift=-3.8em,yshift=-0.5em]ground.south){(b)基于模板的图像描述生成范式}; \node [anchor=north](pos2)at ([xshift=-3.8em,yshift=-0.5em]ground.south){(b) 基于模板的图像描述生成范式};
\end{tikzpicture} \end{tikzpicture}
\ No newline at end of file
...@@ -16,25 +16,25 @@ ...@@ -16,25 +16,25 @@
\node[anchor=north,node] (n4) at ([xshift=6em,yshift=-1.6em]n3.south){4}; \node[anchor=north,node] (n4) at ([xshift=6em,yshift=-1.6em]n3.south){4};
\draw[->] (n0.0) -- node[word,above]{of /0.343}(n2.180); \draw[->] (n0.0) -- node[word,above]{for /0.227}(n2.180);
\draw[->] (n0.60) -- node[word,above,rotate=40]{a /0.499}(n1.-150); \draw[->] (n0.60) -- node[word,above,rotate=40]{a /0.628}(n1.-150);
\draw[->] (n0.-50) -- node[word,above,rotate=-20]{our /0.116}(n3.150); \draw[->] (n0.-50) -- node[word,above,rotate=-20]{our /0.103}(n3.150);
\draw[->] (n0.-70) .. controls ([xshift=-8em]n4.180) and ([xshift=-8em]n4.180) .. node[above,word,xshift=3em,yshift=-0.6em]{that /0.039} (n4.180); \draw[->] (n0.-70) .. controls ([xshift=-8em]n4.180) and ([xshift=-8em]n4.180) .. node[above,word,xshift=3em,yshift=-0.6em]{this /0.042} (n4.180);
\draw[->] (n4.0) .. node[word,above,xshift=-2em,yshift=-0.4em]{hostage /1} controls ([xshift=5em]n4.0) and ([yshift=-6em]n6.-90) .. (n6.-90); \draw[->] (n4.0) .. node[word,above,xshift=-2em,yshift=-0.4em]{video /1} controls ([xshift=5em]n4.0) and ([yshift=-6em]n6.-90) .. (n6.-90);
\draw[->] (n2.-90) -- node[word,above,rotate=-18,pos=0.55]{house /0.125}(n7.180); \draw[->] (n2.-90) -- node[word,above,rotate=-18,pos=0.55]{movie /0.127}(n7.180);
\draw[->] (n3.-10) node[word,above,xshift=3.6em,yshift=-0.8em]{conference /1} .. controls ([xshift=4.6em,yshift=-1.8em]n3.-10) and ([yshift=-1.6em,xshift=-3em]n10.-135) .. (n10.-135); \draw[->] (n3.-10) node[word,above,xshift=3.6em,yshift=-0.8em]{book /1} .. controls ([xshift=4.6em,yshift=-1.8em]n3.-10) and ([yshift=-1.6em,xshift=-3em]n10.-135) .. (n10.-135);
\draw[->] (n7.0) -- node[word,above]{which /1}(n10.180); \draw[->] (n7.0) -- node[word,above]{which /1}(n10.180);
\draw[->] (n2.0) -- node[word,above,pos=0.5]{hostages /0.300}(n6.180); \draw[->] (n2.0) -- node[word,above,pos=0.5]{video /0.300}(n6.180);
\draw[->] (n2.45) -- node[word,above,rotate=18,pos=0.3]{a /0.573}(n11.-135); \draw[->] (n2.45) -- node[word,above,rotate=18,pos=0.3]{a /0.573}(n11.-135);
\draw[->,rounded corners=1em] (n1.-45) node[word,above,xshift=1.4em,yshift=-1.3em,rotate=-43]{house /0.078} -- ([yshift=-0.4em,xshift=-1em]n11.-90) -- (n7.100); \draw[->,rounded corners=1em] (n1.-45) node[word,above,xshift=1.4em,yshift=-1.3em,rotate=-43]{movie /0.187} -- ([yshift=-0.4em,xshift=-1em]n11.-90) -- (n7.100);
\draw[->] (n1.20) node[word,above,xshift=4em]{conference /0.734} .. controls ([xshift=8em]n1.20) and ([xshift=-0.6em,yshift=2.2em]n5.110) .. (n5.110); \draw[->] (n1.20) node[word,above,xshift=4em]{book /0.520} .. controls ([xshift=8em]n1.20) and ([xshift=-0.6em,yshift=2.2em]n5.110) .. (n5.110);
\draw[->] (n11.0) -- node[word,above]{conference /1}(n5.180); \draw[->] (n11.0) -- node[word,above]{book /1}(n5.180);
\draw[->] (n5.-90) ..node[word,above,xshift=1.4em]{is /0.773} controls ([yshift=-1.6em]n5.-90) and ([xshift=-3em]n6.150]) .. (n6.150); \draw[->] (n5.-90) ..node[word,above,xshift=1.4em]{is /0.822} controls ([yshift=-1.6em]n5.-90) and ([xshift=-3em]n6.150]) .. (n6.150);
\draw[->] (n5.0) node[word, above,xshift=1.4em]{as /0.226}.. controls ([xshift=2.6em]n5.0) and ([xshift=-0.6em,yshift=2em]n6.120) .. (n6.120); \draw[->] (n5.0) node[word, above,xshift=1.4em]{as /0.178}.. controls ([xshift=2.6em]n5.0) and ([xshift=-0.6em,yshift=2em]n6.120) .. (n6.120);
\coordinate (a) at ([xshift=6em,yshift=3em]n1); \coordinate (a) at ([xshift=6em,yshift=3em]n1);
\draw[->] (n1.60) .. controls ([xshift=3em,yshift=2em]n1.60) and ([xshift=-2em]a) .. (a) node[word,above,xshift=1em]{hostage /0.187}.. controls ([xshift=8em]a) and ([xshift=-0.6em,yshift=6em]n6.90) .. (n6.90); \draw[->] (n1.60) .. controls ([xshift=3em,yshift=2em]n1.60) and ([xshift=-2em]a) .. (a) node[word,above,xshift=1em]{video /0.293}.. controls ([xshift=8em]a) and ([xshift=-0.6em,yshift=6em]n6.90) .. (n6.90);
\draw[->] (n10.0) -- node[above,word,pos=0.4,rotate=30]{is /1}(n6.-135); \draw[->] (n10.0) -- node[above,word,pos=0.4,rotate=30]{is /1}(n6.-135);
\draw[->] (n6.0) -- node[above,word,yshift=0.2em]{being /1}(n8.180); \draw[->] (n6.0) -- node[above,word,yshift=0.2em]{being /1}(n8.180);
\draw[->] (n8.0) -- node[above,word,yshift=0.3em]{recorded /1}(n9.180); \draw[->] (n8.0) -- node[above,word,yshift=0.3em]{written /1}(n9.180);
\end{tikzpicture} \end{tikzpicture}
\ No newline at end of file
This source diff could not be displayed because it is too large. You can view the blob instead.
...@@ -11,7 +11,7 @@ ...@@ -11,7 +11,7 @@
\node[anchor=east] (t0) at (-0.5em, -1.5) {$\seq{t}$}; \node[anchor=east] (t0) at (-0.5em, -1.5) {$\seq{t}$};
\node[anchor=north] (l) at ([xshift=7em,yshift=-0.5em]t0.south) {\small{(a)\ }}; \node[anchor=north] (l) at ([xshift=7em,yshift=-0.5em]t0.south) {\small{(a)\ 初始化状态}};
\end{scope} \end{scope}
...@@ -29,7 +29,7 @@ ...@@ -29,7 +29,7 @@
\path[<->, thick] (s2.south) edge (t1.north); \path[<->, thick] (s2.south) edge (t1.north);
} }
\node[anchor=north] (l) at ([xshift=7em,yshift=-0.5em]t0.south) {\small{(b)\ }}; \node[anchor=north] (l) at ([xshift=7em,yshift=-0.5em]t0.south) {\small{(b)\ 找到译文第一个词 }};
\end{scope} \end{scope}
...@@ -50,7 +50,7 @@ ...@@ -50,7 +50,7 @@
\node[anchor=west,fill=red!20] (t2) at ([xshift=1em]t1.east) {\footnotesize{an apple}}; \node[anchor=west,fill=red!20] (t2) at ([xshift=1em]t1.east) {\footnotesize{an apple}};
\path[<->, thick] (s3.south) edge (t2.north); \path[<->, thick] (s3.south) edge (t2.north);
} }
\node[anchor=north] (l) at ([xshift=7em,yshift=-0.5em]t0.south) {\small{(c)\ }}; \node[anchor=north] (l) at ([xshift=7em,yshift=-0.5em]t0.south) {\small{(c)\ 找到译文第二个词}};
\end{scope} \end{scope}
...@@ -76,6 +76,6 @@ ...@@ -76,6 +76,6 @@
\node[anchor=west,fill=red!20] (t3) at ([xshift=1em]t2.east) {\footnotesize{on the table}}; \node[anchor=west,fill=red!20] (t3) at ([xshift=1em]t2.east) {\footnotesize{on the table}};
\path[<->, thick] (s1.south) edge (t3.north); \path[<->, thick] (s1.south) edge (t3.north);
} }
\node[anchor=north] (l) at ([xshift=7em,yshift=-0.5em]t0.south) {\small{(d)\ }}; \node[anchor=north] (l) at ([xshift=7em,yshift=-0.5em]t0.south) {\small{(d)\ 找到译文第三个词}};
\end{scope} \end{scope}
\end{tikzpicture} \end{tikzpicture}
\ No newline at end of file
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
\node [anchor=west] (s1) at (0,0) {\textbf{}}; \node [anchor=west] (s1) at (0,0) {\textbf{}};
\node [anchor=west] (s2) at ([xshift=2em]s1.east) {\textbf{}}; \node [anchor=west] (s2) at ([xshift=2em]s1.east) {\textbf{}};
\node [anchor=west] (s3) at ([xshift=2em]s2.east) {\textbf{}}; \node [anchor=west] (s3) at ([xshift=2em]s2.east) {\textbf{}};
\node [anchor=west] (s4) at ([xshift=2em]s3.east) {\textbf{表示}}; \node [anchor=west] (s4) at ([xshift=2em]s3.east) {\textbf{感到}};
\node [anchor=west] (s5) at ([xshift=2em]s4.east) {\textbf{满意}}; \node [anchor=west] (s5) at ([xshift=2em]s4.east) {\textbf{满意}};
\node [anchor=south west] (sentlabel) at ([yshift=-0.5em]s1.north west) {\scriptsize{\textbf{待翻译句子(已经分词):}}}; \node [anchor=south west] (sentlabel) at ([yshift=-0.5em]s1.north west) {\scriptsize{\textbf{待翻译句子(已经分词):}}};
......
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
\node [anchor=west] (s1) at (0,0) {\textbf{}}; \node [anchor=west] (s1) at (0,0) {\textbf{}};
\node [anchor=west] (s2) at ([xshift=2em]s1.east) {\textbf{}}; \node [anchor=west] (s2) at ([xshift=2em]s1.east) {\textbf{}};
\node [anchor=west] (s3) at ([xshift=2em]s2.east) {\textbf{}}; \node [anchor=west] (s3) at ([xshift=2em]s2.east) {\textbf{}};
\node [anchor=west] (s4) at ([xshift=2em]s3.east) {\textbf{表示}}; \node [anchor=west] (s4) at ([xshift=2em]s3.east) {\textbf{感到}};
\node [anchor=west] (s5) at ([xshift=2em]s4.east) {\textbf{满意}}; \node [anchor=west] (s5) at ([xshift=2em]s4.east) {\textbf{满意}};
\node [anchor=south west] (sentlabel) at ([yshift=-0.5em]s1.north west) {\scriptsize{\textbf{待翻译句子(已经分词):}}}; \node [anchor=south west] (sentlabel) at ([yshift=-0.5em]s1.north west) {\scriptsize{\textbf{待翻译句子(已经分词):}}};
......
...@@ -22,7 +22,7 @@ ...@@ -22,7 +22,7 @@
\node[srcnode,anchor=north west] (c8) at ([xshift=-4.5em,yshift=0.4em]c7.south west) {\normalsize{\textbf{return} $span[0, J]$}}; \node[srcnode,anchor=north west] (c8) at ([xshift=-4.5em,yshift=0.4em]c7.south west) {\normalsize{\textbf{return} $span[0, J]$}};
\node[anchor=west] (c9) at ([xshift=-3.2em,yshift=1.7em]c1.west) {\small{\textrm{参数:}\seq{s}为输入字符串。$G$为输入CFG。$J$为待分析字符串长度。}}; \node[anchor=west] (c9) at ([xshift=-3.2em,yshift=1.7em]c1.west) {\small{\textrm{参数:}\seq{s}为输入字符串。$G$为输入CFG。$J$为待分析字符串长度。}};
\node[anchor=west] (c10) at ([xshift=0em,yshift=1.3em]c9.west) {\small{\textrm{输出:字符串全部可能的语法分析结果}}}; \node[anchor=west] (c10) at ([xshift=0em,yshift=1.3em]c9.west) {\small{\textrm{输出:全部可能的字符串语法分析结果}}};
\node[anchor=west] (c11) at ([xshift=0em,yshift=1.3em]c10.west) {\small{\textrm{输入:符合乔姆斯基范式的待分析字符串和一个上下文无关文法(CFG)}}}; \node[anchor=west] (c11) at ([xshift=0em,yshift=1.3em]c10.west) {\small{\textrm{输入:符合乔姆斯基范式的待分析字符串和一个上下文无关文法(CFG)}}};
......
...@@ -40,7 +40,7 @@ ...@@ -40,7 +40,7 @@
\draw [->,thick] ([xshift=-1.0em,yshift=1.0em]alig1.north west)--([xshift=-1.0em,yshift=-0.7em]alig4.south west); \draw [->,thick] ([xshift=-1.0em,yshift=1.0em]alig1.north west)--([xshift=-1.0em,yshift=-0.7em]alig4.south west);
\draw [->,thick] ([xshift=-1.0em,yshift=1.0em]alig1.north west)--([xshift=0.8em,yshift=1.0em]alig13.north east); \draw [->,thick] ([xshift=-1.0em,yshift=1.0em]alig1.north west)--([xshift=0.8em,yshift=1.0em]alig13.north east);
\node[anchor=north] (l) at ([xshift=0em,yshift=-1.5em]alig4.south) {\small{(a)}}; \node[anchor=north] (l) at ([xshift=-2em,yshift=-1.5em]alig4.south) {\small{(a) \ 当前最好结果为2.1}};
\end{scope} \end{scope}
%图2 %图2
...@@ -87,7 +87,7 @@ ...@@ -87,7 +87,7 @@
\draw [->,thick] ([xshift=-1.0em,yshift=1.0em]alig1.north west)--([xshift=-1.0em,yshift=-0.7em]alig4.south west); \draw [->,thick] ([xshift=-1.0em,yshift=1.0em]alig1.north west)--([xshift=-1.0em,yshift=-0.7em]alig4.south west);
\draw [->,thick] ([xshift=-1.0em,yshift=1.0em]alig1.north west)--([xshift=0.8em,yshift=1.0em]alig13.north east); \draw [->,thick] ([xshift=-1.0em,yshift=1.0em]alig1.north west)--([xshift=0.8em,yshift=1.0em]alig13.north east);
\node[anchor=north] (l) at ([xshift=0em,yshift=-1.5em]alig4.south) {\small{(b)}}; \node[anchor=north] (l) at ([xshift=-2em,yshift=-1.5em]alig4.south) {\small{(b)\ 当前最好结果为5.5}};
\end{scope} \end{scope}
%图3 %图3
...@@ -137,7 +137,7 @@ ...@@ -137,7 +137,7 @@
\draw [->,thick] ([xshift=-1.0em,yshift=1.0em]alig1.north west)--([xshift=-1.0em,yshift=-0.7em]alig4.south west); \draw [->,thick] ([xshift=-1.0em,yshift=1.0em]alig1.north west)--([xshift=-1.0em,yshift=-0.7em]alig4.south west);
\draw [->,thick] ([xshift=-1.0em,yshift=1.0em]alig1.north west)--([xshift=0.8em,yshift=1.0em]alig13.north east); \draw [->,thick] ([xshift=-1.0em,yshift=1.0em]alig1.north west)--([xshift=0.8em,yshift=1.0em]alig13.north east);
\node[anchor=north] (l) at ([xshift=0em,yshift=-1.5em]alig4.south) {\small{(c)}}; \node[anchor=north] (l) at ([xshift=-2em,yshift=-1.5em]alig4.south) {\small{(c)\ 当前最好结果为8.5}};
\end{scope} \end{scope}
...@@ -194,7 +194,7 @@ ...@@ -194,7 +194,7 @@
\draw [->,thick] ([xshift=-1.0em,yshift=1.0em]alig1.north west)--([xshift=-1.0em,yshift=-0.7em]alig4.south west); \draw [->,thick] ([xshift=-1.0em,yshift=1.0em]alig1.north west)--([xshift=-1.0em,yshift=-0.7em]alig4.south west);
\draw [->,thick] ([xshift=-1.0em,yshift=1.0em]alig1.north west)--([xshift=0.8em,yshift=1.0em]alig13.north east); \draw [->,thick] ([xshift=-1.0em,yshift=1.0em]alig1.north west)--([xshift=0.8em,yshift=1.0em]alig13.north east);
\node[anchor=north] (l) at ([xshift=0em,yshift=-1.5em]alig4.south) {\small{(d)}}; \node[anchor=north] (l) at ([xshift=-2em,yshift=-1.5em]alig4.south) {\small{(d)\ 当前最好结果为8.2}};
\end{scope} \end{scope}
......
...@@ -78,19 +78,19 @@ ...@@ -78,19 +78,19 @@
} }
} }
\node[fill=blue!40, scale=1.1, inner sep=1pt, minimum size=12pt] at (1,-1) {{\color{white} \small{.9}}}; \node[fill=blue!40, scale=1.1, inner sep=1pt, minimum size=12pt] at (1,-1) {{\color{white} \footnotesize{0.9}}};
\node[fill=blue!40, scale=0.5, inner sep=1pt, minimum size=12pt] at (1,-3) {{\color{white} \small{.1}}}; \node[fill=blue!40, scale=0.5, inner sep=1pt, minimum size=12pt] at (1,-3) {{\color{white} \footnotesize{0.1}}};
\node[fill=blue!40, scale=0.5, inner sep=1pt, minimum size=12pt] at (2,-2) {{\color{white} \small{.1}}}; \node[fill=blue!40, scale=0.5, inner sep=1pt, minimum size=12pt] at (2,-2) {{\color{white} \footnotesize{0.1}}};
\node[fill=blue!40, scale=0.8, inner sep=1pt, minimum size=12pt] at (2,-3) {{\color{white} \small{.6}}}; \node[fill=blue!40, scale=0.8, inner sep=1pt, minimum size=12pt] at (2,-3) {{\color{white} \footnotesize{0.6}}};
\node[fill=blue!40, scale=0.8, inner sep=1pt, minimum size=12pt] at (2,-5) {{\color{white} \small{.6}}}; \node[fill=blue!40, scale=0.8, inner sep=1pt, minimum size=12pt] at (2,-5) {{\color{white} \footnotesize{0.6}}};
\node[fill=blue!40, scale=0.5, inner sep=1pt, minimum size=12pt] at (3,-1) {{\color{white} \small{.1}}}; \node[fill=blue!40, scale=0.5, inner sep=1pt, minimum size=12pt] at (3,-1) {{\color{white} \footnotesize{0.1}}};
\node[fill=blue!40, scale=0.5, inner sep=1pt, minimum size=12pt] at (3,-2) {{\color{white} \small{.1}}}; \node[fill=blue!40, scale=0.5, inner sep=1pt, minimum size=12pt] at (3,-2) {{\color{white} \footnotesize{0.1}}};
\node[fill=blue!40, scale=0.5, inner sep=1pt, minimum size=12pt] at (3,-3) {{\color{white} \small{.1}}}; \node[fill=blue!40, scale=0.5, inner sep=1pt, minimum size=12pt] at (3,-3) {{\color{white} \footnotesize{0.1}}};
\node[fill=blue!40, scale=1.0, inner sep=1pt, minimum size=12pt] at (4,-2) {{\color{white} \small{.8}}}; \node[fill=blue!40, scale=1.0, inner sep=1pt, minimum size=12pt] at (4,-2) {{\color{white} \footnotesize{0.8}}};
\node[fill=blue!40, scale=0.6, inner sep=1pt, minimum size=12pt] at (5,-3) {{\color{white} \small{.2}}}; \node[fill=blue!40, scale=0.6, inner sep=1pt, minimum size=12pt] at (5,-3) {{\color{white} \footnotesize{0.2}}};
\node[fill=blue!40, scale=0.7, inner sep=1pt, minimum size=12pt] at (5,-5) {{\color{white} \small{.4}}}; \node[fill=blue!40, scale=0.7, inner sep=1pt, minimum size=12pt] at (5,-5) {{\color{white} \footnotesize{0.4}}};
\node[fill=blue!40, scale=0.65, inner sep=1pt, minimum size=12pt] at (3,-4) {{\color{white} \small{.3}}}; \node[fill=blue!40, scale=0.65, inner sep=1pt, minimum size=12pt] at (3,-4) {{\color{white} \footnotesize{0.3}}};
\node[fill=blue!40, scale=0.9, inner sep=1pt, minimum size=12pt] at (5,-4) {{\color{white} \small{.7}}}; \node[fill=blue!40, scale=0.9, inner sep=1pt, minimum size=12pt] at (5,-4) {{\color{white} \footnotesize{0.7}}};
\node[] at (4,-6.3) {{\color{blue!40} $\blacksquare$} = 概率化对齐}; \node[] at (4,-6.3) {{\color{blue!40} $\blacksquare$} = 概率化对齐};
\node[] at (4,-7.2) {Matrix 2: 对齐概率}; \node[] at (4,-7.2) {Matrix 2: 对齐概率};
......
...@@ -27,21 +27,21 @@ ...@@ -27,21 +27,21 @@
\begin{pgfonlayer}{background} \begin{pgfonlayer}{background}
{ {
\node [rectangle,fill=blue!20,inner sep=0] [fit = (n11)] (n11box) {}; \node [rectangle,fill=red!20,inner sep=0] [fit = (n11)] (n11box) {};
\node [rectangle,fill=red!20,inner sep=0] [fit = (n4)] (n4box) {}; \node [rectangle,fill=blue!20,inner sep=0] [fit = (n4)] (n4box) {};
\node [rectangle,fill=red!20,inner sep=0] [fit = (n1)] (n1box) {}; \node [rectangle,fill=blue!20,inner sep=0] [fit = (n1)] (n1box) {};
\node [rectangle,fill=red!20,inner sep=0] [fit = (n2)] (n2box) {}; \node [rectangle,fill=blue!20,inner sep=0] [fit = (n2)] (n2box) {};
\node [rectangle,fill=red!20,inner sep=0] [fit = (n3)] (n3box) {}; \node [rectangle,fill=blue!20,inner sep=0] [fit = (n3)] (n3box) {};
\node [rectangle,fill=red!20,inner sep=0] [fit = (n5)] (n5box) {}; \node [rectangle,fill=blue!20,inner sep=0] [fit = (n5)] (n5box) {};
\node [rectangle,fill=red!20,inner sep=0] [fit = (n6)] (n6box) {}; \node [rectangle,fill=blue!20,inner sep=0] [fit = (n6)] (n6box) {};
\node [rectangle,fill=red!20,inner sep=0] [fit = (n7)] (n7box) {}; \node [rectangle,fill=blue!20,inner sep=0] [fit = (n7)] (n7box) {};
\node [rectangle,fill=red!20,inner sep=0] [fit = (n8)] (n8box) {}; \node [rectangle,fill=blue!20,inner sep=0] [fit = (n8)] (n8box) {};
\node [rectangle,fill=red!20,inner sep=0] [fit = (n9)] (n9box) {}; \node [rectangle,fill=blue!20,inner sep=0] [fit = (n9)] (n9box) {};
\node [rectangle,fill=blue!20,inner sep=0] [fit = (n10)] (n10box) {}; \node [rectangle,fill=red!20,inner sep=0] [fit = (n10)] (n10box) {};
\node [anchor=north west, minimum size=1.2em, fill=red!20] (land1) at ([xshift=7.0em,yshift=0em]n1.north east) {}; \node [anchor=north west, minimum size=1.2em, fill=blue!20] (land1) at ([xshift=7.0em,yshift=0em]n1.north east) {};
\node [anchor=west] (land1label) at (land1.east) {\scriptsize{可信}}; \node [anchor=west] (land1label) at (land1.east) {\scriptsize{可信}};
\node [anchor=north west, minimum size=1.2em, fill=blue!20] (land2) at ([yshift=-0.3em]land1.south west) {}; \node [anchor=north west, minimum size=1.2em, fill=red!20] (land2) at ([yshift=-0.3em]land1.south west) {};
\node [anchor=west] (land2label) at (land2.east) {\scriptsize{不可信}}; \node [anchor=west] (land2label) at (land2.east) {\scriptsize{不可信}};
} }
...@@ -54,6 +54,8 @@ ...@@ -54,6 +54,8 @@
\node[anchor=west,minimum size=18pt] (tw5) at ([xshift=0.3em]tw4.east){the}; \node[anchor=west,minimum size=18pt] (tw5) at ([xshift=0.3em]tw4.east){the};
\node[anchor=west,minimum size=18pt] (tw6) at ([yshift=-0.1em,xshift=0.3em]tw5.east){answer}; \node[anchor=west,minimum size=18pt] (tw6) at ([yshift=-0.1em,xshift=0.3em]tw5.east){answer};
\node[anchor=north](pos1) at ([xshift=-1.0em,yshift=-1.0em]tw4.south){\small{(a)标有可信节点信息的句法树}};
\draw[dashed] (cw1.south) -- ([yshift=-0.4em]tw1.north); \draw[dashed] (cw1.south) -- ([yshift=-0.4em]tw1.north);
\draw[dashed] (cw2.south) .. controls +(south:2.0) and +(north:0.6) .. ([yshift=-0.4em]tw4.north); \draw[dashed] (cw2.south) .. controls +(south:2.0) and +(north:0.6) .. ([yshift=-0.4em]tw4.north);
\draw[dashed] (cw3.south) -- ([yshift=-0.4em]tw5.north); \draw[dashed] (cw3.south) -- ([yshift=-0.4em]tw5.north);
...@@ -107,6 +109,8 @@ ...@@ -107,6 +109,8 @@
\node[scale=0.9,anchor=west,minimum size=18pt] (tw15) at ([xshift=0.5em]tw14.east){the}; \node[scale=0.9,anchor=west,minimum size=18pt] (tw15) at ([xshift=0.5em]tw14.east){the};
\node[scale=0.9,anchor=west,minimum size=18pt] (tw16) at ([yshift=-0.1em,xshift=0.5em]tw15.east){answer}; \node[scale=0.9,anchor=west,minimum size=18pt] (tw16) at ([yshift=-0.1em,xshift=0.5em]tw15.east){answer};
\node[anchor=north](pos1) at ([xshift=-1.0em,yshift=-0.6em]tw14.south){\small{(b)通过边缘集合定义切割得到的句法树}};
\draw[dashed] ([xshift=-0.3em]cfrag1.south) -- ([yshift=-0.3em]tw11.north); \draw[dashed] ([xshift=-0.3em]cfrag1.south) -- ([yshift=-0.3em]tw11.north);
\draw[dashed] (cfrag2.south) -- ([yshift=-0.4em]tw14.north); \draw[dashed] (cfrag2.south) -- ([yshift=-0.4em]tw14.north);
\draw[dashed] (cfrag3.south) -- ([yshift=-0.4em]tw15.north); \draw[dashed] (cfrag3.south) -- ([yshift=-0.4em]tw15.north);
......
% !Mode:: "TeX:UTF-8"
% !TEX encoding = UTF-8 Unicode
%----------------------------------------------------------------------------------------
% 机器翻译:统计建模与深度学习方法
% Machine Translation: Statistical Modeling and Deep Learning Methods
%
% Copyright 2020
% 肖桐(xiaotong@mail.neu.edu.cn) 朱靖波 (zhujingbo@mail.neu.edu.cn)
%----------------------------------------------------------------------------------------
%----------------------------------------------------------------------------------------
% CONFIGURATIONS
%----------------------------------------------------------------------------------------
\renewcommand\figurename{}%将figure改为图
%----------------------------------------------------------------------------------------
% postscript
%----------------------------------------------------------------------------------------
\fancyhead[LO]{\sffamily\normalsize\bfseries{后记 \ \quad 肖桐\ 朱靖波}} % Print the nearest section name on the left side of odd pages
\fancyhead[RE]{\sffamily\normalsize\bfseries{后记 \ \quad 肖桐\ 朱靖波}} % Print the current chapter name on the right side of even pages
%\chapter*{后记}
\addcontentsline{toc}{chapter}{后记}
{\color{white}}
\vspace{1em}
\begin{center}
{\Huge \bfnew{后记}}
\end{center}
\vspace{2em}
\begin{spacing}{1.18}
\parinterval 写点儿什么 。。。
\hfill 肖桐
\hfill 2020.12.27
\end{spacing}
\ No newline at end of file
...@@ -22,6 +22,8 @@ ...@@ -22,6 +22,8 @@
%---------------------------------------------------------------------------------------- %----------------------------------------------------------------------------------------
% CHAPTER APPENDIX A % CHAPTER APPENDIX A
%---------------------------------------------------------------------------------------- %----------------------------------------------------------------------------------------
\fancyhead[LO]{\rightmark} % Print the nearest section name on the left side of odd pages
\fancyhead[RE]{\leftmark} % Print the current chapter name on the right side of even pages
\begin{appendices} \begin{appendices}
\chapter{附录A} \chapter{附录A}
......
...@@ -14,16 +14,25 @@ ...@@ -14,16 +14,25 @@
%---------------------------------------------------------------------------------------- %----------------------------------------------------------------------------------------
\renewcommand\figurename{}%将figure改为图 \renewcommand\figurename{}%将figure改为图
\renewcommand\tablename{}%将figure改为图
\chapterimage{fig-NEU-8.jpg} % Chapter heading image
%---------------------------------------------------------------------------------------- %----------------------------------------------------------------------------------------
% CHAPTER 19 % postscript
%---------------------------------------------------------------------------------------- %----------------------------------------------------------------------------------------
\fancyhead[LO]{\sffamily\normalsize\bfseries{随笔 \ \quad 肖桐\ 朱靖波}} % Print the nearest section name on the left side of odd pages
\fancyhead[RE]{\sffamily\normalsize\bfseries{随笔 \ \quad 肖桐\ 朱靖波}} % Print the current chapter name on the right side of even pages
%\chapter*{后记}
\addcontentsline{toc}{chapter}{随笔}
\chapter{机器翻译杂谈} {\color{white}}
\vspace{1em}
\begin{center}
{\Huge \bfnew{随笔}}
\end{center}
\vspace{2em}
\parinterval 朱靖波 2020.12.10-16随笔\\ \begin{spacing}{1.18}
%\section{随笔}
\parinterval 自从计算机诞生开始,机器翻译即利用计算机软件技术实现不同语言自动翻译,就是人们首先想到的计算机主要应用之一。很多人说现在处于人工智能时代,是得语言者的天下,因此机器翻译也是认知智能的终极梦想之一,本节将分享我们对机器翻译技术和应用的一些思考,有些想法不一定正确,也许需要十年之后才能验证。 \parinterval 自从计算机诞生开始,机器翻译即利用计算机软件技术实现不同语言自动翻译,就是人们首先想到的计算机主要应用之一。很多人说现在处于人工智能时代,是得语言者的天下,因此机器翻译也是认知智能的终极梦想之一,本节将分享我们对机器翻译技术和应用的一些思考,有些想法不一定正确,也许需要十年之后才能验证。
...@@ -88,13 +97,11 @@ ...@@ -88,13 +97,11 @@
%\parinterval 通常用于构建机器翻译系统的神经网络结构是人为事先确定的,包括预定义层数(深度)和每层宽度等,其实人为事先给定的网络结构对于当前任务来说是否最佳,这个问题没有结论,学术界目前也无法很好回答这个问题。但根据我们的常识性知识可以得知,过于依赖专家经验来设计网络结构肯定不是最佳方案,后来学术界就产生了网络结构搜索研究工作,即如何根据训练数据本身来自动优化模型深层网络结构,争取达到最佳的训练学习效果,是一个非常有趣的研究方向。目前神经机器翻译技术主要依赖于编码器-解码器两层技术框架,把编码和解码阶段分开,类似于将传统的分析和生成阶段分开,但两者又相互依赖,这样做的好处是技术架构简单,不过可能存在表示学习不够充分和错误蔓延等问题的可能性。为了解决这个问题,我们团队做了一个有趣尝试,提出一个新的神经机器翻译技术框架\ \dash \ 基于联合分布的注意力模型Reformer,不依赖于传统编码器-解码器技术框架,而是直接采用一个统一技术框架完成翻译过程,这项工作目前还比较初级,有待于进一步深入研究。 %\parinterval 通常用于构建机器翻译系统的神经网络结构是人为事先确定的,包括预定义层数(深度)和每层宽度等,其实人为事先给定的网络结构对于当前任务来说是否最佳,这个问题没有结论,学术界目前也无法很好回答这个问题。但根据我们的常识性知识可以得知,过于依赖专家经验来设计网络结构肯定不是最佳方案,后来学术界就产生了网络结构搜索研究工作,即如何根据训练数据本身来自动优化模型深层网络结构,争取达到最佳的训练学习效果,是一个非常有趣的研究方向。目前神经机器翻译技术主要依赖于编码器-解码器两层技术框架,把编码和解码阶段分开,类似于将传统的分析和生成阶段分开,但两者又相互依赖,这样做的好处是技术架构简单,不过可能存在表示学习不够充分和错误蔓延等问题的可能性。为了解决这个问题,我们团队做了一个有趣尝试,提出一个新的神经机器翻译技术框架\ \dash \ 基于联合分布的注意力模型Reformer,不依赖于传统编码器-解码器技术框架,而是直接采用一个统一技术框架完成翻译过程,这项工作目前还比较初级,有待于进一步深入研究。
%\vspace{0.5em} %\vspace{0.5em}
\parinterval 最后简单评价一下机器翻译市场发展的趋势。机器翻译本身是个强刚需,用于解决全球用户多语言交流障碍问题。机器翻译产业真正热起来,应该归功于神经机器翻译技术应用,之前基于规则的方法和统计机器翻译技术虽然也在工业界得到了应用,但由于翻译品质没有达到用户预期,用户付费欲望比较差,没有良好的商业变现能力,导致机器翻译产业在2017年以前类似于“鸡肋”产业。严格上来说,2016年下半年开始,神经机器翻译技术工业界应用快速激活了用户需求,用户对机器翻译的认可度急剧上升,越来越丰富的应用模式和需求被挖掘出来,除了传统计算机辅助翻译CAT以外,语音和OCR与机器翻译技术结合,使得大家比较熟悉的语音翻译APP、翻译机、翻译笔、会议AI同传和垂直行业(专利、医药、旅游等)等的机器翻译解决方案也逐渐得到了广泛应用。总体来说,机器翻译产学研正处于快速上升期,每年市场规模达到至少100\%以上增长,随着多模态机器翻译和大数据翻译技术应用,应用场景会越来越丰富,随着5G甚至6G技术发展,视频翻译和电话通讯翻译等应用会进一步爆发。另外,随着人工智能芯片领域的发展,很自然地机器翻译芯片也会逐渐得到应用,比如嵌入到手机、打印机、复印机、传真机和电视机等智能终端设备,实现所有内容皆可翻译,任何场景皆可运行的目标,机器翻译服务将进入人们的日常生活中,无所不在,让生活更加美好! \parinterval 最后简单评价一下机器翻译市场发展的趋势。机器翻译本身是个强刚需,用于解决全球用户多语言交流障碍问题。机器翻译产业真正热起来,应该归功于神经机器翻译技术应用,之前基于规则的方法和统计机器翻译技术虽然也在工业界得到了应用,但由于翻译品质没有达到用户预期,用户付费欲望比较差,没有良好的商业变现能力,导致机器翻译产业在2017年以前类似于“鸡肋”产业。严格上来说,2016年下半年开始,神经机器翻译技术工业界应用快速激活了用户需求,用户对机器翻译的认可度急剧上升,越来越丰富的应用模式和需求被挖掘出来,除了传统计算机辅助翻译CAT以外,语音和OCR与机器翻译技术结合,使得大家比较熟悉的语音翻译APP、翻译机、翻译笔、会议AI同传和垂直行业(专利、医药、旅游等)等的机器翻译解决方案也逐渐得到了广泛应用。总体来说,机器翻译产学研正处于快速上升期,每年市场规模达到至少100\%以上增长,随着多模态机器翻译和大数据翻译技术应用,应用场景会越来越丰富,随着5G甚至6G技术发展,视频翻译和电话通讯翻译等应用会进一步爆发。另外,随着人工智能芯片领域的发展,很自然地机器翻译芯片也会逐渐得到应用,比如嵌入到手机、打印机、复印机、传真机和电视机等智能终端设备,实现所有内容皆可翻译,任何场景皆可运行的目标,机器翻译服务将进入人们的日常生活中,无所不在,让生活更加美好!\\
%----------------------------------------------
\begin{figure}[htp] \hfill 朱靖波
\centering
\includegraphics[scale=0.4]{./Chapter19/Figures/figure-niutrans.jpg} \hfill 2020.12.10-16 随笔
%\setlength{\abovecaptionskip}{-0.2cm}
%\caption{使用TranSmart系统进行交互式翻译的实例}
\label{fig:19-1} \end{spacing}
\end{figure} \ No newline at end of file
%----------------------------------------------
This source diff could not be displayed because it is too large. You can view the blob instead.
...@@ -149,8 +149,9 @@ ...@@ -149,8 +149,9 @@
%\include{Chapter15/chapter15} %\include{Chapter15/chapter15}
%\include{Chapter16/chapter16} %\include{Chapter16/chapter16}
%\include{Chapter17/chapter17} %\include{Chapter17/chapter17}
\include{Chapter18/chapter18} %\include{Chapter18/chapter18}
\include{Chapter19/chapter19} \include{ChapterPostscript/postscript}
\include{ChapterAcknowledgement/acknowledgement}
%\include{ChapterAppend/chapterappend} %\include{ChapterAppend/chapterappend}
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论