Google I/O is a wrap! Catch up on TensorFlow sessions

# tf.keras.backend.categorical_crossentropy

Categorical crossentropy between an output tensor and a target tensor.

target A tensor of the same shape as output.
output A tensor resulting from a softmax (unless from_logits is True, in which case output is expected to be the logits).
from_logits Boolean, whether output is the result of a softmax, or is a tensor of logits.
axis Int specifying the channels axis. axis=-1 corresponds to data format channels_last', andaxis=1corresponds to data formatchannels_first`.

Output tensor.

ValueError if axis is neither -1 nor one of the axes of output.

#### Example:

import tensorflow as tf
from tensorflow.keras import backend as K
a = tf.constant([1., 0., 0., 0., 1., 0., 0., 0., 1.], shape=[3,3])
print("a: ", a)
b = tf.constant([.9, .05, .05, .5, .89, .6, .05, .01, .94], shape=[3,3])
print("b: ", b)
loss = K.categorical_crossentropy(a, b)
print('Loss: ', loss) #Loss: tf.Tensor([0.10536055 0.8046684  0.06187541], shape=(3,), dtype=float32)
loss = K.categorical_crossentropy(a, a)
print('Loss: ', loss) #Loss:  tf.Tensor([1.1920929e-07 1.1920929e-07 1.1920929e-07], shape=(3,), dtype=float32)
[{ "type": "thumb-down", "id": "missingTheInformationINeed", "label":"Missing the information I need" },{ "type": "thumb-down", "id": "tooComplicatedTooManySteps", "label":"Too complicated / too many steps" },{ "type": "thumb-down", "id": "outOfDate", "label":"Out of date" },{ "type": "thumb-down", "id": "samplesCodeIssue", "label":"Samples / code issue" },{ "type": "thumb-down", "id": "otherDown", "label":"Other" }]
[{ "type": "thumb-up", "id": "easyToUnderstand", "label":"Easy to understand" },{ "type": "thumb-up", "id": "solvedMyProblem", "label":"Solved my problem" },{ "type": "thumb-up", "id": "otherUp", "label":"Other" }]