How machines learn
In Chapter 1, "Machine Learning and Machine Learning Solutions Architecture," we discussed the self-improvement capability of ML algorithms through data processing and parameter updates, leading to the generation of models akin to compiled binaries in computer source code. But how does an algorithm actually learn? In essence, ML algorithms learn by optimizing an objective function, also known as a loss function, which involves minimizing or maximizing it. An objective function can be seen as a business metric, such as the disparity between projected and actual product sales. The aim of optimization is to reduce this disparity. To achieve this, an ML algorithm iterates and processes extensive historical sales data (training data), adjusting its internal model parameters until the gaps between projected and actual values are minimized. This process of finding the optimal model parameters is referred to as optimization, with mathematical routines specifically...