Softmax

The softmax turns n numbers in RN into a probability distribution proportional to the size of the numbers.

Given an n-dimensional vector v with all component terms in RN, the softmax of v is: softmax(v)i=exp(vi)j=1nexp(vi)