batched-bench : init warm-up batch

This commit is contained in:
Georgi Gerganov 2023-10-11 19:24:59 +03:00
parent 76e17f8d93
commit c062ffd18c
No known key found for this signature in database
GPG Key ID: 449E073F9DC10735

View File

@ -102,6 +102,14 @@ int main(int argc, char ** argv) {
// warm up
{
batch.n_tokens = 16;
for (int i = 0; i < batch.n_tokens; ++i) {
batch.token[i] = 0;
batch.pos[i] = i;
batch.seq_id[i] = 0;
batch.logits[i] = false;
}
if (!decode_helper(ctx, batch, ctx_params.n_batch)) {
LOG_TEE("%s: llama_decode() failed\n", __func__);
return 1;