Add

API definition

APP_ERROR Add(const std::vector<float>& baseRawData);

Function

Adds new feature vectors to the AscendIndexGreat database.

Input

const std::vector<float>& baseRawData: feature vectors to be added.

Output

N/A

Return value

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

Restrictions

  • The length of the array baseRawData must be dim × nTotal. nTotal indicates the number of vectors to be added, and dim indicates the dimension of each vector.
  • Value range of nTotal: 10000 ≤ nTotal ≤ 1e8.
  • This API can be called only once to add vectors to the database. This API cannot be used together with AddWithIds.