You can already train an image model for hand gestures. Today in Scratch you will load that model into a rock, paper, scissors game and play against the computer.
Before you build, think: what might go wrong if the model is only slightly sure about a gesture? Have your model's link ready: you will start a new project and build the game step by step, testing it as you go.
Your rock, paper, scissors game has four parts:
The confidence threshold is the interesting one: it decides how sure the model has to be before your game acts on what it thinks it sees.
Set up a new project in Stretch3 with the TM2Scratch extension:
Scratch Extensions are additional sets of blocks that expand the capabilities of your Scratch projects. They allow you to:
When you add an extension to your project:
Add a new sprite to the project that will represent the computer's choice in the game. You can choose any sprite you like, but for this example, we'll use the 'Gobo' sprite.
To add a sprite from the sprite library follow these steps:
You can use search box or the filter links (Animals, People, Fantasy etc) to locate your sprite.
You're previewing this lesson. Get full access to this lesson and hundreds more — each one ready to teach, with interactive activities, printable resources and pupil progress tracking built in.