mirror of
https://gitee.com/milvus-io/milvus.git
synced 2024-12-05 21:39:19 +08:00
Merge branch 'upgrade_sptag' into 'branch-0.5.0'
MS-655 update code style See merge request megasearch/milvus!722 Former-commit-id: b11b90a0ab38d991e017a5675f0d8f540ffc189d
This commit is contained in:
commit
2027b76e42
@ -38,23 +38,23 @@ CPUKDTRNG::Serialize() {
|
||||
std::vector<int64_t> index_len;
|
||||
|
||||
// TODO(zirui): dev
|
||||
// index_ptr_->SaveIndexToMemory(index_blobs, index_len);
|
||||
// index_ptr_->SaveIndexToMemory(index_blobs, index_len);
|
||||
BinarySet binary_set;
|
||||
|
||||
//
|
||||
// auto sample = std::make_shared<uint8_t>();
|
||||
// sample.reset(static_cast<uint8_t*>(index_blobs[0]));
|
||||
// auto tree = std::make_shared<uint8_t>();
|
||||
// tree.reset(static_cast<uint8_t*>(index_blobs[1]));
|
||||
// auto graph = std::make_shared<uint8_t>();
|
||||
// graph.reset(static_cast<uint8_t*>(index_blobs[2]));
|
||||
// auto metadata = std::make_shared<uint8_t>();
|
||||
// metadata.reset(static_cast<uint8_t*>(index_blobs[3]));
|
||||
//
|
||||
// binary_set.Append("samples", sample, index_len[0]);
|
||||
// binary_set.Append("tree", tree, index_len[1]);
|
||||
// binary_set.Append("graph", graph, index_len[2]);
|
||||
// binary_set.Append("metadata", metadata, index_len[3]);
|
||||
//
|
||||
// auto sample = std::make_shared<uint8_t>();
|
||||
// sample.reset(static_cast<uint8_t*>(index_blobs[0]));
|
||||
// auto tree = std::make_shared<uint8_t>();
|
||||
// tree.reset(static_cast<uint8_t*>(index_blobs[1]));
|
||||
// auto graph = std::make_shared<uint8_t>();
|
||||
// graph.reset(static_cast<uint8_t*>(index_blobs[2]));
|
||||
// auto metadata = std::make_shared<uint8_t>();
|
||||
// metadata.reset(static_cast<uint8_t*>(index_blobs[3]));
|
||||
//
|
||||
// binary_set.Append("samples", sample, index_len[0]);
|
||||
// binary_set.Append("tree", tree, index_len[1]);
|
||||
// binary_set.Append("graph", graph, index_len[2]);
|
||||
// binary_set.Append("metadata", metadata, index_len[3]);
|
||||
return binary_set;
|
||||
}
|
||||
|
||||
@ -62,21 +62,21 @@ void
|
||||
CPUKDTRNG::Load(const BinarySet& binary_set) {
|
||||
// TODO(zirui): dev
|
||||
|
||||
// std::vector<void*> index_blobs;
|
||||
//
|
||||
// auto samples = binary_set.GetByName("samples");
|
||||
// index_blobs.push_back(samples->data.get());
|
||||
//
|
||||
// auto tree = binary_set.GetByName("tree");
|
||||
// index_blobs.push_back(tree->data.get());
|
||||
//
|
||||
// auto graph = binary_set.GetByName("graph");
|
||||
// index_blobs.push_back(graph->data.get());
|
||||
//
|
||||
// auto metadata = binary_set.GetByName("metadata");
|
||||
// index_blobs.push_back(metadata->data.get());
|
||||
//
|
||||
// index_ptr_->LoadIndexFromMemory(index_blobs);
|
||||
// std::vector<void*> index_blobs;
|
||||
//
|
||||
// auto samples = binary_set.GetByName("samples");
|
||||
// index_blobs.push_back(samples->data.get());
|
||||
//
|
||||
// auto tree = binary_set.GetByName("tree");
|
||||
// index_blobs.push_back(tree->data.get());
|
||||
//
|
||||
// auto graph = binary_set.GetByName("graph");
|
||||
// index_blobs.push_back(graph->data.get());
|
||||
//
|
||||
// auto metadata = binary_set.GetByName("metadata");
|
||||
// index_blobs.push_back(metadata->data.get());
|
||||
//
|
||||
// index_ptr_->LoadIndexFromMemory(index_blobs);
|
||||
}
|
||||
|
||||
// PreprocessorPtr
|
||||
|
@ -112,7 +112,7 @@ TEST_F(KDTTest, kdt_basic) {
|
||||
}
|
||||
|
||||
// TODO(zirui): enable test
|
||||
//TEST_F(KDTTest, kdt_serialize) {
|
||||
// TEST_F(KDTTest, kdt_serialize) {
|
||||
// assert(!xb.empty());
|
||||
//
|
||||
// auto preprocessor = index_->BuildPreprocessor(base_dataset, conf);
|
||||
|
Loading…
Reference in New Issue
Block a user