squash! ggml : move rope type enum to ggml.h
This commit removes the enum ggml_rope_type from ggml.h and replaces it with a define (GGML_ROPE_TYPE_NEOX). This define is used in the code to check if the mode is set to GPT-NeoX. Also the enum llama_rope_type has been updated to reflect this change.
This commit is contained in:
parent
5e14dbf2ea
commit
c9206f63be
9 changed files with 11 additions and 15 deletions
|
@ -244,6 +244,8 @@
|
|||
#define GGML_EXIT_SUCCESS 0
|
||||
#define GGML_EXIT_ABORTED 1
|
||||
|
||||
#define GGML_ROPE_TYPE_NEOX 2
|
||||
|
||||
#define GGUF_MAGIC "GGUF"
|
||||
|
||||
#define GGUF_VERSION 3
|
||||
|
@ -437,12 +439,6 @@ extern "C" {
|
|||
GGML_FTYPE_MOSTLY_Q4_0_8_8 = 27, // except 1d tensors
|
||||
};
|
||||
|
||||
// Rotary Positional Embedding (RoPE) types
|
||||
enum ggml_rope_type {
|
||||
GGML_ROPE_TYPE_NORM = 0,
|
||||
GGML_ROPE_TYPE_NEOX = 2,
|
||||
};
|
||||
|
||||
// available tensor operations:
|
||||
enum ggml_op {
|
||||
GGML_OP_NONE = 0,
|
||||
|
@ -1460,7 +1456,7 @@ extern "C" {
|
|||
|
||||
// rotary position embedding
|
||||
// if mode & 1 == 1, skip n_past elements (NOT SUPPORTED)
|
||||
// if mode & 2 == 1, GPT-NeoX style
|
||||
// if mode & GGML_ROPE_TYPE_NEOX == 1, GPT-NeoX style
|
||||
//
|
||||
// b is an int32 vector with size a->ne[2], it contains the positions
|
||||
GGML_API struct ggml_tensor * ggml_rope(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue