Coding a Neural Network from Scratch in C: No Libraries Required
ฝัง
- เผยแพร่เมื่อ 21 ส.ค. 2024
- Inside my school and program, I teach you my system to become an AI engineer or freelancer. Life-time access, personal help by me and I will show you exactly how I went from below average student to making $250/hr. Join the High Earner AI Career Program here 👉 www.nicolai-ni... (PRICES WILL INCREASE SOON)
You will also get access to all the technical courses inside the program, also the ones I plan to make in the future! Check out the technical courses below 👇
_____________________________________________________________
In this video 📝 we are going to learn how to build a neural network from scratch in C. We will first go over the basic theory about neurons and neural networks with visualizations. We will then jump into C and build the neural network from scratch and train it.
If you enjoyed this video, be sure to press the 👍 button so that I know what content you guys like to see.
_____________________________________________________________
🛠️ Freelance Work: www.nicolai-ni...
_____________________________________________________________
💻💰🛠️ High Earner AI Career Program: www.nicolai-ni...
⚙️ Real-world AI Technical Courses: (www.nicos-scho...)
📗 OpenCV GPU in Python: www.nicos-scho...
📕 YOLOv7 Object Detection: www.nicos-scho...
📒 Transformer & Segmentation: www.nicos-scho...
📙 YOLOv8 Object Tracking: www.nicos-scho...
📘 Research Paper Implementation: www.nicos-scho...
📔 CustomGPT: www.nicos-scho...
_____________________________________________________________
📞 Connect with Me:
🌳 linktr.ee/nico...
🌍 My Website: www.nicolai-ni...
🤖 GitHub: github.com/nic...
👉 LinkedIn: / nicolaiai
🐦 X/Twitter: / nielsencv_ai
🌆 Instagram: / nicolaihoeirup
_____________________________________________________________
🎮 My Gear (Affiliate links):
💻 Laptop: amzn.to/49LJkTW
🖥️ Desktop PC:
NVIDIA RTX 4090 24GB: amzn.to/3Uc7yAM
Intel I9-14900K: amzn.to/3W4Z5Cb
Motherboard: amzn.to/4aR6wBC
32GB RAM: amzn.to/3Jt2XVR
🖥️ Monitor: amzn.to/4aLP8hh
🖱️ Mouse: amzn.to/3W501GH
⌨️ Keyboard: amzn.to/3xUGz5b
🎙️ Microphone: amzn.to/3w1F1WK
📷 Camera: amzn.to/4b4Ryr9
_____________________________________________________________
Tags:
#NeuralNetwork #C #DeepLearning - วิทยาศาสตร์และเทคโนโลยี
Join My AI Career Program
www.nicolai-nielsen.com/aicareer
Enroll in My School and Technical Courses
www.nicos-school.com
Doing ML things without any libraries and with C is a feeling.... like baby walking without the the help of walker or any support. Thanks for such a great thing
Thanks a lot! Haha yeah that’s so true
Great idea, doing a project like this without any libraries basically guarantees I understand both C and ML, the perfect learning experience.
Thanks a lot! Totally agree
Thank you so much for the video. It was my first time coding NN's, and everything was so clear and easy to follow!
Thank u so much! Really appreciate it
wow man, that is very cool. I have only come across this in python but not C. Keep it up!
Thanks a lot man!
great job man! finnaly something so minimal, simple and comprehencible. Without Bias arraies it gets even more cleaner.. and with the same result ;)
Thanks a lot for watching!
Followed it in JavaScript, and it works !
Thank you !
Great!
Thanks very much for taking the time to make this video. I got your code working, and modified it to do any number of layers and any number of nodes. I could not have done it without your help. What really helped a lot was the fact that you found the simplest complex case - the XOR gate! An OR gate or AND gate would have been too simple, but XOR is just complex enough to see the AI doing its stuff. Bravo.
Thanks a lot for watching Mark! glad that it helped you out. Really appreciate ur kind words aswell. If u don’t mind sharing the general code with me. I would love to take a look at it and maybe do a video about it. My mail is thecodinglibraryyt@gmail.com just in case
Thank you so much for sharing such a knowledge
Thanks for watching!
@@NicolaiAI do you think there is way to make a gan with c ?
Thanks a lot for the comprehensive code mate, I was able to re-implement this in Rust with almost no issues
That's cool. Maybe it makes sense to do a training course on the use of С in the world of finance.
Thanks for the suggestion!
Thanks, great to see implementation in good old "C". Can this also apply for convulsion networks?
Thanks for watching! Yeah but cnn would be a bit more complex since we will add more dimensions
@@NicolaiAI Interesting. Thank You again for this amazing tutorial done in C, super helpful to make and design AI fine tuned for different embedded NPU/GPU/CPU hardware. I have tried looking for books and online courses to do these task all in pure C and if not C++ and couldn't find any, however your channel have many tutorials into it.
@@ShopperPlug thanks a lot for the nice words! Really appreciated it
this video rocks, its a lot to take it at once i had to watch it in chunks but i'm excited to use it to build something for my portfolio!
Sounds awesome man! Thanks for watching
Tysm Man i was searching for this for a long time you are the best! =)
Thanks for watching bro! Means a lot to me
Perfect!!!
Thanks a lot!
dSigmoid should be sigmoid(x) * (1 - sigmoid(x) ) not x * (1-x), am i wrong? i am so confused in this part
They are equivalent here since we take the sigmoid of the values in the hidden layer and output layer and then we pass those values into our dsigmoid. Ur formula is correct but we already have our sigmoid values in this example
nice video and very good explanation!
Glad you liked it! My pleasure
at 44:45 error += deltaOutput[k] * outputWeights[j][k]; the errors individually can be huge but their sum can be == 0 because negative errors may compensate positive errors; so errors should be ABS(error) or error*error... Pls correct me if I'm wrong....
Doing it without libraries at fist is how you are guaranteed to understand it.
*me following with the rust programming language*
Awesome! Great idea
@@NicolaiAI :)
please make a new video like this that helped much and i learned how to code nn myself
Thanks a lot man! Glad that u learned something from the video
thank you. I can make my owned library for regression
Awesome man! Yeah def do that. Great learning
@@NicolaiAI yeah awesome, Man.
thank you so much.
Thanks for watching!
Can i use the this house prediction data purpose
Don't really get the shuffle part, could you explain it in more detail?
Mange tak!
Tak for kigget!
why not using the real Dsigmoid (replacing x by sigmoid(x)) ?
Is this code still available on your github page? I don't see it.
Yeah should be in there somewhere
For(k) error
Line 56
Thanks, How Can Implant Levenberg-Marquardt algorithm in cpp? for nn
letter for letter i copied this, it never finishes a training loop
stack around variables corrupt. the variable changes.
Try removing the return 0; at the end and tell me if it work
Is c++ similar?
Yeah its almost the same in this case
watching this tutorial having never programmed in c before
time to reimplement this all in rust XD (im trying to code an OS and i want to try implementing some cool features)
Sounds very cool!
How's the OS project going?
Where is the dc link?
👍
32:32