model: add support for qwen3.5-27b model (#14415)

This commit is contained in:
Jeffrey Morgan
2026-02-25 01:09:58 -08:00
committed by GitHub
parent da70c3222e
commit 7f9efd53df
3 changed files with 45 additions and 26 deletions

View File

@@ -195,6 +195,7 @@ type Tensor interface {
Concat(ctx Context, t2 Tensor, dim int) Tensor
Rows(ctx Context, t2 Tensor) Tensor
SetRows(ctx Context, src Tensor, idxs Tensor) Tensor
SetInplace(ctx Context, src Tensor, nb1, nb2, nb3, offset int) Tensor
Copy(ctx Context, t2 Tensor) Tensor
Duplicate(ctx Context) Tensor

View File

@@ -1345,6 +1345,21 @@ func (t *Tensor) SetRows(ctx ml.Context, src ml.Tensor, idxs ml.Tensor) ml.Tenso
}
}
func (t *Tensor) SetInplace(ctx ml.Context, src ml.Tensor, nb1, nb2, nb3, offset int) ml.Tensor {
return &Tensor{
b: t.b,
t: C.ggml_set_inplace(
ctx.(*Context).ctx,
t.t,
src.(*Tensor).t,
C.size_t(nb1),
C.size_t(nb2),
C.size_t(nb3),
C.size_t(offset),
),
}
}
func (t *Tensor) Copy(ctx ml.Context, t2 ml.Tensor) ml.Tensor {
return &Tensor{
b: t.b,