Pose Recognition Example

How to use HUSKYLENS 2 pose recognition in Mind+: upload the sample program, enter pose learning on the touchscreen, record different body poses and let the camera assign IDs, then read serial pose data with blocks to trigger games, robots or counters; it’s like turning your camera into a live gesture radar for STEM classrooms and maker spaces.

1.Pose Recognition Blocks

Before You Start:

1.1 Pose Recognition Outputs Data

HUSKYLENS 2 can recognize human bodies within its field of view and print related data through the serial port. The readable data include: the pose ID closest to the center of the HUSKYLENS 2 camera view, the total number of detected bodies, and the ID of the first detected pose.

The sample program is shown below.

Interface Diagram

Click “Upload” in Mind+ and wait for the upload to complete.se the touchscreen to enter the Pose Recognition function of HUSKYLENS 2. Aim the camera at human poses in the image to perform learning. For detailed steps, see Pose Recognition.

Interface Diagram

After the learning process is complete, open the serial port in Mind+ and observe the output results.
Result:The output includes the total number of detected bodies; pose IDs can be output as required. Learned poses are assigned IDs in learning order, while unlearned poses have ID 0.

Interface Diagram

1.2 Obtain Data of Specified Pose

After HUSKYLENS 2 recognizes human poses, it can obtain the data of a specified pose in the image. For example, determine whether a learned pose is present, get the pose name, and obtain the number of identical poses. When multiple identical poses appear, you can specify one pose to retrieve its parameters, including name, X/Y coordinates, width, and height.

The sample program is shown below:

Interface Diagram

Result:As shown in the figure, you can obtain the total number of poses, the count and name of ID1 poses, and the coordinates of the first detected ID1 pose.

Interface Diagram

1.3 Pose Recognition Blocks Description

block description
Used to obtain one set of pose recognition data under the Pose Recognition function of HUSKYLENS 2.
Determines whether human bodies exist in the current frame.
Obtains data for the pose closest to the crosshair, including pose ID, name, center X/Y coordinates, width, and height.
Gets the total number of detected bodies on the screen.
When multiple bodies appear, obtains the data of a specified body.
Determines whether a pose with a specified ID exists in the image. (After HUSKYLENS 2 learns poses, IDs are assigned sequentially.)
Obtains the number of poses with a specified ID in the current frame.
Obtains the data of a pose with a specified ID.
When multiple identical poses appear, obtains the data of one specified pose.

Was this article helpful?

TOP