This video realized by the AI Lab of SoftBank Robotics shows how Pepper robot learns to play the ball-in-a-cup game (“bilboquet” in French). The movement is first demonstrated to the robot by guiding its arm.
From there, Pepper has to improve its performance through trial-and-error learning. Even though the initial demonstration does not land the ball in the cup, Pepper can still learn to play the game successfully.
The movement is represented as a so-called dynamic movement primitive and optimized using an evolutionary algorithm. Our implementation uses the freely available software library dmpbbo: https://github.com/stulp/dmpbbo.
After 100 trials, Pepper has successfully optimized its behavior and is able to repeatedly land the ball in the cup.