Previously, we saw how to use the capabilities of the App Inventor to take advantage of the features and capabilities of modern devices such as text to speech and GPS.
Today we are going to learn about a new way we can create AI applications and Image Classification.
LookExtension is an extension for mit app inventor that enables the creation of artificial intelligence programs that use machine learning to enable smart and mobile devices to classify images on the app.
Create an Artificial intelligence Image Classification app
The extension in mit app inventor is a set of rules and blocks that are not part of the main program but can be imported from an external source to enable us to create applications with Image Classification capability.
mit app inventor App Objectives
- Using the mit app inventor LookExtension extension and using it to build an Android application to identify and classify images through machine learning.
App Tools
Tool #1: Button
Palette:
Name:
Use: Pressed to take pictures by the phone's camera or smart device to identify and classify them.
Tool #2: Label
Palette:
Name: Label1
Use: Show the rating information of the captured image after it has been recognized.
Tool #3: Label
Palette:
Name: Label1
Use: Show program status.
Tool #4: HorizontalArrangement
Palette:
Name: HorizontalArrangement1
Use: Arrange the components on the screen horizontally.
Tool #5: WebViewer
Palette: Interface User
Name: WebViewer1
Use: It has the LookExtension extension and provides an internet connection.
Tool #6: LookExtension
Palette: Extension
Name: Look1
Use: The external extension is responsible for image recognition and classification.
Adjust mit app inventor tool properties
Tool:
Action: Deactivate the Enabled property of the button from the Properties panel.
Tool: Look1
Action:
- Download the LookExtension extension from this link.
- Then upload it within the application via the Import Extension command in the Extension panel.
- Setting: Link the Look1 extension to the tool (WebViewer1) via the Properties panel.
Steps
start app inventor with a new project, use add screen button on designer view to insert multiple screens in the project.App Blocks
App Preview
- Choose Al companion command from the Connect menu.
- Point the phone's camera at the code that will appear on the screen and press the (Scan QR code) button to launch the app on the phone.
- Point the camera of the phone or smart device towards the thing you want to identify and then press the Scan button in the app so that the name of the thing appears in the result title and its degree of recognition, try that with many items.