add

API Definition

void add(Index::idx_t n, const char *x)

Function

Adds new feature vectors to the AscendIndexInt8 base library. When this API is used to add features, the value range of default IDs of the feature vectors to be added is [0, ntotal).

Input

Index::idx_t n: number of feature vectors to be added to the base library.

const char *x: feature vectors to be added to the base library.

Output

N/A

Return Value

N/A

Restrictions

  • The length of the x must be dim x n. Otherwise, an out-of-bounds read/write error may occur, causing program breakdown.
  • The total number of vectors in the base library cannot exceed 1e9.