Automatic differentiation

Machine learning models, especially deep learning models, can optimize their own parameters based on the error rate that's calculated by the value of the derivative function. However, generally, it is impossible to derive the derivative function of any function. This means that there's no practical way of calculating the error rates of each parameter for any machine learning model. Around the 1960s, an algorithm was invented to solve this problem, known as backpropagation. Backpropagation is an algorithm that allows us to derive the value to be optimized for each operation node in the graph. This algorithm implements the following steps:

  1. It finds the error rate between the prediction result of the model and the ...

Get Hands-On Machine Learning with TensorFlow.js now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.