Illustrated C/C++ source sheets, symbol index, API relationship graph, compiler console and debug trace

LIVE AI / FLEXIBLE SENSING / FLIGHT CONTEXT

Sensoraia API

Live AI and sensing, connected to the flight.
See, listen, inspect and return supported results while airborne.

Loading...
Searching...
No Matches
imx500_tensor.h File Reference

Shared IMX500 tensor-info wire layout and bounded decoding policy. More...

#include <stdint.h>
Include dependency graph for imx500_tensor.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define IMX500_TENSOR_HEADER_BYTES   64U
 Driver metadata header preceding the tensor count; not an RPK feature schema.
#define IMX500_TENSOR_COUNT_OFFSET   IMX500_TENSOR_HEADER_BYTES
 Little-endian 32-bit tensor count starts after the fixed header.
#define IMX500_TENSOR_FIRST_RECORD_OFFSET   (IMX500_TENSOR_COUNT_OFFSET + sizeof(uint32_t))
 First record starts after the count, keeping offset arithmetic in one place.
#define IMX500_TENSOR_RECORD_BYTES   40U
 One record contains length, rank and sixteen 16-bit shape extents.
#define IMX500_TENSOR_LENGTH_OFFSET   0U
 Element count offset within a record, distinct from its byte length.
#define IMX500_TENSOR_RANK_OFFSET   4U
 Shape rank offset within a record.
#define IMX500_TENSOR_DIMENSIONS_OFFSET   8U
 First shape extent follows the two 32-bit fields.
#define IMX500_TENSOR_DIMENSION_BYTES   2U
 Each extent is a little-endian unsigned 16-bit value.
#define IMX500_TENSOR_MAX_RANK   16U
 Fixed shape capacity in the driver ABI; reject greater ranks before indexing.
#define IMX500_TENSOR_MAX_COUNT   16U
 Metadata reserves sixteen records even when a model uses fewer outputs.
#define IMX500_TENSOR_INFO_BYTES    (IMX500_TENSOR_FIRST_RECORD_OFFSET + IMX500_TENSOR_MAX_COUNT * IMX500_TENSOR_RECORD_BYTES)
 Full accessible metadata required before following record offsets.
#define IMX500_TENSOR_ELEMENT_LIMIT   4096U
 Sensoraia's accepted element budget, not a claim about every RPK model.

Detailed Description

Shared IMX500 tensor-info wire layout and bounded decoding policy.

The object detector and LOOM interpret the same driver metadata. Keeping the offsets here prevents their camera ABI definitions drifting apart; model-specific interpretation remains with each consumer.

Definition in file imx500_tensor.h.

Macro Definition Documentation

◆ IMX500_TENSOR_COUNT_OFFSET

#define IMX500_TENSOR_COUNT_OFFSET   IMX500_TENSOR_HEADER_BYTES

Little-endian 32-bit tensor count starts after the fixed header.

Definition at line 31 of file imx500_tensor.h.

◆ IMX500_TENSOR_DIMENSION_BYTES

#define IMX500_TENSOR_DIMENSION_BYTES   2U

Each extent is a little-endian unsigned 16-bit value.

Definition at line 43 of file imx500_tensor.h.

◆ IMX500_TENSOR_DIMENSIONS_OFFSET

#define IMX500_TENSOR_DIMENSIONS_OFFSET   8U

First shape extent follows the two 32-bit fields.

Definition at line 41 of file imx500_tensor.h.

◆ IMX500_TENSOR_ELEMENT_LIMIT

#define IMX500_TENSOR_ELEMENT_LIMIT   4096U

Sensoraia's accepted element budget, not a claim about every RPK model.

Definition at line 52 of file imx500_tensor.h.

◆ IMX500_TENSOR_FIRST_RECORD_OFFSET

#define IMX500_TENSOR_FIRST_RECORD_OFFSET   (IMX500_TENSOR_COUNT_OFFSET + sizeof(uint32_t))

First record starts after the count, keeping offset arithmetic in one place.

Definition at line 33 of file imx500_tensor.h.

◆ IMX500_TENSOR_HEADER_BYTES

#define IMX500_TENSOR_HEADER_BYTES   64U

Driver metadata header preceding the tensor count; not an RPK feature schema.

Definition at line 29 of file imx500_tensor.h.

◆ IMX500_TENSOR_INFO_BYTES

Full accessible metadata required before following record offsets.

Definition at line 49 of file imx500_tensor.h.

◆ IMX500_TENSOR_LENGTH_OFFSET

#define IMX500_TENSOR_LENGTH_OFFSET   0U

Element count offset within a record, distinct from its byte length.

Definition at line 37 of file imx500_tensor.h.

◆ IMX500_TENSOR_MAX_COUNT

#define IMX500_TENSOR_MAX_COUNT   16U

Metadata reserves sixteen records even when a model uses fewer outputs.

Definition at line 47 of file imx500_tensor.h.

◆ IMX500_TENSOR_MAX_RANK

#define IMX500_TENSOR_MAX_RANK   16U

Fixed shape capacity in the driver ABI; reject greater ranks before indexing.

Definition at line 45 of file imx500_tensor.h.

◆ IMX500_TENSOR_RANK_OFFSET

#define IMX500_TENSOR_RANK_OFFSET   4U

Shape rank offset within a record.

Definition at line 39 of file imx500_tensor.h.

◆ IMX500_TENSOR_RECORD_BYTES

#define IMX500_TENSOR_RECORD_BYTES   40U

One record contains length, rank and sixteen 16-bit shape extents.

Definition at line 35 of file imx500_tensor.h.