Using Spatial Transformer Layer[1] with keras (theano backend). The file 'SpatialTransformer.py' is originally from skaae's Lasagne version[2].
You can find a simple example in the notebook file.
[1] Jaderberg, Max, et al. "Spatial Transformer Networks." arXiv preprint arXiv:1506.02025 (2015).