HarisIqbal88 / PlotNeuralNet

Latex code for making neural networks diagrams
MIT License
21.74k stars 2.84k forks source link

Any way to provide output image like using to_ouput()(like to_input())? #25

Closed riktimmondal closed 4 years ago

JesperChristensen89 commented 5 years ago

Looking for this as well. Did you find out?

cartacamilla commented 4 years ago

This solved it for me: def to_output( pathfile, off='0', to='(0,0,0)', width=8, height=8, name="temp" ): return r""" \node[canvas is zy plane at x="""+ off +"""] (""" + name + """) at """+ to +""" {\includegraphics[width="""+ str(width)+"cm"+""",height="""+ str(height)+"cm"+"""]{"""+ pathfile +"""}}; """ You can define an offset from the last layer, i.e. ... to_ConvSoftMax(name="soft1", s_filer=512, offset="(0.75,0,0)", to="(end_b9-east)", width=1, height=40, depth=40, caption="SOFT" ), to_connection("end_b9", "soft1"), to_output('../examples/fcn8s/cats.jpg', off='3', to='(soft1-east)'), to_end()

Hope it helps!