Earlier quoted context omitted.
Naive solution (1 line): https://gist.github.com/applecrazy/deda2fac6e83c07b93e001731... Edit: I literally took newlines, converted to \n in a string, and then exec()ed the whole thing. Here's a repl of it working: https://repl.it/@applecrazy/Code-Golfing-a-Neural-Net
Oh dear, I got played. PM address if you want the beer, you sly dog. Obligatory, I'm a normal dude: http://vesche.github.io/ Edit: Wait, you can't PM on here... PM on reddit /u/vesche
How to build your own neural network from scratch in Python
31–40 of 46 posts
Re: How to build your own neural network from scratch in Python
#32If it’s just personal preference, I’m fine with that, I’m not trying to start a flame war.
Re: How to build your own neural network from scratch in Python
#33Re: How to build your own neural network from scratch in Python
#34This is not as glorified as it sound. 100 of thousands of students around the world build neural net from scratch as their homework. People please move on, spend your time somewhere else which is more productive. I coded neural network using c++ in 2009 as homework. But I never though about showing this to people.
Strange reaction to a “beginner’s guide”, how can someone move on before they learn the basics?
Re: How to build your own neural network from scratch in Python
#35Too often you see articles like this and they start with $ import a_whole_bunch_of_stuff Good to see that this is not the case here :) The fast.ai course has a similar exercise in the beginning, but you'll still import the weights from somewhere else. Their fast.ai v1 library has a very short implementation too (loading the MINIST example dataset and then using Resnet18): from fastai import * from fastai.data import…
How is your example not "$ import a_whole_bunch_of_stuff"?
Re: How to build your own neural network from scratch in Python
#36Earlier quoted context omitted.
Naive solution (1 line): https://gist.github.com/applecrazy/deda2fac6e83c07b93e001731... Edit: I literally took newlines, converted to \n in a string, and then exec()ed the whole thing. Here's a repl of it working: https://repl.it/@applecrazy/Code-Golfing-a-Neural-Net
Oh dear, I got played. PM address if you want the beer, you sly dog. Obligatory, I'm a normal dude: http://vesche.github.io/ Edit: Wait, you can't PM on here... PM on reddit /u/vesche
Re: How to build your own neural network from scratch in Python
#37Re: How to build your own neural network from scratch in Python
#38Earlier quoted context omitted.
You always have to start somewhere. Do you want to code all the OS from the ground up, or do you have minimal expectations about the environment your software will run on? Do you want to look at all the tiny details, or do you wish to focus on a specific aspect of the problem? The article author could also give an explanation of linear algebra, but I guess he expects the reader to be familiar with this part of the pr…
> I guess that there's always a software layer which may be considered "backbone". The point is that you don't need any software layers at all to code up a basic neural network implementation. A programming language with basic floating-point operations is all you need. The algorithms are not complicated so even x86 Assembly is practical for this purpose if you're already experienced with it. So the "backbone" can sim…
I grafted my answer to the wrong post, I meant to respond to the guy talking about the project implicitely using Numpy.
Offtopic remark: It would be nice to be able to move a post to a different thread, or make a single answer to several messages.
Re: How to build your own neural network from scratch in Python
#39I suggest a remarkably useful device: Four circular disks when attached to a cart make it easy to move the cart from location to another. Furthermore you could put goods in that cart and move them too. A lot easier than carrying the goods on you back or an animal. A brief search of the internet finds this is a new idea.
Re: How to build your own neural network from scratch in Python
#40Honest question: what are the reasons to code this up using OOP, creating a neural network object plus methods, instead of data structures and functions that operate on them? If it’s just personal preference, I’m fine with that, I’m not trying to start a flame war.
Coming from the R side, I tend to prefer structures & functions as well, but if I tried to write Python that way I'd be wary about showing that code to anyone more entrenched in the Pythonic way of thinking.