Based on Keras's attention