Re:Ask HN: How to learn AI from first principles?
by HardikVala on Sunday January 26, 2025 @12:21PM
(#42831735)
Interesting idea. I like it.
Re:Ask HN: How to learn AI from first principles?
by drillsteps5 on Friday January 31, 2025 @09:16AM
(#42887899)
One can easily build forward pass (forward propagation), for neurons or perceptrons. The learning process itself (which includes gradient descent) is something else entirely, I'd love to learn how to do that, I read a few articles and my stopping point always was multi-variable differential equations, I just couldn't go any further. You could obviously use training functions from existing libraries, but I'm not aware how to do it from scratch...
Without reading about how it's done now, just think about how you think a neural network should function. It ostensibly has input, output, and something in the middle. Maybe its input is a 64x64 pixel handwritten character, and its output is a unicode number. In between the input pixels (a 64x64 array) and the output, are a bunch of neurons. Layers of neurons. That talk to each other and learn or un-learn (are rewarded or punished).
Build that. Build a cube where one side is a pixel grid and the other side delivers a number. Decide how the neurons influence each other and how they train their weights to deliver the result at the other end. However you think it should go. Just raw code it with arrays in whatever dimensions you want and make it work; you can do it in Javascript or BASIC. link them however you want. Don't worry about performance, because you can assume that whatever marginally works can be tested on a massive scale and show "impressive" results.