Machine Learning: The Tool of the Century

An overview of machine learning and artificial neural networks (ANNs)

I want to start this article off by sharing with you a conversation I had today. I asked 10 of my friends, “What’s artificial intelligence?”

My conversation with Kevin went a little like this. Warning: if you’re an AI nerd like me, this may be a little triggering… ⚠️

Me: Hey Kevin! You got a minute?

Kevin: Sure, what’s up?

Me: I have a random question… Do you know what AI is?

Kevin: Who? Aye Eye?

Me: Nooooo, like A . I .

Kevin: Hmmm, Aye eye…

Me: No no no, like artificial intelligence.

Kevin: Nope, never heard of him. Is he a rapper?

Me: …

Nope, artificial intelligence is not a rapper.

All of the people I asked had a similar response, some worse than others. The conclusion I have come to is that none of my friends understand artificial intelligence.

But seriously, this actually blows my mind. More than a third of all companies in the world have used artificial intelligence in one way or another, yet two thirds of consumers don’t even realize they’re using artificial intelligence… including many of my friends. Even apps that Kevin uses, like Netflix and Snapchat, use artificial intelligence.

Everyone should have at least a baseline understanding of how artificial intelligence works. It’s disrupting every aspect of our lives, from medical diagnosis to therapy.

When most people hear “artificial intelligence,” they think of smart robots. Smart robots, like this one to the right, are not artificial intelligence.

This Sophia, an well known, advanced robot that runs on AI.

Rather, they run on artificial intelligence. Artificial intelligence is the software that makes robots like this smart, and more often than not, this is not the goal of artificial intelligence.

There are 3 main types of artificial intelligence: narrow, general, and super. We have yet to achieve super, or even general intelligence. Artificial narrow intelligence (ANI) includes machine learning, which is being used to make self-driving cars, show you advertisements, and improve disease diagnosis.

Machine learning is the field in which computers learn and improve from data overtime without being explicitly programmed.

One type of machine learning uses artificial neural networks (ANNs), inspired by the biological neural networks in our brain.

Like biological neural networks, ANNs take in input(s) and return output(s). The outputs are then passed on to another neuron, thus being the inputs to the next neuron.

This is an abstracted artificial neural network. It takes in input(s), an n amount, which subsequently go through a series of hidden layers to produce n amount of outputs.

Each node represents a neuron, and each edge represents a connection between those neurons. This network is fully connected and feedforward, meaning the output of a neuron is passed forward to all of the neurons in the proceeding layer.

However, this is abstracted, and there’s some math involved:

Each input is multiplied by its corresponding weight, w, represented by an edge in the network. The summation of all inputs * weights is calculated, and a bias term, b, is added. The output is then found by multiplying the summation by an activation function.

We need an activation function to turn the summation between 0 and 1. This makes our data a lot easier to work with.

There are many activation functions, liked ReLU and tanH, but the one most widely used is the Sigmoid activation function.

Euler’s number is e and x is the summation. All you really need to know is that this “squishes” the value between 0 and 1.

Now that we have the fundamentals down, how can this actually be used ⁉️

There are actually a few different types of machine learning we can do with neural networks:

  • Supervised learning ➡️ maps an input to an output based on example input-output pairs

  • Unsupervised learning ➡️ draws inferences from datasets consisting of input data without labeled responses

  • Reinforcement learning ➡️ a type of learning in which an algorithm called an agent learns by interacting with its environment

Although all of these are useful in different scenarios, we’ll be focusing on supervised learning, in which we pass through inputs labeled with desired outputs, or predictions. Based on how “wrong” the neural network’s predictions are, the weights and biases are updated to make the prediction closer to the desired output. This process is called training the neural network.

We train the neural network in a process called gradient descent, in which the neural network’s weights and biases are adjusted to minimize the prediction error. You can think of gradient descent as climbing down a mountain, in which you’re trying to get to the lowest point, or in this case, the lowest error. This will make the neural network better at predicting future data, called the test data.

There are virtually endless applications of this technology, including predicting schizophrenia based on the brain (click here to see my project on this), to giving computers vision with convolutional neural networks (CNNs).

Some of the most beneficial applications are in medical image diagnosis. With vast amounts of training data, a CNN can be used to predict whether a sample has a tumor earlier than most doctors.

Every single day scientists are learning more and more about it. In the next 20 years, machine learning could look completely different than it does now, and it probably will… but there’s no other way to find out unless we see for ourselves 👀

Key Takeaways 🔑

  • Artificial intelligence is a powerful tool that’s disrupting every single industry right now. However, a ton of people don’t understand what it is or how it works

  • Artificial intelligence is not a smart robot — it is what makes the smart robot smart

  • Machine learning is a type of artificial narrow intelligence that can be used to learn from data. It uses artificial neural networks (ANNs) which mimic biological neurons and are trained with gradient descent

  • The three main types of machine learning are unsupervised, supervised, and reinforcement learning, all of which are useful in different scenarios

  • The applications of ANNs are virtually endless, and are even being used to make self-driving cars and more accurate cancer diagnoses