Subscribe to our blog to get the latest articles straight to your inbox.

While machine learning and neural networks are often mentioned in the same breath, they aren’t quite the same thing. Below, we’ll go over everything you need to know to start using neural networks for your most pressing business problems.

The Difference Between Machine Learning and Neural Networks

Strictly speaking, a neural network (also called an “artificial neural network”) is a type of machine learning model that is usually used in supervised learning. By linking together many different nodes, each one responsible for a simple computation, neural networks attempt to form a rough parallel to the way that neurons function in the human brain.

The idea behind neural networks was first born in the 1950s with the perceptron algorithm. A perceptron is a simplified model of a human neuron that accepts an input and performs a computation on that input. The output is then fed to an activation function, which decides whether the neuron will “fire” based on the output value.

While one perceptron cannot recognize complicated patterns on its own, there are thousands, millions, or even billions of connections between the neurons in a neural network. This allows the network to handle even highly complex inputs.

Researchers “train” a neural network over time by analyzing its outputs on different problems and comparing them with the correct answers. Using an algorithm known as backpropagation, the neural network can adjust the influence of any particular node in the network, attempting to reduce the errors that the network makes when calculating a final result.

The Types of Neural Networks

In the “classic” artificial neural network, information is transmitted in a single direction from the input to the output nodes. However, there are two other neural network models that are particularly well-suited for certain problems: convolutional neural networks (CNNs) and recurrent neural networks (RNNs).

Convolutional Neural Networks

Convolutional neural networks (CNNs) are frequently used for the tasks of image classification.

For example, suppose that you have a set of photographs and you want to determine whether a cat is present in each image. CNNs process images from the ground up. Neurons that are located earlier in the network are responsible for examining small windows of pixels and detecting simple, small features such as edges and corners. These outputs are then fed into neurons in the intermediate layers, which look for larger features such as whiskers, noses, and ears. These outputs are then used to make a final judgment about whether the image contains a cat.

CNNs, and deep neural networks in general, are so revolutionary because they take the task of feature extraction out of the hands of human beings. Prior to using CNNs, researchers would often have to manually decide which characteristics of the image were most important for detecting a cat. However, neural networks can build up these feature representations automatically, determining for themselves which parts of the image are the most meaningful.

Recurrent Neural Networks

Whereas CNNs are well-suited for working with image data, recurrent neural networks (RNNs) are a strong choice for building up sequential representations of data over time: tasks such as document translation and voice recognition.

Just as you can’t detect a cat looking at a single pixel, you can’t recognize text or speech looking at a single letter or syllable. To correctly perform translation and speech recognition, you need to understand not only the current letter or syllable, but also the previous data that came before it in time.

RNNs are capable of “remembering” the network’s past outputs and using these results as inputs to later computations. By including loops as part of the network model, information from previous steps can persist over time, helping the network make smarter decisions.

When to Use Neural Networks

Often referred to under the trendy name of “deep learning,” neural networks are currently in vogue. This is thanks to two main reasons:

  • The proliferation of “big data” makes it easier than ever for machine learning professionals to find the input data they need to train a neural network.
  • GPUs (graphics processing units) are computer processors that are optimized for performing similar calculations in parallel. Advances in GPU technology have enabled machine learning researchers to vastly expand the size of their neural networks, train them faster, and get better results.

Neural networks are best for situations where the data is “high-dimensional.” For example, a medium-size image file may have 1024 x 768 pixels. Each pixel contains 3 values for the intensity of red, green, and blue at that point in the image. All told, this is 1024 x 768 x 3 = 2,359,296 values. Each one of these values is a separate dimension and a separate input to a neuron at the start of the network.

Of course, while neural networks are an important part of machine learning theory and practice, they’re not all that there is to offer. Based on the structure of the input data, it’s usually fairly clear whether using a neural network, or another machine learning technique, is the right choice.

For example, one machine learning model that’s entirely separate from neural networks is the decision tree. Let’s say that you run a real estate website and you want to predict the value of a house based on certain information.

In a decision tree, calculating a final result begins at the top of the tree and proceeds downwards:

  • At the top node of the tree, you examine a single feature of the data, such as the number of bedrooms in the house. Based on the value of this feature, the computation splits off into two or more children nodes, similar to a “choose your own adventure” book. For example, there might be one node for houses with 1 or 2 bedrooms, and another node for houses with more than 2 bedrooms.
  • At the next level of the tree, the computation splits again based on a different feature of the data, such as the house’s ZIP code, its square footage, or the level of crime in the area.
  • The computation ends when you reach a terminal node at the bottom of the tree. This node should have an associated value that estimates the house’s price.

Decision trees often require human input via feature selection and engineering in order to reach optimal performance. On the other hand, neural networks are capable of handling extremely large numbers of dimensions and quickly condensing them into the most important features.

Final Thoughts

Deciding when to use neural networks for your machine learning problem is all about learning from experience and exercising your best judgment. Need an expert opinion? Give us a call and we’ll be happy to dispense some good advice.