3 ms·
For a recent publication, I had to create a neural network architecture diagram and tried it two ways - one by hacking someone's python code to create an isomet
by heyitsguay 6y ago
For a recent publication, I had to create a neural network architecture diagram and tried it two ways - one by hacking someone's python code to create an isometric 3d diagram (https://i.ibb.co/HdBvTFk/fig2.png https://i.ibb.co/HdBvTFk/fig2.png), the second using draw.io to create a 2d diagram (https://i.ibb.co/kmrfpVK/fig2a.png https://i.ibb.co/kmrfpVK/fig2a.png).
The 3D figure looks more appealing to my eye, but I went with the 2D one instead. The issue with architecture SVG generation code that I've seen is that it's inflexible once you want to do anything outside common layer computations or arrangements. I found someone's code that had a U-Net example and then manually had to go in and modify a whole bunch of stuff to get it to do just what I wanted. On top of that, I opted to do a bunch of postprocessing in an image editor anyway. More importantly, the 3D diagram is harder to parse for anyone looking to re-implement the model. Most (but not all) of the information is there, but you have to work for it. With the 2D diagram, the architecture is fully specified and, I believe, very easy to read (though I'm open to feedback). It's not as pretty, but ease of manual creation and the boost in clarity are more important.
NN-SVG looks like a better UI around a beautiful parametrized isometric 3D architecture diagram generator, but it also looks like it suffers from the drawbacks I have experienced in the past. Can it handle residual or skip connections? How easy is it to modify? If you are creating publication-quality architecture diagrams daily, automating it may save you time, but if you've gotta write a bunch of code every time your model's components are tweaked and only need pretty diagrams once and a while, you might be better off doing it by hand. Moreover, whether you use a 3D or 2D diagram, I think it's worth favoring a format that aids reproducibility.