MCPcopy Create free account
hub / github.com/VectorDB-NTU/RaBitQ-Library / resize

Method resize

include/rabitqlib/utils/buffer.hpp:79–84  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

77 [[nodiscard]] auto has_next() const -> bool { return cur_ < size_; }
78
79 void resize(size_t new_size) {
80 this->capacity_ = new_size;
81 data_ = std::vector<AnnCandidate<T>, memory::AlignedAllocator<AnnCandidate<T>>>(
82 capacity_ + 1
83 );
84 }
85
86 void copy_results(PID* knn) const {
87 for (size_t i = 0; i < size_; ++i) {

Callers 4

SetUpMethod · 0.45
PrepareDataMethod · 0.45
search_new_neighborsMethod · 0.45
search_knnMethod · 0.45

Calls

no outgoing calls

Tested by 2

SetUpMethod · 0.36
PrepareDataMethod · 0.36