From 604d705a0c3c2ab55f6b0f9916fedc18b34af4dc Mon Sep 17 00:00:00 2001 From: Matt Ellis Date: Sat, 6 Apr 2024 22:58:28 -0500 Subject: [PATCH 1/2] Remove unused parameter model name in the _get_model_scrit_db() function. --- include/rediscluster.h | 11 ++++++----- src/cpp/rediscluster.cpp | 11 +++++------ 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/include/rediscluster.h b/include/rediscluster.h index b9bbffaf..04ff496f 100644 --- a/include/rediscluster.h +++ b/include/rediscluster.h @@ -738,16 +738,17 @@ class RedisCluster : public RedisServer std::vector outputs); /*! - * \brief Retrieve the optimum model prefix for - * the set of inputs - * \param name The name of the model + * \brief Retrieve the db node in the cluster that contains + * the most input and output tensors. If multiple + * db nodes contain the same amount of input and + * output tensors, the first db node in the internal + * data structure is returned. * \param inputs The keys of inputs tensors to use * in the model * \param outputs The keys of output tensors that * will be used to save model results */ - DBNode* _get_model_script_db(const std::string& name, - std::vector& inputs, + DBNode* _get_model_script_db(std::vector& inputs, std::vector& outputs); /*! diff --git a/src/cpp/rediscluster.cpp b/src/cpp/rediscluster.cpp index 0b2df126..2813a67b 100644 --- a/src/cpp/rediscluster.cpp +++ b/src/cpp/rediscluster.cpp @@ -1410,14 +1410,13 @@ void RedisCluster::_delete_keys(std::vector keys) (void)run(cmd); } -// Retrieve the optimum model prefix for the set of inputs -DBNode* RedisCluster::_get_model_script_db(const std::string& name, - std::vector& inputs, +// Retrieve the optimum db node for model and script execution +DBNode* RedisCluster::_get_model_script_db(std::vector& inputs, std::vector& outputs) { - /* This function calculates the optimal model name to use - to run the provided inputs. If a cluster is not being used, - the model name is returned, else a prefixed model name is returned. + /* This function determines which db node in the cluster + contains the most input and output tensors and + returns a pointer to that db node. */ // TODO we should randomly choose the max if there are multiple maxes From 13540212dbfcd9cc47f1eb82fc0b6622d17bfbd3 Mon Sep 17 00:00:00 2001 From: Matt Ellis Date: Sat, 6 Apr 2024 23:04:38 -0500 Subject: [PATCH 2/2] Add changelog entry. --- doc/changelog.rst | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/doc/changelog.rst b/doc/changelog.rst index cebe32a2..3e1616c3 100644 --- a/doc/changelog.rst +++ b/doc/changelog.rst @@ -8,16 +8,20 @@ To be released at some future point in time Description +- Remove unused parameter in internal redis cluster method - Update CI for Intel suite - Fix inconsistency in C-API ConfigOptions is_configured() parameters Detailed Notes +- Removes an unused parameter in the RedisCluster::_get_model_script_db() + method. (PR477_) - Version numbers changed for the Intel Compiler chain that lead to the C and C++ compilers not being available. Now, the entirety of the Base and HPC kits are installed to ensure consistent versions. (PR475_) - Fix an inconsistency in the C-API ConfigOptions is_configured() parameter names. (PR471_) +.. _PR477: https://github.com/CrayLabs/SmartRedis/pull/477 .. _PR475: https://github.com/CrayLabs/SmartRedis/pull/475 .. _PR471: https://github.com/CrayLabs/SmartRedis/pull/471