The activation function used to produce the probabilities per class is called the softmax function. It turns the output of the fully connected layer, or the last layer, into probabilities. The sum of the probabilities of the classes is 1 – Panda = 0.04, Cat = 0.91, and Dog = 0.05, which totals 1.Â
We can see the values of the softmax function in the following screenshot:
Fig 6.15: Output of softmax
In the next section of this chapter, we will implement a handwritten digit recognition CNN model using the Keras API.