aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGeorgi Gerganov <ggerganov@gmail.com>2023-05-13 11:54:33 +0300
committerGeorgi Gerganov <ggerganov@gmail.com>2023-05-13 11:54:33 +0300
commitf048af0230ad5381bb20b9e3c1467ec6fc7debdf (patch)
tree16567e87cf4b47a1722ec5c5d7f84746d9cd1909
parentac0cd259d54be7e45ffa2c7b2508812cf4f83ccf (diff)
ggml : sync alibi fix from ggml repo
-rw-r--r--ggml.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/ggml.c b/ggml.c
index 4eccd41..b42ca03 100644
--- a/ggml.c
+++ b/ggml.c
@@ -8553,7 +8553,7 @@ static void ggml_compute_forward_alibi_f32(
m_k = powf(m1, 2 * (k - n_heads_log2_floor) + 1);
}
- pdst[0] = (j+1) * m_k + src[0];
+ pdst[0] = i * m_k + src[0];
}
}
}
@@ -8615,7 +8615,7 @@ static void ggml_compute_forward_alibi_f16(
}
// we return F32
- pdst[0] = (j+1) * m_k + GGML_FP16_TO_FP32(src[0]);
+ pdst[0] = i * m_k + GGML_FP16_TO_FP32(src[0]);
}
}
}