Image Classification using Inception V4

In this example, we convert Inception V4 trained on Tensorflow to SINGA for image classification. Tested on SINGA version 1.1.1 with parameters pretrained by tensorflow.


  • Download the parameter checkpoint file

      $ wget
      $ tar xvf inception_v4.tar.gz
  • Download synset_word.txt file.

  • Run the program

      # use cpu
      $ python -C &
      # use gpu
      $ python &
  • Submit images for classification

      $ curl -i -F image=@image1.jpg http://localhost:9999/api
      $ curl -i -F image=@image2.jpg http://localhost:9999/api
      $ curl -i -F image=@image3.jpg http://localhost:9999/api

image1.jpg, image2.jpg and image3.jpg should be downloaded before executing the above commands.


We first extract the parameter values from Tensorflow‘s checkpoint file into a pickle version. After downloading and decompressing the checkpoint file, run the following script

$ python --file_name=inception_v4.ckpt