TensorFlow in version <=2.4 is slow when tf.keras.layers.Embedding is used
Using the embedding layer can significantly slow down backward propagation.
tf.keras.layers.Embedding can significantly slow down backwards
propagation (up to 20 times). This is caused by a bug which is not yet fixed
in TensorFlow upstream.
TensorFlow upstream does not have a fix yet. If the Embedding layer is important to you from performace point of view, switch to alternative libraries, such as PyTorch.