Fix label_smoothing in multidimensional CategoricalCrossentropy.
Fix label_smoothing in multidimensional CategoricalCrossentropy.

When label smoothing in CategoricalCrossentropy is non-zero, it takes
tf.shape(y_true)[1] as the number of classes. However, if the true
values and predictions are multidimensional (for example when training
a POS tagger where batch elements are sentences composed of words),
a wrong value is taken and the training does not work.

This fix takes the _last_ dimension as the one containing classes.

sarvex/tensorflow,annarev/tensorflow,freedomtan/tensorflow,aam-at/tensorflow,davidzchen/tensorflow,aldian/tensorflow,tensorflow/tensorflow,yongtang/tensorflow,davidzchen/tensorflow,tensorflow/tensorflow-pywrap_saved_model,tensorflow/tensorflow-experimental_link_static_libraries_once,paolodedios/tensorflow,yongtang/tensorflow,gautam1858/tensorflow,petewarden/tensorflow,karllessard/tensorflow,Intel-Corporation/tensorflow,paolodedios/tensorflow,annarev/tensorflow,annarev/tensorflow,tensorflow/tensorflow-pywrap_tf_optimizer,karllessard/tensorflow,tensorflow/tensorflow,davidzchen/tensorflow,cxxgtxy/tensorflow,davidzchen/tensorflow,frreiss/tensorflow-fred,karllessard/tensorflow,Intel-tensorflow/tensorflow,frreiss/tensorflow-fred,aam-at/tensorflow,yongtang/tensorflow,petewarden/tensorflow,Intel-tensorflow/tensorflow,cxxgtxy/tensorflow,tensorflow/tensorflow-pywrap_saved_model,annarev/tensorflow,cxxgtxy/tensorflow,tensorflow/tensorflow-experimental_link_static_libraries_once,tensorflow/tensorflow-pywrap_tf_optimizer,yongtang/tensorflow,tensorflow/tensorflow-experimental_link_static_libraries_once,sarvex/tensorflow,annarev/tensorflow,tensorflow/tensorflow-pywrap_saved_model,yongtang/tensorflow,aam-at/tensorflow,aam-at/tensorflow,paolodedios/tensorflow,davidzchen/tensorflow,tensorflow/tensorflow-experimental_link_static_libraries_once,Intel-tensorflow/tensorflow,tensorflow/tensorflow-pywrap_tf_optimizer,karllessard/tensorflow,annarev/tensorflow,tensorflow/tensorflow,Intel-tensorflow/tensorflow,freedomtan/tensorflow,petewarden/tensorflow,Intel-Corporation/tensorflow,tensorflow/tensorflow,aam-at/tensorflow,tensorflow/tensorflow,freedomtan/tensorflow,gautam1858/tensorflow,aldian/tensorflow,yongtang/tensorflow,davidzchen/tensorflow,frreiss/tensorflow-fred,aldian/tensorflow,annarev/tensorflow,gautam1858/tensorflow,karllessard/tensorflow,paolodedios/tensorflow,tensorflow/tensorflow-pywrap_saved_model,Intel-tensorflow/tensorflow,karllessard/tensorflow,freedomtan/tensorflow,tensorflow/tensorflow,yongtang/tensorflow,tensorflow/tensorflow-experimental_link_static_libraries_once,cxxgtxy/tensorflow,sarvex/tensorflow,tensorflow/tensorflow-pywrap_saved_model,aam-at/tensorflow,freedomtan/tensorflow,tensorflow/tensorflow-experimental_link_static_libraries_once,gautam1858/tensorflow,sarvex/tensorflow,gautam1858/tensorflow,Intel-tensorflow/tensorflow,paolodedios/tensorflow,cxxgtxy/tensorflow,freedomtan/tensorflow,freedomtan/tensorflow,karllessard/tensorflow,gautam1858/tensorflow,Intel-tensorflow/tensorflow,tensorflow/tensorflow,frreiss/tensorflow-fred,davidzchen/tensorflow,tensorflow/tensorflow,aam-at/tensorflow,sarvex/tensorflow,freedomtan/tensorflow,davidzchen/tensorflow,davidzchen/tensorflow,tensorflow/tensorflow-pywrap_saved_model,aldian/tensorflow,tensorflow/tensorflow,petewarden/tensorflow,freedomtan/tensorflow,gautam1858/tensorflow,tensorflow/tensorflow-experimental_link_static_libraries_once,Intel-tensorflow/tensorflow,annarev/tensorflow,karllessard/tensorflow,yongtang/tensorflow,tensorflow/tensorflow,aam-at/tensorflow,freedomtan/tensorflow,frreiss/tensorflow-fred,karllessard/tensorflow,tensorflow/tensorflow,sarvex/tensorflow,yongtang/tensorflow,tensorflow/tensorflow-pywrap_tf_optimizer,annarev/tensorflow,Intel-Corporation/tensorflow,petewarden/tensorflow,tensorflow/tensorflow-experimental_link_static_libraries_once,tensorflow/tensorflow-experimental_link_static_libraries_once,petewarden/tensorflow,tensorflow/tensorflow-pywrap_tf_optimizer,davidzchen/tensorflow,davidzchen/tensorflow,paolodedios/tensorflow,aldian/tensorflow,sarvex/tensorflow,tensorflow/tensorflow-pywrap_tf_optimizer,petewarden/tensorflow,frreiss/tensorflow-fred,paolodedios/tensorflow,tensorflow/tensorflow-pywrap_saved_model,annarev/tensorflow,tensorflow/tensorflow-pywrap_saved_model,tensorflow/tensorflow-pywrap_tf_optimizer,gautam1858/tensorflow,yongtang/tensorflow,tensorflow/tensorflow-pywrap_saved_model,gautam1858/tensorflow,frreiss/tensorflow-fred,paolodedios/tensorflow,annarev/tensorflow,Intel-tensorflow/tensorflow,tensorflow/tensorflow-pywrap_tf_optimizer,Intel-tensorflow/tensorflow,aldian/tensorflow,frreiss/tensorflow-fred,petewarden/tensorflow,petewarden/tensorflow,cxxgtxy/tensorflow,petewarden/tensorflow,karllessard/tensorflow,aldian/tensorflow,tensorflow/tensorflow-experimental_link_static_libraries_once,Intel-Corporation/tensorflow,aam-at/tensorflow,cxxgtxy/tensorflow,tensorflow/tensorflow-pywrap_saved_model,yongtang/tensorflow,Intel-Corporation/tensorflow,davidzchen/tensorflow,tensorflow/tensorflow-pywrap_tf_optimizer,gautam1858/tensorflow,tensorflow/tensorflow-experimental_link_static_libraries_once,frreiss/tensorflow-fred,tensorflow/tensorflow-pywrap_tf_optimizer,paolodedios/tensorflow,frreiss/tensorflow-fred,frreiss/tensorflow-fred,aam-at/tensorflow,gautam1858/tensorflow,aam-at/tensorflow,aam-at/tensorflow,petewarden/tensorflow,sarvex/tensorflow,tensorflow/tensorflow-pywrap_saved_model,paolodedios/tensorflow,freedomtan/tensorflow,Intel-Corporation/tensorflow,frreiss/tensorflow-fred,Intel-Corporation/tensorflow,tensorflow/tensorflow-pywrap_tf_optimizer,petewarden/tensorflow,gautam1858/tensorflow,aldian/tensorflow,paolodedios/tensorflow,karllessard/tensorflow,freedomtan/tensorflow,Intel-tensorflow/tensorflow,Intel-Corporation/tensorflow,cxxgtxy/tensorflow