Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions src/core/algorithm/flat/flat_index_format.h
Original file line number Diff line number Diff line change
Expand Up @@ -89,8 +89,8 @@ struct LinearIntegerQuantizerParams {
/*! Location of Vectors Block in Storage Segment
*/
struct BlockLocation {
uint16_t segment_id{0};
uint16_t block_index{0};
uint32_t segment_id{0};
uint32_t block_index{0};
};

/*! The Header of a Block in Storage Segment
Expand Down Expand Up @@ -153,10 +153,10 @@ struct VectorLocation {
: segment_id(0u), column_major(0u), reserved(0u), offset(0u) {}

//! Constructor
VectorLocation(uint16_t id, bool col, uint32_t off)
VectorLocation(uint32_t id, bool col, uint32_t off)
: segment_id(id), column_major(col), reserved(0u), offset(off) {}

uint16_t segment_id{0};
uint32_t segment_id{0};
uint16_t column_major : 1;
uint16_t reserved : 15;
uint32_t offset{0};
Expand All @@ -168,8 +168,8 @@ struct VectorLocation {
}
};

static_assert(sizeof(VectorLocation) == sizeof(uint64_t),
"VectorLocation must be size of 8 bytes");
// static_assert(sizeof(VectorLocation) == sizeof(uint64_t),
// "VectorLocation must be size of 8 bytes");

struct KeyInfo {
KeyInfo(void) : centroid_idx(0u) {}
Expand Down
4 changes: 2 additions & 2 deletions src/core/algorithm/flat/flat_streamer_entity.h
Original file line number Diff line number Diff line change
Expand Up @@ -380,8 +380,8 @@ class FlatStreamerEntity {

private:
//! Constants
static constexpr size_t kMaxSegmentId = std::numeric_limits<uint16_t>::max();
static constexpr size_t kMaxBlockId = std::numeric_limits<uint16_t>::max();
static constexpr size_t kMaxSegmentId = std::numeric_limits<uint32_t>::max();
static constexpr size_t kMaxBlockId = std::numeric_limits<uint32_t>::max();

//! Members
std::mutex mutex_{};
Expand Down
1 change: 1 addition & 0 deletions src/include/zvec/ailego/utility/string_helper.h
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@

#pragma once

#include <cstdint>
#include <string>
#include <vector>
#include <zvec/ailego/string/string_concat_helper.h>
Expand Down