Skip to content

Commit 2cfa7ae

Browse files
committed
add imrope branch to switch
1 parent 71efb38 commit 2cfa7ae

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

ggml/src/ggml-cpu/ops.cpp

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5625,7 +5625,7 @@ static void ggml_compute_forward_rope_flt(
56255625
ggml_rope_yarn_corr_dims(n_dims, n_ctx_orig, freq_base, beta_fast, beta_slow, corr_dims);
56265626

56275627
const bool is_imrope = mode == GGML_ROPE_TYPE_IMROPE; // qwen3vl apply interleaved mrope
5628-
const bool mrope_used = mode & GGML_ROPE_TYPE_MROPE; // ggml_rope_multi, note: also true for vision (24 & 8 == true)
5628+
const bool mrope_used = mode & GGML_ROPE_TYPE_MROPE; // ggml_rope_multi, note: also true for vision (24 & 8 == true) and for imrope
56295629
const bool is_vision = mode == GGML_ROPE_TYPE_VISION;
56305630

56315631
if (mrope_used) {
@@ -5680,7 +5680,8 @@ static void ggml_compute_forward_rope_flt(
56805680
rotate_pairs<T>(n_dims, 1, cache, src, dst_data, 1);
56815681
break;
56825682
case GGML_ROPE_TYPE_NEOX:
5683-
case GGML_ROPE_TYPE_MROPE: //pure, not vision
5683+
case GGML_ROPE_TYPE_MROPE:
5684+
case GGML_ROPE_TYPE_IMROPE:
56845685
rotate_pairs<T>(n_dims, n_dims/2, cache, src, dst_data);
56855686
break;
56865687
case GGML_ROPE_TYPE_VISION:

0 commit comments

Comments
 (0)