You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
hgraph index When the query result is 0, a bad_alloc error is reported
Since the query result data is 0, the result memory of size 0 is applied, resulting in the application failure and error bad_alloc
To Reproduce
Codes to reproduce the behavior:
nlohmann::json hnswsq_parameters{{"base_quantization_type", "sq8"},
{"max_degree", max_degree},
{"ef_construction", ef_construction},
{"build_thread_count", 1}};
nlohmann::json index_parameters{{"dtype", dtype}, {"metric_type", metric}, {"dim", dim}, {"index_param", hnswsq_parameters}};
auto index = vsag::Factory::CreateIndex("hgraph", index_parameters.dump(), vsag_allocator);
HnswIndexHandler* hnsw = static_cast<HnswIndexHandler*>(index_handler);
auto dataset = vsag::Dataset::Make();
dataset->Dim(dim)
->NumElements(11000)
->Ids(ids)
->Float32Vectors(vector_list)
->Owner(false);
ret = hnsw->build_index(dataset);
query->NumElements(1)->Dim(dim)->Float32Vectors(query_vector)->Owner(false);
// The data filtered by the filter is 100%
ret = hnsw->knn_search(query, topk, search_parameters.dump(), dist, ids, result_size, filter);
Environment
Please run bash scripts/check_environment.sh and paste the output here:
OS: e.g. Ubuntu 22.04
vsag version: e.g. v0.11.0 or 7f94a27
compiler version: e.g. GCC 11.4.0
interface: cpp or python
Expected behavior
Verify the returned result like hnsw
The text was updated successfully, but these errors were encountered:
Describe the bug
hgraph index When the query result is 0, a bad_alloc error is reported
Since the query result data is 0, the result memory of size 0 is applied, resulting in the application failure and error bad_alloc
To Reproduce
Codes to reproduce the behavior:
Environment
Please run
bash scripts/check_environment.sh
and paste the output here:Ubuntu 22.04
v0.11.0
or7f94a27
GCC 11.4.0
cpp
orpython
Expected behavior
Verify the returned result like hnsw
The text was updated successfully, but these errors were encountered: