Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file added ar-SA/images/12_or_330.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added ar-SA/images/banner.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added ar-SA/images/bee_or_berry.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added ar-SA/images/cake_or_biscuit.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added ar-SA/images/five_or_three.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added ar-SA/images/train_model.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added ar-SA/images/wywm.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
23 changes: 23 additions & 0 deletions ar-SA/meta.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
title: Teach a machine
hero_image: images/banner.png
description: Teach a computer to tell you how many fingers you are holding up!
version: 1
listed: true
copyedit: true
last_tested: "2024-05-24"
steps:
-
title: What you will make
-
title: Add images
completion:
- engaged
-
title: Train and test
completion:
- internal
-
title: Challenge
challenge: true
completion:
- external
35 changes: 35 additions & 0 deletions ar-SA/resources/Teach a machine 1.srt
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
1
00:00:02,840 --> 00:00:03,960
Go to rpf.io/tm

2
00:00:05,920 --> 00:00:10,880
and rename 'Class 1' and 
'Class 2' to 'Five' and 'Three'

3
00:00:10,880 --> 00:00:13,040
Click 'Webcam' in the Five class

4
00:00:13,040 --> 00:00:14,760
and hold up five fingers

5
00:00:14,760 --> 00:00:19,240
With your other hand, press and 
hold the 'Hold to record' button

6
00:00:19,240 --> 00:00:21,680
to gather loads of images

7
00:00:21,680 --> 00:00:24,360
Switch to the 'Three' class 
and gather loads of images

8
00:00:24,360 --> 00:00:29,200
of you holding up three fingers

1 change: 1 addition & 0 deletions ar-SA/resources/readme.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
To watch a video with subtitles on VLC (videolan.org), ensure the video file and subtitle file are in the same folder and have the exact same name (e.g., video.mp4 and video.srt). Open the video in VLC, and it will automatically load the subtitles. If the subtitles don’t appear, right-click the video screen, go to **Subtitle**, then **Add Subtitle File**, and select the correct .srt file. Enjoy watching with subtitles!
27 changes: 27 additions & 0 deletions ar-SA/resources/teach a machine 2.srt
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
1
00:00:03,040 --> 00:00:05,320
Click 'Train model' and hang on...

2
00:00:05,320 --> 00:00:08,920
because it could take ten to 
twenty seconds to complete

3
00:00:08,920 --> 00:00:12,800
When your model is trained, 
the preview panel will open

4
00:00:12,800 --> 00:00:18,200
Hold up five and three fingers and watch 
the confidence scores in the output below.

5
00:00:18,200 --> 00:00:21,440
Why not see if it can recognise cake or biscuits?

6
00:00:21,440 --> 00:00:27,200
Or bees and berries?

27 changes: 27 additions & 0 deletions ar-SA/step_1.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
## What you will make

![The image shows a machine learning interface from "Teachable Machine" where a model is being trained to recognize hand gestures for the numbers "Five" and "Three." On the right, in the "Preview" section, the webcam feed displays a hand showing three fingers. Below this, the "Output" section shows the classification results, with the model predicting a 94% probability for "Three" and a small 6% probability for "Five." The model has successfully identified the hand gesture as "Three."](images/wywm.png)

You will teach a computer to tell you how many fingers you are holding up!

\--- collapse ---

---

## title: Where are my images stored?

- This project uses a technology called 'machine learning'. Machine learning systems are trained using a large amount of data.
- This project does not require you to create an account or log in. For this project, the image examples you use to make the model are only stored temporarily in your browser (only on your machine).
- No images from your webcam are sent to this website or any other website.

\--- /collapse ---

You will need a **webcam**.

## --- collapse ---

## title: No YouTube? Download the videos!

You can [download all the videos for this project](https://rpf.io/p/en/teach-a-machine-go){:target="_blank"}.

\--- /collapse ---
54 changes: 54 additions & 0 deletions ar-SA/step_2.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
## Add images

<html>
<div style="position: relative; overflow: hidden; padding-top: 56.25%;">
<p><iframe style="position: absolute; top: 0; left: 0; right: 0; width: 100%; height: 100%; border: none;" src="https://www.youtube.com/embed/hsxN8Fy8XYY?rel=0&cc_load_policy=1" allowfullscreen allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share"></iframe></p>
</div>
</html>

\--- task ---

Open [Teachable Machine](https://rpf.io/tm){:target="_blank"}.

\--- /task ---

Each class is a category that you want the computer to recognise.

\--- task ---

- Rename `Class 1` to `Five`
- Rename `Class 2` to `Three`

\--- /task ---

Gather images of `five` fingers.

\--- task ---

- Click **Webcam** in the `Five` class
- Hold up five fingers to your webcam (make sure your whole hand is in view)
- With your other hand, press and hold the **Hold to Record** button to gather lots of images

\--- /task ---

\--- collapse ---

---

## title: Where are my images stored?

- None of your data is stored or sent to this or any other site.
- The technology is called 'machine learning', but it is not learning while you use it.
- It has already been trained using a large number of photos.

\--- /collapse ---

Gather images of `three` fingers.

\--- task ---

- Click **Webcam** in the `Three` class
- Hold up three fingers to your webcam (make sure your whole hand is in view)
- With your other hand, press and hold the **Hold to Record** button to gather lots of images

\--- /task ---
37 changes: 37 additions & 0 deletions ar-SA/step_3.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
## Train the model

<html>
<div style="position: relative; width: 100%; overflow: hidden; padding-top: 56.25%;">
<p><iframe style="position: absolute; top: 0; left: 0; right: 0; width: 100%; height: 100%; border: none;" src="https://www.youtube.com/embed/Sso5cORp1yQ?rel=0&cc_load_policy=1" width="560" height="315" allowfullscreen allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share"></iframe></p>
</div>
</html>

\--- task ---

Click **Train Model**.

![The 'Train Model' button.](images/train_model.png)

\--- /task ---

**Note**: Be patient! It can take 10 to 20 seconds to complete.

### Preview and test

When your model is trained, the preview panel will open.

\--- task ---

- Hold up **five** fingers and watch the 'Output' section underneath the preview.

You will see confidence scores for `Five` and `Three`.

\--- /task ---

\--- task ---

- Hold up **three** fingers
- What is the highest confidence score you can get for `Five`?
- What is the highest confidence score you can get for `Three`?

\--- /task ---
36 changes: 36 additions & 0 deletions ar-SA/step_4.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
## Challenge

\--- challenge ---

Create your own classifier!

### Bee or berry?

\--- task ---

I once ate a bee by mistake. Teach a machine to keep you safe!

![An image of a bee is held up to a web camera. Then, an image of a berry. In the output panel underneath the video, the confidence score is displayed as to whether a bee or a berry is being shown.](images/bee_or_berry.gif)

\--- /task ---

### Cake or biscuit?

\--- task ---

Settle the argument.

![A piece of cake is held up to a web camera. Then, a biscuit. In the output panel underneath the video, the confidence score is displayed as to whether a cake or a biscuit is being shown.](images/cake_or_biscuit.gif)

\--- /task ---

### Resistor recogniser

\--- task ---

Solve a problem for digital makers everywhere!

![A 12 ohm resistor is held up to a web camera. Then, a 330 ohm resistor. In the output panel underneath the video, the confidence score is displayed as to whether a 12 ohm or a 330 ohm resistor is being shown.](images/12_or_330.gif)

\--- /task ---
\--- /challenge ---
3 changes: 3 additions & 0 deletions ar-SA/step_5.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
## What can you do now?

There are lots of other machine learning and AI projects in the [artificial intelligence](https://projects.raspberrypi.org/en/pathways/ai-toolkit) toolkit.
Binary file added cy-GB/images/12_or_330.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added cy-GB/images/banner.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added cy-GB/images/bee_or_berry.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added cy-GB/images/cake_or_biscuit.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added cy-GB/images/five_or_three.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added cy-GB/images/train_model.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added cy-GB/images/wywm.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
23 changes: 23 additions & 0 deletions cy-GB/meta.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
title: Teach a machine
hero_image: images/banner.png
description: Teach a computer to tell you how many fingers you are holding up!
version: 1
listed: true
copyedit: true
last_tested: "2024-05-24"
steps:
-
title: What you will make
-
title: Add images
completion:
- engaged
-
title: Train and test
completion:
- internal
-
title: Challenge
challenge: true
completion:
- external
35 changes: 35 additions & 0 deletions cy-GB/resources/Teach a machine 1.srt
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
1
00:00:02,840 --> 00:00:03,960
Go to rpf.io/tm

2
00:00:05,920 --> 00:00:10,880
and rename 'Class 1' and 
'Class 2' to 'Five' and 'Three'

3
00:00:10,880 --> 00:00:13,040
Click 'Webcam' in the Five class

4
00:00:13,040 --> 00:00:14,760
and hold up five fingers

5
00:00:14,760 --> 00:00:19,240
With your other hand, press and 
hold the 'Hold to record' button

6
00:00:19,240 --> 00:00:21,680
to gather loads of images

7
00:00:21,680 --> 00:00:24,360
Switch to the 'Three' class 
and gather loads of images

8
00:00:24,360 --> 00:00:29,200
of you holding up three fingers

1 change: 1 addition & 0 deletions cy-GB/resources/readme.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
To watch a video with subtitles on VLC (videolan.org), ensure the video file and subtitle file are in the same folder and have the exact same name (e.g., video.mp4 and video.srt). Open the video in VLC, and it will automatically load the subtitles. If the subtitles don’t appear, right-click the video screen, go to **Subtitle**, then **Add Subtitle File**, and select the correct .srt file. Enjoy watching with subtitles!
27 changes: 27 additions & 0 deletions cy-GB/resources/teach a machine 2.srt
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
1
00:00:03,040 --> 00:00:05,320
Click 'Train model' and hang on...

2
00:00:05,320 --> 00:00:08,920
because it could take ten to 
twenty seconds to complete

3
00:00:08,920 --> 00:00:12,800
When your model is trained, 
the preview panel will open

4
00:00:12,800 --> 00:00:18,200
Hold up five and three fingers and watch 
the confidence scores in the output below.

5
00:00:18,200 --> 00:00:21,440
Why not see if it can recognise cake or biscuits?

6
00:00:21,440 --> 00:00:27,200
Or bees and berries?

27 changes: 27 additions & 0 deletions cy-GB/step_1.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
## What you will make

![The image shows a machine learning interface from "Teachable Machine" where a model is being trained to recognize hand gestures for the numbers "Five" and "Three." On the right, in the "Preview" section, the webcam feed displays a hand showing three fingers. Below this, the "Output" section shows the classification results, with the model predicting a 94% probability for "Three" and a small 6% probability for "Five." The model has successfully identified the hand gesture as "Three."](images/wywm.png)

You will teach a computer to tell you how many fingers you are holding up!

\--- collapse ---

---

## title: Where are my images stored?

- This project uses a technology called 'machine learning'. Machine learning systems are trained using a large amount of data.
- This project does not require you to create an account or log in. For this project, the image examples you use to make the model are only stored temporarily in your browser (only on your machine).
- No images from your webcam are sent to this website or any other website.

\--- /collapse ---

You will need a **webcam**.

## --- collapse ---

## title: No YouTube? Download the videos!

You can [download all the videos for this project](https://rpf.io/p/en/teach-a-machine-go){:target="_blank"}.

\--- /collapse ---
Loading