Google Image Classifier
The Google Image Classifier is a general-purpose model designed to recognize and identify objects in an image. It’s based on the MobileNet ImageNet classifier model.
Already included in the SD card image
Demo: Google Image Classifier
Time: 15 minutes
This demo uses an object detection model to identify objects from an image. Try any image you like and see how accurate the model is.
What you’ll need
- Assembled Vision Kit
- Connection to your device
Step 1: Get connected
First, make sure you’re connected to your device and have a terminal open.
Step 2: Stop your current demo
Your Vision Kit may already have another demo running, like the Smile Detector which runs by default when your kit is turned on. You’ll need to turn off any demos that are currently running. To do that, press Control-C.
Step 3: Find an image
Before you can try out the demo, you need an image that the model can look at. Learn how you can use an online image.
Step 4: Run command
Enter the following command into your terminal application:
~/AIY-projects-python/src/examples/vision/image_classification.py --input <input image>
If you ran into an error, check Help.
Try it out
Your demo should now be running! If you ran into an error, check the FAQ for help.
If may take some time for the kit to process the image and print out a result. Once it does, check your terminal screen for its answer.
When you’re done with the demo, remember to stop it before trying another demo by pressing Control-C.
Finding an image to use with your model
You can find an image online using the Wget program. When you have an image in mind, here’s how to use it:
- Make sure you’re connected to your kit via SSH or through peripherals and have a terminal window open
- Make sure you also have the image’s URL available
- In your terminal, enter: wget
- For example: wget https://www.example.com/example.jpg
- The file will be downloaded to the current directory