-
Notifications
You must be signed in to change notification settings - Fork 2k
Some changes for AI Kit/HAT+ #3966
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from 6 commits
Commits
Show all changes
8 commits
Select commit
Hold shift + click to select a range
33b6ea8
hailo: Update documentation for new assets file location and note abo…
naushir 9063891
hailo: Add alternative package version instructions.
naushir 875623b
hailo: Rename the page from "AI software" to "AI Kit/Hat+ software" f…
naushir 1521088
Apply suggestions from code review
nathan-contino 0ff632b
Apply suggestions from code review
nathan-contino 32c6a2c
Update documentation/asciidoc/computers/ai/getting-started.adoc
nathan-contino 01799f8
Update documentation/asciidoc/computers/ai/getting-started.adoc
nathan-contino d50cc58
Apply suggestions from code review
nathan-contino File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -60,6 +60,8 @@ Serial Number: HLDDLBB234500054 | |
| Part Number: HM21LB1C2LAE | ||
| Product Name: HAILO-8L AI ACC M.2 B+M KEY MODULE EXT TMP | ||
| ---- | ||
|
|
||
| NOTE: AI HAT+ devices may show `<N/A>` for `Serial Number`, `Part Number` and `Product Name`. This is expected, and does not impact functionality. | ||
| + | ||
| Additionally, you can run `dmesg | grep -i hailo` to check the kernel logs, which should yield output similar to the following: | ||
| + | ||
|
|
@@ -96,24 +98,20 @@ The `rpicam-apps` suite of camera applications implements a xref:camera_software | |
|
|
||
| The following demos use xref:camera_software.adoc#rpicam-hello[`rpicam-hello`], which by default displays a preview window. However, you can use other `rpicam-apps` instead, including xref:camera_software.adoc#rpicam-vid[`rpicam-vid`] and xref:camera_software.adoc#rpicam-still[`rpicam-still`]. You may need to add or modify some command line options to make the demo commands compatible with alternative applications. | ||
|
|
||
| To begin, download the post-processing JSON files required for the demos. These files determine which post-processing stages to run and configure the behaviour of each stage. For example, you can enable, disable, strengthen, or weaken the strength of the temporal filtering in the object detection demos. Or you could enable or disable the output mask drawing in the segmentation demo. | ||
|
|
||
| To download the entire collection of post-processing JSON files, clone the `rpicam-apps` repo. Run the following command to clone only the most recent commit from the repo, saving space: | ||
| To begin, run the following command to install the latest `rpicam-apps` software package: | ||
|
|
||
| [source,console] | ||
| ---- | ||
| $ git clone --depth 1 https://github.com/raspberrypi/rpicam-apps.git ~/rpicam-apps | ||
| $ sudo apt update && sudo apt install rpicam-apps | ||
| ---- | ||
|
|
||
| TIP: The commands provided in subsequent sections use the JSON files in this repository. To make it easy to reference these files, this command creates the cloned `rpicam-apps` directory in your home folder. If you modify the location of this directory, you must also alter the demo commands below to reference the new location of the JSON files. | ||
|
|
||
| ==== Object Detection | ||
|
|
||
| This demo displays bounding boxes around objects detected by a neural network. To disable the viewfinder, use the xref:camera_software.adoc#nopreview[`-n`] flag. To return purely textual output describing the objects detected, add the `-v 2` option. Run the following command to try the demo on your Raspberry Pi: | ||
|
|
||
| [source,console] | ||
| ---- | ||
| $ rpicam-hello -t 0 --post-process-file ~/rpicam-apps/assets/hailo_yolov6_inference.json --lores-width 640 --lores-height 640 | ||
| $ rpicam-hello -t 0 --post-process-file /usr/share/rpi-camera-assets/hailo_yolov6_inference.json | ||
| ---- | ||
|
|
||
| Alternatively, you can try another model with different trade-offs in performance and efficiency. | ||
|
|
@@ -122,21 +120,21 @@ To run the demo with the Yolov8 model, run the following command: | |
|
|
||
| [source,console] | ||
| ---- | ||
| $ rpicam-hello -t 0 --post-process-file ~/rpicam-apps/assets/hailo_yolov8_inference.json --lores-width 640 --lores-height 640 | ||
| $ rpicam-hello -t 0 --post-process-file /usr/share/rpi-camera-assets/hailo_yolov8_inference.json | ||
| ---- | ||
|
|
||
| To run the demo with the YoloX model, run the following command: | ||
|
|
||
| [source,console] | ||
| ---- | ||
| $ rpicam-hello -t 0 --post-process-file ~/rpicam-apps/assets/hailo_yolox_inference.json --lores-width 640 --lores-height 640 | ||
| $ rpicam-hello -t 0 --post-process-file /usr/share/rpi-camera-assets/hailo_yolox_inference.json | ||
| ---- | ||
|
|
||
| To run the demo with the Yolov5 Person and Face model, run the following command: | ||
|
|
||
| [source,console] | ||
| ---- | ||
| $ rpicam-hello -t 0 --post-process-file ~/rpicam-apps/assets/hailo_yolov5_personface.json --lores-width 640 --lores-height 640 | ||
| $ rpicam-hello -t 0 --post-process-file /usr/share/rpi-camera-assets/hailo_yolov5_personface.json | ||
| ---- | ||
|
|
||
| ==== Image Segmentation | ||
|
|
@@ -145,7 +143,7 @@ This demo performs object detection and segments the object by drawing a colour | |
|
|
||
| [source,console] | ||
| ---- | ||
| $ rpicam-hello -t 0 --post-process-file ~/rpicam-apps/assets/hailo_yolov5_segmentation.json --lores-width 640 --lores-height 640 --framerate 20 | ||
| $ rpicam-hello -t 0 --post-process-file /usr/share/rpi-camera-assets/hailo_yolov5_segmentation.json --framerate 20 | ||
| ---- | ||
|
|
||
| ==== Pose Estimation | ||
|
|
@@ -154,8 +152,51 @@ This demo performs 17-point human pose estimation, drawing lines connecting the | |
|
|
||
| [source,console] | ||
| ---- | ||
| $ rpicam-hello -t 0 --post-process-file ~/rpicam-apps/assets/hailo_yolov8_pose.json --lores-width 640 --lores-height 640 | ||
| $ rpicam-hello -t 0 --post-process-file /usr/share/rpi-camera-assets/hailo_yolov8_pose.json | ||
| ---- | ||
|
|
||
| === Alternative Package Versions | ||
|
|
||
| The AI Kit and AI HAT+ do not function if there is a version mismatch between the Hailo software packages and device drivers. In addition, Hailo's neural network tooling may also require particular a version for the generated model file. If you require an specific version, complete the following steps to install the proper versions of all of the dependencies: | ||
nathan-contino marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
|
|
||
| . If you have previously used `apt-mark` to hold any of the relevant packages, you may need to unhold them: | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Is this something that a typical user is likely to have done? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Only if they have an explicit reason to do so, e.g. running older models. |
||
| + | ||
| [source,console] | ||
| ---- | ||
| $ sudo apt-mark unhold hailo-tappas-core hailort hailo-dkms | ||
| ---- | ||
|
|
||
| . Install the required version of the software packages: | ||
| + | ||
| [tabs%sync] | ||
| ====== | ||
| v4.18:: | ||
| To install version 4.18 of Hailo's neural network tooling: | ||
| + | ||
| + | ||
| [source,console] | ||
| ---- | ||
| $ sudo apt install hailo-tappas-core=3.29.1 hailort=4.18.0 hailo-dkms=4.18.0-2 | ||
| ---- | ||
| + | ||
| [source,console] | ||
| ---- | ||
| $ sudo apt-mark hold hailo-tappas-core hailort hailo-dkms | ||
| ---- | ||
|
|
||
| v4.17:: | ||
| To install version 4.17 of Hailo's neural network tooling: | ||
| + | ||
| [source,console] | ||
| ---- | ||
| $ sudo apt install hailo-tappas-core-3.28.2 hailort=4.17.0 hailo-dkms=4.17.0-1 | ||
| ---- | ||
| + | ||
| [source,console] | ||
| ---- | ||
| $ sudo apt-mark hold hailo-tappas-core hailort hailo-dkms | ||
| ---- | ||
| ====== | ||
|
|
||
| === Further Resources | ||
|
|
||
|
|
||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.