What are Global minima and Local minima in Machine Learning? What are Global minima and Local minima in Machine Learning? How is it used?
 A: There are a few explanations already, but I figure I would throw some mathematical flavor in the mix.
Let $f : \mathbb{R}^n \to \mathbb{R}$ be a function.  A Global Minimum (minima is the plural form) is a point in $\mathbf{x}_0 \in \mathbb{R}^n$ such that for all other $\mathbf{x} \in \mathbb{R}^n$, $f(\mathbf{x}_0) < f(\mathbf{x})$.
In English, this means that $\mathbf{x}_0$ is the point where $f$ attains its smallest value.  For example, the point $x=1$ is the global minima for the function $x^2 - 2x + 1$.  The function $x^3$ has no global minima; I can always find a point which attains a smaller value (mostly by choosing large negative numbers).
Let $f : \mathbb{R}^n \to \mathbb{R}$ be a function.  A Local Minimum (minima is the plural form) is a point in $\mathbf{x}_0 \in  \mathbb{R}^n$ such that $f(\mathbf{x}_0) < f(\mathbf{x}) \iff \lVert\mathbf{x} - \mathbf{x}_0 \rVert< \epsilon $. The "local" here refers to a neighourbood around $\mathbf{x}_0$ (hence the local).  It might be the case that some other point $\mathbf{x}_1$ results in smaller output than $\mathbf{x}_0$, which is why local optima can mislead optimization models.
So in short:  Global minima are the places where the function attains its smallest value.  Local minima are places where the function attains its smallest value in a neighbourhood of a point.  Global minima are what we want when we optimize a loss function (smallest loss we could ever obtain).  Local optima can be good, but by virtue of being local and not global we could do better.
A: In ML, one would like to find parameters that minimize the loss function i.e., give you the lowest loss on your dataset. If your loss function is convex, standard optimization techniques like gradient descent will find parameters that converge towards global minima i.e., where loss value is the lowest. However, if your loss function is non-convex, convergence to global minima isn't guaranteed. Hence, the optimization might lead towards local minima convergence, where loss value is higher than the value at global minima.
A: The terms refer to properties of the loss function. When we optimize the parameters of, say, a neural network, we can get caught in a local minimum that has some nice properties that a global minimum has (it is a valley of some sort), but it is not the minimum of the function.
In other words, we can do better.
In this drawing, the horizonal axis is some parameter value for a one-parameter model, and the vertical axis is the loss function. A loss function for a useful model might have many more parameters than just one, and you can wind up with a loss function that is twisted and crumpled in thousands or millions of dimensions.

