diff --git a/cpp/CHANGELOG.md b/cpp/CHANGELOG.md index a41bc23484a5c290302d8fe06472dff625b1326f..68cd3568b838052c1b827fc368d5c4eac7dea986 100644 --- a/cpp/CHANGELOG.md +++ b/cpp/CHANGELOG.md @@ -34,6 +34,7 @@ Please mark all change in change log and use the ticket from JIRA. - MS-586 - Remove BUILD_FAISS_WITH_MKL option - MS-590 - Refine cmake code to support cpplint - MS-600 - Reconstruct unittest code +- MS-602 - Remove zilliz namespace # Milvus 0.4.0 (2019-09-12) diff --git a/cpp/src/cache/Cache.h b/cpp/src/cache/Cache.h index 7818a2e6b78b8db3f2da2756ed3f08fd588d2251..62a7f13ca854f8b55664a1b72079d3aea5f057b9 100644 --- a/cpp/src/cache/Cache.h +++ b/cpp/src/cache/Cache.h @@ -25,7 +25,6 @@ #include #include -namespace zilliz { namespace milvus { namespace cache { @@ -88,6 +87,5 @@ class Cache { } // namespace cache } // namespace milvus -} // namespace zilliz #include "cache/Cache.inl" diff --git a/cpp/src/cache/Cache.inl b/cpp/src/cache/Cache.inl index ebd8f3c25d2b23fd5adce6e3d50e36efb26a7e0e..2ab6b3ffa66480612e92056d62eefbe03eb809c7 100644 --- a/cpp/src/cache/Cache.inl +++ b/cpp/src/cache/Cache.inl @@ -17,7 +17,7 @@ -namespace zilliz { + namespace milvus { namespace cache { @@ -190,5 +190,5 @@ Cache::print() { } // namespace cache } // namespace milvus -} // namespace zilliz + diff --git a/cpp/src/cache/CacheMgr.h b/cpp/src/cache/CacheMgr.h index 11cd742a6aa7052a67e80c64a9f37d37e886f78e..f5e04f650968552c01664139b8442b56fddf3868 100644 --- a/cpp/src/cache/CacheMgr.h +++ b/cpp/src/cache/CacheMgr.h @@ -24,7 +24,6 @@ #include #include -namespace zilliz { namespace milvus { namespace cache { @@ -70,6 +69,5 @@ class CacheMgr { } // namespace cache } // namespace milvus -} // namespace zilliz #include "cache/CacheMgr.inl" diff --git a/cpp/src/cache/CacheMgr.inl b/cpp/src/cache/CacheMgr.inl index b0c47b3dc37f54b6b336fe26f3b292d45ba5697f..23b2f0df743b7b237887fec8d322b413fd34f34f 100644 --- a/cpp/src/cache/CacheMgr.inl +++ b/cpp/src/cache/CacheMgr.inl @@ -16,7 +16,7 @@ // under the License. -namespace zilliz { + namespace milvus { namespace cache { @@ -142,4 +142,4 @@ CacheMgr::SetCapacity(int64_t capacity) { } // namespace cache } // namespace milvus -} // namespace zilliz + diff --git a/cpp/src/cache/CpuCacheMgr.cpp b/cpp/src/cache/CpuCacheMgr.cpp index 99a284f0742ad7071e72275c7a62bfec0aae5cfe..7cfe59e72e58b3bcd91b75a00df87e8f4e030878 100644 --- a/cpp/src/cache/CpuCacheMgr.cpp +++ b/cpp/src/cache/CpuCacheMgr.cpp @@ -21,7 +21,6 @@ #include -namespace zilliz { namespace milvus { namespace cache { @@ -72,4 +71,3 @@ CpuCacheMgr::GetIndex(const std::string& key) { } // namespace cache } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/cache/CpuCacheMgr.h b/cpp/src/cache/CpuCacheMgr.h index ad6087de7c42104f36d233d107d5691b603bd630..2f8c50991a9e50eadf60935bbcc40d3d78de3d4d 100644 --- a/cpp/src/cache/CpuCacheMgr.h +++ b/cpp/src/cache/CpuCacheMgr.h @@ -23,7 +23,6 @@ #include #include -namespace zilliz { namespace milvus { namespace cache { @@ -42,4 +41,3 @@ class CpuCacheMgr : public CacheMgr { } // namespace cache } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/cache/DataObj.h b/cpp/src/cache/DataObj.h index 80cc560e7c5099101ec5c11724e87f51f78cc11e..eb58b708250cbc221361f2b782ac8042a9a8d8a4 100644 --- a/cpp/src/cache/DataObj.h +++ b/cpp/src/cache/DataObj.h @@ -21,7 +21,6 @@ #include -namespace zilliz { namespace milvus { namespace cache { @@ -65,4 +64,3 @@ using DataObjPtr = std::shared_ptr; } // namespace cache } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/cache/GpuCacheMgr.cpp b/cpp/src/cache/GpuCacheMgr.cpp index 9c9e94eda9d31bf891239dd946dc1baca47581f9..a9eff6d3c3ceb295675ff3ce35d6be000dceb308 100644 --- a/cpp/src/cache/GpuCacheMgr.cpp +++ b/cpp/src/cache/GpuCacheMgr.cpp @@ -22,7 +22,6 @@ #include #include -namespace zilliz { namespace milvus { namespace cache { @@ -84,4 +83,3 @@ GpuCacheMgr::GetIndex(const std::string& key) { } // namespace cache } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/cache/GpuCacheMgr.h b/cpp/src/cache/GpuCacheMgr.h index 15cdcae28fb7691b01eee6466e0fc5e3a0325516..8c0d4b95026ab4aea4684b55d593b2d8b3c20b4c 100644 --- a/cpp/src/cache/GpuCacheMgr.h +++ b/cpp/src/cache/GpuCacheMgr.h @@ -22,7 +22,6 @@ #include #include -namespace zilliz { namespace milvus { namespace cache { @@ -46,4 +45,3 @@ class GpuCacheMgr : public CacheMgr { } // namespace cache } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/cache/LRU.h b/cpp/src/cache/LRU.h index d6a5b9ace7079030c8e449fd6c18e33e57cc0a2d..9b0eac060854e5d24871c8217308224b71b39b72 100644 --- a/cpp/src/cache/LRU.h +++ b/cpp/src/cache/LRU.h @@ -23,7 +23,6 @@ #include #include -namespace zilliz { namespace milvus { namespace cache { @@ -121,4 +120,3 @@ class LRU { } // namespace cache } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/config/ConfigMgr.cpp b/cpp/src/config/ConfigMgr.cpp index e006217fd2023dd958abae327b2e2dab1d52409a..5889f52fac2987ab7a8c7830c176acdf2d0417c6 100644 --- a/cpp/src/config/ConfigMgr.cpp +++ b/cpp/src/config/ConfigMgr.cpp @@ -18,7 +18,6 @@ #include "config/ConfigMgr.h" #include "YamlConfigMgr.h" -namespace zilliz { namespace milvus { namespace server { @@ -30,4 +29,3 @@ ConfigMgr::GetInstance() { } // namespace server } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/config/ConfigMgr.h b/cpp/src/config/ConfigMgr.h index e5336ee34df858f2810958660f32256224b238c8..40753beaa9766e536fb2c34cecfd7166022add49 100644 --- a/cpp/src/config/ConfigMgr.h +++ b/cpp/src/config/ConfigMgr.h @@ -22,7 +22,6 @@ #include -namespace zilliz { namespace milvus { namespace server { @@ -60,4 +59,3 @@ class ConfigMgr { } // namespace server } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/config/ConfigNode.cpp b/cpp/src/config/ConfigNode.cpp index ff27a0af751623a4879b7e1de72c129e702a5952..cf148e4d29e57341276d1e1a95df99f320046995 100644 --- a/cpp/src/config/ConfigNode.cpp +++ b/cpp/src/config/ConfigNode.cpp @@ -23,7 +23,6 @@ #include #include -namespace zilliz { namespace milvus { namespace server { @@ -234,4 +233,3 @@ ConfigNode::DumpString(const std::string& prefix) const { } // namespace server } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/config/ConfigNode.h b/cpp/src/config/ConfigNode.h index 937066dbf534a6533ed8d280462c01eb2de01c5f..b7bf2c3af14607246e8ffab10afd47ca2ba32c4a 100644 --- a/cpp/src/config/ConfigNode.h +++ b/cpp/src/config/ConfigNode.h @@ -21,7 +21,6 @@ #include #include -namespace zilliz { namespace milvus { namespace server { @@ -94,4 +93,3 @@ class ConfigNode { } // namespace server } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/config/YamlConfigMgr.cpp b/cpp/src/config/YamlConfigMgr.cpp index 02653d6fad2a2f56cd6b523cc44796e4cd255616..71535495442851e1e3ce276cb916428064fb8458 100644 --- a/cpp/src/config/YamlConfigMgr.cpp +++ b/cpp/src/config/YamlConfigMgr.cpp @@ -20,7 +20,6 @@ #include -namespace zilliz { namespace milvus { namespace server { @@ -116,4 +115,3 @@ YamlConfigMgr::LoadConfigNode(const YAML::Node& node, ConfigNode& config) { } // namespace server } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/config/YamlConfigMgr.h b/cpp/src/config/YamlConfigMgr.h index 743276b504ef97264736cc1a4c0cf908cba59abc..1c68bc883fd814ccd491ee3b3ed0f89654c1185f 100644 --- a/cpp/src/config/YamlConfigMgr.h +++ b/cpp/src/config/YamlConfigMgr.h @@ -24,7 +24,6 @@ #include #include -namespace zilliz { namespace milvus { namespace server { @@ -62,4 +61,3 @@ class YamlConfigMgr : public ConfigMgr { } // namespace server } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/core/build.sh b/cpp/src/core/build.sh old mode 100755 new mode 100644 diff --git a/cpp/src/core/knowhere/knowhere/adapter/ArrowAdapter.cpp b/cpp/src/core/knowhere/knowhere/adapter/ArrowAdapter.cpp index bc1dfbf13d81929a0f4ecb3fb40144b0a1923fb4..38227f43ab858ed652ab2b377102121304fdfc0e 100644 --- a/cpp/src/core/knowhere/knowhere/adapter/ArrowAdapter.cpp +++ b/cpp/src/core/knowhere/knowhere/adapter/ArrowAdapter.cpp @@ -17,7 +17,6 @@ #include "knowhere/adapter/ArrowAdapter.h" -namespace zilliz { namespace knowhere { ArrayPtr @@ -52,4 +51,3 @@ CopySchema(const SchemaPtr& origin) { } } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/adapter/ArrowAdapter.h b/cpp/src/core/knowhere/knowhere/adapter/ArrowAdapter.h index f4d0b348cf62ee101d2981757af1df4ff7429bf7..75580cd16354dde245749180548d6acdb6451479 100644 --- a/cpp/src/core/knowhere/knowhere/adapter/ArrowAdapter.h +++ b/cpp/src/core/knowhere/knowhere/adapter/ArrowAdapter.h @@ -23,7 +23,6 @@ #include "knowhere/common/Array.h" -namespace zilliz { namespace knowhere { ArrayPtr @@ -33,4 +32,3 @@ SchemaPtr CopySchema(const SchemaPtr& origin); } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/adapter/SptagAdapter.cpp b/cpp/src/core/knowhere/knowhere/adapter/SptagAdapter.cpp index 8a0ad69591515702477d46e69aea9e0afb2f1e08..f4b1a7953fa89fbe274af2df9a046b9702fb8918 100644 --- a/cpp/src/core/knowhere/knowhere/adapter/SptagAdapter.cpp +++ b/cpp/src/core/knowhere/knowhere/adapter/SptagAdapter.cpp @@ -19,7 +19,6 @@ #include "knowhere/adapter/Structure.h" #include "knowhere/index/vector_index/helpers/Definitions.h" -namespace zilliz { namespace knowhere { std::shared_ptr @@ -121,4 +120,3 @@ ConvertToDataset(std::vector query_results) { } } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/adapter/SptagAdapter.h b/cpp/src/core/knowhere/knowhere/adapter/SptagAdapter.h index 0889657cf9480d824e77d92747f06eef9bb5fcd4..9f924975623f8c775ad7e54f71ad2c3d18b2d082 100644 --- a/cpp/src/core/knowhere/knowhere/adapter/SptagAdapter.h +++ b/cpp/src/core/knowhere/knowhere/adapter/SptagAdapter.h @@ -23,7 +23,6 @@ #include "knowhere/common/Dataset.h" -namespace zilliz { namespace knowhere { std::shared_ptr @@ -39,4 +38,3 @@ DatasetPtr ConvertToDataset(std::vector query_results); } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/adapter/Structure.cpp b/cpp/src/core/knowhere/knowhere/adapter/Structure.cpp index 2cd69f3d105d66dc678b46b4fa1d6e91233969a4..44b068c7929461a4da2399a813392e8b9d00a57c 100644 --- a/cpp/src/core/knowhere/knowhere/adapter/Structure.cpp +++ b/cpp/src/core/knowhere/knowhere/adapter/Structure.cpp @@ -20,7 +20,6 @@ #include #include -namespace zilliz { namespace knowhere { ArrayPtr @@ -86,4 +85,3 @@ ConstructFloatField(const std::string& name) { } } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/adapter/Structure.h b/cpp/src/core/knowhere/knowhere/adapter/Structure.h index 526dc91b734240cacf071b62eef55a9131eb82f5..6bde9ddfe6fcb675bbf447224d17f21965001a81 100644 --- a/cpp/src/core/knowhere/knowhere/adapter/Structure.h +++ b/cpp/src/core/knowhere/knowhere/adapter/Structure.h @@ -23,7 +23,6 @@ #include "knowhere/common/Dataset.h" -namespace zilliz { namespace knowhere { extern ArrayPtr @@ -51,4 +50,3 @@ extern FieldPtr ConstructFloatField(const std::string& name); } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/adapter/VectorAdapter.h b/cpp/src/core/knowhere/knowhere/adapter/VectorAdapter.h index ae4ef998cd852a4b78ed1329c925d7fdcca0e43d..2b16227bb302781ef420a9174a9c746e8d5e1684 100644 --- a/cpp/src/core/knowhere/knowhere/adapter/VectorAdapter.h +++ b/cpp/src/core/knowhere/knowhere/adapter/VectorAdapter.h @@ -17,7 +17,6 @@ #pragma once -namespace zilliz { namespace knowhere { #define GETTENSOR(dataset) \ @@ -27,4 +26,3 @@ namespace knowhere { auto rows = tensor->shape()[0]; } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/common/Array.h b/cpp/src/core/knowhere/knowhere/common/Array.h index 89bbf6ccd714e8f0f8fc507fb130718df956bf12..71ad78b79beaff1808bac55194cbc6a23378a4b8 100644 --- a/cpp/src/core/knowhere/knowhere/common/Array.h +++ b/cpp/src/core/knowhere/knowhere/common/Array.h @@ -22,7 +22,6 @@ #include "Schema.h" -namespace zilliz { namespace knowhere { using ArrayData = arrow::ArrayData; @@ -49,4 +48,3 @@ using Decimal128Array = arrow::Decimal128Array; using Decimal128ArrayPtr = std::shared_ptr; } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/common/BinarySet.h b/cpp/src/core/knowhere/knowhere/common/BinarySet.h index 6d8580e071943cfc3e649a86800f864de2e66071..6e6d53000e4a96ee326d0aa720c7d7232ca126d6 100644 --- a/cpp/src/core/knowhere/knowhere/common/BinarySet.h +++ b/cpp/src/core/knowhere/knowhere/common/BinarySet.h @@ -25,7 +25,6 @@ #include "Id.h" -namespace zilliz { namespace knowhere { struct Binary { @@ -74,4 +73,3 @@ class BinarySet { }; } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/common/Buffer.h b/cpp/src/core/knowhere/knowhere/common/Buffer.h index 42af87a09bf284fa15e6726565b6f2c938cef220..d95da186028f0f30799d8fa112391294c382d566 100644 --- a/cpp/src/core/knowhere/knowhere/common/Buffer.h +++ b/cpp/src/core/knowhere/knowhere/common/Buffer.h @@ -21,7 +21,6 @@ #include -namespace zilliz { namespace knowhere { using Buffer = arrow::Buffer; @@ -60,4 +59,3 @@ MakeMutableBuffer(uint8_t* data, const int64_t size) { } } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/common/Config.h b/cpp/src/core/knowhere/knowhere/common/Config.h index afb621d5e15ba5c9f359c4bcfb02d14f9c46c7d4..6191ecb771f61168dca171982fc76f908a54def5 100644 --- a/cpp/src/core/knowhere/knowhere/common/Config.h +++ b/cpp/src/core/knowhere/knowhere/common/Config.h @@ -19,7 +19,6 @@ #include -namespace zilliz { namespace knowhere { enum class METRICTYPE { @@ -55,4 +54,3 @@ struct Cfg { using Config = std::shared_ptr; } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/common/Dataset.h b/cpp/src/core/knowhere/knowhere/common/Dataset.h index 4a4f4bdd80f3a14465598f53b1bb777afdc1c617..1331239dd6bd7b0856a0846a0d74b3b7baf20c90 100644 --- a/cpp/src/core/knowhere/knowhere/common/Dataset.h +++ b/cpp/src/core/knowhere/knowhere/common/Dataset.h @@ -28,7 +28,6 @@ #include "Tensor.h" #include "knowhere/adapter/ArrowAdapter.h" -namespace zilliz { namespace knowhere { class Dataset; @@ -148,4 +147,3 @@ class Dataset { using DatasetPtr = std::shared_ptr; } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/common/Exception.cpp b/cpp/src/core/knowhere/knowhere/common/Exception.cpp index 75d9ce39bbcf7eee31cf98bbb18501e6b9bc0881..4fef9529ac90c3733b1f903c5ec68266a846cdf1 100644 --- a/cpp/src/core/knowhere/knowhere/common/Exception.cpp +++ b/cpp/src/core/knowhere/knowhere/common/Exception.cpp @@ -20,7 +20,6 @@ #include "Log.h" #include "knowhere/common/Exception.h" -namespace zilliz { namespace knowhere { KnowhereException::KnowhereException(const std::string& msg) : msg(msg) { @@ -48,4 +47,3 @@ KnowhereException::what() const noexcept { } } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/common/Exception.h b/cpp/src/core/knowhere/knowhere/common/Exception.h index ec89c4d61631e604d3f729901743830bd3d527fc..9ffc7838cfdf3d7de794ac9b91ad2a8c88af2b4a 100644 --- a/cpp/src/core/knowhere/knowhere/common/Exception.h +++ b/cpp/src/core/knowhere/knowhere/common/Exception.h @@ -20,7 +20,6 @@ #include #include -namespace zilliz { namespace knowhere { class KnowhereException : public std::exception { @@ -52,4 +51,3 @@ class KnowhereException : public std::exception { } while (false) } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/common/Id.h b/cpp/src/core/knowhere/knowhere/common/Id.h index 968607587430d2b1de87d48a42f4ca56712dec6b..1c8216168452faecfe1eb9038e63eb3d9eb14f4c 100644 --- a/cpp/src/core/knowhere/knowhere/common/Id.h +++ b/cpp/src/core/knowhere/knowhere/common/Id.h @@ -17,13 +17,9 @@ #pragma once -//#include "zcommon/id/id.h" -// using ID = zilliz::common::ID; - #include #include -namespace zilliz { namespace knowhere { class ID { @@ -58,4 +54,3 @@ class ID { }; } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/common/Log.h b/cpp/src/core/knowhere/knowhere/common/Log.h index 1ca78b155aae5c9ed6a8cc15105f97eab9a80f81..222d03d73e65ce2d30c0a2589c223b4d998bd269 100644 --- a/cpp/src/core/knowhere/knowhere/common/Log.h +++ b/cpp/src/core/knowhere/knowhere/common/Log.h @@ -19,7 +19,6 @@ #include "utils/easylogging++.h" -namespace zilliz { namespace knowhere { #define KNOWHERE_DOMAIN_NAME "[KNOWHERE] " @@ -33,4 +32,3 @@ namespace knowhere { #define KNOWHERE_LOG_FATAL LOG(FATAL) << KNOWHERE_DOMAIN_NAME } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/common/Schema.h b/cpp/src/core/knowhere/knowhere/common/Schema.h index 6dc4784e53d4172bc39191d6ce869b9d64f8fce7..c90bac757223d7646dd60b5b7a894e852ca136ab 100644 --- a/cpp/src/core/knowhere/knowhere/common/Schema.h +++ b/cpp/src/core/knowhere/knowhere/common/Schema.h @@ -21,7 +21,6 @@ #include -namespace zilliz { namespace knowhere { using DataType = arrow::DataType; @@ -32,4 +31,3 @@ using SchemaPtr = std::shared_ptr; using SchemaConstPtr = std::shared_ptr; } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/common/Tensor.h b/cpp/src/core/knowhere/knowhere/common/Tensor.h index cd23933e962bb60457da3402ac7403d2cbb7986c..ff957319e56ac605129d4b1077c4f25c9f1f5722 100644 --- a/cpp/src/core/knowhere/knowhere/common/Tensor.h +++ b/cpp/src/core/knowhere/knowhere/common/Tensor.h @@ -21,11 +21,9 @@ #include -namespace zilliz { namespace knowhere { using Tensor = arrow::Tensor; using TensorPtr = std::shared_ptr; } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/common/Timer.cpp b/cpp/src/core/knowhere/knowhere/common/Timer.cpp index f4db63203c25551e1a6d052cfe6fb6e9b5cab1d0..fefe1e1705bb32a7b739af87ad3e1e5360ebdf31 100644 --- a/cpp/src/core/knowhere/knowhere/common/Timer.cpp +++ b/cpp/src/core/knowhere/knowhere/common/Timer.cpp @@ -19,7 +19,6 @@ #include "knowhere/common/Timer.h" -namespace zilliz { namespace knowhere { TimeRecorder::TimeRecorder(const std::string& header, int64_t log_level) : header_(header), log_level_(log_level) { @@ -99,4 +98,3 @@ TimeRecorder::ElapseFromBegin(const std::string& msg) { } } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/common/Timer.h b/cpp/src/core/knowhere/knowhere/common/Timer.h index b1557e4c2079113359afdd6cd7f4638d2c7e9eca..7e01e88aa9a9c9f640979afc0ec994350b3d96de 100644 --- a/cpp/src/core/knowhere/knowhere/common/Timer.h +++ b/cpp/src/core/knowhere/knowhere/common/Timer.h @@ -20,7 +20,6 @@ #include #include -namespace zilliz { namespace knowhere { class TimeRecorder { @@ -52,4 +51,3 @@ class TimeRecorder { }; } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/Index.h b/cpp/src/core/knowhere/knowhere/index/Index.h index 613a8d049a7a4c4fc863fa351782a05c7f36384a..ffa685689b12c65e45cb3a8fc9b5506392164172 100644 --- a/cpp/src/core/knowhere/knowhere/index/Index.h +++ b/cpp/src/core/knowhere/knowhere/index/Index.h @@ -25,7 +25,6 @@ #include "knowhere/common/Dataset.h" #include "knowhere/index/preprocessor/Preprocessor.h" -namespace zilliz { namespace knowhere { class Index { @@ -66,4 +65,3 @@ class Index { using IndexPtr = std::shared_ptr; } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/IndexModel.h b/cpp/src/core/knowhere/knowhere/index/IndexModel.h index 64acc5ad224e38824640143bd63f9e5c28fe8b88..1229e21f2cb48f6e2b17d51dc62ecdc6a4bb693d 100644 --- a/cpp/src/core/knowhere/knowhere/index/IndexModel.h +++ b/cpp/src/core/knowhere/knowhere/index/IndexModel.h @@ -20,7 +20,6 @@ #include #include "knowhere/common/BinarySet.h" -namespace zilliz { namespace knowhere { class IndexModel { @@ -35,4 +34,3 @@ class IndexModel { using IndexModelPtr = std::shared_ptr; } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/IndexType.h b/cpp/src/core/knowhere/knowhere/index/IndexType.h index 64a21887908cc573a1e92904772b40d0df141c5a..e39b57bf44732c6b6b33bfb89399503177b75c01 100644 --- a/cpp/src/core/knowhere/knowhere/index/IndexType.h +++ b/cpp/src/core/knowhere/knowhere/index/IndexType.h @@ -17,7 +17,6 @@ #pragma once -namespace zilliz { namespace knowhere { enum class IndexType { @@ -28,4 +27,3 @@ enum class IndexType { }; } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/preprocessor/Normalize.cpp b/cpp/src/core/knowhere/knowhere/index/preprocessor/Normalize.cpp index 2a31a22f164023a7eca853f894f7d2c5e19455c9..f21c787abe0ed7dad881460623fc4b6d9d975513 100644 --- a/cpp/src/core/knowhere/knowhere/index/preprocessor/Normalize.cpp +++ b/cpp/src/core/knowhere/knowhere/index/preprocessor/Normalize.cpp @@ -20,7 +20,7 @@ #include "knowhere/index/preprocessor/Normalize.h" // // -// namespace zilliz { +// // namespace knowhere { // // DatasetPtr @@ -54,4 +54,4 @@ //} // //} // namespace knowhere -//} // namespace zilliz +// diff --git a/cpp/src/core/knowhere/knowhere/index/preprocessor/Normalize.h b/cpp/src/core/knowhere/knowhere/index/preprocessor/Normalize.h index 9e918d56b82355850205c7f9256abe587a95be1a..572c447b2794bd447a4edf7ea42f16ebc5344ad8 100644 --- a/cpp/src/core/knowhere/knowhere/index/preprocessor/Normalize.h +++ b/cpp/src/core/knowhere/knowhere/index/preprocessor/Normalize.h @@ -21,7 +21,7 @@ //#include "preprocessor.h" // // -// namespace zilliz { +// // namespace knowhere { // // class NormalizePreprocessor : public Preprocessor { @@ -40,4 +40,4 @@ // // //} // namespace knowhere -//} // namespace zilliz +// diff --git a/cpp/src/core/knowhere/knowhere/index/preprocessor/Preprocessor.h b/cpp/src/core/knowhere/knowhere/index/preprocessor/Preprocessor.h index c04dbdf3dc8747c6a55636904e4789ef3824c397..d1cb1817d6e102759bfc8e2be5083417f63c12e6 100644 --- a/cpp/src/core/knowhere/knowhere/index/preprocessor/Preprocessor.h +++ b/cpp/src/core/knowhere/knowhere/index/preprocessor/Preprocessor.h @@ -21,7 +21,6 @@ #include "knowhere/common/Dataset.h" -namespace zilliz { namespace knowhere { class Preprocessor { @@ -33,4 +32,3 @@ class Preprocessor { using PreprocessorPtr = std::shared_ptr; } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/vector_index/FaissBaseIndex.cpp b/cpp/src/core/knowhere/knowhere/index/vector_index/FaissBaseIndex.cpp index 5e90da9d562929873df237e40537437d2db7e0f1..4fc9a82009be6007b883868723c4854c7a770683 100644 --- a/cpp/src/core/knowhere/knowhere/index/vector_index/FaissBaseIndex.cpp +++ b/cpp/src/core/knowhere/knowhere/index/vector_index/FaissBaseIndex.cpp @@ -23,7 +23,6 @@ #include "knowhere/index/vector_index/FaissBaseIndex.h" #include "knowhere/index/vector_index/helpers/FaissIO.h" -namespace zilliz { namespace knowhere { FaissBaseIndex::FaissBaseIndex(std::shared_ptr index) : index_(std::move(index)) { @@ -79,4 +78,3 @@ FaissBaseIndex::SealImpl() { } } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/vector_index/FaissBaseIndex.h b/cpp/src/core/knowhere/knowhere/index/vector_index/FaissBaseIndex.h index bac4a2bf29bad372bbec9d91e6ae78534d55f937..f3fceebb88e9858e666ead347e263de0fb124e9a 100644 --- a/cpp/src/core/knowhere/knowhere/index/vector_index/FaissBaseIndex.h +++ b/cpp/src/core/knowhere/knowhere/index/vector_index/FaissBaseIndex.h @@ -23,7 +23,6 @@ #include "knowhere/common/BinarySet.h" -namespace zilliz { namespace knowhere { class FaissBaseIndex { @@ -44,4 +43,3 @@ class FaissBaseIndex { }; } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/vector_index/IndexGPUIVF.cpp b/cpp/src/core/knowhere/knowhere/index/vector_index/IndexGPUIVF.cpp index 332d31bce089cea4aaaff25173799aec8627f84d..dc886b7383eded1067d258fdefd48f1c4c93dcc7 100644 --- a/cpp/src/core/knowhere/knowhere/index/vector_index/IndexGPUIVF.cpp +++ b/cpp/src/core/knowhere/knowhere/index/vector_index/IndexGPUIVF.cpp @@ -29,7 +29,6 @@ #include "knowhere/index/vector_index/helpers/Cloner.h" #include "knowhere/index/vector_index/helpers/FaissIO.h" -namespace zilliz { namespace knowhere { IndexModelPtr @@ -171,7 +170,7 @@ GPUIVF::CopyGpuToCpu(const Config& config) { VectorIndexPtr GPUIVF::Clone() { auto cpu_idx = CopyGpuToCpu(Config()); - return ::zilliz::knowhere::cloner::CopyCpuToGpu(cpu_idx, gpu_id_, Config()); + return knowhere::cloner::CopyCpuToGpu(cpu_idx, gpu_id_, Config()); } VectorIndexPtr @@ -201,4 +200,3 @@ GPUIndex::GetGpuDevice() { } } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/vector_index/IndexGPUIVF.h b/cpp/src/core/knowhere/knowhere/index/vector_index/IndexGPUIVF.h index 347e255b872b783974bd763a3212d7e5915d73f2..8edd0fe30e6971fbb4d33e3fb0c7276488cca3f7 100644 --- a/cpp/src/core/knowhere/knowhere/index/vector_index/IndexGPUIVF.h +++ b/cpp/src/core/knowhere/knowhere/index/vector_index/IndexGPUIVF.h @@ -23,7 +23,6 @@ #include "IndexIVF.h" #include "knowhere/index/vector_index/helpers/FaissGpuResourceMgr.h" -namespace zilliz { namespace knowhere { class GPUIndex { @@ -95,4 +94,3 @@ class GPUIVF : public IVF, public GPUIndex { }; } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/vector_index/IndexGPUIVFPQ.cpp b/cpp/src/core/knowhere/knowhere/index/vector_index/IndexGPUIVFPQ.cpp index 7aa8f7db2a19015ee5a7812525b3066cdfd63723..077f0817dab6016c94bd32eba32e9c2f7ab46a66 100644 --- a/cpp/src/core/knowhere/knowhere/index/vector_index/IndexGPUIVFPQ.cpp +++ b/cpp/src/core/knowhere/knowhere/index/vector_index/IndexGPUIVFPQ.cpp @@ -24,7 +24,6 @@ #include "knowhere/common/Exception.h" #include "knowhere/index/vector_index/IndexGPUIVFPQ.h" -namespace zilliz { namespace knowhere { IndexModelPtr @@ -68,4 +67,3 @@ GPUIVFPQ::CopyGpuToCpu(const Config& config) { } } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/vector_index/IndexGPUIVFPQ.h b/cpp/src/core/knowhere/knowhere/index/vector_index/IndexGPUIVFPQ.h index 6d298e77e61cde0b976694485ec10fbf3a4bda14..13ea1075ca5740bc6094d0ec2e59bcdd501f3d91 100644 --- a/cpp/src/core/knowhere/knowhere/index/vector_index/IndexGPUIVFPQ.h +++ b/cpp/src/core/knowhere/knowhere/index/vector_index/IndexGPUIVFPQ.h @@ -21,7 +21,6 @@ #include "IndexGPUIVF.h" -namespace zilliz { namespace knowhere { class GPUIVFPQ : public GPUIVF { @@ -43,4 +42,3 @@ class GPUIVFPQ : public GPUIVF { }; } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/vector_index/IndexGPUIVFSQ.cpp b/cpp/src/core/knowhere/knowhere/index/vector_index/IndexGPUIVFSQ.cpp index bf2aa224746ff1cbca494fd7f21431285c2c290c..1b4f4e9edba8edf4e2c19b5c48ea1bebed3cf432 100644 --- a/cpp/src/core/knowhere/knowhere/index/vector_index/IndexGPUIVFSQ.cpp +++ b/cpp/src/core/knowhere/knowhere/index/vector_index/IndexGPUIVFSQ.cpp @@ -24,7 +24,6 @@ #include "knowhere/index/vector_index/IndexGPUIVFSQ.h" #include "knowhere/index/vector_index/IndexIVFSQ.h" -namespace zilliz { namespace knowhere { IndexModelPtr @@ -73,4 +72,3 @@ GPUIVFSQ::CopyGpuToCpu(const Config& config) { } } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/vector_index/IndexGPUIVFSQ.h b/cpp/src/core/knowhere/knowhere/index/vector_index/IndexGPUIVFSQ.h index 5c6b4a038bae7e6915479bd08364e80a4cf733c3..ed8013d77f1f87535a8cabb7ca256c7ee28bc399 100644 --- a/cpp/src/core/knowhere/knowhere/index/vector_index/IndexGPUIVFSQ.h +++ b/cpp/src/core/knowhere/knowhere/index/vector_index/IndexGPUIVFSQ.h @@ -22,7 +22,6 @@ #include "IndexGPUIVF.h" -namespace zilliz { namespace knowhere { class GPUIVFSQ : public GPUIVF { @@ -42,4 +41,3 @@ class GPUIVFSQ : public GPUIVF { }; } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/vector_index/IndexIDMAP.cpp b/cpp/src/core/knowhere/knowhere/index/vector_index/IndexIDMAP.cpp index 8d4ff16a1ff601626b639056e66decad96fa4438..2371591b5c179ba546489aa53c424c99b4fd92d6 100644 --- a/cpp/src/core/knowhere/knowhere/index/vector_index/IndexIDMAP.cpp +++ b/cpp/src/core/knowhere/knowhere/index/vector_index/IndexIDMAP.cpp @@ -27,7 +27,6 @@ #include "knowhere/index/vector_index/IndexIDMAP.h" #include "knowhere/index/vector_index/helpers/FaissIO.h" -namespace zilliz { namespace knowhere { BinarySet @@ -269,4 +268,3 @@ GPUIDMAP::search_impl(int64_t n, const float* data, int64_t k, float* distances, } } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/vector_index/IndexIDMAP.h b/cpp/src/core/knowhere/knowhere/index/vector_index/IndexIDMAP.h index fd13b87e34e16c24facf4d0f123bd7990ab6d057..ec1cbb9e770735d4c92f91492085a37b1783e5a2 100644 --- a/cpp/src/core/knowhere/knowhere/index/vector_index/IndexIDMAP.h +++ b/cpp/src/core/knowhere/knowhere/index/vector_index/IndexIDMAP.h @@ -23,7 +23,6 @@ #include #include -namespace zilliz { namespace knowhere { class IDMAP : public VectorIndex, public FaissBaseIndex { @@ -97,4 +96,3 @@ class GPUIDMAP : public IDMAP, public GPUIndex { using GPUIDMAPPtr = std::shared_ptr; } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/vector_index/IndexIVF.cpp b/cpp/src/core/knowhere/knowhere/index/vector_index/IndexIVF.cpp index 13805ce14d03439ba2333fd4682e957ce038ba83..428710d355aa0d25aa3e936d6e3354f071725677 100644 --- a/cpp/src/core/knowhere/knowhere/index/vector_index/IndexIVF.cpp +++ b/cpp/src/core/knowhere/knowhere/index/vector_index/IndexIVF.cpp @@ -33,7 +33,6 @@ #include "knowhere/index/vector_index/IndexGPUIVF.h" #include "knowhere/index/vector_index/IndexIVF.h" -namespace zilliz { namespace knowhere { IndexModelPtr @@ -268,4 +267,3 @@ IVFIndexModel::SealImpl() { } } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/vector_index/IndexIVF.h b/cpp/src/core/knowhere/knowhere/index/vector_index/IndexIVF.h index 088849c22ac3c3f4e8af46d966e4b8593570d0a9..ef9982fa300dfe24c4afaf4986c7fde0735834cb 100644 --- a/cpp/src/core/knowhere/knowhere/index/vector_index/IndexIVF.h +++ b/cpp/src/core/knowhere/knowhere/index/vector_index/IndexIVF.h @@ -26,7 +26,6 @@ #include "VectorIndex.h" #include "faiss/IndexIVF.h" -namespace zilliz { namespace knowhere { using Graph = std::vector>; @@ -122,4 +121,3 @@ class IVFIndexModel : public IndexModel, public FaissBaseIndex { using IVFIndexModelPtr = std::shared_ptr; } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/vector_index/IndexIVFPQ.cpp b/cpp/src/core/knowhere/knowhere/index/vector_index/IndexIVFPQ.cpp index c0eda943100f589fa5571388bfe641da71f07677..03acbf31d774730b9514bd6b46d93866f384b5da 100644 --- a/cpp/src/core/knowhere/knowhere/index/vector_index/IndexIVFPQ.cpp +++ b/cpp/src/core/knowhere/knowhere/index/vector_index/IndexIVFPQ.cpp @@ -24,7 +24,6 @@ #include "knowhere/common/Exception.h" #include "knowhere/index/vector_index/IndexIVFPQ.h" -namespace zilliz { namespace knowhere { IndexModelPtr @@ -62,4 +61,3 @@ IVFPQ::Clone_impl(const std::shared_ptr& index) { } } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/vector_index/IndexIVFPQ.h b/cpp/src/core/knowhere/knowhere/index/vector_index/IndexIVFPQ.h index f071c1e0fa547be01845fa04613d186599db9ab4..69aaa5090bd46a5cc115f8f7bd177da4135bbcdd 100644 --- a/cpp/src/core/knowhere/knowhere/index/vector_index/IndexIVFPQ.h +++ b/cpp/src/core/knowhere/knowhere/index/vector_index/IndexIVFPQ.h @@ -22,7 +22,6 @@ #include "IndexIVF.h" -namespace zilliz { namespace knowhere { class IVFPQ : public IVF { @@ -44,4 +43,3 @@ class IVFPQ : public IVF { }; } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/vector_index/IndexIVFSQ.cpp b/cpp/src/core/knowhere/knowhere/index/vector_index/IndexIVFSQ.cpp index 5406211fa32275cbe2c0634b11e8fdb71b83bb8c..11e508549ac3f0363605fb3ccba93ce6851e8aa8 100644 --- a/cpp/src/core/knowhere/knowhere/index/vector_index/IndexIVFSQ.cpp +++ b/cpp/src/core/knowhere/knowhere/index/vector_index/IndexIVFSQ.cpp @@ -24,7 +24,6 @@ #include "knowhere/index/vector_index/IndexIVFSQ.h" #include "knowhere/index/vector_index/helpers/FaissGpuResourceMgr.h" -namespace zilliz { namespace knowhere { IndexModelPtr @@ -70,4 +69,3 @@ IVFSQ::CopyCpuToGpu(const int64_t& device_id, const Config& config) { } } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/vector_index/IndexIVFSQ.h b/cpp/src/core/knowhere/knowhere/index/vector_index/IndexIVFSQ.h index 3a05ca982657a13b708ab429e2caa5c39aa97fb3..cac95faebf10d6e4f187f46ae8e61b5f2c95343e 100644 --- a/cpp/src/core/knowhere/knowhere/index/vector_index/IndexIVFSQ.h +++ b/cpp/src/core/knowhere/knowhere/index/vector_index/IndexIVFSQ.h @@ -22,7 +22,6 @@ #include "IndexIVF.h" -namespace zilliz { namespace knowhere { class IVFSQ : public IVF { @@ -44,4 +43,3 @@ class IVFSQ : public IVF { }; } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/vector_index/IndexKDT.cpp b/cpp/src/core/knowhere/knowhere/index/vector_index/IndexKDT.cpp index 6efb839384c4b599ff04ac4bb02e53f550944835..c23a6ef61d81298b2a53f66889addf05561cc2da 100644 --- a/cpp/src/core/knowhere/knowhere/index/vector_index/IndexKDT.cpp +++ b/cpp/src/core/knowhere/knowhere/index/vector_index/IndexKDT.cpp @@ -30,7 +30,6 @@ #include "knowhere/common/Exception.h" #include "knowhere/index/vector_index/helpers/KDTParameterMgr.h" -namespace zilliz { namespace knowhere { BinarySet @@ -174,4 +173,3 @@ CPUKDTRNGIndexModel::Load(const BinarySet& binary) { } } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/vector_index/IndexKDT.h b/cpp/src/core/knowhere/knowhere/index/vector_index/IndexKDT.h index 86737ac3dd6cf573a36d02c93f1bf46615f44c09..f6d436995b0d1051bf8c75c2c7a51cae4eb1d890 100644 --- a/cpp/src/core/knowhere/knowhere/index/vector_index/IndexKDT.h +++ b/cpp/src/core/knowhere/knowhere/index/vector_index/IndexKDT.h @@ -23,7 +23,6 @@ #include "VectorIndex.h" #include "knowhere/index/IndexModel.h" -namespace zilliz { namespace knowhere { class CPUKDTRNG : public VectorIndex { @@ -86,4 +85,3 @@ class CPUKDTRNGIndexModel : public IndexModel { using CPUKDTRNGIndexModelPtr = std::shared_ptr; } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/vector_index/IndexNSG.cpp b/cpp/src/core/knowhere/knowhere/index/vector_index/IndexNSG.cpp index b731f801b3bcfd8580a26d31977164b1a7eeab4f..f5519b824089b94885cbfb05ffdabcb6c63a1b36 100644 --- a/cpp/src/core/knowhere/knowhere/index/vector_index/IndexNSG.cpp +++ b/cpp/src/core/knowhere/knowhere/index/vector_index/IndexNSG.cpp @@ -25,7 +25,6 @@ #include "knowhere/index/vector_index/nsg/NSG.h" #include "knowhere/index/vector_index/nsg/NSGIO.h" -namespace zilliz { namespace knowhere { BinarySet @@ -167,4 +166,3 @@ NSG::Seal() { } } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/vector_index/IndexNSG.h b/cpp/src/core/knowhere/knowhere/index/vector_index/IndexNSG.h index 4371ddb65a76a0e916d805957e3692c262d8feaa..04a146d58a3aa7c0f704a2c586f119c9765f4df9 100644 --- a/cpp/src/core/knowhere/knowhere/index/vector_index/IndexNSG.h +++ b/cpp/src/core/knowhere/knowhere/index/vector_index/IndexNSG.h @@ -22,7 +22,6 @@ #include "VectorIndex.h" -namespace zilliz { namespace knowhere { namespace algo { @@ -63,4 +62,3 @@ class NSG : public VectorIndex { using NSGIndexPtr = std::shared_ptr(); } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/vector_index/VectorIndex.h b/cpp/src/core/knowhere/knowhere/index/vector_index/VectorIndex.h index e96de885af12cefc059cd918fb098b492cef92ca..810c4d2ea4874b9f9d86e7da2e39c692b6727387 100644 --- a/cpp/src/core/knowhere/knowhere/index/vector_index/VectorIndex.h +++ b/cpp/src/core/knowhere/knowhere/index/vector_index/VectorIndex.h @@ -25,7 +25,6 @@ #include "knowhere/index/preprocessor/Preprocessor.h" #include "knowhere/index/vector_index/helpers/IndexParameter.h" -namespace zilliz { namespace knowhere { class VectorIndex; @@ -60,4 +59,3 @@ class VectorIndex : public Index { }; } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/Cloner.cpp b/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/Cloner.cpp index c6f3f81053065bebe1d132980ee83be0e3a6003e..16191b818321b1b9439f800cd9c0415c85609ba8 100644 --- a/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/Cloner.cpp +++ b/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/Cloner.cpp @@ -23,7 +23,6 @@ #include "knowhere/index/vector_index/IndexIVFPQ.h" #include "knowhere/index/vector_index/IndexIVFSQ.h" -namespace zilliz { namespace knowhere { namespace cloner { @@ -57,4 +56,3 @@ CopyCpuToGpu(const VectorIndexPtr& index, const int64_t& device_id, const Config } // namespace cloner } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/Cloner.h b/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/Cloner.h index fb5d00d7df2add25b07609550565065f747e7f80..3134238ed86db8c4810c83522d96ed2a65f29244 100644 --- a/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/Cloner.h +++ b/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/Cloner.h @@ -19,7 +19,6 @@ #include "knowhere/index/vector_index/VectorIndex.h" -namespace zilliz { namespace knowhere { namespace cloner { @@ -32,4 +31,3 @@ CopyGpuToCpu(const VectorIndexPtr& index, const Config& config); } // namespace cloner } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/Definitions.h b/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/Definitions.h index d5959f7501c0cf3134ce604fe1e4fce9ce7216e9..f39a28d20fd8a6bb972e5f2e89e60706d51e28bd 100644 --- a/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/Definitions.h +++ b/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/Definitions.h @@ -17,7 +17,6 @@ #pragma once -namespace zilliz { namespace knowhere { namespace definition { @@ -27,4 +26,3 @@ namespace definition { } // namespace definition } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/FaissGpuResourceMgr.cpp b/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/FaissGpuResourceMgr.cpp index 70c879d03aebb5599a2ff23dacfa0af4f70c8194..d74c6bc562e1b79555fef20f5d7e2f5ad24dc5d0 100644 --- a/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/FaissGpuResourceMgr.cpp +++ b/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/FaissGpuResourceMgr.cpp @@ -19,7 +19,6 @@ #include -namespace zilliz { namespace knowhere { FaissGpuResourceMgr& @@ -125,4 +124,3 @@ FaissGpuResourceMgr::Dump() { } } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/FaissGpuResourceMgr.h b/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/FaissGpuResourceMgr.h index 926b8b4e00cb9e2e37694ba5de4ebe35e735a281..bf570ca4eb0d82517dbe00510ae647f7e8724586 100644 --- a/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/FaissGpuResourceMgr.h +++ b/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/FaissGpuResourceMgr.h @@ -26,7 +26,6 @@ #include "src/utils/BlockingQueue.h" -namespace zilliz { namespace knowhere { struct Resource { @@ -45,7 +44,7 @@ using ResWPtr = std::weak_ptr; class FaissGpuResourceMgr { public: friend class ResScope; - using ResBQ = zilliz::milvus::server::BlockingQueue; + using ResBQ = milvus::server::BlockingQueue; public: struct DeviceParams { @@ -127,4 +126,3 @@ class ResScope { }; } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/FaissIO.cpp b/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/FaissIO.cpp index 30a54b388dbfdfea0bd51220b9c68d41625e56c5..99532137c08ed25b556fe6d473da736c4a9ac2df 100644 --- a/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/FaissIO.cpp +++ b/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/FaissIO.cpp @@ -19,7 +19,6 @@ #include "knowhere/index/vector_index/helpers/FaissIO.h" -namespace zilliz { namespace knowhere { // TODO(linxj): Get From Config File @@ -66,4 +65,3 @@ MemoryIOReader::operator()(void* ptr, size_t size, size_t nitems) { } } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/FaissIO.h b/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/FaissIO.h index c850e89d9f24166fc7ac63efab31cce5046c3a9b..7cce5bbbaca21ef5b6113bd814e11ebcdf4746bd 100644 --- a/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/FaissIO.h +++ b/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/FaissIO.h @@ -19,7 +19,6 @@ #include -namespace zilliz { namespace knowhere { struct MemoryIOWriter : public faiss::IOWriter { @@ -41,4 +40,3 @@ struct MemoryIOReader : public faiss::IOReader { }; } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/IndexParameter.cpp b/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/IndexParameter.cpp index c4a179bc6a6ce4c68497ec45b508986039662d80..20f3388174a1572b4b35d82ab0ba451fa4c6f774 100644 --- a/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/IndexParameter.cpp +++ b/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/IndexParameter.cpp @@ -20,7 +20,6 @@ #include -namespace zilliz { namespace knowhere { faiss::MetricType @@ -36,4 +35,3 @@ GetMetricType(METRICTYPE& type) { } } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/IndexParameter.h b/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/IndexParameter.h index d5056d7ee698262761a1ce767d9ffaf753ce7097..b2854abef8611edfb017873a17386c006fdf591b 100644 --- a/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/IndexParameter.h +++ b/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/IndexParameter.h @@ -22,7 +22,6 @@ #include "knowhere/common/Config.h" -namespace zilliz { namespace knowhere { extern faiss::MetricType @@ -132,4 +131,3 @@ struct KDTCfg : public Cfg { }; } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/KDTParameterMgr.cpp b/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/KDTParameterMgr.cpp index 015dc17fc5af24baea2b54d2dec296e7468a4e63..19bf070dbae735dd5142c823cf824f382f64c670 100644 --- a/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/KDTParameterMgr.cpp +++ b/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/KDTParameterMgr.cpp @@ -19,7 +19,6 @@ #include "knowhere/index/vector_index/helpers/KDTParameterMgr.h" -namespace zilliz { namespace knowhere { const std::vector& @@ -54,4 +53,3 @@ KDTParameterMgr::KDTParameterMgr() { } } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/KDTParameterMgr.h b/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/KDTParameterMgr.h index ec2d73eebb849ce415a68b6615c9058be951cb90..fe90761e173194e87e5e28cdc921e8f93df48107 100644 --- a/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/KDTParameterMgr.h +++ b/cpp/src/core/knowhere/knowhere/index/vector_index/helpers/KDTParameterMgr.h @@ -22,7 +22,6 @@ #include #include -namespace zilliz { namespace knowhere { using KDTParameter = std::pair; @@ -51,4 +50,3 @@ class KDTParameterMgr { }; } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/vector_index/nsg/NSG.cpp b/cpp/src/core/knowhere/knowhere/index/vector_index/nsg/NSG.cpp index 19bc825d81b75341c610e00cfbeb70a31a644772..375664fbf818ee8d2c949111d52e75278a3c314d 100644 --- a/cpp/src/core/knowhere/knowhere/index/vector_index/nsg/NSG.cpp +++ b/cpp/src/core/knowhere/knowhere/index/vector_index/nsg/NSG.cpp @@ -32,7 +32,6 @@ // TODO: enable macro //#include -namespace zilliz { namespace knowhere { namespace algo { @@ -792,4 +791,3 @@ NsgIndex::SetKnnGraph(Graph& g) { } // namespace algo } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/vector_index/nsg/NSG.h b/cpp/src/core/knowhere/knowhere/index/vector_index/nsg/NSG.h index e0752603986bc63bca8826d53c502cf1d0a4a65f..160c076e45e717948f55e24352b82c69ab5b4b14 100644 --- a/cpp/src/core/knowhere/knowhere/index/vector_index/nsg/NSG.h +++ b/cpp/src/core/knowhere/knowhere/index/vector_index/nsg/NSG.h @@ -24,7 +24,6 @@ #include #include "Neighbor.h" -namespace zilliz { namespace knowhere { namespace algo { @@ -143,4 +142,3 @@ class NsgIndex { } // namespace algo } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/vector_index/nsg/NSGHelper.cpp b/cpp/src/core/knowhere/knowhere/index/vector_index/nsg/NSGHelper.cpp index 1dd306bf77a398560e1eed506b13ecaa5b2d22c8..05e8d18787ed09c608f71d893319659959871b99 100644 --- a/cpp/src/core/knowhere/knowhere/index/vector_index/nsg/NSGHelper.cpp +++ b/cpp/src/core/knowhere/knowhere/index/vector_index/nsg/NSGHelper.cpp @@ -20,7 +20,6 @@ #include "knowhere/index/vector_index/nsg/NSGHelper.h" -namespace zilliz { namespace knowhere { namespace algo { @@ -180,4 +179,3 @@ calculate(const float* a, const float* b, unsigned size) { } // namespace algo } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/vector_index/nsg/NSGHelper.h b/cpp/src/core/knowhere/knowhere/index/vector_index/nsg/NSGHelper.h index cb8007f2b1faa800f3fa1ef47a3ea63fcb3f8052..5007cf019c016f6040b779e65deb7de461d26654 100644 --- a/cpp/src/core/knowhere/knowhere/index/vector_index/nsg/NSGHelper.h +++ b/cpp/src/core/knowhere/knowhere/index/vector_index/nsg/NSGHelper.h @@ -25,7 +25,6 @@ #include "NSG.h" #include "knowhere/common/Config.h" -namespace zilliz { namespace knowhere { namespace algo { @@ -36,4 +35,3 @@ calculate(const float* a, const float* b, unsigned size); } // namespace algo } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/vector_index/nsg/NSGIO.cpp b/cpp/src/core/knowhere/knowhere/index/vector_index/nsg/NSGIO.cpp index db3113da2f23226928220f49de59cd9bfb6db6e5..cac3b5864f22675a3e7e695adc40f2e9afc907d3 100644 --- a/cpp/src/core/knowhere/knowhere/index/vector_index/nsg/NSGIO.cpp +++ b/cpp/src/core/knowhere/knowhere/index/vector_index/nsg/NSGIO.cpp @@ -19,7 +19,6 @@ #include "knowhere/index/vector_index/nsg/NSGIO.h" -namespace zilliz { namespace knowhere { namespace algo { @@ -68,4 +67,3 @@ read_index(MemoryIOReader& reader) { } // namespace algo } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/vector_index/nsg/NSGIO.h b/cpp/src/core/knowhere/knowhere/index/vector_index/nsg/NSGIO.h index fd740a991eb8f3210936b5739397062ca1e6f35c..12913b69df754824a60f2c08b7c6745bde0a65ef 100644 --- a/cpp/src/core/knowhere/knowhere/index/vector_index/nsg/NSGIO.h +++ b/cpp/src/core/knowhere/knowhere/index/vector_index/nsg/NSGIO.h @@ -21,7 +21,6 @@ #include "knowhere/index/vector_index/IndexIVF.h" #include "knowhere/index/vector_index/helpers/FaissIO.h" -namespace zilliz { namespace knowhere { namespace algo { @@ -32,4 +31,3 @@ read_index(MemoryIOReader& reader); } // namespace algo } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/knowhere/knowhere/index/vector_index/nsg/Neighbor.h b/cpp/src/core/knowhere/knowhere/index/vector_index/nsg/Neighbor.h index ee71a3f66ecfcac0aac22526d2ede5ff40185bbc..c3a314164c18797daacd7179bd6f40ef347e8b30 100644 --- a/cpp/src/core/knowhere/knowhere/index/vector_index/nsg/Neighbor.h +++ b/cpp/src/core/knowhere/knowhere/index/vector_index/nsg/Neighbor.h @@ -19,7 +19,6 @@ #include -namespace zilliz { namespace knowhere { namespace algo { @@ -61,4 +60,3 @@ typedef std::lock_guard LockGuard; } // namespace algo } // namespace knowhere -} // namespace zilliz diff --git a/cpp/src/core/unittest/kdtree.cpp b/cpp/src/core/unittest/kdtree.cpp index 351a177d4b4595f7ebba17dfeeac972847cc4a09..9b1e428a8052311115dc1f0c44cbefaa5f7eccf6 100644 --- a/cpp/src/core/unittest/kdtree.cpp +++ b/cpp/src/core/unittest/kdtree.cpp @@ -24,7 +24,7 @@ // // namespace { // -// namespace kn = zilliz::knowhere; +// namespace kn = knowhere; // //} // namespace // diff --git a/cpp/src/core/unittest/test_idmap.cpp b/cpp/src/core/unittest/test_idmap.cpp index 9ee4ea732d7b919ce3b7aba262134a662a222132..e907d309eb36c4563aeb420d4ef9cace25d75d51 100644 --- a/cpp/src/core/unittest/test_idmap.cpp +++ b/cpp/src/core/unittest/test_idmap.cpp @@ -27,7 +27,7 @@ namespace { -namespace kn = zilliz::knowhere; +namespace kn = knowhere; } // namespace @@ -179,9 +179,9 @@ TEST_F(IDMAPTest, copy_test) { auto clone_result = clone_index->Search(query_dataset, conf); AssertAnns(clone_result, nq, k); ASSERT_THROW({ std::static_pointer_cast(clone_index)->GetRawVectors(); }, - zilliz::knowhere::KnowhereException); + knowhere::KnowhereException); ASSERT_THROW({ std::static_pointer_cast(clone_index)->GetRawIds(); }, - zilliz::knowhere::KnowhereException); + knowhere::KnowhereException); auto binary = clone_index->Serialize(); clone_index->Load(binary); diff --git a/cpp/src/core/unittest/test_ivf.cpp b/cpp/src/core/unittest/test_ivf.cpp index 2aa6937dbe26af916011d4a6ab40c082d3fef4c2..a0da0eca8ebd6edafe67a255f2bb6d865ee9ea32 100644 --- a/cpp/src/core/unittest/test_ivf.cpp +++ b/cpp/src/core/unittest/test_ivf.cpp @@ -39,7 +39,7 @@ namespace { -namespace kn = zilliz::knowhere; +namespace kn = knowhere; } // namespace diff --git a/cpp/src/core/unittest/test_json.cpp b/cpp/src/core/unittest/test_json.cpp index acdddad30a657335dbff8da73253fe52b81ca17f..613e0deff5dfdcfe847f256233822a113af993c1 100644 --- a/cpp/src/core/unittest/test_json.cpp +++ b/cpp/src/core/unittest/test_json.cpp @@ -19,7 +19,7 @@ namespace { -namespace kn = zilliz::knowhere; +namespace kn = knowhere; } // namespace diff --git a/cpp/src/core/unittest/test_kdt.cpp b/cpp/src/core/unittest/test_kdt.cpp index 85c8650d1b3e4b9c5aa4209c2a3a9b938729b934..6fa6ba33f36cb0f917c4e6e62c875f975316b9ce 100644 --- a/cpp/src/core/unittest/test_kdt.cpp +++ b/cpp/src/core/unittest/test_kdt.cpp @@ -30,7 +30,7 @@ namespace { -namespace kn = zilliz::knowhere; +namespace kn = knowhere; } // namespace @@ -132,7 +132,7 @@ TEST_F(KDTTest, kdt_serialize) { PrintResult(result, nq, k); ASSERT_EQ(new_index->Count(), nb); ASSERT_EQ(new_index->Dimension(), dim); - ASSERT_THROW({ new_index->Clone(); }, zilliz::knowhere::KnowhereException); + ASSERT_THROW({ new_index->Clone(); }, knowhere::KnowhereException); ASSERT_NO_THROW({ new_index->Seal(); }); { diff --git a/cpp/src/core/unittest/test_nsg/test_nsg.cpp b/cpp/src/core/unittest/test_nsg/test_nsg.cpp index b93a2ddc355eeff4165c8f4eabd4faf4cf98616d..70261a63dc1c8a63243ccdb377dbc87b89abbaea 100644 --- a/cpp/src/core/unittest/test_nsg/test_nsg.cpp +++ b/cpp/src/core/unittest/test_nsg/test_nsg.cpp @@ -28,7 +28,7 @@ namespace { -namespace kn = zilliz::knowhere; +namespace kn = knowhere; } // namespace @@ -98,7 +98,7 @@ TEST_F(NSGInterfaceTest, basic_test) { ASSERT_EQ(index_->Count(), nb); ASSERT_EQ(index_->Dimension(), dim); - ASSERT_THROW({ index_->Clone(); }, zilliz::knowhere::KnowhereException); + ASSERT_THROW({ index_->Clone(); }, knowhere::KnowhereException); ASSERT_NO_THROW({ index_->Add(base_dataset, kn::Config()); index_->Seal(); diff --git a/cpp/src/core/unittest/utils.cpp b/cpp/src/core/unittest/utils.cpp index e81ad8ea0253cf7668203386acdf76a8e94958e9..3c342738c1e2959a768cc5bac27ed9fe287e2767 100644 --- a/cpp/src/core/unittest/utils.cpp +++ b/cpp/src/core/unittest/utils.cpp @@ -25,7 +25,7 @@ INITIALIZE_EASYLOGGINGPP namespace { -namespace kn = zilliz::knowhere; +namespace kn = knowhere; } // namespace @@ -56,7 +56,7 @@ DataGen::Generate(const int& dim, const int& nb, const int& nq) { query_dataset = generate_query_dataset(nq, dim, xq.data()); } -zilliz::knowhere::DatasetPtr +knowhere::DatasetPtr DataGen::GenQuery(const int& nq) { xq.resize(nq * dim); for (int i = 0; i < nq * dim; ++i) { diff --git a/cpp/src/core/unittest/utils.h b/cpp/src/core/unittest/utils.h index 07a104ad4aa35776563a280a938644111427bcdd..acc3e89183972190955639b70c19da3b8c15272c 100644 --- a/cpp/src/core/unittest/utils.h +++ b/cpp/src/core/unittest/utils.h @@ -34,7 +34,7 @@ class DataGen { void Generate(const int& dim, const int& nb, const int& nq); - zilliz::knowhere::DatasetPtr + knowhere::DatasetPtr GenQuery(const int& nq); protected: @@ -45,8 +45,8 @@ class DataGen { std::vector xb; std::vector xq; std::vector ids; - zilliz::knowhere::DatasetPtr base_dataset = nullptr; - zilliz::knowhere::DatasetPtr query_dataset = nullptr; + knowhere::DatasetPtr base_dataset = nullptr; + knowhere::DatasetPtr query_dataset = nullptr; }; extern void @@ -62,10 +62,10 @@ GenBase(const int64_t& dim, const int64_t& nb, float* xb, int64_t* ids); extern void InitLog(); -zilliz::knowhere::DatasetPtr +knowhere::DatasetPtr generate_dataset(int64_t nb, int64_t dim, float* xb, int64_t* ids); -zilliz::knowhere::DatasetPtr +knowhere::DatasetPtr generate_query_dataset(int64_t nb, int64_t dim, float* xb); struct FileIOWriter { diff --git a/cpp/src/db/Constants.h b/cpp/src/db/Constants.h index 0feffadaf44b66cd760a1a333fb02d698b61e94c..a1e09bc196d3df61eec9ccbd3df2fd380e996e40 100644 --- a/cpp/src/db/Constants.h +++ b/cpp/src/db/Constants.h @@ -19,7 +19,6 @@ #include -namespace zilliz { namespace milvus { namespace engine { @@ -38,4 +37,3 @@ static constexpr uint64_t ONE_GB = ONE_KB * ONE_MB; } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/db/DB.h b/cpp/src/db/DB.h index 9a6a2e74a6e4fee2a55693a7ae020d62912b5ccf..a790fadb502f3f1d93d879873daa8a5adb228c44 100644 --- a/cpp/src/db/DB.h +++ b/cpp/src/db/DB.h @@ -26,7 +26,6 @@ #include #include -namespace zilliz { namespace milvus { namespace engine { @@ -96,4 +95,3 @@ using DBPtr = std::shared_ptr; } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/db/DBFactory.cpp b/cpp/src/db/DBFactory.cpp index 89d04b3632dad765ebc08cd161f661ac5388c07a..fae3a180c07b00b9261dca4dbdfea4344178dc43 100644 --- a/cpp/src/db/DBFactory.cpp +++ b/cpp/src/db/DBFactory.cpp @@ -28,7 +28,6 @@ #include #include -namespace zilliz { namespace milvus { namespace engine { @@ -47,4 +46,3 @@ DBFactory::Build(const DBOptions& options) { } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/db/DBFactory.h b/cpp/src/db/DBFactory.h index c5c73a064965ea7fbe662f7adfc242449cdd3f7b..e787f7c8839b414b192e4ab72a7677df29f56cd6 100644 --- a/cpp/src/db/DBFactory.h +++ b/cpp/src/db/DBFactory.h @@ -23,7 +23,6 @@ #include #include -namespace zilliz { namespace milvus { namespace engine { @@ -38,4 +37,3 @@ class DBFactory { } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/db/DBImpl.cpp b/cpp/src/db/DBImpl.cpp index 10cdf60b5ab41e9336bb1622a7affd194d11885a..ece62284f7d51428546acb6ec91d003ed0217db4 100644 --- a/cpp/src/db/DBImpl.cpp +++ b/cpp/src/db/DBImpl.cpp @@ -39,7 +39,6 @@ #include #include -namespace zilliz { namespace milvus { namespace engine { @@ -249,7 +248,7 @@ DBImpl::InsertVectors(const std::string& table_id, uint64_t n, const float* vect } Status status; - zilliz::milvus::server::CollectInsertMetrics metrics(n, status); + milvus::server::CollectInsertMetrics metrics(n, status); status = mem_mgr_->InsertVectors(table_id, n, vectors, vector_ids); // std::chrono::microseconds time_span = // std::chrono::duration_cast(end_time - start_time); @@ -914,4 +913,3 @@ DBImpl::BackgroundBuildIndex() { } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/db/DBImpl.h b/cpp/src/db/DBImpl.h index 366408d8b0befcba5ffeeffc560231af334cb19d..865b3dfa5361e4ccfa22fb1df223d3d5badd13fa 100644 --- a/cpp/src/db/DBImpl.h +++ b/cpp/src/db/DBImpl.h @@ -32,7 +32,6 @@ #include #include -namespace zilliz { namespace milvus { namespace engine { @@ -165,4 +164,3 @@ class DBImpl : public DB { } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/db/IDGenerator.cpp b/cpp/src/db/IDGenerator.cpp index b80e1ce3546856c556222996d740d0827ab60fc7..6b150a926a6b367569a4e47340abe0d024ec3d91 100644 --- a/cpp/src/db/IDGenerator.cpp +++ b/cpp/src/db/IDGenerator.cpp @@ -21,7 +21,6 @@ #include #include -namespace zilliz { namespace milvus { namespace engine { @@ -64,4 +63,3 @@ SimpleIDGenerator::GetNextIDNumbers(size_t n, IDNumbers& ids) { } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/db/IDGenerator.h b/cpp/src/db/IDGenerator.h index f41f745864e43320ade1fb8ada5ba8e90de82866..cdd22efc1ae5be96a233fc9fd3456f4f6c91d87c 100644 --- a/cpp/src/db/IDGenerator.h +++ b/cpp/src/db/IDGenerator.h @@ -22,7 +22,6 @@ #include #include -namespace zilliz { namespace milvus { namespace engine { @@ -56,4 +55,3 @@ class SimpleIDGenerator : public IDGenerator { } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/db/Options.cpp b/cpp/src/db/Options.cpp index edaf69c9e669b20dc2a12e471d46c0d92c390af4..9d6a7d02368dc96da87ae1911e9590d17ff12784 100644 --- a/cpp/src/db/Options.cpp +++ b/cpp/src/db/Options.cpp @@ -23,7 +23,6 @@ #include #include -namespace zilliz { namespace milvus { namespace engine { @@ -91,4 +90,3 @@ ArchiveConf::ParseType(const std::string& type) { } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/db/Options.h b/cpp/src/db/Options.h index d51a30f2b496d4340844aa715511b26198a22c91..ebecb4de5a0ff2c51174cb123d9cd6466ae54bde 100644 --- a/cpp/src/db/Options.h +++ b/cpp/src/db/Options.h @@ -24,7 +24,6 @@ #include #include -namespace zilliz { namespace milvus { namespace engine { @@ -81,4 +80,3 @@ struct DBOptions { } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/db/Types.h b/cpp/src/db/Types.h index c37434a405f3191c556e5f6f081dbd1f25b20aa9..94528a9a8afb0023ec09ad3d12603c1a3f0a6746 100644 --- a/cpp/src/db/Types.h +++ b/cpp/src/db/Types.h @@ -23,7 +23,6 @@ #include #include -namespace zilliz { namespace milvus { namespace engine { @@ -42,4 +41,3 @@ struct TableIndex { } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/db/Utils.cpp b/cpp/src/db/Utils.cpp index d9e500f84ae5b9453acd7b2c31c0a2ab1d1146cd..0ddf03568aaa280db059acbab3d7b2f51b277cc4 100644 --- a/cpp/src/db/Utils.cpp +++ b/cpp/src/db/Utils.cpp @@ -25,7 +25,6 @@ #include #include -namespace zilliz { namespace milvus { namespace engine { namespace utils { @@ -239,4 +238,3 @@ ParseMetaUri(const std::string& uri, MetaUriInfo& info) { } // namespace utils } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/db/Utils.h b/cpp/src/db/Utils.h index c161e32b955a3e7043b3792efd88e267a272cd72..0b157f6dfd932394845b82a4d9685bd9ce52ef6f 100644 --- a/cpp/src/db/Utils.h +++ b/cpp/src/db/Utils.h @@ -24,7 +24,6 @@ #include #include -namespace zilliz { namespace milvus { namespace engine { namespace utils { @@ -69,4 +68,3 @@ ParseMetaUri(const std::string& uri, MetaUriInfo& info); } // namespace utils } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/db/engine/EngineFactory.cpp b/cpp/src/db/engine/EngineFactory.cpp index 338b7d72afddabf7cd1e4d00ea39963092484f80..c3597d1020106e419c1f66995d7efcde490ce396 100644 --- a/cpp/src/db/engine/EngineFactory.cpp +++ b/cpp/src/db/engine/EngineFactory.cpp @@ -21,7 +21,6 @@ #include -namespace zilliz { namespace milvus { namespace engine { @@ -43,4 +42,3 @@ EngineFactory::Build(uint16_t dimension, const std::string& location, EngineType } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/db/engine/EngineFactory.h b/cpp/src/db/engine/EngineFactory.h index 5d22fbb4d2b99fb18725c4290d52cbbc3b8fbc4c..d98952ccd9c99f2ed771600a488d935d2243b558 100644 --- a/cpp/src/db/engine/EngineFactory.h +++ b/cpp/src/db/engine/EngineFactory.h @@ -22,7 +22,6 @@ #include -namespace zilliz { namespace milvus { namespace engine { @@ -35,4 +34,3 @@ class EngineFactory { } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/db/engine/ExecutionEngine.h b/cpp/src/db/engine/ExecutionEngine.h index 4ae3e872b39255919cb4675c0717e61df74fec5d..1572b967d150f2b78e147f9d8b5040dc364ec543 100644 --- a/cpp/src/db/engine/ExecutionEngine.h +++ b/cpp/src/db/engine/ExecutionEngine.h @@ -23,7 +23,6 @@ #include #include -namespace zilliz { namespace milvus { namespace engine { @@ -105,4 +104,3 @@ using ExecutionEnginePtr = std::shared_ptr; } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/db/engine/ExecutionEngineImpl.cpp b/cpp/src/db/engine/ExecutionEngineImpl.cpp index 2a239ddbea58114a4e31789e6c8801d59de75aa7..52365d09150a70ecf71cb008f78fd59e3487915f 100644 --- a/cpp/src/db/engine/ExecutionEngineImpl.cpp +++ b/cpp/src/db/engine/ExecutionEngineImpl.cpp @@ -34,7 +34,6 @@ #include #include -namespace zilliz { namespace milvus { namespace engine { @@ -324,7 +323,7 @@ ExecutionEngineImpl::Search(int64_t n, const float* data, int64_t k, int64_t npr Status ExecutionEngineImpl::Cache() { cache::DataObjPtr obj = std::make_shared(index_, PhysicalSize()); - zilliz::milvus::cache::CpuCacheMgr::GetInstance()->InsertItem(location_, obj); + milvus::cache::CpuCacheMgr::GetInstance()->InsertItem(location_, obj); return Status::OK(); } @@ -332,7 +331,7 @@ ExecutionEngineImpl::Cache() { Status ExecutionEngineImpl::GpuCache(uint64_t gpu_id) { cache::DataObjPtr obj = std::make_shared(index_, PhysicalSize()); - zilliz::milvus::cache::GpuCacheMgr::GetInstance(gpu_id)->InsertItem(location_, obj); + milvus::cache::GpuCacheMgr::GetInstance(gpu_id)->InsertItem(location_, obj); return Status::OK(); } @@ -351,4 +350,3 @@ ExecutionEngineImpl::Init() { } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/db/engine/ExecutionEngineImpl.h b/cpp/src/db/engine/ExecutionEngineImpl.h index e8f9521460ce7d6f0c39c5b3caee4c74c9ae38b7..62a7b29a6361df9a23f99812fee9f9e8bad29035 100644 --- a/cpp/src/db/engine/ExecutionEngineImpl.h +++ b/cpp/src/db/engine/ExecutionEngineImpl.h @@ -23,7 +23,6 @@ #include #include -namespace zilliz { namespace milvus { namespace engine { @@ -119,4 +118,3 @@ class ExecutionEngineImpl : public ExecutionEngine { } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/db/insert/MemManager.h b/cpp/src/db/insert/MemManager.h index 920e6e9692540098d8f3da4e5e45cd23b43fd5b1..cc766041657d5b7553107f1c6cdb0f5af837b57c 100644 --- a/cpp/src/db/insert/MemManager.h +++ b/cpp/src/db/insert/MemManager.h @@ -24,7 +24,6 @@ #include #include -namespace zilliz { namespace milvus { namespace engine { @@ -53,4 +52,3 @@ using MemManagerPtr = std::shared_ptr; } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/db/insert/MemManagerImpl.cpp b/cpp/src/db/insert/MemManagerImpl.cpp index 1a59c8b892cfe5b8773900fa35e8cb6e6a86b121..69c3397eb9e553c00cf4c23be8a891877c166009 100644 --- a/cpp/src/db/insert/MemManagerImpl.cpp +++ b/cpp/src/db/insert/MemManagerImpl.cpp @@ -22,7 +22,6 @@ #include -namespace zilliz { namespace milvus { namespace engine { @@ -140,4 +139,3 @@ MemManagerImpl::GetCurrentMem() { } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/db/insert/MemManagerImpl.h b/cpp/src/db/insert/MemManagerImpl.h index 4de5626459697b171f73793a605872dd315930d8..862b068d0fa21de42f84f650af4a146e3f65fb10 100644 --- a/cpp/src/db/insert/MemManagerImpl.h +++ b/cpp/src/db/insert/MemManagerImpl.h @@ -30,7 +30,6 @@ #include #include -namespace zilliz { namespace milvus { namespace engine { @@ -80,4 +79,3 @@ class MemManagerImpl : public MemManager { } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/db/insert/MemMenagerFactory.cpp b/cpp/src/db/insert/MemMenagerFactory.cpp index 8f0d6704d7434b83db1d7e59306c2a50cdcaa5bb..033992501b3362908af6d9d20ab026613364be37 100644 --- a/cpp/src/db/insert/MemMenagerFactory.cpp +++ b/cpp/src/db/insert/MemMenagerFactory.cpp @@ -28,7 +28,6 @@ #include #include -namespace zilliz { namespace milvus { namespace engine { @@ -39,4 +38,3 @@ MemManagerFactory::Build(const std::shared_ptr& meta, const DBOption } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/db/insert/MemMenagerFactory.h b/cpp/src/db/insert/MemMenagerFactory.h index d7996abe99b4eaed5e5b18255a2f11c61651e4a1..a489a3952b772a0e985e97b527e8388216a3652f 100644 --- a/cpp/src/db/insert/MemMenagerFactory.h +++ b/cpp/src/db/insert/MemMenagerFactory.h @@ -22,7 +22,6 @@ #include -namespace zilliz { namespace milvus { namespace engine { @@ -34,4 +33,3 @@ class MemManagerFactory { } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/db/insert/MemTable.cpp b/cpp/src/db/insert/MemTable.cpp index e189dbf15ba278e54b92e2ef74f380c416b6b480..871eab8d7d89e4d398e34de44f5472437e64ef58 100644 --- a/cpp/src/db/insert/MemTable.cpp +++ b/cpp/src/db/insert/MemTable.cpp @@ -21,7 +21,6 @@ #include #include -namespace zilliz { namespace milvus { namespace engine { @@ -104,4 +103,3 @@ MemTable::GetCurrentMem() { } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/db/insert/MemTable.h b/cpp/src/db/insert/MemTable.h index b2b16cf4721d736bc42bb3a3982ec601003e6644..cb22b6ed343cbbfd97f4f0dfc0516da251f919f1 100644 --- a/cpp/src/db/insert/MemTable.h +++ b/cpp/src/db/insert/MemTable.h @@ -26,7 +26,6 @@ #include #include -namespace zilliz { namespace milvus { namespace engine { @@ -73,4 +72,3 @@ using MemTablePtr = std::shared_ptr; } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/db/insert/MemTableFile.cpp b/cpp/src/db/insert/MemTableFile.cpp index 8395b0b62a8bd504f6c2be21a7d489f79c570e23..582751329730421cbb61738311c0dec3713c3f90 100644 --- a/cpp/src/db/insert/MemTableFile.cpp +++ b/cpp/src/db/insert/MemTableFile.cpp @@ -24,7 +24,6 @@ #include #include -namespace zilliz { namespace milvus { namespace engine { @@ -126,4 +125,3 @@ MemTableFile::Serialize() { } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/db/insert/MemTableFile.h b/cpp/src/db/insert/MemTableFile.h index 72ae09c8615b1d773fb8a250f66255b9a393b7e2..e11274b7de7ff88a00d6461f5fd6d78528ddbea6 100644 --- a/cpp/src/db/insert/MemTableFile.h +++ b/cpp/src/db/insert/MemTableFile.h @@ -25,7 +25,6 @@ #include #include -namespace zilliz { namespace milvus { namespace engine { @@ -66,4 +65,3 @@ using MemTableFilePtr = std::shared_ptr; } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/db/insert/VectorSource.cpp b/cpp/src/db/insert/VectorSource.cpp index 7a9fdf5d0faefdebb49fd19673062cc9bc305cb8..dbedf58029cd6acb65987c0cf438eea5cfbb56e9 100644 --- a/cpp/src/db/insert/VectorSource.cpp +++ b/cpp/src/db/insert/VectorSource.cpp @@ -21,7 +21,6 @@ #include "metrics/Metrics.h" #include "utils/Log.h" -namespace zilliz { namespace milvus { namespace engine { @@ -77,4 +76,3 @@ VectorSource::GetVectorIds() { } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/db/insert/VectorSource.h b/cpp/src/db/insert/VectorSource.h index 4b8e9d21b9eaadd67c54f2c7b3a0f7f64371047e..1d936268f4780f037cf13ec8b44db14abd612d4a 100644 --- a/cpp/src/db/insert/VectorSource.h +++ b/cpp/src/db/insert/VectorSource.h @@ -24,7 +24,6 @@ #include -namespace zilliz { namespace milvus { namespace engine { @@ -59,4 +58,3 @@ using VectorSourcePtr = std::shared_ptr; } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/db/meta/Meta.h b/cpp/src/db/meta/Meta.h index 3e3128366c2dbe915986b6d9f05255f7d96351fa..8167834568fff65d863c587363259177fe93e323 100644 --- a/cpp/src/db/meta/Meta.h +++ b/cpp/src/db/meta/Meta.h @@ -27,7 +27,6 @@ #include #include -namespace zilliz { namespace milvus { namespace engine { namespace meta { @@ -124,4 +123,3 @@ using MetaPtr = std::shared_ptr; } // namespace meta } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/db/meta/MetaConsts.h b/cpp/src/db/meta/MetaConsts.h index 64cfeab78a83befaa5a92b5d3b48b4928bf368a5..e963a63f43ae89fa4b23277caeff06eed8fdbfa4 100644 --- a/cpp/src/db/meta/MetaConsts.h +++ b/cpp/src/db/meta/MetaConsts.h @@ -17,7 +17,6 @@ #pragma once -namespace zilliz { namespace milvus { namespace engine { namespace meta { @@ -41,4 +40,3 @@ const size_t W_SEC = 7 * D_SEC; } // namespace meta } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/db/meta/MetaFactory.cpp b/cpp/src/db/meta/MetaFactory.cpp index d8beecbd4eae0a12b2604532afe9fe3e0640900f..8031038e3701861b0f36bf52d6c0c8a89e911c73 100644 --- a/cpp/src/db/meta/MetaFactory.cpp +++ b/cpp/src/db/meta/MetaFactory.cpp @@ -30,7 +30,6 @@ #include #include -namespace zilliz { namespace milvus { namespace engine { @@ -75,4 +74,3 @@ MetaFactory::Build(const DBMetaOptions& metaOptions, const int& mode) { } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/db/meta/MetaFactory.h b/cpp/src/db/meta/MetaFactory.h index 0792515ac1683d61b8a3a0882011f228469eb72d..f16584426ed42af0a9e2d4f67b8e26451ba6b37e 100644 --- a/cpp/src/db/meta/MetaFactory.h +++ b/cpp/src/db/meta/MetaFactory.h @@ -22,7 +22,6 @@ #include -namespace zilliz { namespace milvus { namespace engine { @@ -37,4 +36,3 @@ class MetaFactory { } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/db/meta/MetaTypes.h b/cpp/src/db/meta/MetaTypes.h index aad8b61c876d93d87b982cc96b8e3c88473a9d66..c973f3fdeae40f18984d8a5ee937ee558771080d 100644 --- a/cpp/src/db/meta/MetaTypes.h +++ b/cpp/src/db/meta/MetaTypes.h @@ -25,7 +25,6 @@ #include #include -namespace zilliz { namespace milvus { namespace engine { namespace meta { @@ -96,4 +95,3 @@ using DatePartionedTableFilesSchema = std::map; } // namespace meta } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/db/meta/MySQLConnectionPool.cpp b/cpp/src/db/meta/MySQLConnectionPool.cpp index 6c9312010790cab25e9cf5ba67b0405c12cb30f4..ef013dce95a3f17ac63a4adba5fe3b70a2666df6 100644 --- a/cpp/src/db/meta/MySQLConnectionPool.cpp +++ b/cpp/src/db/meta/MySQLConnectionPool.cpp @@ -17,7 +17,6 @@ #include "db/meta/MySQLConnectionPool.h" -namespace zilliz { namespace milvus { namespace engine { namespace meta { @@ -95,4 +94,3 @@ MySQLConnectionPool::max_idle_time() { } // namespace meta } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/db/meta/MySQLConnectionPool.h b/cpp/src/db/meta/MySQLConnectionPool.h index 9c6b751d1ef474700321cb534869c4fdfb90a27d..60e353c3c48e3c134301632470228dd53b2e483c 100644 --- a/cpp/src/db/meta/MySQLConnectionPool.h +++ b/cpp/src/db/meta/MySQLConnectionPool.h @@ -23,7 +23,6 @@ #include "utils/Log.h" -namespace zilliz { namespace milvus { namespace engine { namespace meta { @@ -90,4 +89,3 @@ class MySQLConnectionPool : public mysqlpp::ConnectionPool { } // namespace meta } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/db/meta/MySQLMetaImpl.cpp b/cpp/src/db/meta/MySQLMetaImpl.cpp index db93ce9ec6900861c59080ac5ebad3ceddb4987e..872c1ced2e20a5f30c998d7dd27735d6afde158b 100644 --- a/cpp/src/db/meta/MySQLMetaImpl.cpp +++ b/cpp/src/db/meta/MySQLMetaImpl.cpp @@ -38,7 +38,6 @@ #include #include -namespace zilliz { namespace milvus { namespace engine { namespace meta { @@ -1994,4 +1993,3 @@ MySQLMetaImpl::DropAll() { } // namespace meta } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/db/meta/MySQLMetaImpl.h b/cpp/src/db/meta/MySQLMetaImpl.h index 48bdf5b9ab62eb7183b4e558fcde17ddb20473be..7ca66bc992adb80f10fee6a4d2c92a2571e83588 100644 --- a/cpp/src/db/meta/MySQLMetaImpl.h +++ b/cpp/src/db/meta/MySQLMetaImpl.h @@ -27,7 +27,6 @@ #include #include -namespace zilliz { namespace milvus { namespace engine { namespace meta { @@ -143,4 +142,3 @@ class MySQLMetaImpl : public Meta { } // namespace meta } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/db/meta/SqliteMetaImpl.cpp b/cpp/src/db/meta/SqliteMetaImpl.cpp index accad0be7098530e609ba08f4fada49e6da1d13e..dd9bb6fd300bff7dc15470c61ad92c92f0a1b2e8 100644 --- a/cpp/src/db/meta/SqliteMetaImpl.cpp +++ b/cpp/src/db/meta/SqliteMetaImpl.cpp @@ -34,7 +34,7 @@ #include #include -namespace zilliz { + namespace milvus { namespace engine { namespace meta { @@ -1298,4 +1298,4 @@ SqliteMetaImpl::DropAll() { } // namespace meta } // namespace engine } // namespace milvus -} // namespace zilliz + diff --git a/cpp/src/db/meta/SqliteMetaImpl.h b/cpp/src/db/meta/SqliteMetaImpl.h index 70f22db2818e34e55d058e9c7757dd99b29436e2..dc132c41ec5dd3b9e675898b0deaae64a227c5cf 100644 --- a/cpp/src/db/meta/SqliteMetaImpl.h +++ b/cpp/src/db/meta/SqliteMetaImpl.h @@ -24,7 +24,6 @@ #include #include -namespace zilliz { namespace milvus { namespace engine { namespace meta { @@ -138,4 +137,3 @@ class SqliteMetaImpl : public Meta { } // namespace meta } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/grpc/cpp_gen.sh b/cpp/src/grpc/cpp_gen.sh old mode 100755 new mode 100644 diff --git a/cpp/src/main.cpp b/cpp/src/main.cpp index 5d808a7e4c287149597591b5a5756e74f0a821fe..b50eedeabaec2edd6dedeffb805bb07d1628c95b 100644 --- a/cpp/src/main.cpp +++ b/cpp/src/main.cpp @@ -99,14 +99,14 @@ main(int argc, char* argv[]) { } /* Handle Signal */ - signal(SIGHUP, zilliz::milvus::server::SignalUtil::HandleSignal); - signal(SIGINT, zilliz::milvus::server::SignalUtil::HandleSignal); - signal(SIGUSR1, zilliz::milvus::server::SignalUtil::HandleSignal); - signal(SIGSEGV, zilliz::milvus::server::SignalUtil::HandleSignal); - signal(SIGUSR2, zilliz::milvus::server::SignalUtil::HandleSignal); - signal(SIGTERM, zilliz::milvus::server::SignalUtil::HandleSignal); + signal(SIGHUP, milvus::server::SignalUtil::HandleSignal); + signal(SIGINT, milvus::server::SignalUtil::HandleSignal); + signal(SIGUSR1, milvus::server::SignalUtil::HandleSignal); + signal(SIGSEGV, milvus::server::SignalUtil::HandleSignal); + signal(SIGUSR2, milvus::server::SignalUtil::HandleSignal); + signal(SIGTERM, milvus::server::SignalUtil::HandleSignal); - zilliz::milvus::server::Server& server = zilliz::milvus::server::Server::GetInstance(); + milvus::server::Server& server = milvus::server::Server::GetInstance(); server.Init(start_daemonized, pid_filename, config_filename, log_config_file); server.Start(); diff --git a/cpp/src/metrics/MetricBase.h b/cpp/src/metrics/MetricBase.h index 5442b9b71427ee5a0ed6d221105915bb944887ec..eeca45e78923bb60678a0b464f78f0090422b82d 100644 --- a/cpp/src/metrics/MetricBase.h +++ b/cpp/src/metrics/MetricBase.h @@ -22,7 +22,6 @@ #include -namespace zilliz { namespace milvus { namespace server { class MetricsBase { @@ -208,4 +207,3 @@ class MetricsBase { } // namespace server } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/metrics/Metrics.cpp b/cpp/src/metrics/Metrics.cpp index 9a182ce57131ff031866a6396befdfdfb97374ca..51db5555b8760ad945a2779fbd0c23e9ac1c935c 100644 --- a/cpp/src/metrics/Metrics.cpp +++ b/cpp/src/metrics/Metrics.cpp @@ -21,7 +21,6 @@ #include -namespace zilliz { namespace milvus { namespace server { @@ -47,4 +46,3 @@ Metrics::CreateMetricsCollector() { } // namespace server } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/metrics/Metrics.h b/cpp/src/metrics/Metrics.h index f644004f143abff0872328593387323e1437fe1d..c207a50d9e67ec398732b30cc36b784bc1188878 100644 --- a/cpp/src/metrics/Metrics.h +++ b/cpp/src/metrics/Metrics.h @@ -20,7 +20,6 @@ #include "MetricBase.h" #include "db/meta/MetaTypes.h" -namespace zilliz { namespace milvus { namespace server { @@ -255,4 +254,3 @@ class MetricCollector : CollectMetricsBase { } // namespace server } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/metrics/PrometheusMetrics.cpp b/cpp/src/metrics/PrometheusMetrics.cpp index 72b26eb63d298374dfabd66c246c595029bfe2a0..bc1860389f392022eb35cd0b0c8aad4a2787a048 100644 --- a/cpp/src/metrics/PrometheusMetrics.cpp +++ b/cpp/src/metrics/PrometheusMetrics.cpp @@ -24,7 +24,6 @@ #include #include -namespace zilliz { namespace milvus { namespace server { @@ -242,4 +241,3 @@ PrometheusMetrics::GpuCacheUsageGaugeSet() { } // namespace server } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/metrics/PrometheusMetrics.h b/cpp/src/metrics/PrometheusMetrics.h index 9e009186d2b611e94e86ea2582f9b0aeac9f522f..ef60f9a231f97b8dcbb97e984fbaf3920cb25b50 100644 --- a/cpp/src/metrics/PrometheusMetrics.h +++ b/cpp/src/metrics/PrometheusMetrics.h @@ -31,7 +31,6 @@ //#define server::Metrics::GetInstance() server::GetInstance() #define METRICS_MICROSECONDS(a, b) (std::chrono::duration_cast(b - a)).count(); -namespace zilliz { namespace milvus { namespace server { @@ -654,4 +653,3 @@ class PrometheusMetrics : public MetricsBase { } // namespace server } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/metrics/SystemInfo.cpp b/cpp/src/metrics/SystemInfo.cpp index 98822945ca67261376e5edc7b88b358f2bce1020..1414d94eaeb446eab3ee338b4589b6b9df676585 100644 --- a/cpp/src/metrics/SystemInfo.cpp +++ b/cpp/src/metrics/SystemInfo.cpp @@ -25,7 +25,6 @@ #include #include -namespace zilliz { namespace milvus { namespace server { @@ -306,4 +305,3 @@ SystemInfo::Octets() { } // namespace server } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/metrics/SystemInfo.h b/cpp/src/metrics/SystemInfo.h index 7fda0730e61df13f235fb0adb3dfbd2af8708922..0176475232449c2fd5148197c18874af9626ce91 100644 --- a/cpp/src/metrics/SystemInfo.h +++ b/cpp/src/metrics/SystemInfo.h @@ -29,7 +29,6 @@ #include #include -namespace zilliz { namespace milvus { namespace server { @@ -132,4 +131,3 @@ class SystemInfo { } // namespace server } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/Algorithm.cpp b/cpp/src/scheduler/Algorithm.cpp index 48fee94d9caf3dd159596e464bc3081c2de90cd3..44f83742c25633902c5f00a249a4ec8c359d7568 100644 --- a/cpp/src/scheduler/Algorithm.cpp +++ b/cpp/src/scheduler/Algorithm.cpp @@ -21,7 +21,6 @@ #include #include -namespace zilliz { namespace milvus { namespace scheduler { @@ -106,4 +105,3 @@ ShortestPath(const ResourcePtr& src, const ResourcePtr& dest, const ResourceMgrP } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/Algorithm.h b/cpp/src/scheduler/Algorithm.h index ed0f17d762fb2953309d5d746e84d2ffca1100ff..69ff8f3a704fa466d5eddae74fb381a4ef0377e0 100644 --- a/cpp/src/scheduler/Algorithm.h +++ b/cpp/src/scheduler/Algorithm.h @@ -21,7 +21,6 @@ #include #include -namespace zilliz { namespace milvus { namespace scheduler { @@ -31,4 +30,3 @@ ShortestPath(const ResourcePtr& src, const ResourcePtr& dest, const ResourceMgrP } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/Definition.h b/cpp/src/scheduler/Definition.h index c886aafdac75e301d2cbd830d5835434651dab14..162988e90acca5f2682b1f880e08694395f97095 100644 --- a/cpp/src/scheduler/Definition.h +++ b/cpp/src/scheduler/Definition.h @@ -30,7 +30,6 @@ #include "db/engine/ExecutionEngine.h" #include "db/meta/MetaTypes.h" -namespace zilliz { namespace milvus { namespace scheduler { @@ -44,4 +43,3 @@ using MetricType = engine::MetricType; } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/JobMgr.cpp b/cpp/src/scheduler/JobMgr.cpp index 92cf1189fd4d77611aa4400bd7aa1d7d1551170d..25a4932f03ae9ab55c351be5af9cfbbc87bdaf06 100644 --- a/cpp/src/scheduler/JobMgr.cpp +++ b/cpp/src/scheduler/JobMgr.cpp @@ -21,7 +21,6 @@ #include -namespace zilliz { namespace milvus { namespace scheduler { @@ -85,4 +84,3 @@ JobMgr::build_task(const JobPtr& job) { } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/JobMgr.h b/cpp/src/scheduler/JobMgr.h index 66adff18d23cf615b7cce8a7bc1db6220a91bf4e..4340c9e616a6a353913cfcf8596f71c7ed969da0 100644 --- a/cpp/src/scheduler/JobMgr.h +++ b/cpp/src/scheduler/JobMgr.h @@ -31,7 +31,6 @@ #include "job/Job.h" #include "task/Task.h" -namespace zilliz { namespace milvus { namespace scheduler { @@ -72,4 +71,3 @@ using JobMgrPtr = std::shared_ptr; } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/ResourceFactory.cpp b/cpp/src/scheduler/ResourceFactory.cpp index f89e8207e47de7be577a13fc08011a05daed80be..fad8571b61bfe693dcca11991b4ed9b9f232e10f 100644 --- a/cpp/src/scheduler/ResourceFactory.cpp +++ b/cpp/src/scheduler/ResourceFactory.cpp @@ -17,7 +17,6 @@ #include "scheduler/ResourceFactory.h" -namespace zilliz { namespace milvus { namespace scheduler { @@ -37,4 +36,3 @@ ResourceFactory::Create(const std::string& name, const std::string& type, uint64 } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/ResourceFactory.h b/cpp/src/scheduler/ResourceFactory.h index bf663a7db8449467a0ca60b3b123f568b8d6e0e2..3290cb023c9fe48945a9c6db0135e2228118af87 100644 --- a/cpp/src/scheduler/ResourceFactory.h +++ b/cpp/src/scheduler/ResourceFactory.h @@ -25,7 +25,6 @@ #include "resource/GpuResource.h" #include "resource/Resource.h" -namespace zilliz { namespace milvus { namespace scheduler { @@ -38,4 +37,3 @@ class ResourceFactory { } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/ResourceMgr.cpp b/cpp/src/scheduler/ResourceMgr.cpp index ce9fcc9fb9abecf2b705718f90681e910772b9de..9906c71bbead05e1d1753e1636f218a069331953 100644 --- a/cpp/src/scheduler/ResourceMgr.cpp +++ b/cpp/src/scheduler/ResourceMgr.cpp @@ -19,7 +19,6 @@ #include "scheduler/ResourceMgr.h" #include "utils/Log.h" -namespace zilliz { namespace milvus { namespace scheduler { @@ -201,4 +200,3 @@ ResourceMgr::event_process() { } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/ResourceMgr.h b/cpp/src/scheduler/ResourceMgr.h index 531491066f8ac6336d726ccb7c7c98889efecaa2..a81e6c239ff74d9fe620112821d535e7b870f491 100644 --- a/cpp/src/scheduler/ResourceMgr.h +++ b/cpp/src/scheduler/ResourceMgr.h @@ -28,7 +28,6 @@ #include "resource/Resource.h" #include "utils/Log.h" -namespace zilliz { namespace milvus { namespace scheduler { @@ -127,4 +126,3 @@ using ResourceMgrWPtr = std::weak_ptr; } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/SchedInst.cpp b/cpp/src/scheduler/SchedInst.cpp index cdeb834f5711e32e8e75e6d3f16d862e83865203..f17aceb59673b0318d9e1eb44062ca1c71e0ff89 100644 --- a/cpp/src/scheduler/SchedInst.cpp +++ b/cpp/src/scheduler/SchedInst.cpp @@ -26,7 +26,6 @@ #include #include -namespace zilliz { namespace milvus { namespace scheduler { @@ -171,4 +170,3 @@ StopSchedulerService() { } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/SchedInst.h b/cpp/src/scheduler/SchedInst.h index 9947e9f62bbb76bfb2910c9c0b8ccc23a0e14649..dc8e4ed478fb84ac964c5e4b7315c2df1d01a6da 100644 --- a/cpp/src/scheduler/SchedInst.h +++ b/cpp/src/scheduler/SchedInst.h @@ -24,7 +24,6 @@ #include #include -namespace zilliz { namespace milvus { namespace scheduler { @@ -90,4 +89,3 @@ StopSchedulerService(); } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/Scheduler.cpp b/cpp/src/scheduler/Scheduler.cpp index 8272bf621947edfb0421fae080fa45aa23df8810..6963ed3c5f3d9fa3f6706aea581e9458fd8b7d3e 100644 --- a/cpp/src/scheduler/Scheduler.cpp +++ b/cpp/src/scheduler/Scheduler.cpp @@ -23,7 +23,6 @@ #include -namespace zilliz { namespace milvus { namespace scheduler { @@ -139,4 +138,3 @@ Scheduler::OnTaskTableUpdated(const EventPtr& event) { } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/Scheduler.h b/cpp/src/scheduler/Scheduler.h index 58cb4cbce81d5d76374c29eba586a58cbfd7dbe2..1d8af9f4d40e9793445f2c37881269034ac599b4 100644 --- a/cpp/src/scheduler/Scheduler.h +++ b/cpp/src/scheduler/Scheduler.h @@ -28,7 +28,6 @@ #include "resource/Resource.h" #include "utils/Log.h" -namespace zilliz { namespace milvus { namespace scheduler { @@ -133,4 +132,3 @@ using SchedulerPtr = std::shared_ptr; } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/TaskCreator.cpp b/cpp/src/scheduler/TaskCreator.cpp index cfcb0eb448605500ae5a591673fafd9ecdf71bfd..a82328a9bfe558d99eb93ab394ee62cfdb3a258d 100644 --- a/cpp/src/scheduler/TaskCreator.cpp +++ b/cpp/src/scheduler/TaskCreator.cpp @@ -19,7 +19,6 @@ #include "scheduler/tasklabel/BroadcastLabel.h" #include "tasklabel/DefaultLabel.h" -namespace zilliz { namespace milvus { namespace scheduler { @@ -65,4 +64,3 @@ TaskCreator::Create(const DeleteJobPtr& job) { } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/TaskCreator.h b/cpp/src/scheduler/TaskCreator.h index 5ae6a0763a60f5bf806770e207a5e18faf6c4f4b..1c1e98a6154d599f478305eeb3a43052b77a08e8 100644 --- a/cpp/src/scheduler/TaskCreator.h +++ b/cpp/src/scheduler/TaskCreator.h @@ -34,7 +34,6 @@ #include "task/SearchTask.h" #include "task/Task.h" -namespace zilliz { namespace milvus { namespace scheduler { @@ -53,4 +52,3 @@ class TaskCreator { } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/TaskTable.cpp b/cpp/src/scheduler/TaskTable.cpp index db06abd96640f1c4ae60201082c04999df62ba45..0d6742c649f19dbb3c25349bf089d80825970aab 100644 --- a/cpp/src/scheduler/TaskTable.cpp +++ b/cpp/src/scheduler/TaskTable.cpp @@ -23,7 +23,6 @@ #include #include -namespace zilliz { namespace milvus { namespace scheduler { @@ -244,4 +243,3 @@ TaskTable::Dump() { } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/TaskTable.h b/cpp/src/scheduler/TaskTable.h index 80c8438eb1d468a3582ce266d834ddeb1fb9d3c9..35becbe5f8ca23b81e9fa664f5b9508c5f3b60e6 100644 --- a/cpp/src/scheduler/TaskTable.h +++ b/cpp/src/scheduler/TaskTable.h @@ -28,7 +28,6 @@ #include "event/Event.h" #include "task/SearchTask.h" -namespace zilliz { namespace milvus { namespace scheduler { @@ -257,4 +256,3 @@ class TaskTable { } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/Utils.cpp b/cpp/src/scheduler/Utils.cpp index b50fe4adb9d20aa552a2432fca885779a59a8efb..071f152227205f141079c6bb455b269358bf642c 100644 --- a/cpp/src/scheduler/Utils.cpp +++ b/cpp/src/scheduler/Utils.cpp @@ -20,7 +20,6 @@ #include #include -namespace zilliz { namespace milvus { namespace scheduler { @@ -41,4 +40,3 @@ get_num_gpu() { } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/Utils.h b/cpp/src/scheduler/Utils.h index eec5f8ba687ed2b045e6596372eafdc354f05c8a..e999e0fda3d460ac95299720c104d72385f49896 100644 --- a/cpp/src/scheduler/Utils.h +++ b/cpp/src/scheduler/Utils.h @@ -17,7 +17,6 @@ #include -namespace zilliz { namespace milvus { namespace scheduler { @@ -29,4 +28,3 @@ get_num_gpu(); } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/action/Action.h b/cpp/src/scheduler/action/Action.h index b75dc4515f4adad51798f418d66ea94b319b4616..51c788f82f9d4ab91f8e0ffd874bede5efedd4fe 100644 --- a/cpp/src/scheduler/action/Action.h +++ b/cpp/src/scheduler/action/Action.h @@ -22,7 +22,6 @@ #include -namespace zilliz { namespace milvus { namespace scheduler { @@ -47,4 +46,3 @@ class Action { } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/action/PushTaskToNeighbour.cpp b/cpp/src/scheduler/action/PushTaskToNeighbour.cpp index 6fb861c8f3e6ca651613724e25206d09c359e314..22b82864b68cdbc2778cb00405fef5849ba4e59c 100644 --- a/cpp/src/scheduler/action/PushTaskToNeighbour.cpp +++ b/cpp/src/scheduler/action/PushTaskToNeighbour.cpp @@ -21,7 +21,6 @@ #include "Action.h" #include "src/cache/GpuCacheMgr.h" -namespace zilliz { namespace milvus { namespace scheduler { @@ -113,7 +112,7 @@ Action::DefaultLabelTaskScheduler(ResourceMgrWPtr res_mgr, ResourcePtr resource, auto location = index_engine->GetLocation(); for (auto i = 0; i < res_mgr.lock()->GetNumGpuResource(); ++i) { - auto index = zilliz::milvus::cache::GpuCacheMgr::GetInstance(i)->GetIndex(location); + auto index = milvus::cache::GpuCacheMgr::GetInstance(i)->GetIndex(location); if (index != nullptr) { moved = true; auto dest_resource = res_mgr.lock()->GetResource(ResourceType::GPU, i); @@ -178,4 +177,3 @@ Action::SpecifiedResourceLabelTaskScheduler(ResourceMgrWPtr res_mgr, ResourcePtr } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/event/Event.h b/cpp/src/scheduler/event/Event.h index 6d55820248c72b8934119adfb94d2d1296896279..5b1f37fb9962c9a86d4fbce16627c5d58211bdc8 100644 --- a/cpp/src/scheduler/event/Event.h +++ b/cpp/src/scheduler/event/Event.h @@ -21,7 +21,6 @@ #include #include -namespace zilliz { namespace milvus { namespace scheduler { @@ -54,4 +53,3 @@ using EventPtr = std::shared_ptr; } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/event/EventDump.cpp b/cpp/src/scheduler/event/EventDump.cpp index 6cc40ea28ce3ac5ed6cc1bfde533aea419417f45..91e2da369aaf799084e92a390579e18fc6bba622 100644 --- a/cpp/src/scheduler/event/EventDump.cpp +++ b/cpp/src/scheduler/event/EventDump.cpp @@ -21,7 +21,6 @@ #include "StartUpEvent.h" #include "TaskTableUpdatedEvent.h" -namespace zilliz { namespace milvus { namespace scheduler { @@ -57,4 +56,3 @@ operator<<(std::ostream& out, const TaskTableUpdatedEvent& event) { } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/event/FinishTaskEvent.h b/cpp/src/scheduler/event/FinishTaskEvent.h index b593abfe3118c60d64d97bc2add488076f8bfc30..1b2d8f9818baa9c7fcf0eff18ca7bee149327b9b 100644 --- a/cpp/src/scheduler/event/FinishTaskEvent.h +++ b/cpp/src/scheduler/event/FinishTaskEvent.h @@ -24,7 +24,6 @@ #include #include -namespace zilliz { namespace milvus { namespace scheduler { @@ -48,4 +47,3 @@ class FinishTaskEvent : public Event { } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/event/LoadCompletedEvent.h b/cpp/src/scheduler/event/LoadCompletedEvent.h index fa1f34b8c1e3d540c23434ec46ce1bb9acfcd0fa..5a701e0dfc6cd005c8594ba3f425c2f2085161b9 100644 --- a/cpp/src/scheduler/event/LoadCompletedEvent.h +++ b/cpp/src/scheduler/event/LoadCompletedEvent.h @@ -24,7 +24,6 @@ #include #include -namespace zilliz { namespace milvus { namespace scheduler { @@ -48,4 +47,3 @@ class LoadCompletedEvent : public Event { } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/event/StartUpEvent.h b/cpp/src/scheduler/event/StartUpEvent.h index 037bf0f4d03c4110188de742f53f9437c749b94d..c4abb4e27ca85f7cda3fc12423cb9813d8891770 100644 --- a/cpp/src/scheduler/event/StartUpEvent.h +++ b/cpp/src/scheduler/event/StartUpEvent.h @@ -23,7 +23,6 @@ #include #include -namespace zilliz { namespace milvus { namespace scheduler { @@ -43,4 +42,3 @@ class StartUpEvent : public Event { } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/event/TaskTableUpdatedEvent.h b/cpp/src/scheduler/event/TaskTableUpdatedEvent.h index 814b25f056e3d3bf1c105e3db085326eeccd69df..ed64a42d899bcf97edeb0c7d065c8eb7a341a1a9 100644 --- a/cpp/src/scheduler/event/TaskTableUpdatedEvent.h +++ b/cpp/src/scheduler/event/TaskTableUpdatedEvent.h @@ -23,7 +23,6 @@ #include #include -namespace zilliz { namespace milvus { namespace scheduler { @@ -44,4 +43,3 @@ class TaskTableUpdatedEvent : public Event { } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/job/DeleteJob.cpp b/cpp/src/scheduler/job/DeleteJob.cpp index 5fcbb4051372c87b9b9d918ddb27c8e828ad1dca..96a6bb18173eb1cd318d09ad5f9873ce637e474f 100644 --- a/cpp/src/scheduler/job/DeleteJob.cpp +++ b/cpp/src/scheduler/job/DeleteJob.cpp @@ -19,7 +19,6 @@ #include -namespace zilliz { namespace milvus { namespace scheduler { @@ -48,4 +47,3 @@ DeleteJob::ResourceDone() { } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/job/DeleteJob.h b/cpp/src/scheduler/job/DeleteJob.h index 6c2f1e40c7d80c3e9aec508729112349bf7c71c1..4ac48f6913cb1aa3e7cc476fd828cc01fc3a4a96 100644 --- a/cpp/src/scheduler/job/DeleteJob.h +++ b/cpp/src/scheduler/job/DeleteJob.h @@ -30,7 +30,6 @@ #include "Job.h" #include "db/meta/Meta.h" -namespace zilliz { namespace milvus { namespace scheduler { @@ -70,4 +69,3 @@ using DeleteJobPtr = std::shared_ptr; } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/job/Job.h b/cpp/src/scheduler/job/Job.h index ccfa3518f923efba6653abb08499bcb210b1f734..5fe645363fe87f0b5736c3401b48048f560b1e3f 100644 --- a/cpp/src/scheduler/job/Job.h +++ b/cpp/src/scheduler/job/Job.h @@ -27,7 +27,6 @@ #include #include -namespace zilliz { namespace milvus { namespace scheduler { @@ -66,4 +65,3 @@ using JobWPtr = std::weak_ptr; } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/job/SearchJob.cpp b/cpp/src/scheduler/job/SearchJob.cpp index b4d3ef84c26651c30a97f3479beb14586c887840..518e3111c090ad0e7700da47b32ef9a9edb80364 100644 --- a/cpp/src/scheduler/job/SearchJob.cpp +++ b/cpp/src/scheduler/job/SearchJob.cpp @@ -18,12 +18,10 @@ #include "scheduler/job/SearchJob.h" #include "utils/Log.h" -namespace zilliz { namespace milvus { namespace scheduler { -SearchJob::SearchJob(zilliz::milvus::scheduler::JobId id, uint64_t topk, uint64_t nq, uint64_t nprobe, - const float* vectors) +SearchJob::SearchJob(milvus::scheduler::JobId id, uint64_t topk, uint64_t nq, uint64_t nprobe, const float* vectors) : Job(id, JobType::SEARCH), topk_(topk), nq_(nq), nprobe_(nprobe), vectors_(vectors) { } @@ -67,4 +65,3 @@ SearchJob::GetStatus() { } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/job/SearchJob.h b/cpp/src/scheduler/job/SearchJob.h index 7ffb0cd20169b6a4eaf7abf5655de9b60fb2fca0..aed40cd942bfb86748274309bd143b8978881548 100644 --- a/cpp/src/scheduler/job/SearchJob.h +++ b/cpp/src/scheduler/job/SearchJob.h @@ -31,7 +31,6 @@ #include "Job.h" #include "db/meta/MetaTypes.h" -namespace zilliz { namespace milvus { namespace scheduler { @@ -107,4 +106,3 @@ using SearchJobPtr = std::shared_ptr; } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/resource/Connection.h b/cpp/src/scheduler/resource/Connection.h index ac2ac81bf5e6d65ea898042a3a3009e6cacba169..421d32f768a954909a5bff7aec35cd1f95a4e1fb 100644 --- a/cpp/src/scheduler/resource/Connection.h +++ b/cpp/src/scheduler/resource/Connection.h @@ -21,7 +21,6 @@ #include #include -namespace zilliz { namespace milvus { namespace scheduler { @@ -61,4 +60,3 @@ class Connection { } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/resource/CpuResource.cpp b/cpp/src/scheduler/resource/CpuResource.cpp index d1b0e2b8c3ca328efacfe561c8082d6677377ac8..500737a829f2e13b9a7eff1f4505e706943a4174 100644 --- a/cpp/src/scheduler/resource/CpuResource.cpp +++ b/cpp/src/scheduler/resource/CpuResource.cpp @@ -19,7 +19,6 @@ #include -namespace zilliz { namespace milvus { namespace scheduler { @@ -45,4 +44,3 @@ CpuResource::Process(TaskPtr task) { } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/resource/CpuResource.h b/cpp/src/scheduler/resource/CpuResource.h index 562a30637357e2e7995974d60149ec0261a7f03b..e3e4fc383f8a74f9f8b5599c40ba737ac7c3b532 100644 --- a/cpp/src/scheduler/resource/CpuResource.h +++ b/cpp/src/scheduler/resource/CpuResource.h @@ -21,7 +21,6 @@ #include "Resource.h" -namespace zilliz { namespace milvus { namespace scheduler { @@ -47,4 +46,3 @@ class CpuResource : public Resource { } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/resource/DiskResource.cpp b/cpp/src/scheduler/resource/DiskResource.cpp index 08c03d2ef2639b6452cd92afcb4731cdfd045c2f..fe1fc9c8d978b650e05ffd61194f5474875dd2d1 100644 --- a/cpp/src/scheduler/resource/DiskResource.cpp +++ b/cpp/src/scheduler/resource/DiskResource.cpp @@ -20,7 +20,6 @@ #include #include -namespace zilliz { namespace milvus { namespace scheduler { @@ -44,4 +43,3 @@ DiskResource::Process(TaskPtr task) { } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/resource/DiskResource.h b/cpp/src/scheduler/resource/DiskResource.h index d86de49934e18fcdc8dae5e3fa0d1b9de0560646..2346cd115a849ef849d0a249ba53e217d4753374 100644 --- a/cpp/src/scheduler/resource/DiskResource.h +++ b/cpp/src/scheduler/resource/DiskResource.h @@ -21,7 +21,6 @@ #include -namespace zilliz { namespace milvus { namespace scheduler { @@ -47,4 +46,3 @@ class DiskResource : public Resource { } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/resource/GpuResource.cpp b/cpp/src/scheduler/resource/GpuResource.cpp index a28b00bbe55c71e292f860708a28d4ce870ebbd5..20ed73e38c8d2580c042fe6e06bea95672091a5b 100644 --- a/cpp/src/scheduler/resource/GpuResource.cpp +++ b/cpp/src/scheduler/resource/GpuResource.cpp @@ -17,7 +17,6 @@ #include "scheduler/resource/GpuResource.h" -namespace zilliz { namespace milvus { namespace scheduler { @@ -43,4 +42,3 @@ GpuResource::Process(TaskPtr task) { } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/resource/GpuResource.h b/cpp/src/scheduler/resource/GpuResource.h index 33a197aed078a471e49e4c249ac92117b422dff1..e0df03d5a78b6ad9915d39062b9fb3762b84f852 100644 --- a/cpp/src/scheduler/resource/GpuResource.h +++ b/cpp/src/scheduler/resource/GpuResource.h @@ -22,7 +22,6 @@ #include #include -namespace zilliz { namespace milvus { namespace scheduler { @@ -48,4 +47,3 @@ class GpuResource : public Resource { } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/resource/Node.cpp b/cpp/src/scheduler/resource/Node.cpp index 39333cc0721fd6d2801f24e091d2cfa9697d9542..5401c364418d8aa08182010d6b4a6b66095f93d1 100644 --- a/cpp/src/scheduler/resource/Node.cpp +++ b/cpp/src/scheduler/resource/Node.cpp @@ -20,7 +20,6 @@ #include #include -namespace zilliz { namespace milvus { namespace scheduler { @@ -61,4 +60,3 @@ Node::AddNeighbour(const NeighbourNodePtr& neighbour_node, Connection& connectio } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/resource/Node.h b/cpp/src/scheduler/resource/Node.h index 588eef5f2eb2849d97f9bcbf216892c166cb1956..071ee9bab82121954af26040bf2cc9d0ece730af 100644 --- a/cpp/src/scheduler/resource/Node.h +++ b/cpp/src/scheduler/resource/Node.h @@ -25,7 +25,6 @@ #include "Connection.h" #include "scheduler/TaskTable.h" -namespace zilliz { namespace milvus { namespace scheduler { @@ -67,4 +66,3 @@ using NodeWPtr = std::weak_ptr; } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/resource/Resource.cpp b/cpp/src/scheduler/resource/Resource.cpp index 48208a07a5d13f94c5f42501df09262fc52a207a..8fea475d70b834f92aa66e49e33f1f8848ed7940 100644 --- a/cpp/src/scheduler/resource/Resource.cpp +++ b/cpp/src/scheduler/resource/Resource.cpp @@ -21,7 +21,6 @@ #include #include -namespace zilliz { namespace milvus { namespace scheduler { @@ -178,4 +177,3 @@ Resource::executor_function() { } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/resource/Resource.h b/cpp/src/scheduler/resource/Resource.h index 2bffaae5cfb9d7d88f69440c497e1fe79106f755..e8b50fe9af91f922502796e394d4074ce6e8ebff 100644 --- a/cpp/src/scheduler/resource/Resource.h +++ b/cpp/src/scheduler/resource/Resource.h @@ -35,7 +35,6 @@ #include "Connection.h" #include "Node.h" -namespace zilliz { namespace milvus { namespace scheduler { @@ -211,4 +210,3 @@ using ResourceWPtr = std::weak_ptr; } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/resource/TestResource.cpp b/cpp/src/scheduler/resource/TestResource.cpp index dd161172367c3902c8fd01372d3abf599f11b4ae..c8c2fb7537180518b851f34cc3f70c0fac5ef64d 100644 --- a/cpp/src/scheduler/resource/TestResource.cpp +++ b/cpp/src/scheduler/resource/TestResource.cpp @@ -19,7 +19,6 @@ #include -namespace zilliz { namespace milvus { namespace scheduler { @@ -45,4 +44,3 @@ TestResource::Process(TaskPtr task) { } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/resource/TestResource.h b/cpp/src/scheduler/resource/TestResource.h index 45dbe675005c964b571c0f7b4a7c692855a5743e..9bbc5a54d0199d6a1332bc6bc36d83e536eac5b1 100644 --- a/cpp/src/scheduler/resource/TestResource.h +++ b/cpp/src/scheduler/resource/TestResource.h @@ -22,7 +22,6 @@ #include #include -namespace zilliz { namespace milvus { namespace scheduler { @@ -48,4 +47,3 @@ class TestResource : public Resource { } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/task/DeleteTask.cpp b/cpp/src/scheduler/task/DeleteTask.cpp index c6cc33ac8824b9b1b11f349f24699004a9809ff4..480fb860565c001d24c3faa107c98835f88be4bf 100644 --- a/cpp/src/scheduler/task/DeleteTask.cpp +++ b/cpp/src/scheduler/task/DeleteTask.cpp @@ -17,7 +17,6 @@ #include "scheduler/task/DeleteTask.h" -namespace zilliz { namespace milvus { namespace scheduler { @@ -36,4 +35,3 @@ XDeleteTask::Execute() { } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/task/DeleteTask.h b/cpp/src/scheduler/task/DeleteTask.h index 473fee26816b002e9b6fbc2b2bca1b8c9639eeb0..75f0969bff890d29239f6a94307297cc499b619d 100644 --- a/cpp/src/scheduler/task/DeleteTask.h +++ b/cpp/src/scheduler/task/DeleteTask.h @@ -20,7 +20,6 @@ #include "Task.h" #include "scheduler/job/DeleteJob.h" -namespace zilliz { namespace milvus { namespace scheduler { @@ -40,4 +39,3 @@ class XDeleteTask : public Task { } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/task/Path.h b/cpp/src/scheduler/task/Path.h index 2be2a7fc0d20bbecc5df84212404d5693adf29b6..c23db9bb09967382042efa7208cae772397f6d79 100644 --- a/cpp/src/scheduler/task/Path.h +++ b/cpp/src/scheduler/task/Path.h @@ -20,7 +20,6 @@ #include #include -namespace zilliz { namespace milvus { namespace scheduler { @@ -82,4 +81,3 @@ class Path { } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/task/SearchTask.cpp b/cpp/src/scheduler/task/SearchTask.cpp index 02556999159409d096051a320d4d0a3a5c09e324..cf247ca4217662109ba809962e02bcf2d6bf1811 100644 --- a/cpp/src/scheduler/task/SearchTask.cpp +++ b/cpp/src/scheduler/task/SearchTask.cpp @@ -26,7 +26,6 @@ #include #include -namespace zilliz { namespace milvus { namespace scheduler { @@ -374,4 +373,3 @@ XSearchTask::TopkResult(scheduler::ResultSet& result_src, uint64_t topk, bool as } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/task/SearchTask.h b/cpp/src/scheduler/task/SearchTask.h index a89df4637b97a6444c09a1e450b68dc37271690b..3143799715449d76008c6bf94c744761bc9a8559 100644 --- a/cpp/src/scheduler/task/SearchTask.h +++ b/cpp/src/scheduler/task/SearchTask.h @@ -23,7 +23,6 @@ #include -namespace zilliz { namespace milvus { namespace scheduler { @@ -63,4 +62,3 @@ class XSearchTask : public Task { } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/task/Task.h b/cpp/src/scheduler/task/Task.h index da5fb3b3af7a3273ab8b7abe23a1c877b1f6d121..c4b118e0c87a089064b5252b6e261fcf5d83c49b 100644 --- a/cpp/src/scheduler/task/Task.h +++ b/cpp/src/scheduler/task/Task.h @@ -25,7 +25,6 @@ #include #include -namespace zilliz { namespace milvus { namespace scheduler { @@ -93,4 +92,3 @@ class Task { } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/task/TestTask.cpp b/cpp/src/scheduler/task/TestTask.cpp index aba73434673d7be38405593b108f6ed71b3ba7b2..76e814a628b875247fea141b99b5039964c86010 100644 --- a/cpp/src/scheduler/task/TestTask.cpp +++ b/cpp/src/scheduler/task/TestTask.cpp @@ -18,7 +18,6 @@ #include "scheduler/task/TestTask.h" #include "cache/GpuCacheMgr.h" -namespace zilliz { namespace milvus { namespace scheduler { @@ -48,4 +47,3 @@ TestTask::Wait() { } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/task/TestTask.h b/cpp/src/scheduler/task/TestTask.h index 5d96b888aa841366a21e7c1670f9b371e2617b9a..3ad9cb16e13c626a39ecb30a0b8f64e5528c5b45 100644 --- a/cpp/src/scheduler/task/TestTask.h +++ b/cpp/src/scheduler/task/TestTask.h @@ -19,7 +19,6 @@ #include "SearchTask.h" -namespace zilliz { namespace milvus { namespace scheduler { @@ -48,4 +47,3 @@ class TestTask : public XSearchTask { } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/tasklabel/BroadcastLabel.h b/cpp/src/scheduler/tasklabel/BroadcastLabel.h index ed68d3ccc14866952a8752f11a77a911ee7018eb..f0b48afb238772093dd3fa189f9b3288c6d6bf23 100644 --- a/cpp/src/scheduler/tasklabel/BroadcastLabel.h +++ b/cpp/src/scheduler/tasklabel/BroadcastLabel.h @@ -21,7 +21,6 @@ #include -namespace zilliz { namespace milvus { namespace scheduler { @@ -35,4 +34,3 @@ using BroadcastLabelPtr = std::shared_ptr; } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/tasklabel/DefaultLabel.h b/cpp/src/scheduler/tasklabel/DefaultLabel.h index fe7019f655fccd4f95117622c35dfc30cedc1a53..c2157435757cbb41392a498e9dc82964f7506206 100644 --- a/cpp/src/scheduler/tasklabel/DefaultLabel.h +++ b/cpp/src/scheduler/tasklabel/DefaultLabel.h @@ -21,7 +21,6 @@ #include -namespace zilliz { namespace milvus { namespace scheduler { @@ -35,4 +34,3 @@ using DefaultLabelPtr = std::shared_ptr; } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/tasklabel/SpecResLabel.h b/cpp/src/scheduler/tasklabel/SpecResLabel.h index b5bea81b3978a8a042e8255ff3f5fe3e19ad4083..2e42e6c2e999e98f06e1130a2c9f30fc1b2fda3b 100644 --- a/cpp/src/scheduler/tasklabel/SpecResLabel.h +++ b/cpp/src/scheduler/tasklabel/SpecResLabel.h @@ -26,7 +26,6 @@ class Resource; using ResourceWPtr = std::weak_ptr; -namespace zilliz { namespace milvus { namespace scheduler { @@ -55,4 +54,3 @@ using SpecResLabelPtr = std::shared_ptr(); } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/scheduler/tasklabel/TaskLabel.h b/cpp/src/scheduler/tasklabel/TaskLabel.h index 57f486ea89fe233c30724a21b3432921ed466ead..d35ce409ffbcbd4503418d9f321525c8b7f8dfe3 100644 --- a/cpp/src/scheduler/tasklabel/TaskLabel.h +++ b/cpp/src/scheduler/tasklabel/TaskLabel.h @@ -19,7 +19,6 @@ #include -namespace zilliz { namespace milvus { namespace scheduler { @@ -48,4 +47,3 @@ using TaskLabelPtr = std::shared_ptr; } // namespace scheduler } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/server/Config.cpp b/cpp/src/server/Config.cpp index 76ac246c24b4dc387660ee948ff29ad8d1e00b90..5d6a237c1d0970f67adf1d589a0b7fde3593fc8b 100644 --- a/cpp/src/server/Config.cpp +++ b/cpp/src/server/Config.cpp @@ -30,7 +30,6 @@ #include "utils/CommonUtil.h" #include "utils/ValidationUtil.h" -namespace zilliz { namespace milvus { namespace server { @@ -1363,4 +1362,3 @@ Config::SetResourceConfigMode(const std::string& value) { } // namespace server } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/server/Config.h b/cpp/src/server/Config.h index 4e3d563901c595efa9a9eca0916c12e4dd6a46cc..9f6932d26793419abeafe006a4a7af52f3202595 100644 --- a/cpp/src/server/Config.h +++ b/cpp/src/server/Config.h @@ -26,7 +26,6 @@ #include "config/ConfigNode.h" #include "utils/Status.h" -namespace zilliz { namespace milvus { namespace server { @@ -359,4 +358,3 @@ class Config { } // namespace server } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/server/DBWrapper.cpp b/cpp/src/server/DBWrapper.cpp index 713714cadc472ea278cc0169ac851a29bcd8a581..401c494575d57895dfd52417a99950c6857061a7 100644 --- a/cpp/src/server/DBWrapper.cpp +++ b/cpp/src/server/DBWrapper.cpp @@ -26,7 +26,6 @@ #include #include -namespace zilliz { namespace milvus { namespace server { @@ -170,4 +169,3 @@ DBWrapper::StopService() { } // namespace server } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/server/DBWrapper.h b/cpp/src/server/DBWrapper.h index 6adc68dcb3e1c9b4977684f210b41415151c4ea9..08e07c09f62f51690084dfe0a08f14b5035fd9df 100644 --- a/cpp/src/server/DBWrapper.h +++ b/cpp/src/server/DBWrapper.h @@ -22,7 +22,6 @@ #include -namespace zilliz { namespace milvus { namespace server { @@ -59,4 +58,3 @@ class DBWrapper { } // namespace server } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/server/Server.cpp b/cpp/src/server/Server.cpp index 2e06cccf8a2078ee35d67dd79198a54b09190bce..d9aabfc1798c2894950cb2493ba75e78c8081cbc 100644 --- a/cpp/src/server/Server.cpp +++ b/cpp/src/server/Server.cpp @@ -37,7 +37,6 @@ #include "utils/TimeRecorder.h" #include "wrapper/KnowhereResource.h" -namespace zilliz { namespace milvus { namespace server { @@ -264,4 +263,3 @@ Server::StopService() { } // namespace server } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/server/Server.h b/cpp/src/server/Server.h index b86945cef9a125a2673bf5ad7a78bb19e5517fff..658dbf7c3026cd432d98c46010cb8e364659d7a5 100644 --- a/cpp/src/server/Server.h +++ b/cpp/src/server/Server.h @@ -22,7 +22,6 @@ #include #include -namespace zilliz { namespace milvus { namespace server { @@ -65,4 +64,3 @@ class Server { } // namespace server } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/server/grpc_impl/GrpcRequestHandler.cpp b/cpp/src/server/grpc_impl/GrpcRequestHandler.cpp index 6089df6f8e2ce63940758c3679b580a04c52e05d..a9ee3d77d0d0e761284ab6838ab16a0e1aef281b 100644 --- a/cpp/src/server/grpc_impl/GrpcRequestHandler.cpp +++ b/cpp/src/server/grpc_impl/GrpcRequestHandler.cpp @@ -21,7 +21,6 @@ #include -namespace zilliz { namespace milvus { namespace server { namespace grpc { @@ -197,4 +196,3 @@ GrpcRequestHandler::DropIndex(::grpc::ServerContext* context, const ::milvus::gr } // namespace grpc } // namespace server } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/server/grpc_impl/GrpcRequestHandler.h b/cpp/src/server/grpc_impl/GrpcRequestHandler.h index 66ec126371d93519aed2f734884d660bb4658e6c..0decf61500a67689d41f768e47ee1a0d802290b6 100644 --- a/cpp/src/server/grpc_impl/GrpcRequestHandler.h +++ b/cpp/src/server/grpc_impl/GrpcRequestHandler.h @@ -23,7 +23,6 @@ #include "grpc/gen-milvus/milvus.grpc.pb.h" #include "grpc/gen-status/status.pb.h" -namespace zilliz { namespace milvus { namespace server { namespace grpc { @@ -324,4 +323,3 @@ class GrpcRequestHandler final : public ::milvus::grpc::MilvusService::Service { } // namespace grpc } // namespace server } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/server/grpc_impl/GrpcRequestScheduler.cpp b/cpp/src/server/grpc_impl/GrpcRequestScheduler.cpp index 9135cd6f6ca087c742465b970860cc091cf444c8..b2aefe4f6593ba6db6f5bc12f236e943a771ac91 100644 --- a/cpp/src/server/grpc_impl/GrpcRequestScheduler.cpp +++ b/cpp/src/server/grpc_impl/GrpcRequestScheduler.cpp @@ -22,7 +22,6 @@ #include -namespace zilliz { namespace milvus { namespace server { namespace grpc { @@ -239,4 +238,3 @@ GrpcRequestScheduler::PutTaskToQueue(const BaseTaskPtr& task_ptr) { } // namespace grpc } // namespace server } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/server/grpc_impl/GrpcRequestScheduler.h b/cpp/src/server/grpc_impl/GrpcRequestScheduler.h index d38f4c67ac16fb51ebd83daa48dd63f15c6fa9c0..802d247fb5bbfb9d4becdaf3018b17f3e2cef49a 100644 --- a/cpp/src/server/grpc_impl/GrpcRequestScheduler.h +++ b/cpp/src/server/grpc_impl/GrpcRequestScheduler.h @@ -28,7 +28,6 @@ #include #include -namespace zilliz { namespace milvus { namespace server { namespace grpc { @@ -130,4 +129,3 @@ class GrpcRequestScheduler { } // namespace grpc } // namespace server } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/server/grpc_impl/GrpcRequestTask.cpp b/cpp/src/server/grpc_impl/GrpcRequestTask.cpp index 241e24e8f676ea759550a4c32e2a14d207e6da70..9f0b8fd95d1c7778aa2d69b183dba7b467c55982 100644 --- a/cpp/src/server/grpc_impl/GrpcRequestTask.cpp +++ b/cpp/src/server/grpc_impl/GrpcRequestTask.cpp @@ -34,7 +34,6 @@ #include "utils/TimeRecorder.h" #include "utils/ValidationUtil.h" -namespace zilliz { namespace milvus { namespace server { namespace grpc { @@ -43,8 +42,8 @@ static const char* DQL_TASK_GROUP = "dql"; static const char* DDL_DML_TASK_GROUP = "ddl_dml"; static const char* PING_TASK_GROUP = "ping"; -using DB_META = zilliz::milvus::engine::meta::Meta; -using DB_DATE = zilliz::milvus::engine::meta::DateT; +using DB_META = milvus::engine::meta::Meta; +using DB_DATE = milvus::engine::meta::DateT; namespace { engine::EngineType @@ -934,4 +933,3 @@ DropIndexTask::OnExecute() { } // namespace grpc } // namespace server } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/server/grpc_impl/GrpcRequestTask.h b/cpp/src/server/grpc_impl/GrpcRequestTask.h index af5ed2bc80168179ec121a80cdeb1fe18c59da1a..ad2828ebf3471b3ed028abe586dd7b6b1907a577 100644 --- a/cpp/src/server/grpc_impl/GrpcRequestTask.h +++ b/cpp/src/server/grpc_impl/GrpcRequestTask.h @@ -29,7 +29,6 @@ #include #include -namespace zilliz { namespace milvus { namespace server { namespace grpc { @@ -271,4 +270,3 @@ class DropIndexTask : public GrpcBaseTask { } // namespace grpc } // namespace server } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/server/grpc_impl/GrpcServer.cpp b/cpp/src/server/grpc_impl/GrpcServer.cpp index dd7895c6794c40f64d6614633844e236c0b261f8..5e0c5f3169bc2a026bcf7104bc5456e46da5eea2 100644 --- a/cpp/src/server/grpc_impl/GrpcServer.cpp +++ b/cpp/src/server/grpc_impl/GrpcServer.cpp @@ -36,7 +36,6 @@ #include #include -namespace zilliz { namespace milvus { namespace server { namespace grpc { @@ -119,4 +118,3 @@ GrpcServer::StopService() { } // namespace grpc } // namespace server } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/server/grpc_impl/GrpcServer.h b/cpp/src/server/grpc_impl/GrpcServer.h index 9f3f8279364c4cde7bed55d39f550ae1f99e3fba..aeaf9f0dcaf406a62ee716f5aac57f04a7feef53 100644 --- a/cpp/src/server/grpc_impl/GrpcServer.h +++ b/cpp/src/server/grpc_impl/GrpcServer.h @@ -25,7 +25,6 @@ #include #include -namespace zilliz { namespace milvus { namespace server { namespace grpc { @@ -60,4 +59,3 @@ class GrpcServer { } // namespace grpc } // namespace server } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/utils/BlockingQueue.h b/cpp/src/utils/BlockingQueue.h index 422f170cd615579b849c7a9d933971fe599d55ad..dc7968fcb6eb10e5448fcf05f4de6e654bba2261 100644 --- a/cpp/src/utils/BlockingQueue.h +++ b/cpp/src/utils/BlockingQueue.h @@ -23,7 +23,6 @@ #include #include -namespace zilliz { namespace milvus { namespace server { @@ -69,6 +68,5 @@ class BlockingQueue { } // namespace server } // namespace milvus -} // namespace zilliz #include "./BlockingQueue.inl" diff --git a/cpp/src/utils/BlockingQueue.inl b/cpp/src/utils/BlockingQueue.inl index ed15aac77a0597b7c16ba83d6f6e17fbfaaff005..c4318c5fc631ea82b6eaf8bf048bc0f489dfcd74 100644 --- a/cpp/src/utils/BlockingQueue.inl +++ b/cpp/src/utils/BlockingQueue.inl @@ -18,7 +18,7 @@ #pragma once -namespace zilliz { + namespace milvus { namespace server { @@ -94,5 +94,5 @@ BlockingQueue::SetCapacity(const size_t capacity) { } // namespace server } // namespace milvus -} // namespace zilliz + diff --git a/cpp/src/utils/CommonUtil.cpp b/cpp/src/utils/CommonUtil.cpp index 14ed34481f39e0a31640aa68f8459b0e75ec57ba..fbf3112aeb29b80e6e228fc322ab09f8b5d1df94 100644 --- a/cpp/src/utils/CommonUtil.cpp +++ b/cpp/src/utils/CommonUtil.cpp @@ -38,7 +38,6 @@ #define THREAD_MULTIPLY_CPU 1 #endif -namespace zilliz { namespace milvus { namespace server { @@ -225,4 +224,3 @@ CommonUtil::ConvertTime(tm time_struct, time_t& time_integer) { } // namespace server } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/utils/CommonUtil.h b/cpp/src/utils/CommonUtil.h index 58ac41ecb1ee4b0c7e73ee95c7006c2bbe090482..939bdd6d31e8ee46ead21b70bafbc930c17be9d8 100644 --- a/cpp/src/utils/CommonUtil.h +++ b/cpp/src/utils/CommonUtil.h @@ -22,7 +22,6 @@ #include #include -namespace zilliz { namespace milvus { namespace server { @@ -61,4 +60,3 @@ class CommonUtil { } // namespace server } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/utils/Error.h b/cpp/src/utils/Error.h index 59e9015afb04f99e5ff1c5b3d53197b08e6f24d2..81403947c85a54a7f54c14a680fe235b7520c5e2 100644 --- a/cpp/src/utils/Error.h +++ b/cpp/src/utils/Error.h @@ -21,7 +21,6 @@ #include #include -namespace zilliz { namespace milvus { using ErrorCode = int32_t; @@ -123,4 +122,3 @@ class ServerException : public std::exception { } // namespace server } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/utils/Exception.h b/cpp/src/utils/Exception.h index 2ca61c4884842c0f793895662ce79692410bda46..a2d8473fa37e9053754e69c7005cc6d9a308cbf5 100644 --- a/cpp/src/utils/Exception.h +++ b/cpp/src/utils/Exception.h @@ -22,7 +22,6 @@ #include #include -namespace zilliz { namespace milvus { class Exception : public std::exception { @@ -62,4 +61,3 @@ class InvalidArgumentException : public Exception { }; } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/utils/Log.h b/cpp/src/utils/Log.h index 64a8622b73651d7234f8d00e48d2bba76981b96d..1dd116367a22666a4b8cc0f47ff3340108c3e7c1 100644 --- a/cpp/src/utils/Log.h +++ b/cpp/src/utils/Log.h @@ -19,7 +19,6 @@ #include "utils/easylogging++.h" -namespace zilliz { namespace milvus { ///////////////////////////////////////////////////////////////////////////////////////////////// @@ -53,4 +52,3 @@ namespace milvus { #define WRAPPER_LOG_FATAL LOG(FATAL) << WRAPPER_DOMAIN_NAME } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/utils/LogUtil.cpp b/cpp/src/utils/LogUtil.cpp index 32e942bca36c561e25a9a910fe117ec5c46a72b0..ed2e1a446b50f486454cc2171839da1a613d8a99 100644 --- a/cpp/src/utils/LogUtil.cpp +++ b/cpp/src/utils/LogUtil.cpp @@ -21,7 +21,6 @@ #include #include -namespace zilliz { namespace milvus { namespace server { @@ -95,4 +94,3 @@ InitLog(const std::string& log_config_file) { } // namespace server } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/utils/LogUtil.h b/cpp/src/utils/LogUtil.h index eb396f266e73a5e572c5648c4559bf2ed9d0aa7a..9926939442385511b27f42acfb4bd39fa6fad439 100644 --- a/cpp/src/utils/LogUtil.h +++ b/cpp/src/utils/LogUtil.h @@ -23,7 +23,6 @@ #include #include -namespace zilliz { namespace milvus { namespace server { @@ -35,11 +34,10 @@ RolloutHandler(const char* filename, std::size_t size, el::Level level); #define SHOW_LOCATION #ifdef SHOW_LOCATION -#define LOCATION_INFO "[" << zilliz::sql::server::GetFileName(__FILE__) << ":" << __LINE__ << "] " +#define LOCATION_INFO "[" << sql::server::GetFileName(__FILE__) << ":" << __LINE__ << "] " #else #define LOCATION_INFO "" #endif } // namespace server } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/utils/SignalUtil.cpp b/cpp/src/utils/SignalUtil.cpp index a01e7573c72aa1a629ba78bbe2ed7d2a98895ab1..5531aaed27f898680e875cdb74bbba496ad2d2f8 100644 --- a/cpp/src/utils/SignalUtil.cpp +++ b/cpp/src/utils/SignalUtil.cpp @@ -23,7 +23,6 @@ #include #include -namespace zilliz { namespace milvus { namespace server { @@ -68,4 +67,3 @@ SignalUtil::PrintStacktrace() { } // namespace server } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/utils/SignalUtil.h b/cpp/src/utils/SignalUtil.h index 414b3203211562ed94ad67edb79e353cae68bdb1..2ecfdecfba0be1f304043be8faef30666bbaee00 100644 --- a/cpp/src/utils/SignalUtil.h +++ b/cpp/src/utils/SignalUtil.h @@ -17,7 +17,6 @@ #pragma once -namespace zilliz { namespace milvus { namespace server { @@ -31,4 +30,3 @@ class SignalUtil { } // namespace server } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/utils/Status.cpp b/cpp/src/utils/Status.cpp index 95132d3a2a45319efa2e6b4115aa639f526c643f..ad97717cf7190422bc6db09e13723bbc5130cbbe 100644 --- a/cpp/src/utils/Status.cpp +++ b/cpp/src/utils/Status.cpp @@ -19,7 +19,6 @@ #include -namespace zilliz { namespace milvus { constexpr int CODE_WIDTH = sizeof(StatusCode); @@ -138,4 +137,3 @@ Status::ToString() const { } } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/utils/Status.h b/cpp/src/utils/Status.h index cb6c134781110d5dd07f59a4a30397ef2130fb94..07a12261bba03b8cea48f8f19ac3e7926b9743a6 100644 --- a/cpp/src/utils/Status.h +++ b/cpp/src/utils/Status.h @@ -21,7 +21,6 @@ #include -namespace zilliz { namespace milvus { using StatusCode = ErrorCode; @@ -75,4 +74,3 @@ class Status { }; // Status } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/utils/StringHelpFunctions.cpp b/cpp/src/utils/StringHelpFunctions.cpp index 444467845f292478786e5a70b1905e66302a2fd8..230cc1a0ff57dcf815aa805c605e3b91f1f42a81 100644 --- a/cpp/src/utils/StringHelpFunctions.cpp +++ b/cpp/src/utils/StringHelpFunctions.cpp @@ -19,7 +19,6 @@ #include -namespace zilliz { namespace milvus { namespace server { @@ -125,4 +124,3 @@ StringHelpFunctions::SplitStringByQuote(const std::string& str, const std::strin } // namespace server } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/utils/StringHelpFunctions.h b/cpp/src/utils/StringHelpFunctions.h index 06615fc74080ae175d96dc9931984ab2aa9cd784..cb355332f115a0c4087d8cbb9cf020567160c911 100644 --- a/cpp/src/utils/StringHelpFunctions.h +++ b/cpp/src/utils/StringHelpFunctions.h @@ -22,7 +22,6 @@ #include #include -namespace zilliz { namespace milvus { namespace server { @@ -61,4 +60,3 @@ class StringHelpFunctions { } // namespace server } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/utils/ThreadPool.h b/cpp/src/utils/ThreadPool.h index db4c9d11ad9457d9400f36cab8f62f54702d5d5f..d605d70018e8606abfed9f83b352ba61276c717e 100644 --- a/cpp/src/utils/ThreadPool.h +++ b/cpp/src/utils/ThreadPool.h @@ -30,7 +30,6 @@ #define MAX_THREADS_NUM 32 -namespace zilliz { namespace milvus { class ThreadPool { @@ -118,4 +117,3 @@ inline ThreadPool::~ThreadPool() { } } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/utils/TimeRecorder.cpp b/cpp/src/utils/TimeRecorder.cpp index cffcbc98efe950749d64c0ca551d062b11a3ac1d..f3061d9d2b5d28d3919342948575460dbc202a67 100644 --- a/cpp/src/utils/TimeRecorder.cpp +++ b/cpp/src/utils/TimeRecorder.cpp @@ -18,7 +18,6 @@ #include "utils/TimeRecorder.h" #include "utils/Log.h" -namespace zilliz { namespace milvus { TimeRecorder::TimeRecorder(const std::string& header, int64_t log_level) : header_(header), log_level_(log_level) { @@ -98,4 +97,3 @@ TimeRecorder::ElapseFromBegin(const std::string& msg) { } } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/utils/TimeRecorder.h b/cpp/src/utils/TimeRecorder.h index 8f795f01c39b97a43f59b18a83e0a1f0bfde027b..cc0a86fbe00a7aa87ee315281942895bac3c516a 100644 --- a/cpp/src/utils/TimeRecorder.h +++ b/cpp/src/utils/TimeRecorder.h @@ -20,7 +20,6 @@ #include #include -namespace zilliz { namespace milvus { class TimeRecorder { @@ -52,4 +51,3 @@ class TimeRecorder { }; } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/utils/ValidationUtil.cpp b/cpp/src/utils/ValidationUtil.cpp index a39427ef1508d088866c20d74624d73c329af33e..248be51088912dc9b956da3d857776420db24063 100644 --- a/cpp/src/utils/ValidationUtil.cpp +++ b/cpp/src/utils/ValidationUtil.cpp @@ -25,7 +25,6 @@ #include #include -namespace zilliz { namespace milvus { namespace server { @@ -290,4 +289,3 @@ ValidationUtil::ValidateDbURI(const std::string& uri) { } // namespace server } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/utils/ValidationUtil.h b/cpp/src/utils/ValidationUtil.h index 415347cec5c862a1b1bfd6fe2f4e3b9f485f8e21..7b24c93fb501f95c2ab9e4360ea271c6768ae15f 100644 --- a/cpp/src/utils/ValidationUtil.h +++ b/cpp/src/utils/ValidationUtil.h @@ -22,7 +22,6 @@ #include -namespace zilliz { namespace milvus { namespace server { @@ -79,4 +78,3 @@ class ValidationUtil { } // namespace server } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/wrapper/ConfAdapter.cpp b/cpp/src/wrapper/ConfAdapter.cpp index 09d219b99923e90ffef7836ee48142c714e0411a..2dcf6bab7e1a0c9ccb354a5bcd46ebce9dffca27 100644 --- a/cpp/src/wrapper/ConfAdapter.cpp +++ b/cpp/src/wrapper/ConfAdapter.cpp @@ -24,7 +24,6 @@ // TODO(lxj): add conf checker -namespace zilliz { namespace milvus { namespace engine { @@ -162,4 +161,3 @@ NSGConfAdapter::MatchSearch(const TempMetaConf& metaconf, const IndexType& type) } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/wrapper/ConfAdapter.h b/cpp/src/wrapper/ConfAdapter.h index e02d76e44185bc5a5a197b08ee86ff95dbb339e1..4c8e528a2d63c8e9898ef0c1c906732e30e21e2f 100644 --- a/cpp/src/wrapper/ConfAdapter.h +++ b/cpp/src/wrapper/ConfAdapter.h @@ -22,7 +22,6 @@ #include -namespace zilliz { namespace milvus { namespace engine { @@ -93,4 +92,3 @@ class NSGConfAdapter : public IVFConfAdapter { } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/wrapper/ConfAdapterMgr.cpp b/cpp/src/wrapper/ConfAdapterMgr.cpp index 4ed80b22b772fcf37e86e45354b0692c97a40d5b..05c23c4238dbfa7a2a1c8a99dc883aa28d5c97f1 100644 --- a/cpp/src/wrapper/ConfAdapterMgr.cpp +++ b/cpp/src/wrapper/ConfAdapterMgr.cpp @@ -18,7 +18,6 @@ #include "wrapper/ConfAdapterMgr.h" #include "utils/Exception.h" -namespace zilliz { namespace milvus { namespace engine { @@ -59,4 +58,3 @@ AdapterMgr::RegisterAdapter() { } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/wrapper/ConfAdapterMgr.h b/cpp/src/wrapper/ConfAdapterMgr.h index 1ac0647c160cbe56a5488fc2794140a93a5e52b8..a88e090760a28b4258da4ec9a0c79913ab816eed 100644 --- a/cpp/src/wrapper/ConfAdapterMgr.h +++ b/cpp/src/wrapper/ConfAdapterMgr.h @@ -23,7 +23,6 @@ #include #include -namespace zilliz { namespace milvus { namespace engine { @@ -55,4 +54,3 @@ class AdapterMgr { } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/wrapper/DataTransfer.cpp b/cpp/src/wrapper/DataTransfer.cpp index ac771c1895369d9c49c964b0f30de39af7102f51..5eb83290d18b259f27506313984eed8833ce4e66 100644 --- a/cpp/src/wrapper/DataTransfer.cpp +++ b/cpp/src/wrapper/DataTransfer.cpp @@ -21,7 +21,6 @@ #include #include -namespace zilliz { namespace milvus { namespace engine { @@ -57,4 +56,3 @@ GenDataset(const int64_t& nb, const int64_t& dim, const float* xb) { } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/wrapper/DataTransfer.h b/cpp/src/wrapper/DataTransfer.h index ad5361c4f5c4e2696ebdcb999fce5b155bc936e2..e945eaa6dbb0f275e19d6edcbc36d634a6b62f5a 100644 --- a/cpp/src/wrapper/DataTransfer.h +++ b/cpp/src/wrapper/DataTransfer.h @@ -19,16 +19,14 @@ #include "knowhere/adapter/Structure.h" -namespace zilliz { namespace milvus { namespace engine { -extern zilliz::knowhere::DatasetPtr +extern knowhere::DatasetPtr GenDatasetWithIds(const int64_t& nb, const int64_t& dim, const float* xb, const int64_t* ids); -extern zilliz::knowhere::DatasetPtr +extern knowhere::DatasetPtr GenDataset(const int64_t& nb, const int64_t& dim, const float* xb); } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/wrapper/KnowhereResource.cpp b/cpp/src/wrapper/KnowhereResource.cpp index 7194ba237402cd241d492260c2c93fb3f1a8614f..d291bb92998bd3d20b1c04351b71af8d2fe7f20e 100644 --- a/cpp/src/wrapper/KnowhereResource.cpp +++ b/cpp/src/wrapper/KnowhereResource.cpp @@ -25,7 +25,6 @@ #include #include -namespace zilliz { namespace milvus { namespace engine { @@ -85,4 +84,3 @@ KnowhereResource::Finalize() { } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/wrapper/KnowhereResource.h b/cpp/src/wrapper/KnowhereResource.h index 144d632c0750d1e385e81378dd7cd33da3f8b12e..dff8b32c0b90c8e492afcbbbd50b8ac03cc3747d 100644 --- a/cpp/src/wrapper/KnowhereResource.h +++ b/cpp/src/wrapper/KnowhereResource.h @@ -19,7 +19,6 @@ #include "utils/Status.h" -namespace zilliz { namespace milvus { namespace engine { @@ -34,4 +33,3 @@ class KnowhereResource { } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/wrapper/VecImpl.cpp b/cpp/src/wrapper/VecImpl.cpp index 0e90ab135e90739615ece05f6cdb6a0edba7ec8a..a6023052db2e6658e82809ebc9567a76dc8db630 100644 --- a/cpp/src/wrapper/VecImpl.cpp +++ b/cpp/src/wrapper/VecImpl.cpp @@ -28,7 +28,6 @@ * only responible for index combination */ -namespace zilliz { namespace milvus { namespace engine { @@ -115,14 +114,14 @@ VecIndexImpl::Search(const int64_t& nq, const float* xq, float* dist, int64_t* i return Status::OK(); } -zilliz::knowhere::BinarySet +knowhere::BinarySet VecIndexImpl::Serialize() { type = ConvertToCpuIndexType(type); return index_->Serialize(); } Status -VecIndexImpl::Load(const zilliz::knowhere::BinarySet& index_binary) { +VecIndexImpl::Load(const knowhere::BinarySet& index_binary) { index_->Load(index_binary); dim = Dimension(); return Status::OK(); @@ -146,7 +145,7 @@ VecIndexImpl::GetType() { VecIndexPtr VecIndexImpl::CopyToGpu(const int64_t& device_id, const Config& cfg) { // TODO(linxj): exception handle - auto gpu_index = zilliz::knowhere::cloner::CopyCpuToGpu(index_, device_id, cfg); + auto gpu_index = knowhere::cloner::CopyCpuToGpu(index_, device_id, cfg); auto new_index = std::make_shared(gpu_index, ConvertToGpuIndexType(type)); new_index->dim = dim; return new_index; @@ -155,7 +154,7 @@ VecIndexImpl::CopyToGpu(const int64_t& device_id, const Config& cfg) { VecIndexPtr VecIndexImpl::CopyToCpu(const Config& cfg) { // TODO(linxj): exception handle - auto cpu_index = zilliz::knowhere::cloner::CopyGpuToCpu(index_, cfg); + auto cpu_index = knowhere::cloner::CopyGpuToCpu(index_, cfg); auto new_index = std::make_shared(cpu_index, ConvertToCpuIndexType(type)); new_index->dim = dim; return new_index; @@ -259,7 +258,7 @@ IVFMixIndex::BuildAll(const int64_t& nb, const float* xb, const int64_t* ids, co } Status -IVFMixIndex::Load(const zilliz::knowhere::BinarySet& index_binary) { +IVFMixIndex::Load(const knowhere::BinarySet& index_binary) { index_->Load(index_binary); dim = Dimension(); return Status::OK(); @@ -267,4 +266,3 @@ IVFMixIndex::Load(const zilliz::knowhere::BinarySet& index_binary) { } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/wrapper/VecImpl.h b/cpp/src/wrapper/VecImpl.h index fe015424f6b64459f94bcf77e19f9f7a12c0d6a3..2be822084f1e534b9620ccc861aa22f0bf4de75a 100644 --- a/cpp/src/wrapper/VecImpl.h +++ b/cpp/src/wrapper/VecImpl.h @@ -23,13 +23,12 @@ #include #include -namespace zilliz { namespace milvus { namespace engine { class VecIndexImpl : public VecIndex { public: - explicit VecIndexImpl(std::shared_ptr index, const IndexType& type) + explicit VecIndexImpl(std::shared_ptr index, const IndexType& type) : index_(std::move(index)), type(type) { } @@ -55,11 +54,11 @@ class VecIndexImpl : public VecIndex { Status Add(const int64_t& nb, const float* xb, const int64_t* ids, const Config& cfg) override; - zilliz::knowhere::BinarySet + knowhere::BinarySet Serialize() override; Status - Load(const zilliz::knowhere::BinarySet& index_binary) override; + Load(const knowhere::BinarySet& index_binary) override; VecIndexPtr Clone() override; @@ -75,12 +74,12 @@ class VecIndexImpl : public VecIndex { IndexType type = IndexType::INVALID; - std::shared_ptr index_ = nullptr; + std::shared_ptr index_ = nullptr; }; class IVFMixIndex : public VecIndexImpl { public: - explicit IVFMixIndex(std::shared_ptr index, const IndexType& type) + explicit IVFMixIndex(std::shared_ptr index, const IndexType& type) : VecIndexImpl(std::move(index), type) { } @@ -89,12 +88,12 @@ class IVFMixIndex : public VecIndexImpl { const float* xt) override; Status - Load(const zilliz::knowhere::BinarySet& index_binary) override; + Load(const knowhere::BinarySet& index_binary) override; }; class BFIndex : public VecIndexImpl { public: - explicit BFIndex(std::shared_ptr index) + explicit BFIndex(std::shared_ptr index) : VecIndexImpl(std::move(index), IndexType::FAISS_IDMAP) { } @@ -114,4 +113,3 @@ class BFIndex : public VecIndexImpl { } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/wrapper/VecIndex.cpp b/cpp/src/wrapper/VecIndex.cpp index c5ebd684fac846312ac69214ce64ab9ca264ea79..627f3515e4c8ed456cf33e3d1616849b6a76e68d 100644 --- a/cpp/src/wrapper/VecIndex.cpp +++ b/cpp/src/wrapper/VecIndex.cpp @@ -31,7 +31,6 @@ #include -namespace zilliz { namespace milvus { namespace engine { @@ -95,51 +94,51 @@ FileIOWriter::operator()(void* ptr, size_t size) { VecIndexPtr GetVecIndexFactory(const IndexType& type, const Config& cfg) { - std::shared_ptr index; + std::shared_ptr index; auto gpu_device = -1; // TODO(linxj): remove hardcode here switch (type) { case IndexType::FAISS_IDMAP: { - index = std::make_shared(); + index = std::make_shared(); return std::make_shared(index); } case IndexType::FAISS_IVFFLAT_CPU: { - index = std::make_shared(); + index = std::make_shared(); break; } case IndexType::FAISS_IVFFLAT_GPU: { - index = std::make_shared(gpu_device); + index = std::make_shared(gpu_device); break; } case IndexType::FAISS_IVFFLAT_MIX: { - index = std::make_shared(gpu_device); + index = std::make_shared(gpu_device); return std::make_shared(index, IndexType::FAISS_IVFFLAT_MIX); } case IndexType::FAISS_IVFPQ_CPU: { - index = std::make_shared(); + index = std::make_shared(); break; } case IndexType::FAISS_IVFPQ_GPU: { - index = std::make_shared(gpu_device); + index = std::make_shared(gpu_device); break; } case IndexType::SPTAG_KDT_RNT_CPU: { - index = std::make_shared(); + index = std::make_shared(); break; } case IndexType::FAISS_IVFSQ8_MIX: { - index = std::make_shared(gpu_device); + index = std::make_shared(gpu_device); return std::make_shared(index, IndexType::FAISS_IVFSQ8_MIX); } case IndexType::FAISS_IVFSQ8_CPU: { - index = std::make_shared(); + index = std::make_shared(); break; } case IndexType::FAISS_IVFSQ8_GPU: { - index = std::make_shared(gpu_device); + index = std::make_shared(gpu_device); break; } case IndexType::NSG_MIX: { - index = std::make_shared(gpu_device); + index = std::make_shared(gpu_device); break; } default: { return nullptr; } @@ -148,7 +147,7 @@ GetVecIndexFactory(const IndexType& type, const Config& cfg) { } VecIndexPtr -LoadVecIndex(const IndexType& index_type, const zilliz::knowhere::BinarySet& index_binary) { +LoadVecIndex(const IndexType& index_type, const knowhere::BinarySet& index_binary) { auto index = GetVecIndexFactory(index_type); index->Load(index_binary); return index; @@ -267,4 +266,3 @@ ConvertToGpuIndexType(const IndexType& type) { } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/src/wrapper/VecIndex.h b/cpp/src/wrapper/VecIndex.h index 4bc51021ce84937385cba2a016e04bcb90535670..d2088b64ef574dbb690145baf8a79d466dfc1e7e 100644 --- a/cpp/src/wrapper/VecIndex.h +++ b/cpp/src/wrapper/VecIndex.h @@ -24,11 +24,10 @@ #include "knowhere/common/Config.h" #include "utils/Status.h" -namespace zilliz { namespace milvus { namespace engine { -using Config = zilliz::knowhere::Config; +using Config = knowhere::Config; enum class IndexType { INVALID = 0, @@ -82,11 +81,11 @@ class VecIndex { virtual int64_t Count() = 0; - virtual zilliz::knowhere::BinarySet + virtual knowhere::BinarySet Serialize() = 0; virtual Status - Load(const zilliz::knowhere::BinarySet& index_binary) = 0; + Load(const knowhere::BinarySet& index_binary) = 0; }; extern Status @@ -99,7 +98,7 @@ extern VecIndexPtr GetVecIndexFactory(const IndexType& type, const Config& cfg = Config()); extern VecIndexPtr -LoadVecIndex(const IndexType& index_type, const zilliz::knowhere::BinarySet& index_binary); +LoadVecIndex(const IndexType& index_type, const knowhere::BinarySet& index_binary); extern IndexType ConvertToCpuIndexType(const IndexType& type); @@ -109,4 +108,3 @@ ConvertToGpuIndexType(const IndexType& type); } // namespace engine } // namespace milvus -} // namespace zilliz diff --git a/cpp/unittest/db/test_db.cpp b/cpp/unittest/db/test_db.cpp index 0bb74437b013bc840ba4f4c523598d34f04bb883..413e192335edf9ffbc6f4e595953ddf48262787f 100644 --- a/cpp/unittest/db/test_db.cpp +++ b/cpp/unittest/db/test_db.cpp @@ -30,7 +30,7 @@ namespace { -namespace ms = zilliz::milvus; +namespace ms = milvus; static const char *TABLE_NAME = "test_group"; static constexpr int64_t TABLE_DIM = 256; @@ -81,11 +81,11 @@ ConvertTimeRangeToDBDates(const std::string &start_value, time_t tt_start, tt_end; tm tm_start, tm_end; - if (!zilliz::milvus::server::CommonUtil::TimeStrToTime(start_value, tt_start, tm_start)) { + if (!milvus::server::CommonUtil::TimeStrToTime(start_value, tt_start, tm_start)) { return; } - if (!zilliz::milvus::server::CommonUtil::TimeStrToTime(end_value, tt_end, tm_end)) { + if (!milvus::server::CommonUtil::TimeStrToTime(end_value, tt_end, tm_end)) { return; } @@ -98,7 +98,7 @@ ConvertTimeRangeToDBDates(const std::string &start_value, for (int64_t i = 0; i < days; i++) { time_t tt_day = tt_start + DAY_SECONDS * i; tm tm_day; - zilliz::milvus::server::CommonUtil::ConvertTime(tt_day, tm_day); + milvus::server::CommonUtil::ConvertTime(tt_day, tm_day); int64_t date = tm_day.tm_year * 10000 + tm_day.tm_mon * 100 + tm_day.tm_mday;//according to db logic diff --git a/cpp/unittest/db/test_db_mysql.cpp b/cpp/unittest/db/test_db_mysql.cpp index 2a7456785e638169a86329ad1512abcb24d45399..89d92c1e065bd790944953a2021baaa2f4f9a5cb 100644 --- a/cpp/unittest/db/test_db_mysql.cpp +++ b/cpp/unittest/db/test_db_mysql.cpp @@ -28,7 +28,7 @@ namespace { -namespace ms = zilliz::milvus; +namespace ms = milvus; static const char *TABLE_NAME = "test_group"; static constexpr int64_t TABLE_DIM = 256; diff --git a/cpp/unittest/db/test_engine.cpp b/cpp/unittest/db/test_engine.cpp index 517b2fd506389618cec3502829c12156d4ff793d..40afbb38f9c4e02cc47dbcc97d2044d978e0dab0 100644 --- a/cpp/unittest/db/test_engine.cpp +++ b/cpp/unittest/db/test_engine.cpp @@ -25,7 +25,7 @@ namespace { -namespace ms = zilliz::milvus; +namespace ms = milvus; } diff --git a/cpp/unittest/db/test_mem.cpp b/cpp/unittest/db/test_mem.cpp index 93500acce7bc6104160a4ba1eea9d9f0e7588270..a99631155e971a448550cf14d995d91fed15052b 100644 --- a/cpp/unittest/db/test_mem.cpp +++ b/cpp/unittest/db/test_mem.cpp @@ -37,7 +37,7 @@ namespace { -namespace ms = zilliz::milvus; +namespace ms = milvus; static constexpr int64_t TABLE_DIM = 256; diff --git a/cpp/unittest/db/test_meta.cpp b/cpp/unittest/db/test_meta.cpp index 39217ea298e06fa8490e694dd0231c94530c7506..b8eb690462ed3d0299792f42ff9ca849df1755ce 100644 --- a/cpp/unittest/db/test_meta.cpp +++ b/cpp/unittest/db/test_meta.cpp @@ -27,7 +27,7 @@ namespace { -namespace ms = zilliz::milvus; +namespace ms = milvus; } // namespace diff --git a/cpp/unittest/db/test_meta_mysql.cpp b/cpp/unittest/db/test_meta_mysql.cpp index 5605b9eb14455c2f091b4fe45eb2e2647f494f3a..c1d33a17a4bf38ce628422242048f1fe81c112f7 100644 --- a/cpp/unittest/db/test_meta_mysql.cpp +++ b/cpp/unittest/db/test_meta_mysql.cpp @@ -29,7 +29,7 @@ namespace { -namespace ms = zilliz::milvus; +namespace ms = milvus; } diff --git a/cpp/unittest/db/test_misc.cpp b/cpp/unittest/db/test_misc.cpp index d6b024930ffcaed87862e5087c005db48954d2ce..18cca45b4b913b1b5e4364cbe3aceeb35e4e736f 100644 --- a/cpp/unittest/db/test_misc.cpp +++ b/cpp/unittest/db/test_misc.cpp @@ -29,7 +29,7 @@ namespace { -namespace ms = zilliz::milvus; +namespace ms = milvus; } // namespace diff --git a/cpp/unittest/db/test_search.cpp b/cpp/unittest/db/test_search.cpp index d0d55a11c6abb3d618c784cb4ac2dcaf1fe2ef8d..12fc8e277a608c5bd90668ef30ef85ab41f8a418 100644 --- a/cpp/unittest/db/test_search.cpp +++ b/cpp/unittest/db/test_search.cpp @@ -24,7 +24,7 @@ namespace { -namespace ms = zilliz::milvus; +namespace ms = milvus; static constexpr uint64_t NQ = 15; static constexpr uint64_t TOP_K = 64; diff --git a/cpp/unittest/db/utils.cpp b/cpp/unittest/db/utils.cpp index 2ad7c4f743ad6de64a8877ea74f43936ea34526b..61c75a09338013f7f73b7a0af44a4fb52282750b 100644 --- a/cpp/unittest/db/utils.cpp +++ b/cpp/unittest/db/utils.cpp @@ -33,7 +33,7 @@ INITIALIZE_EASYLOGGINGPP namespace { -namespace ms = zilliz::milvus; +namespace ms = milvus; class DBTestEnvironment : public ::testing::Environment { public: @@ -73,14 +73,14 @@ void BaseTest::SetUp() { InitLog(); - zilliz::knowhere::FaissGpuResourceMgr::GetInstance().InitDevice(0, 1024 * 1024 * 200, 1024 * 1024 * 300, 2); + knowhere::FaissGpuResourceMgr::GetInstance().InitDevice(0, 1024 * 1024 * 200, 1024 * 1024 * 300, 2); } void BaseTest::TearDown() { - zilliz::milvus::cache::CpuCacheMgr::GetInstance()->ClearCache(); - zilliz::milvus::cache::GpuCacheMgr::GetInstance(0)->ClearCache(); - zilliz::knowhere::FaissGpuResourceMgr::GetInstance().Free(); + milvus::cache::CpuCacheMgr::GetInstance()->ClearCache(); + milvus::cache::GpuCacheMgr::GetInstance(0)->ClearCache(); + knowhere::FaissGpuResourceMgr::GetInstance().Free(); } ms::engine::DBOptions diff --git a/cpp/unittest/db/utils.h b/cpp/unittest/db/utils.h index dee9dcf84339adefb56a64f06b1a1745f5b055ab..8da160dc92fc60a8ae93b8c0f60d46b8ae6606e6 100644 --- a/cpp/unittest/db/utils.h +++ b/cpp/unittest/db/utils.h @@ -48,13 +48,13 @@ class BaseTest : public ::testing::Test { void SetUp() override; void TearDown() override; - virtual zilliz::milvus::engine::DBOptions GetOptions(); + virtual milvus::engine::DBOptions GetOptions(); }; ///////////////////////////////////////////////////////////////////////////////////////////////////////////////// class DBTest : public BaseTest { protected: - zilliz::milvus::engine::DBPtr db_; + milvus::engine::DBPtr db_; void SetUp() override; void TearDown() override; @@ -63,7 +63,7 @@ class DBTest : public BaseTest { ///////////////////////////////////////////////////////////////////////////////////////////////////////////////// class DBTest2 : public DBTest { protected: - zilliz::milvus::engine::DBOptions GetOptions() override; + milvus::engine::DBOptions GetOptions() override; }; ///////////////////////////////////////////////////////////////////////////////////////////////////////////////// @@ -73,7 +73,7 @@ class EngineTest : public DBTest { ///////////////////////////////////////////////////////////////////////////////////////////////////////////////// class MetaTest : public BaseTest { protected: - std::shared_ptr impl_; + std::shared_ptr impl_; void SetUp() override; void TearDown() override; @@ -82,17 +82,17 @@ class MetaTest : public BaseTest { ///////////////////////////////////////////////////////////////////////////////////////////////////////////////// class MySqlDBTest : public DBTest { protected: - zilliz::milvus::engine::DBOptions GetOptions() override; + milvus::engine::DBOptions GetOptions() override; }; ///////////////////////////////////////////////////////////////////////////////////////////////////////////////// class MySqlMetaTest : public BaseTest { protected: - std::shared_ptr impl_; + std::shared_ptr impl_; void SetUp() override; void TearDown() override; - zilliz::milvus::engine::DBOptions GetOptions() override; + milvus::engine::DBOptions GetOptions() override; }; ///////////////////////////////////////////////////////////////////////////////////////////////////////////////// diff --git a/cpp/unittest/metrics/test_metricbase.cpp b/cpp/unittest/metrics/test_metricbase.cpp index 7f7731248011b67654f6007da3f718d869e4975e..4edb3b81515eeac45181a20780af9f1c3da4e16a 100644 --- a/cpp/unittest/metrics/test_metricbase.cpp +++ b/cpp/unittest/metrics/test_metricbase.cpp @@ -23,7 +23,7 @@ namespace { -namespace ms = zilliz::milvus; +namespace ms = milvus; } // namespace diff --git a/cpp/unittest/metrics/test_metrics.cpp b/cpp/unittest/metrics/test_metrics.cpp index ec950fedcc923f747acf61b7013cf7f2a68643de..ba0b51af00b6ef950af36087b3582bd2a830bcae 100644 --- a/cpp/unittest/metrics/test_metrics.cpp +++ b/cpp/unittest/metrics/test_metrics.cpp @@ -31,7 +31,7 @@ namespace { -namespace ms = zilliz::milvus; +namespace ms = milvus; } // namespace @@ -47,8 +47,8 @@ TEST_F(MetricTest, METRIC_TEST) { ms::server::Metrics::GetInstance().Init(); // server::PrometheusMetrics::GetInstance().exposer_ptr()->RegisterCollectable(server::PrometheusMetrics::GetInstance().registry_ptr()); - zilliz::milvus::cache::CpuCacheMgr::GetInstance()->SetCapacity(1UL * 1024 * 1024 * 1024); - std::cout << zilliz::milvus::cache::CpuCacheMgr::GetInstance()->CacheCapacity() << std::endl; + milvus::cache::CpuCacheMgr::GetInstance()->SetCapacity(1UL * 1024 * 1024 * 1024); + std::cout << milvus::cache::CpuCacheMgr::GetInstance()->CacheCapacity() << std::endl; static const char *group_name = "test_group"; static const int group_dim = 256; diff --git a/cpp/unittest/metrics/test_prometheus.cpp b/cpp/unittest/metrics/test_prometheus.cpp index 4847e6162797dc3b2cff38f0a45613383c424db8..14982d058d154bf248bc352068af65eb43107d41 100644 --- a/cpp/unittest/metrics/test_prometheus.cpp +++ b/cpp/unittest/metrics/test_prometheus.cpp @@ -24,7 +24,7 @@ namespace { -namespace ms = zilliz::milvus; +namespace ms = milvus; } // namespace diff --git a/cpp/unittest/metrics/utils.cpp b/cpp/unittest/metrics/utils.cpp index 82752227664f3315a8ebbf3075a5772b8619b8ae..c2a53babc3e881775885adb365710eb1989aaf2c 100644 --- a/cpp/unittest/metrics/utils.cpp +++ b/cpp/unittest/metrics/utils.cpp @@ -28,7 +28,7 @@ INITIALIZE_EASYLOGGINGPP namespace { -namespace ms = zilliz::milvus; +namespace ms = milvus; class DBTestEnvironment : public ::testing::Environment { public: diff --git a/cpp/unittest/metrics/utils.h b/cpp/unittest/metrics/utils.h index 3daeeb8fa6c42efe287acc5dbbe148007c565599..996dec89f59e97a4119b25b5ea4f7a296f0006a4 100644 --- a/cpp/unittest/metrics/utils.h +++ b/cpp/unittest/metrics/utils.h @@ -41,7 +41,7 @@ #endif void -ASSERT_STATS(zilliz::milvus::Status &stat); +ASSERT_STATS(milvus::Status &stat); //class TestEnv : public ::testing::Environment { //public: @@ -66,10 +66,10 @@ ASSERT_STATS(zilliz::milvus::Status &stat); class MetricTest : public ::testing::Test { protected: - zilliz::milvus::engine::DBPtr db_; + milvus::engine::DBPtr db_; void InitLog(); void SetUp() override; void TearDown() override; - virtual zilliz::milvus::engine::DBOptions GetOptions(); + virtual milvus::engine::DBOptions GetOptions(); }; diff --git a/cpp/unittest/scheduler/task_test.cpp b/cpp/unittest/scheduler/task_test.cpp index d4bb0318da1792daf8ea2b074c1b5555c13283e9..ce91a62a521a56743eab951519d5effd00f1a322 100644 --- a/cpp/unittest/scheduler/task_test.cpp +++ b/cpp/unittest/scheduler/task_test.cpp @@ -19,7 +19,7 @@ #include "scheduler/task/SearchTask.h" #include -namespace zilliz { + namespace milvus { namespace scheduler { @@ -30,5 +30,5 @@ TEST(TaskTest, INVALID_INDEX) { } // namespace scheduler } // namespace milvus -} // namespace zilliz + diff --git a/cpp/unittest/scheduler/test_algorithm.cpp b/cpp/unittest/scheduler/test_algorithm.cpp index 56574a74636e24e4d2d85e9ab703145571187559..bcb90873735e3b361e44bf83ec70ac9322a91e6b 100644 --- a/cpp/unittest/scheduler/test_algorithm.cpp +++ b/cpp/unittest/scheduler/test_algorithm.cpp @@ -24,7 +24,7 @@ #include "scheduler/ResourceFactory.h" #include "scheduler/Algorithm.h" -namespace zilliz { + namespace milvus { namespace scheduler { @@ -105,4 +105,4 @@ TEST_F(AlgorithmTest, SHORTESTPATH_TEST) { } // namespace scheduler } // namespace milvus -} // namespace zilliz + diff --git a/cpp/unittest/scheduler/test_event.cpp b/cpp/unittest/scheduler/test_event.cpp index 73fffc8f6e345bcedb61a6c946ef45214ee95786..07d51e8557730740614ed5485d4daea6c0489e71 100644 --- a/cpp/unittest/scheduler/test_event.cpp +++ b/cpp/unittest/scheduler/test_event.cpp @@ -23,7 +23,7 @@ #include "scheduler/event/StartUpEvent.h" -namespace zilliz { + namespace milvus { namespace scheduler { @@ -62,5 +62,5 @@ TEST(EventTest, TASKTABLE_UPDATED_EVENT) { } // namespace scheduler } // namespace milvus -} // namespace zilliz + diff --git a/cpp/unittest/scheduler/test_node.cpp b/cpp/unittest/scheduler/test_node.cpp index 3323453f0b181899a55b4f26535cb67b600339de..9b34b73191d25f9f59ec88537c24a1668a87d8af 100644 --- a/cpp/unittest/scheduler/test_node.cpp +++ b/cpp/unittest/scheduler/test_node.cpp @@ -21,7 +21,7 @@ namespace { -namespace ms = zilliz::milvus::scheduler; +namespace ms = milvus::scheduler; } // namespace diff --git a/cpp/unittest/scheduler/test_normal.cpp b/cpp/unittest/scheduler/test_normal.cpp index e24b43c6f83c1ac103b2127b414b61e573c16682..fb59b042148d6bfa0ee0a345f0559a2e292da083 100644 --- a/cpp/unittest/scheduler/test_normal.cpp +++ b/cpp/unittest/scheduler/test_normal.cpp @@ -27,7 +27,7 @@ namespace { -namespace ms = zilliz::milvus::scheduler; +namespace ms = milvus::scheduler; } // namespace diff --git a/cpp/unittest/scheduler/test_resource.cpp b/cpp/unittest/scheduler/test_resource.cpp index b6c522b8b59d9a91ae7dba306c17fe9b16046365..72457613937938334ec810cc3f0859cd1ad94e8e 100644 --- a/cpp/unittest/scheduler/test_resource.cpp +++ b/cpp/unittest/scheduler/test_resource.cpp @@ -26,7 +26,7 @@ #include "scheduler/ResourceFactory.h" #include -namespace zilliz { + namespace milvus { namespace scheduler { @@ -282,4 +282,4 @@ TEST_F(ResourceAdvanceTest, TEST_RESOURCE_TEST) { } // namespace scheduler } // namespace milvus -} // namespace zilliz + diff --git a/cpp/unittest/scheduler/test_resource_factory.cpp b/cpp/unittest/scheduler/test_resource_factory.cpp index 679edc6e3ff6987fc7fc682b314bb5b5b317192d..aaad3aa2c99d63b208778116c4e3d940af77c5e8 100644 --- a/cpp/unittest/scheduler/test_resource_factory.cpp +++ b/cpp/unittest/scheduler/test_resource_factory.cpp @@ -21,7 +21,7 @@ namespace { -namespace ms = zilliz::milvus::scheduler; +namespace ms = milvus::scheduler; } // namespace diff --git a/cpp/unittest/scheduler/test_resource_mgr.cpp b/cpp/unittest/scheduler/test_resource_mgr.cpp index bf8ade9f6448a29b2c30b985e471c705d19d4bc1..40633baa54d9324378e82d12f19acaebf74a12ab 100644 --- a/cpp/unittest/scheduler/test_resource_mgr.cpp +++ b/cpp/unittest/scheduler/test_resource_mgr.cpp @@ -24,7 +24,7 @@ #include "scheduler/ResourceMgr.h" #include -namespace zilliz { + namespace milvus { namespace scheduler { @@ -191,4 +191,4 @@ TEST_F(ResourceMgrAdvanceTest, REGISTER_SUBSCRIBER) { } // namespace scheduler } // namespace milvus -} // namespace zilliz + diff --git a/cpp/unittest/scheduler/test_schedinst.cpp b/cpp/unittest/scheduler/test_schedinst.cpp index 4f3364c8fb84ea8fa99e59fc15253e561fb5eee1..e63a9615bcb37dfaef14987fe515cfc89203d581 100644 --- a/cpp/unittest/scheduler/test_schedinst.cpp +++ b/cpp/unittest/scheduler/test_schedinst.cpp @@ -21,7 +21,7 @@ #include "server/Config.h" #include "scheduler/SchedInst.h" -namespace zilliz { + namespace milvus { namespace scheduler { @@ -83,6 +83,6 @@ TEST_F(SchedInstTest, SIMPLE_GPU) { } // namespace scheduler } // namespace milvus -} // namespace zilliz + diff --git a/cpp/unittest/scheduler/test_scheduler.cpp b/cpp/unittest/scheduler/test_scheduler.cpp index 4acfda315a065c29afb2383d6e119bd2277d7d49..9666cc98124a32d932bb17218561406594612c2f 100644 --- a/cpp/unittest/scheduler/test_scheduler.cpp +++ b/cpp/unittest/scheduler/test_scheduler.cpp @@ -28,7 +28,7 @@ #include "utils/Error.h" #include "wrapper/VecIndex.h" -namespace zilliz { + namespace milvus { namespace scheduler { @@ -43,7 +43,7 @@ class MockVecIndex : public engine::VecIndex { } engine::VecIndexPtr Clone() override { - return zilliz::milvus::engine::VecIndexPtr(); + return milvus::engine::VecIndexPtr(); } int64_t GetDeviceId() override { @@ -81,12 +81,12 @@ class MockVecIndex : public engine::VecIndex { return ntotal_; } - virtual zilliz::knowhere::BinarySet Serialize() { - zilliz::knowhere::BinarySet binset; + virtual knowhere::BinarySet Serialize() { + knowhere::BinarySet binset; return binset; } - virtual Status Load(const zilliz::knowhere::BinarySet &index_binary) { + virtual Status Load(const knowhere::BinarySet &index_binary) { } public: @@ -253,4 +253,4 @@ TEST_F(SchedulerTest2, SPECIFIED_RESOURCE_TEST) { } // namespace scheduler } // namespace milvus -} // namespace zilliz + diff --git a/cpp/unittest/scheduler/test_tasktable.cpp b/cpp/unittest/scheduler/test_tasktable.cpp index 0cb7018023d1f4b78b940fbe913c4207c21a6607..3cfbb5a27fbd941c2101653b4d00a057de55c408 100644 --- a/cpp/unittest/scheduler/test_tasktable.cpp +++ b/cpp/unittest/scheduler/test_tasktable.cpp @@ -22,7 +22,7 @@ namespace { -namespace ms = zilliz::milvus::scheduler; +namespace ms = milvus::scheduler; } // namespace diff --git a/cpp/unittest/server/test_cache.cpp b/cpp/unittest/server/test_cache.cpp index 8fea11fa62d75a019c40b38494fdb27bf28a0a3f..754f23f51be8548e178322df3e2ce06f0587e292 100644 --- a/cpp/unittest/server/test_cache.cpp +++ b/cpp/unittest/server/test_cache.cpp @@ -23,7 +23,7 @@ namespace { -namespace ms = zilliz::milvus; +namespace ms = milvus; class InvalidCacheMgr : public ms::cache::CacheMgr { public: @@ -55,7 +55,7 @@ class MockVecIndex : public ms::engine::VecIndex { } ms::engine::VecIndexPtr Clone() override { - return zilliz::milvus::engine::VecIndexPtr(); + return milvus::engine::VecIndexPtr(); } int64_t GetDeviceId() override { @@ -98,12 +98,12 @@ class MockVecIndex : public ms::engine::VecIndex { return ntotal_; } - virtual zilliz::knowhere::BinarySet Serialize() { - zilliz::knowhere::BinarySet binset; + virtual knowhere::BinarySet Serialize() { + knowhere::BinarySet binset; return binset; } - virtual ms::Status Load(const zilliz::knowhere::BinarySet &index_binary) { + virtual ms::Status Load(const knowhere::BinarySet &index_binary) { return ms::Status(); } @@ -127,7 +127,7 @@ TEST(CacheTest, DUMMY_TEST) { mock_index.CopyToGpu(1, cfg); mock_index.GetDeviceId(); mock_index.GetType(); - zilliz::knowhere::BinarySet index_binary; + knowhere::BinarySet index_binary; mock_index.Load(index_binary); mock_index.Serialize(); } diff --git a/cpp/unittest/server/test_config.cpp b/cpp/unittest/server/test_config.cpp index 0c613d8954bbb10e36f7747e2cf754da51de3a57..ef708a8382e3949875d455b8f803eadcfd4c90d6 100644 --- a/cpp/unittest/server/test_config.cpp +++ b/cpp/unittest/server/test_config.cpp @@ -25,7 +25,7 @@ namespace { -namespace ms = zilliz::milvus; +namespace ms = milvus; static const char *CONFIG_FILE_PATH = "./milvus/conf/server_config.yaml"; static const char *LOG_FILE_PATH = "./milvus/conf/log_config.conf"; diff --git a/cpp/unittest/server/test_rpc.cpp b/cpp/unittest/server/test_rpc.cpp index 3a36e3ee507afcb915f4316845f7e75e10c64307..5baaed3152c41c8e26816c11a2daf332e73138fa 100644 --- a/cpp/unittest/server/test_rpc.cpp +++ b/cpp/unittest/server/test_rpc.cpp @@ -36,7 +36,7 @@ namespace { -namespace ms = zilliz::milvus; +namespace ms = milvus; static const char *TABLE_NAME = "test_grpc"; static constexpr int64_t TABLE_DIM = 256; diff --git a/cpp/unittest/server/util_test.cpp b/cpp/unittest/server/util_test.cpp index 89095193fb6be4ec0b662228a8691c9b1fb97d0b..0ee214a7e7c06787ce822d4a58cb47543c0f5289 100644 --- a/cpp/unittest/server/util_test.cpp +++ b/cpp/unittest/server/util_test.cpp @@ -33,7 +33,7 @@ namespace { -namespace ms = zilliz::milvus; +namespace ms = milvus; static const char *LOG_FILE_PATH = "./milvus/conf/log_config.conf"; diff --git a/cpp/unittest/wrapper/test_wrapper.cpp b/cpp/unittest/wrapper/test_wrapper.cpp index b97b96d2052de071f46165ff90f31ca5366811fb..4dd2e33bd5427dae635a75a9d03625e9d237f1c6 100644 --- a/cpp/unittest/wrapper/test_wrapper.cpp +++ b/cpp/unittest/wrapper/test_wrapper.cpp @@ -27,8 +27,8 @@ INITIALIZE_EASYLOGGINGPP namespace { -namespace ms = zilliz::milvus::engine; -namespace kw = zilliz::knowhere; +namespace ms = milvus::engine; +namespace kw = knowhere; } // namespace @@ -50,41 +50,41 @@ class ParamGenerator { kw::Config Gen(const ms::IndexType &type) { switch (type) { case ms::IndexType::FAISS_IDMAP: { - auto tempconf = std::make_shared(); - tempconf->metric_type = zilliz::knowhere::METRICTYPE::L2; + auto tempconf = std::make_shared(); + tempconf->metric_type = knowhere::METRICTYPE::L2; return tempconf; } case ms::IndexType::FAISS_IVFFLAT_CPU: case ms::IndexType::FAISS_IVFFLAT_GPU: case ms::IndexType::FAISS_IVFFLAT_MIX: { - auto tempconf = std::make_shared(); + auto tempconf = std::make_shared(); tempconf->nlist = 100; tempconf->nprobe = 16; - tempconf->metric_type = zilliz::knowhere::METRICTYPE::L2; + tempconf->metric_type = knowhere::METRICTYPE::L2; return tempconf; } case ms::IndexType::FAISS_IVFSQ8_CPU: case ms::IndexType::FAISS_IVFSQ8_GPU: case ms::IndexType::FAISS_IVFSQ8_MIX: { - auto tempconf = std::make_shared(); + auto tempconf = std::make_shared(); tempconf->nlist = 100; tempconf->nprobe = 16; tempconf->nbits = 8; - tempconf->metric_type = zilliz::knowhere::METRICTYPE::L2; + tempconf->metric_type = knowhere::METRICTYPE::L2; return tempconf; } case ms::IndexType::FAISS_IVFPQ_CPU: case ms::IndexType::FAISS_IVFPQ_GPU: { - auto tempconf = std::make_shared(); + auto tempconf = std::make_shared(); tempconf->nlist = 100; tempconf->nprobe = 16; tempconf->nbits = 8; tempconf->m = 8; - tempconf->metric_type = zilliz::knowhere::METRICTYPE::L2; + tempconf->metric_type = knowhere::METRICTYPE::L2; return tempconf; } case ms::IndexType::NSG_MIX: { - auto tempconf = std::make_shared(); + auto tempconf = std::make_shared(); tempconf->nlist = 100; tempconf->nprobe = 16; tempconf->search_length = 8; @@ -92,7 +92,7 @@ class ParamGenerator { tempconf->search_length = 40; // TODO(linxj): be 20 when search tempconf->out_degree = 60; tempconf->candidate_pool_size = 200; - tempconf->metric_type = zilliz::knowhere::METRICTYPE::L2; + tempconf->metric_type = knowhere::METRICTYPE::L2; return tempconf; } } @@ -103,7 +103,7 @@ class KnowhereWrapperTest : public TestWithParam<::std::tuple> { protected: void SetUp() override { - zilliz::knowhere::FaissGpuResourceMgr::GetInstance().InitDevice(DEVICE_ID, + knowhere::FaissGpuResourceMgr::GetInstance().InitDevice(DEVICE_ID, 1024 * 1024 * 200, 1024 * 1024 * 300, 2); @@ -123,7 +123,7 @@ class KnowhereWrapperTest } void TearDown() override { - zilliz::knowhere::FaissGpuResourceMgr::GetInstance().Free(); + knowhere::FaissGpuResourceMgr::GetInstance().Free(); } void AssertResult(const std::vector &ids, const std::vector &dis) {