fix: omit array parsing
these instances of decode should not need any array data so omit them
This commit is contained in:
parent
fe623c2cf4
commit
240921fd96
|
|
@ -415,7 +415,7 @@ func projectorMemoryRequirements(filename string) (weights uint64) {
|
|||
}
|
||||
defer file.Close()
|
||||
|
||||
ggml, _, err := ggml.Decode(file, 1024)
|
||||
ggml, _, err := ggml.Decode(file, 0)
|
||||
if err != nil {
|
||||
return 0
|
||||
}
|
||||
|
|
|
|||
|
|
@ -467,7 +467,7 @@ func quantizeLayer(layer *layerGGML, quantizeType string, fn func(resp api.Progr
|
|||
return nil, err
|
||||
}
|
||||
|
||||
f, _, err := ggml.Decode(temp, 1024)
|
||||
f, _, err := ggml.Decode(temp, 0)
|
||||
if err != nil {
|
||||
slog.Error(fmt.Sprintf("error decoding ggml: %s\n", err))
|
||||
return nil, err
|
||||
|
|
|
|||
|
|
@ -75,7 +75,7 @@ func (m *Model) Capabilities() []model.Capability {
|
|||
if err == nil {
|
||||
defer r.Close()
|
||||
|
||||
f, _, err := ggml.Decode(r, 1024)
|
||||
f, _, err := ggml.Decode(r, 0)
|
||||
if err == nil {
|
||||
if _, ok := f.KV()[fmt.Sprintf("%s.pooling_type", f.KV().Architecture())]; ok {
|
||||
capabilities = append(capabilities, model.CapabilityEmbedding)
|
||||
|
|
|
|||
Loading…
Reference in New Issue