Skip to content

Commit 9f70ebf

Browse files
author
katsu560
committed
load files from model
1 parent 50d5683 commit 9f70ebf

File tree

2 files changed

+0
-25
lines changed

2 files changed

+0
-25
lines changed

include/ggml/ggml.h

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -2329,22 +2329,12 @@ extern "C" {
23292329
GGML_API const void * gguf_get_arr_data(const struct gguf_context * ctx, int key_id);
23302330
GGML_API const char * gguf_get_arr_str (const struct gguf_context * ctx, int key_id, int i);
23312331

2332-
<<<<<<< HEAD
23332332
GGML_API int gguf_get_n_tensors (const struct gguf_context * ctx);
23342333
GGML_API int gguf_find_tensor (const struct gguf_context * ctx, const char * name);
23352334
GGML_API size_t gguf_get_tensor_offset(const struct gguf_context * ctx, int i);
23362335
GGML_API char * gguf_get_tensor_name (const struct gguf_context * ctx, int i);
23372336
GGML_API enum ggml_type gguf_get_tensor_type (const struct gguf_context * ctx, int i);
23382337
GGML_API size_t gguf_get_tensor_size (const struct gguf_context * ctx, int i);
2339-
=======
2340-
GGML_API int gguf_get_n_tensors (const struct gguf_context * ctx);
2341-
GGML_API int gguf_find_tensor (const struct gguf_context * ctx, const char * name);
2342-
GGML_API size_t gguf_get_tensor_offset (const struct gguf_context * ctx, int i);
2343-
GGML_API char * gguf_get_tensor_name (const struct gguf_context * ctx, int i);
2344-
GGML_API enum ggml_type gguf_get_tensor_type (const struct gguf_context * ctx, int i);
2345-
GGML_API size_t gguf_get_tensor_size (const struct gguf_context * ctx, int i);
2346-
GGML_API int gguf_find_and_get_tensor(const struct gguf_context * ctx, const char * name, char ** data, size_t * size);
2347-
>>>>>>> 2210bb0ccfdbf848bd4ba52ec0797bea5c1acd8d
23482338

23492339
// removes key if it exists
23502340
GGML_API void gguf_remove_key(struct gguf_context * ctx, const char * key);

src/ggml.c

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -21977,21 +21977,6 @@ size_t gguf_get_tensor_size(const struct gguf_context * ctx, int i) {
2197721977
return ctx->infos[i].size;
2197821978
}
2197921979

21980-
<<<<<<< HEAD
21981-
=======
21982-
int gguf_find_and_get_tensor(const struct gguf_context * ctx, const char * name, char ** data, size_t * size) {
21983-
int tensor = gguf_find_tensor(ctx, name);
21984-
if (tensor != -1) {
21985-
const size_t offset = gguf_get_tensor_offset(ctx, tensor);
21986-
char * _data = (char *)gguf_get_data(ctx);
21987-
*data = _data + offset;
21988-
*size = gguf_get_tensor_size(ctx, tensor);
21989-
}
21990-
21991-
return tensor;
21992-
}
21993-
21994-
>>>>>>> 2210bb0ccfdbf848bd4ba52ec0797bea5c1acd8d
2199521980
// returns the index
2199621981
static int gguf_get_or_add_key(struct gguf_context * ctx, const char * key) {
2199721982
const int idx = gguf_find_key(ctx, key);

0 commit comments

Comments
 (0)