This commit is contained in:
Josh Yan 2024-08-28 09:58:23 -07:00
parent 73d69bc90b
commit cc17b02b23
3 changed files with 3 additions and 1 deletions

1
.gitattributes vendored
View File

@ -1,3 +1,4 @@
llm/ext_server/* linguist-vendored
llm/*.h linguist-vendored
* text=auto
*.go text eol=lf

View File

@ -20,6 +20,7 @@ package llm
import "C"
import (
"errors"
"fmt"
"sync/atomic"
"time"

View File

@ -435,7 +435,7 @@ func CreateModel(ctx context.Context, name model.Name, modelFileDir, quantizatio
return err
}
tensorCount := len(baseLayer.GGML.Tensors())
tensorCount := len(baseLayer.GGML.Tensors().Items)
ft := baseLayer.GGML.KV().FileType()
if !slices.Contains([]string{"F16", "F32"}, ft.String()) {
return errors.New("quantization is only supported for F16 and F32 models")