资源算法spatial-transformer-tensorflow

spatial-transformer-tensorflow

2020-02-27 | |  36 |   0 |   0

Spatial Transformer Network

图片.png

The Spatial Transformer Network [1] allows the spatial manipulation of data within the network.

图片.png

API

A Spatial Transformer Network implemented in Tensorflow 0.7 and based on [2].

How to use

图片.png

transformer(U, theta, out_size)

Parameters

U : 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 :

identity = np.array([[1., 0., 0.],
                    [0., 1., 0.]]) 
identity = identity.flatten()
theta = tf.Variable(initial_value=identity)

Experiments

图片.png

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


上一篇:ntm_back_translation

下一篇:recurrent-spatial-transformer-code

用户评价
全部评价

热门资源

  • seetafaceJNI

    项目介绍 基于中科院seetaface2进行封装的JAVA...

  • spark-corenlp

    This package wraps Stanford CoreNLP annotators ...

  • Keras-ResNeXt

    Keras ResNeXt Implementation of ResNeXt models...

  • capsnet-with-caps...

    CapsNet with capsule-wise convolution Project ...

  • inferno-boilerplate

    This is a very basic boilerplate example for pe...