From 86a742099ad1235c607a5aad287b5ee55b6cf263 Mon Sep 17 00:00:00 2001 From: luoyao Date: Tue, 17 Dec 2024 15:01:17 +0800 Subject: [PATCH] update --- src/models/llm/llama/llama3.inl | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/models/llm/llama/llama3.inl b/src/models/llm/llama/llama3.inl index e2a88b3..a4edb89 100644 --- a/src/models/llm/llama/llama3.inl +++ b/src/models/llm/llama/llama3.inl @@ -406,6 +406,7 @@ StatusCode Llama3::Impl::embed_prompt( // check if need pool embeddings std::string trans_pool_type; + trans_pool_type.resize(pool_type.size()); std::transform(pool_type.begin(), pool_type.end(), trans_pool_type.begin(), [](unsigned char c) { return std::tolower(c);}); if (trans_pool_type == "mean") { std::vector pooled_embeds(embed_dims, 0.0f); @@ -556,7 +557,7 @@ Llama3::Llama3() { * @tparam OUTPUT */ template -Llama3::~Llama3() {}; +Llama3::~Llama3() = default; /*** *