Return to page


What is the Backpropagation Algorithm?

Backpropagation algorithms are the building blocks of neural networks. This algorithm is used to test the limits of a neural network and to analyze any errors between output and input nodes. Backpropagation is fast and ideal for small to medium-sized networks, as these networks have fewer derivatives. Backpropagation is more memory-efficient than other algorithms. 

Backpropagation Algorithms in Neural Networks 

Backpropagation is used in neural networks to improve output. A neural network is a collection of connected input and output nodes. Each node's accuracy is expressed as a loss function, which is also known as an error rate. To read more about Neural Networks, click here.

Backpropagation calculates the mathematical gradient, or slope, of the error rate compared against the other weights in the neural network. Based on the calculations, neural network nodes with high error rates are given less weight than nodes with lower error rates, which are given more weight. Weights determine how much influence an input will have on an output.

How Backpropagation Algorithms Work

Note the output of the model when the “W” value is 3: 


Notice the difference between the actual output and the desired output:


If the “W” value is changed to 4, notice the errors: 


Backpropagation trains a neural network by assigning random weights to the algorithms and analyzing where the error in the system increases. When errors occur, the difference between the model output and the actual output is calculated. Once calculated, a different weight is assigned and the system is run again, to see if the error is minimized. If the error is not minimized, then an update of parameters is required

To update parameters, weights and biases are adjusted. Biases are located after weights and are in a different layer of a network, always being assigned the value of 1. After the parameters are updated, the process is run again. Once the error is at a minimum, the model is ready to start predicting. 

In looking at the diagram below, if “W” also known as weight is changed, then the error of the system goes up, if “W” is changed into a smaller number the error goes down. Once the error is as close to zero as possible that weight is set as the parameter and the model can start predicting. 

Types of Backpropagation

There are two types of backpropagation: static and recurrent. 

Static Backpropagation 

A static backpropagation network aims to produce a map of static inputs to fixed outputs. This type of network can solve static classification problems such as optical character recognition (OCR), which allows computers to understand written documents. 

Recurrent Backpropagation 

Recurrent backpropagation is used in data mining, to find the fixed value. Once the fixed value is found, the error is computed and then run through a backpropagation algorithm.

The difference between the two types of backpropagation is that static mapping is immediate and recurrent backpropagation takes a longer time to map. 

Why Use Backpropagation

Backpropagation increases the accuracy of predictions as it is able to calculate derivatives quickly. Backpropagation algorithms are intended to develop learning algorithms for multilayer feedforward neural networks. This algorithm is trained to capture mapping, which in turn aids in data mining and machine learning.  Backpropagation increases efficiency by reducing the errors found in a network.