getBase

API Definition

void getBase(int deviceId, char* xb) const

Function

Obtains the feature vectors managed by AscendIndexFlat in the specific deviceId.

Input

int deviceId: processor name on the NPU.

Output

char* xb: feature vectors of the base library stored in deviceId by AscendIndexFlat.

Return Value

N/A

Restrictions

The deviceId must be a valid processor ID.

The value of xb must be a non-null pointer and the length must be dim x BaseSize x sizeof(float32) bytes. Otherwise, an out-of-bounds read/write error may occur, causing program breakdown. BaseSize is the return value of the getBaseSize function.