STM32N6 NPU Deployment — Politecnico di Milano  1.0
Documentation for Neural Network Deployment on STM32N6 NPU - Politecnico di Milano 2024-2025
display_mpe.c File Reference
#include "display_mpe.h"
#include "app_config.h"
#include "main.h"
#include "display_keypoints_17.h"
#include "utils.h"
#include <assert.h>
#include <stdlib.h>
#include <stdint.h>
Include dependency graph for display_mpe.c:

Go to the source code of this file.

Macros

#define NUMBER_COLORS   10
 

Functions

static void Display_keypoint (mpe_pp_keyPoints_t *key, uint32_t color)
 
static void Display_binding (mpe_pp_keyPoints_t *from, mpe_pp_keyPoints_t *to, uint32_t color)
 
void Display_mpe_InitFunctions (int clamp_point_init(int *x, int *y), void convert_length_init(float32_t wi, float32_t hi, int *wo, int *ho), void convert_point_init(float32_t xi, float32_t yi, int *xo, int *yo), void Display_binding_line_init(int x0, int y0, int x1, int y1, uint32_t color))
 
void Display_mpe_Detection (mpe_pp_outBuffer_t *detect)
 

Variables

const uint32_t colors [NUMBER_COLORS]
 
static int(* clamp_point )(int *x, int *y)
 
static void(* convert_length )(float32_t wi, float32_t hi, int *wo, int *ho)
 
static void(* convert_point )(float32_t xi, float32_t yi, int *xo, int *yo)
 
static void(* Display_binding_line )(int x0, int y0, int x1, int y1, uint32_t color)
 

Detailed Description

Author
GPM Application Team
Attention

Copyright (c) 2024 STMicroelectronics. All rights reserved.

This software is licensed under terms that can be found in the LICENSE file in the root directory of this software component. If no LICENSE file comes with this software, it is provided AS-IS.

Definition in file display_mpe.c.

Macro Definition Documentation

◆ NUMBER_COLORS

#define NUMBER_COLORS   10

Definition at line 28 of file display_mpe.c.

Function Documentation

◆ Display_binding()

static void Display_binding ( mpe_pp_keyPoints_t *  from,
mpe_pp_keyPoints_t *  to,
uint32_t  color 
)
static

Definition at line 70 of file display_mpe.c.

References AI_POSE_PP_CONF_THRESHOLD, BINDING_WIDTH, clamp_point, convert_point, and Display_binding_line.

Referenced by Display_mpe_Detection().

Here is the caller graph for this function:

◆ Display_keypoint()

static void Display_keypoint ( mpe_pp_keyPoints_t *  key,
uint32_t  color 
)
static

Definition at line 47 of file display_mpe.c.

References AI_POSE_PP_CONF_THRESHOLD, CIRCLE_RADIUS, clamp_point, and convert_point.

Referenced by Display_mpe_Detection().

Here is the caller graph for this function:

◆ Display_mpe_Detection()

void Display_mpe_Detection ( mpe_pp_outBuffer_t *  detect)

Definition at line 117 of file display_mpe.c.

References AI_POSE_PP_POSE_KEYPOINTS_NB, ARRAY_NB, bindings, clamp_point, colors, convert_length, convert_point, Display_binding(), Display_keypoint(), kp_color, and NUMBER_COLORS.

Referenced by Display_NetworkOutput().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Display_mpe_InitFunctions()

void Display_mpe_InitFunctions ( int   clamp_point_initint *x, int *y,
void   convert_length_initfloat32_t wi, float32_t hi, int *wo, int *ho,
void   convert_point_initfloat32_t xi, float32_t yi, int *xo, int *yo,
void   Display_binding_line_initint x0, int y0, int x1, int y1, uint32_t color 
)

Definition at line 106 of file display_mpe.c.

References clamp_point, convert_length, convert_point, and Display_binding_line.

Referenced by LCD_init().

Here is the caller graph for this function:

Variable Documentation

◆ clamp_point

int(* clamp_point) (int *x, int *y) ( int *  x,
int *  y 
)
static

◆ colors

const uint32_t colors[NUMBER_COLORS]
Initial value:
= {
UTIL_LCD_COLOR_GREEN,
UTIL_LCD_COLOR_RED,
UTIL_LCD_COLOR_CYAN,
UTIL_LCD_COLOR_MAGENTA,
UTIL_LCD_COLOR_YELLOW,
UTIL_LCD_COLOR_GRAY,
UTIL_LCD_COLOR_BLACK,
UTIL_LCD_COLOR_BROWN,
UTIL_LCD_COLOR_BLUE,
UTIL_LCD_COLOR_ORANGE
}

Definition at line 29 of file display_mpe.c.

Referenced by Display_mpe_Detection().

◆ convert_length

void(* convert_length) (float32_t wi, float32_t hi, int *wo, int *ho) ( float32_t  wi,
float32_t  hi,
int *  wo,
int *  ho 
)
static

Definition at line 43 of file display_mpe.c.

Referenced by Display_mpe_Detection(), and Display_mpe_InitFunctions().

◆ convert_point

void(* convert_point) (float32_t xi, float32_t yi, int *xo, int *yo) ( float32_t  xi,
float32_t  yi,
int *  xo,
int *  yo 
)
static

◆ Display_binding_line

void(* Display_binding_line) (int x0, int y0, int x1, int y1, uint32_t color) ( int  x0,
int  y0,
int  x1,
int  y1,
uint32_t  color 
)
static

Definition at line 45 of file display_mpe.c.

Referenced by Display_binding(), and Display_mpe_InitFunctions().