Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/daviddao/spatial-transformer-tensorflow
🐝Tensorflow Implementation of Spatial Transformer Networks
https://github.com/daviddao/spatial-transformer-tensorflow
spatial-transformer-network tensorflow
Last synced: 13 days ago
JSON representation
🐝Tensorflow Implementation of Spatial Transformer Networks
- Host: GitHub
- URL: https://github.com/daviddao/spatial-transformer-tensorflow
- Owner: daviddao
- License: mit
- Created: 2016-03-27T02:04:32.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2019-10-17T09:04:40.000Z (about 5 years ago)
- Last Synced: 2024-10-15T17:48:30.847Z (29 days ago)
- Topics: spatial-transformer-network, tensorflow
- Language: Python
- Homepage:
- Size: 4.28 MB
- Stars: 292
- Watchers: 12
- Forks: 110
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Spatial Transformer Network
[![](https://tinyurl.com/greenai-pledge)](https://github.com/daviddao/green-ai)
The Spatial Transformer Network [1] allows the spatial manipulation of data within the network.
### API
A Spatial Transformer Network implemented in Tensorflow 0.7 and based on [2].
#### How to use
```python
transformer(U, theta, out_size)
```
#### ParametersU : float
The output of a convolutional net should have the
shape [num_batch, height, width, num_channels].
theta: float
The output of the
localisation network should be [num_batch, 6].
out_size: tuple of two ints
The size of the output of the network
#### Notes
To initialize the network to the identity transform init ``theta`` to :```python
identity = np.array([[1., 0., 0.],
[0., 1., 0.]])
identity = identity.flatten()
theta = tf.Variable(initial_value=identity)
```#### Experiments
We used cluttered MNIST. Left column are the input images, right are the attended parts of the image by an STN.
All experiments were run in Tensorflow 0.7.
### References
[1] Jaderberg, Max, et al. "Spatial Transformer Networks." arXiv preprint arXiv:1506.02025 (2015)
[2] https://github.com/skaae/transformer_network/blob/master/transformerlayer.py