Try it Yourself: 11 Brick Image Set for Image Recognition and Neural Network exploration

This work is licensed under a Creative Commons Attribution 3.0 International License.
Updated 12/8/2018:
I have now uploaded all the data sets I’ve used to Kaggle, you can download them here:
20 Brick Types for Sorting (4,500+ images)
5 Parts to This Blog
This part of a 5 Blog Series to cover the mechanical and software design for the Lego Sorter, as well as sharing the training set and some evaluation sets:
1. Lego Sorter using TensorFlow on Raspberry
2. Mechanical Separation (Design, Motors and Sensors)
3. Overview of the Software stack
4. Using Inception V3 to Identify LEGO vs. Generic Bricks
5. Try It Yourself: 2 Big Data Sets so you can Replicate this Project
Perform Image Recognition
This image set is a fantastic opportunity to become familiar with image recognition techniques. Here are some ideas you can test:
1. Can you detect the objects?
There are multiple ways of detecting an object in a image such as Contours and Edge detection. Can you identify the object? Calculate its are? Crop the image?

2. If you were to prepare a Neural Network training set, can you identify the images that contain more than one object?
This would probably be easy once you can identify objects. You will realize that in order to train a Neural Network on this set, you might want to analyze each image contains only 1 brick type.

3. Can you identify the Bricks using only Image Recognition?
Identifying the LEGO brick doesn’t necessarily need a Neural network and it is possible to use Image Recognition techniques (combined with geometry) to correctly identify the bricks.
Train and Validate your own Model
4. Use other Neural Networks or Machine Learning Techniques
I decided to use TensorFlow and Inception V3 to train my model, but there are many other options you can use.
You can choose another neural network (build your own or re-train ones such as VGG16, VGG19, ResNet, Xception, etc.) and also use different frameworks like scikit-learn and XGBoost

5. Validate your Results with the Evaluation Sets
I have included an actual set captured from two evaluation runs of my LEGO Sorter. Use these sets to validate your trained Neural Network.
Identify Lego Brand vs non-Lego Brand pieces
I purposely built a sample of bricks that included LEGO Brand and non-LEGO brand.
This would definitely be for bonus points as it is probably ambitious given the size of the data set, but if it’s possible, it would be very interesting to learn how you solved it!

5 Parts to This Blog
This part of a 5 Blog Series to cover the mechanical and software design for the Lego Sorter, as well as sharing the training set and some evaluation sets:
1. Lego Sorter using TensorFlow on Raspberry
2. Mechanical Separation (Design, Motors and Sensors)
3. Overview of the Software stack
4. Using Inception V3 to Identify LEGO vs. Generic Bricks
5. Try It Yourself: 2 Big Data Sets so you can Replicate this Project