Skip to content

Commit ff6d3c1

Browse files
committed
embed_pooled -> embd_pooled
1 parent 940b1e8 commit ff6d3c1

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

llama.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12619,14 +12619,14 @@ static int llama_decode_internal(
1261912619
std::vector<std::vector<llama_seq_id>> seq_id;
1262012620

1262112621
// this indicates we are doing pooled embedding, so we ignore batch.logits and output all tokens
12622-
bool embed_pooled = cparams.embeddings && cparams.pooling_type != LLAMA_POOLING_TYPE_NONE;
12622+
const bool embd_pooled = cparams.embeddings && cparams.pooling_type != LLAMA_POOLING_TYPE_NONE;
1262312623

1262412624
// count outputs
12625-
if (batch_all.logits && !embed_pooled) {
12625+
if (batch_all.logits && !embd_pooled) {
1262612626
for (uint32_t i = 0; i < n_tokens_all; ++i) {
1262712627
n_outputs += batch_all.logits[i] != 0;
1262812628
}
12629-
} else if (lctx.logits_all || embed_pooled) {
12629+
} else if (lctx.logits_all || embd_pooled) {
1263012630
n_outputs = n_tokens_all;
1263112631
} else {
1263212632
// keep last output only
@@ -12672,7 +12672,7 @@ static int llama_decode_internal(
1267212672
{
1267312673
int32_t n_outputs_new = 0;
1267412674

12675-
if (u_batch.logits && !embed_pooled) {
12675+
if (u_batch.logits && !embd_pooled) {
1267612676
for (uint32_t i = 0; i < n_tokens; i++) {
1267712677
n_outputs_new += u_batch.logits[i] != 0;
1267812678
}

0 commit comments

Comments
 (0)