Increase memory for overhead from 32 MB to 256 MB

This commit is contained in:
saharNooby 2023-04-03 09:32:58 +04:00
parent d62a050144
commit 5b2830ed30
1 changed files with 3 additions and 2 deletions

View File

@ -183,8 +183,9 @@ struct rwkv_context * rwkv_init_from_file(const char * file_path, uint32_t n_thr
size_t(2) * 5 * model->n_layer * model->n_embed * sizeof(float) + size_t(2) * 5 * model->n_layer * model->n_embed * sizeof(float) +
// Logits // Logits
size_t(model->n_vocab) * sizeof(float) + size_t(model->n_vocab) * sizeof(float) +
// +32 MB just for any overhead // +256 MB just for any overhead
size_t(32) * 1024 * 1024; // TODO This is too much for smaller models; need a more proper and robust way of measuring required memory
size_t(256) * 1024 * 1024;
// Initialize ggml // Initialize ggml
struct ggml_init_params params; struct ggml_init_params params;