3

enter image description here

Can you please help in drawing the above figure?

This is the code which I tried so far:

\documentclass{article}
\usepackage{tikz}
\usepackage[utf8]{inputenc}
\usepackage{tikz}
\usetikzlibrary{calc,shapes, positioning}
\usetikzlibrary{arrows}
\usetikzlibrary{decorations.text}
\usetikzlibrary{matrix,chains,positioning,decorations.pathreplacing,arrows}

\begin{document}


\begin{tikzpicture}[
init/.style={
    draw,
    circle,
    inner sep=2pt,
    font=\Huge,
    join = by -latex
},
squa/.style={
    draw,
    inner sep=2pt,
    font=\Large,
    join = by -latex
},
start chain=2,node distance=13mm
]

\node[on chain=2,init] (sigma) 
    {$\displaystyle\Sigma$};
\node[on chain=2,squa,label=above:{\parbox{2cm}}]   
    {$+$};
\node[on chain=2,squa,label=above:,join=by -latex] 
    {$y$};

\node[label=above:\parbox{2cm}{\centering Bias \\ $$}] at (sigma|-w1) (b) {};

\end{tikzpicture}

\end{document}
  • Welcome. This is not a "please do it for me site" so your chances of getting help will improve if you show us what you have tried yourself so far. – Svend Tveskæg Oct 6 '15 at 4:47
9

Possible solution

    \documentclass[border={10pt}]{standalone}

\usepackage{tikz}
\usetikzlibrary{arrows, decorations.pathmorphing, backgrounds, positioning,fit,petri}
\usetikzlibrary{calc}
\begin{document}

\begin{tikzpicture}
    [%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    node distance=2cm, >=stealth', very thick,
    cross/.style={path picture={ \draw[black]
                   (path picture bounding box.south east) -- (path picture bounding box.north west) 
                   (path picture bounding box.south west) -- (path picture bounding box.north east);
                  }},
    %---------------                  
    BigRectangle/.style={rectangle,draw=black,fill=white,thick,
                              inner sep=0pt,minimum size=2cm},
    %---------------
    SmallRectangle/.style={rectangle,draw=black,fill=white,thick,
                              inner sep=0pt,minimum size=.7cm},
    %---------------       
    Circle/.style={circle,draw=black,fill=white,thick,
                              inner sep=0pt,minimum size=6mm},                                             
    ]%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
     \node[BigRectangle]   (A)               {} node[yshift=15mm,align=center] {Input feature \\ maps};
     \node[BigRectangle]   (B) [right=of A]  {};
     \node[Circle,cross,yshift=7mm] (C)  at (barycentric cs:A=0.5,B=0.5)  {};
     \node[SmallRectangle,yshift=17mm] (D) [below=of C]  {};
     %\node[BigRectangle] (D) [left=of  C]  {D};

     \draw[<-] (C) -- (C -| A.east);
     \draw[->] (C) -- (C -| B.west);
     \draw[<-] (C) -- (D);


     \node[BigRectangle]   (E) [below=of A]  {};
     \node[BigRectangle]   (F) [right=of E]  {} node[below=of F,xshift=-8mm, yshift=14mm,align=center] {Conv. kernel  \qquad Conv. ouput };;
     \node[Circle,cross,yshift=7mm] (G)  at (barycentric cs:E=0.5,F=0.5)  {};
     \node[SmallRectangle,yshift=17mm] (H) [below=of G]  {};

     \draw[<-] (G) -- (G -| E.east);
     \draw[->] (G) -- (G -| F.west);
     \draw[<-] (G) -- (H);

     \node[Circle,xshift=2cm] (I)  at (barycentric cs:B=0.5,F=0.5)  {$\sum$};
     \draw[->] (B) -| (I);
     \draw[->] (F) -| (I);

     \node[Circle,node distance=.5cm] (J) [right=of I] {+};
     \node[Circle,node distance=.5cm] (K) [right=of J] {$\phi$}  node[left=of J,xshift=9mm,align=center] {Conv. kernel  \qquad Conv. ouput };
     \node[BigRectangle,node distance=.5cm]   (L) [right=of K]  {} node[above=of L,yshift=-20mm,align=center] {Output feature \\ maps};

     \draw[->] (I) -- (J);
     \draw[->] (J) -- (K);
     \draw[->] (K) -- (L);

     \node[node distance=.5cm] (M)  [above=of J]  {Bias};
     \draw[->] (M) -- (J);

     \node[fill,circle,node distance=.5cm,minimum size=.2cm,inner sep=0pt] (N)  [below=of L]  {};
     \node[fill,circle,node distance=.5cm,minimum size=.2cm,inner sep=0pt] (Q)  [below=of N]  {};
     \node[fill,circle,node distance=.5cm,minimum size=.2cm,inner sep=0pt] (Z)  [below=of Q]  {};

\end{tikzpicture}
\end{document}

enter image description here

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.