How I Understood Machine Learning with No Maths Background

Machine Learning is thought of as one of the most challenging fields of programming, so how did a 17-year-old high school student end up creating complex GAN networks in TensorFlow?

Illarstration of machine learning
from Unsplash

It is not easy

No one has ever said machine learning is easy. Not only do you have to have an excellent grasp of coding and programming concepts, but you also have to understand the maths.

The maths is by far, what separates those who try and those who succeed. You will need to understand Calculus, Linear Algebra, Iterative Operations along with much more. These topics are as daunting as they sound to any newbie but don’t shy away just yet. This guide will give you the tools and mindset required to chip away at each of these and even go beyond!

How I started

Coding in python was my very first step towards the beautiful world of ML. I began reading books and doing online courses in python. At this time, I had no idea what I wanted to do, but I would soon catch a glimpse of AI, and it’s beauty.

Once I had decided Machine Learning is what I wanted to do, I began taking in-depth, intermediate courses about neural networks (on Udacity) — obviously this was a mistake.

After realising my mistake, I took a step back, took a deep breath and began learning the maths required. I would watch video after video explaining all sorts of concepts such as Vector Spaces, planes, partial derivates, dot products matrix multiplication and so on. As you can guess, there was a lot, and my enthusiasm was running out.

This process involved lots of giving up and coming back later. There was not much hope for 15 year old me.

What didn’t work

The big problem most people have when starting with machine learning is that they are too ambitious. I watched a video of AI playing hide and seek, which got me so excited that I wanted to know how to build machine learning algorithms right then and there.

My excitement is what made my life difficult; by going straight into those deep learning courses, I put myself in an impossible position. I had set high expectations of myself that when I couldn’t understand anything, it crushed me. Do not do this, be reasonable and understand you will be in for a rough ride.

What did work

The one thing I did correctly was learning to code first. I highly recommend getting a strong understanding of Python before trying to tackle machine learning. Python is a great language, especially if you are brand new to programming in general. If you decide later on that you don’t want to learn AI, then python is still a great language to know.

Your next step should be to begin cracking on with that maths involved with machine learning. This is the hardest part, and the best solution that I found was to crack down on specific topics. I had to make notes, do practice questions and even revise now and again. It was almost like having school after I finished school, every day.

The key for me was to build from the bottom up. That meant doing the most tedious parts first and not building a neural network for a long time.

Someone holding a sticky note with “Python” written on it
Someone holding a sticky note with “Python” written on it
from Unsplash

What You Should Do

Firstly, make sure you are very comfortable with Python. Make sure you understand the following: Classes/Objects, Functions, Loops, Data types (lists, dictionaries, tuples etc.).

After a foundation has been built, you will need to move on to something like Pandas. Pandas is a library in Python which makes working with lots of data much more manageable. If you are unsure whether you know enough, then try building Blackjack in python; this should test your skills and maybe even teach you a thing or two.

You understand python and now you’re incredibly eager to get started with machine learning, but where do you start? Like I’ve said before, start with searching up and covering the mathematical principles. Learn the following (in-depth): Calculus (derivatives, integration, partial derivatives), Linear Algebra (matrices, matrix multiplication, dot multiplication, vector spaces). Make sure you are NOT LAZY. Just because you can derive x squared does not mean you know derivatives (cover fractional derivatives and awkward powers).

from Unsplash

I used examsolutions for the calculus and khan academy for all of my linear algebra. Lastly try to get a rough understanding of stats (averages, sampling, standard deviation, distributions), which is also found on khan academy.

Especially for the linear algebra I highly recommend doing as much as you can; obviously, not all of it is required, but it helps to go a bit beyond what is required. I say this because many people will learn the bare minimum but then will continuously struggle with it. If you go a little beyond then, you will find everything you see in machine learning will be like second nature to you.

If you want to have a more thorough understanding of matrices I recommend a youtube playlist by 3Blue1Brown “Essence of Linear Algebra”.

form Unsplash

Your First Algorithm

Now that you’ve acquired all the background knowledge that you need, you can start with your first algorithm! However, don’t do what I did and start with neural networks — I know, it’s a bummer.

Before getting to your final goal, try just understanding the following: SVM, k-nearest neighbour, random forest and AdaBoost. If you can grasp these concepts, then you are ready for the mighty giant that is building a neural network from scratch!

Once you’re ready to build your very own neural net, I recommend this introductory course on Udacity. I learned almost all of my machine learning skills from here.

I wish you all lots of luck and don’t forget, if you get stuck, no one has ever said machine learning is easy.

Extra Notes

This is an account of how I overcame the mountain of machine learning, and I hope it will encourage you to do the same.

Please give it a clap to help those lost souls looking for a bit of encouragement.

Medium has become my go-to place to post my thoughts and guides on the world of programming. I highly recommend to anyone. I post every week, see you there :)