• Stars
    star
    313
  • Rank 133,714 (Top 3 %)
  • Language
    Python
  • Created over 6 years ago
  • Updated over 6 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Computes features for images using various pretrained Tensorflow models

Compute-Features

Computes features for images using various pretrained Tensorflow models. For each model, this will output the final fully connected layer (e.g. fc7 for Alexnet, fc8 for VGG_19, etc.). These can be used within various applications such as classification, clustering, etc.

Usage

Download one of the checkpoint files below, for example Inception V1.

tar -xvf inception_v1_2016_08_28.tar.gz
python compute_features.py --data_dir=test_images/ --checkpoint_file=inception_v1.ckpt --model=inception_v1

The output will be in inception_v1_features.pkl, which contains a dictionary of the form {image_path:feature}.

Look at load_features.py for an example of how to use the features that were computed. For example,

python load_features.py features/inception_v1_features.pkl

Some of these aren't working, such as inception_v4 due to differences in the model checkpoint and the model defined in the nets/ directory. Still working on that.

Pre-trained Models

You can download all models here. Otherwise links for individual models can be found below.

These CNNs have been trained on the ILSVRC-2012-CLS image classification dataset.

In the table below, we list each model, the corresponding TensorFlow model file, the link to the model checkpoint, and the top 1 and top 5 accuracy (on the imagenet test set). Note that the VGG and ResNet V1 parameters have been converted from their original caffe formats (here and here), whereas the Inception and ResNet V2 parameters have been trained internally at Google. Also be aware that these accuracies were computed by evaluating using a single image crop. Some academic papers report higher accuracy by using multiple crops at multiple scales.

Model TF-Slim File Checkpoint Top-1 Accuracy Top-5 Accuracy
Inception V1 Code inception_v1_2016_08_28.tar.gz 69.8 89.6
Inception V2 Code inception_v2_2016_08_28.tar.gz 73.9 91.8
Inception V3 Code inception_v3_2016_08_28.tar.gz 78.0 93.9
Inception V4 Code inception_v4_2016_09_09.tar.gz 80.2 95.2
Inception-ResNet-v2 Code inception_resnet_v2_2016_08_30.tar.gz 80.4 95.3
ResNet V1 50 Code resnet_v1_50_2016_08_28.tar.gz 75.2 92.2
ResNet V1 101 Code resnet_v1_101_2016_08_28.tar.gz 76.4 92.9
ResNet V1 152 Code resnet_v1_152_2016_08_28.tar.gz 76.8 93.2
ResNet V2 50 Code resnet_v2_50_2017_04_14.tar.gz 75.6 92.8
ResNet V2 101 Code resnet_v2_101_2017_04_14.tar.gz 77.0 93.7
ResNet V2 152 Code resnet_v2_152_2017_04_14.tar.gz 77.8 94.1
VGG 16 Code vgg_16_2016_08_28.tar.gz 71.5 89.8
VGG 19 Code vgg_19_2016_08_28.tar.gz 71.1 89.8

More Repositories

1

Colorful-Image-Colorization

A deep learning approach to colorizing images
Python
320
star
2

Underwater-Color-Correction

Using GANs to correct color distortion in underwater images.
Python
290
star
3

cWGANs

Conditional Wasserstein GANs
Python
71
star
4

Improved-Wasserstein-GAN

Implementation of the improved WGAN in Tensorflow
Python
19
star
5

deepixel

A deep learning approach to depixelate an image using tensorflow
Python
18
star
6

LSGANs-Tensorflow

Least Squares GANs in Tensorflow
Python
17
star
7

Wasserstein-GAN-Tensorflow

Implementation of Wasserstein GAN in Tensorflow
Python
16
star
8

Autoencoder

An autoencoder using a convolutional neural network with Tensorflow
Python
11
star
9

Colorizing-Images-Using-Adversarial-Networks

Colorizing images using an adversarial network approach.
TeX
11
star
10

Day-Night-Classification

Day and night image classification using a Support Vector Machine and Neural Network
Python
5
star
11

EBGAN-Tensorflow

Energy-Based Generative Adversarial Networks in Tensorflow
Python
4
star
12

tensorflow_ops

A small library of common functions to use in Tensorflow
Python
4
star
13

ICGANs

Implementation of Invertible Conditional GANs for Image Editing
Python
4
star
14

AstroGAN

Generating galaxies using GANs
Python
3
star
15

Adversarial-Agent

Imitation learning using GANs for GTAV
Python
2
star
16

UGAN-V2

Unpaired image to image translation.
Python
2
star
17

BB84-Quantum-Key-Exchange

An implementation of the BB84 Quantum Key Exchange in Java
Java
2
star
18

simGAN

Implementation of simGAN
Python
1
star
19

PlantMonitor

Monitoring my plant with various sensors
Python
1
star
20

Tensorflow-Operations

Collection of Tensorflow operations I commonly use
Python
1
star
21

DCGANs-Tensorflow

Implementation of DCGANs in Tensorflow
Python
1
star
22

DistorterGAN

Distorts images to make them appear underwater.
Python
1
star
23

pokemon

Scripts and stuff for machine learning on pokemon
Python
1
star
24

Classification-Tool

Simple binary labeling system in Python
Python
1
star
25

DRAGAN

Implementation of the How to Train your DRAGAN
1
star
26

MOOC

Massive Open Online Courses
1
star