alexlenail/NN-SVG

Publication-ready NN-architecture schematics.

JavaScript

5,691

30 commits

updated Jun 2, 2026

See the code

README

NN-SVG

License: MIT status | Docs | Contributing

Illustrations of Neural Network architectures are often time-consuming to produce, and machine learning researchers all too often find themselves constructing these diagrams from scratch by hand.

NN-SVG is a tool for creating Neural Network (NN) architecture drawings parametrically rather than manually. It also provides the ability to export those drawings to Scalable Vector Graphics (SVG) files, suitable for inclusion in academic papers or web pages.

The tool provides the ability to generate figures of three kinds: classic Fully-Connected Neural Network (FCNN) figures, Convolutional Neural Network (CNN) figures of the sort introduced in the LeNet paper, and Deep Neural Network figures following the style introduced in the AlexNet paper. The former two are accomplished using the D3 javascript library and the latter with the javascript library Three.js. NN-SVG provides the ability to style the figure to the user's liking via many size, color, and layout parameters.

I hope this tool will save machine learning researchers time, and I hope this software might also serve as a pedagogical tool in some contexts.

Citation

LeNail, (2019). NN-SVG: Publication-Ready Neural Network Architecture Schematics.
Journal of Open Source Software, 4(33), 747, https://doi.org/10.21105/joss.00747

d3
deep-learning
diagrams
drawing
machine-learning
neural-network
svg
threejs

alexlenail/NN-SVG

Publication-ready NN-architecture schematics.

JavaScript

5,691

30 commits

updated Jun 2, 2026

See the code

README

NN-SVG

License: MIT status | Docs | Contributing

Illustrations of Neural Network architectures are often time-consuming to produce, and machine learning researchers all too often find themselves constructing these diagrams from scratch by hand.

NN-SVG is a tool for creating Neural Network (NN) architecture drawings parametrically rather than manually. It also provides the ability to export those drawings to Scalable Vector Graphics (SVG) files, suitable for inclusion in academic papers or web pages.

The tool provides the ability to generate figures of three kinds: classic Fully-Connected Neural Network (FCNN) figures, Convolutional Neural Network (CNN) figures of the sort introduced in the LeNet paper, and Deep Neural Network figures following the style introduced in the AlexNet paper. The former two are accomplished using the D3 javascript library and the latter with the javascript library Three.js. NN-SVG provides the ability to style the figure to the user's liking via many size, color, and layout parameters.

I hope this tool will save machine learning researchers time, and I hope this software might also serve as a pedagogical tool in some contexts.

Citation

LeNail, (2019). NN-SVG: Publication-Ready Neural Network Architecture Schematics.
Journal of Open Source Software, 4(33), 747, https://doi.org/10.21105/joss.00747

d3
deep-learning
diagrams
drawing
machine-learning
neural-network
svg
threejs

Significant stargazers

(top 24 of 35)

Pietro Monticone

1,201 followers · starred Feb 2022

Labrak Yanis

51 followers · starred Jan 2022

Nikita Volkov

422 followers · starred Jan 2022

Unai Martinez-Corral

221 followers · starred Jan 2022