Skip to content

A sandbox for fast image classification experiments. Define a custom network architecture using provided building blocks in seconds, then run an experiment!

Notifications You must be signed in to change notification settings

JBartholomewMN/Image-Classification-Sandbox

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

50 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Image Classification Sandbox


Introduction

The Image Classification Sandbox is an environment enabling quick and easy construction of classification networks for experimentation. The Sandbox has 4 building blocks for experimentation including some visual transformers, which can be mixed and matched arbitrarily for a custom network, or assembled to build popular networks (such as Darknet-53). The datasets that are supported are MNIST, ImageNet, and STL10.

Try An Experiment

Let's run a simple example. The configuration file defines everything (the network layers, optimizer, augmentatations, etc). Feel free to change or add!

python train_classifier.py --config experiments/mnist_conv_vanilla.py

Let's run a more complex experiment that uses a network with transformers that use convolutions!

python train_classifier.py --config experiments/mnist_convformer2.py

Building Blocks

If you would like to experiment with your own architecture, you can define your own config.py file. In the 'layers' field, you have 4 choices. No matter how you define your layers, final output is treated as fully convolutional allowing input images of different sizes. The system automatically appends a 1d convolution to get your feature maps down to your number of output classes and then follows it with a 2d global average and a fully connected layer (inspired by Darknet-53).

Note: Some details are omitted below like batch norms, layer norms, activations, etc

Infrequently Asked Questions

  1. Why did you build this? I wanted to build an environment where I could experiment with transformers originally, but ended up building out other blocks to have baselines and reference points. After investing time into this project, I figured I would open it up to anyone else who might benefit.
  2. Can I use this for whatever? Yes, go for it.
  3. Do the transformers work? Yes they do, but it takes a long time to train them, alot of data, and they can be very finnicky.

Citation

If you use ICS in your work, please cite:

@misc{Bartholomew2021ICS,
  author =       {Bartholomew, John}
  title =        {Image Classification Sandbox},
  howpublished = {\url{https://github.com/JBartholomewMN/Image-Classification-Sandbox}},
  year =         {2021}
}
``

About

A sandbox for fast image classification experiments. Define a custom network architecture using provided building blocks in seconds, then run an experiment!

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages