summaryrefslogtreecommitdiff
path: root/ggml/include
diff options
context:
space:
mode:
authorKawrakow <iwankawrakow@gmail.com>2025-03-02 13:47:38 +0200
committerGitHub <noreply@github.com>2025-03-02 13:47:38 +0200
commita89adaa78f505675be7be6180f419b4b0158c15a (patch)
treead82fa3ad44f66f37885bdf0d0d025166eff9535 /ggml/include
parentef9a3d17b52bb5f6d55f7ef7e05e41e22f2ad81d (diff)
SER - Smart Expert Reduction (#239)
* A better way to measure the cost of ggml_barrier * Smart expert selection * Add ser option to llama-bench --------- Co-authored-by: Iwan Kawrakow <iwan.kawrakow@gmail.com>
Diffstat (limited to 'ggml/include')
-rw-r--r--ggml/include/ggml.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/ggml/include/ggml.h b/ggml/include/ggml.h
index d12b90d0..91219d4a 100644
--- a/ggml/include/ggml.h
+++ b/ggml/include/ggml.h
@@ -597,6 +597,7 @@ extern "C" {
GGML_OP_ARANGE,
GGML_OP_TIMESTEP_EMBEDDING,
GGML_OP_ARGSORT,
+ GGML_OP_ARGSORT_THRESH,
GGML_OP_LEAKY_RELU,
GGML_OP_SOFTCAP,
GGML_OP_SOFT_CAP_MAX,
@@ -1913,6 +1914,12 @@ extern "C" {
struct ggml_tensor * a,
enum ggml_sort_order order);
+ GGML_API struct ggml_tensor * ggml_argsort_thresh(
+ struct ggml_context * ctx,
+ struct ggml_tensor * a,
+ int min_entries,
+ float threshold);
+
GGML_API struct ggml_tensor * ggml_arange(
struct ggml_context * ctx,
float start,
@@ -1924,6 +1931,12 @@ extern "C" {
struct ggml_context * ctx,
struct ggml_tensor * a,
int k);
+ GGML_API struct ggml_tensor * ggml_top_k_thresh(
+ struct ggml_context * ctx,
+ struct ggml_tensor * a,
+ int k,
+ int min_entries,
+ float thresh);
#define GGML_KQ_MASK_PAD 32