How machines learn
In Chapter 1, Machine Learning and Machine Learning Solutions Architecture, we briefly talked about how ML algorithms can improve themselves by processing data and updating model parameters to generate models (analogous to traditional compiled binary from computer source code). So, how does an algorithm actually learn? In short, ML algorithms learn by optimizing (for example, minimizing or maximizing) an objective function (also known as a loss function). You can think of an objective function as a business metric, such as the difference between the projected sales of a product and the actual sales, and the goal of optimizing this objective would be to reduce the difference between the actual sales number and the projected sales number. To optimize this objective, an ML algorithm would iterate and process through large amounts of historical sales data (training data) and adjust its internal model parameters until it can minimize the differences between the projected...