AddFeatures

API definition

APP_ERROR AddFeatures(int n, const float *features);

Function

Adds n feature vectors to the feature database.

Input

int n: number of feature vectors to be inserted.

const float *features: feature vectors to be inserted. The length is n × dim (vector dimension).

Output

N/A

Return value

APP_ERROR: return status. For details, see Return Code Reference.

Restrictions

  • n: The value range is (0, capacity].
  • features must be a non-null pointer and its length must meet the requirements. Otherwise, an out-of-bounds read/write error may occur, causing program breakdown.

API definition

APP_ERROR AddFeatures(int n, const float16_t *features);

Function

Adds n feature vectors to the feature database.

Input

int n: number of feature vectors to be inserted.

const float16_t *features: feature vectors to be inserted. The length is n × dim (vector dimension).

Output

N/A

Return value

APP_ERROR: return status. For details, see Return Code Reference.

Restrictions

  • n: The value range is (0, capacity].
  • features must be a non-null pointer and its length must meet the requirements. Otherwise, an out-of-bounds read/write error may occur, causing program breakdown.