mirror of
https://github.com/ggerganov/llama.cpp.git
synced 2024-12-27 20:04:35 +00:00
gguf : minor stuff
This commit is contained in:
parent
1da82c551f
commit
8083ae347a
@ -256,10 +256,9 @@ bool gguf_ex_read_0(const std::string & fname) {
|
||||
|
||||
// find kv string
|
||||
{
|
||||
char findkey[32];
|
||||
sprintf(findkey, "some.parameter.string");
|
||||
const char * findkey = "some.parameter.string";
|
||||
|
||||
int keyidx = gguf_find_key(ctx, findkey);
|
||||
const int keyidx = gguf_find_key(ctx, findkey);
|
||||
if (keyidx == -1) {
|
||||
fprintf(stdout, "%s: find key: %s not found.\n", __func__, findkey);
|
||||
} else {
|
||||
|
4
ggml.c
4
ggml.c
@ -19031,10 +19031,6 @@ const char * gguf_get_key(struct gguf_context * ctx, int i) {
|
||||
return ctx->header.kv[i].key.data;
|
||||
}
|
||||
|
||||
enum gguf_type gguf_get_type(struct gguf_context * ctx, int i) {
|
||||
return ctx->header.kv[i].type;
|
||||
}
|
||||
|
||||
const char * gguf_get_arr_str(struct gguf_context * ctx, int key_id, int i) {
|
||||
struct gguf_kv * kv = &ctx->header.kv[key_id];
|
||||
struct gguf_str * str = &((struct gguf_str *) kv->value.arr.data)[i];
|
||||
|
Loading…
Reference in New Issue
Block a user