Neural-Network-p5
Neural-Network-p5 copied to clipboard
Added a way to visualize the neural network
I've added a method to the NeuralNetwork class that allows you to visualize it, looking something like this:

You can test it out here: https://sm-wistful.github.io/nvisdemo/demo.html
This implementation is still in beta, mainly because I would like to add:
-
A way to animate the network's learning (combining visualize with train)
-
A better way to access the p5 file; right now it parses the current URL and assumes there will be a p5.js file in the same directory. I would like to look into ways around this without using a CDN
I merged #28 b/c it's such a simple and small method, but I'm not sure about this one yet. Mostly I'm rewriting the entire library right now along with my tutorials so this code will be replaced with a new ES6 version. I also am hoping to do a "visualize the neural network" coding challenge! Thanks for this contribution and let's revisit a little later?
Thanks for replying. I do realize this solution isn’t very ideal and the code could use some work to be more readable, so I can definitely understand wanting to hold off. I honestly would like to see something that’s more intuitive and less clunky as well (though I struggled to figure out a good way myself) so I will definitely look out for that coding challenge! I agree that perhaps at that point things will be more clear and I can revisit contributing to this functionality.