Posts: 3
Joined: Mon Jan 16, 2017 10:43 am

Using Lego 42055 and IBM Watson to identify bricks

Mon Jan 16, 2017 12:31 pm

A fun way to learn about Watson Visual Recognition and creating your own classifier, is with
Lego 42055, and a Raspberry Pi.


This is on top of this Lego 42055 machine

What you can notice in the video is the time it takes to identify a brick, we have 12 bricks, that are transported in 16 seconds. It took 40 seconds more to finish the recognition process.


Not all identifications are correct
We can gain some performance by tighter coupling, but the measurements show that I takes up to 2 seconds to classify an image.
This is the round trip to the Watson Cloud Services.

To train Watson with the images, I first did a couple of rounds just collecting frames/images.
For each brick ca. 35 images are used to train, and not to forget: the "negative" images, those are the images that have no brick but "only" transporter belt.
I made sure the lighting and camera distance stayed (more or less) the same.

First I had hoped to keep op with the fysical world and show live icons.
In the end, I decided to demonstrated the recognition skills by photographing the order in which the bricks were put on the transport belt.

This is how I mounted the Raspberry Pi on the Lego machine

Posts: 1
Joined: Thu Oct 12, 2017 12:26 am

Re: Using Lego 42055 and IBM Watson to identify bricks

Thu Oct 12, 2017 12:28 am

I would love to create the same thing. I have been having a lot of difficult getting started with Watson. I was hoping you could lead my in a good direction or provide the source that you used.

Posts: 3
Joined: Mon Jan 16, 2017 10:43 am

Re: Using Lego 42055 and IBM Watson to identify bricks

Fri Oct 13, 2017 8:29 am

Hi, I shared a more technical explanation here: https://www.ibm.com/developerworks/comm ... pi?lang=en
I have used the JAVA version of the Watson SDK : there are other options available here: https://github.com/watson-developer-cloud

The basic mechanism I used here was:
  • let the Raspberry Software for the Camera take a picture every second
    save the picture in a folder
    another software process monitors this folder (in my case a java program)
    the new pictures are send to the IBM cloud where I used my own model (you need to train it first)
    the result code is mapped to a picture that I display

Return to “Other projects”

Who is online

Users browsing this forum: Baidu [Spider] and 6 guests