Git Product home page Git Product logo

tensorflow-t3d's Introduction

Tensorflow-T3D

Tensorflow implementation for 'Temporal 3D ConvNets'(t3d)


Author yfxc
E-mail [email protected]

Introduction

'T3D' model can be applied to action recognition.Paper Url :https://arxiv.org/abs/1711.08200
Here is the tensorflow implementation with tf.slim to make code leaner. Different from the authors' original implementation.I convert traditional 3D convolution(eg. tf.nn.conv3d ) to P3D('pseudo-3d') convolution which can greatly reduce the number of parameters.
(P3D details:http://openaccess.thecvf.com/content_ICCV_2017/papers/Qiu_Learning_Spatio-Temporal_Representation_ICCV_2017_paper.pdf )

Preparing your own dataset.

Suppose you are about to use UCF dataset.Firstly converting videos to images is necessary. To do this,you could run codes like follows:(Suppose UCF-101 dataset is in the same directory as the code-files.)

  • ./process_video2image.sh UCF101
  • And next step,you should get the 'train.list' and 'test.list' which you would afterwards fetch from for training data and testing data individually:(number โ€˜5โ€™ indicates that one-fifth of all data is testing data.)
  • ./process_gettxt.sh UCF101 5

Note that:Due to the fact that Relative Path of the video clips exist in 'train.list' and 'test.list', So you must make sure that 'DataGenerator.py' and UCF-101 are in the same directory! or modify the codes by yourself.

Train or Eval model

After getting your own data and setting preference parameters in 'settings.py',You can run python train.py --txt='./train.list'(input parameter 'txt' has default value:'./train.list',in this way you can just run python train.py) to train model. You can also train and test model in 'tf-p3d-train_eval.ipynb' with jupyter notebook.

Others

  • Changing the properties for data augmentation in 'DataAugmenter.py'

Warning

  • DO NOT use tf.contrib.layers.batch_norm() or slim.batch_norm() which may lead to wrong answers when testing.Using tf.layers.batch_normalization(training=...) instead.

tensorflow-t3d's People

Contributors

yfxc avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.