mirror of
https://github.com/ollama/ollama.git
synced 2026-01-29 07:12:03 +03:00
* x: make `ollama create --experimental` import from safetensors This change allows pulling in safetensors models into the new experimental model format, and also fixes the `ollama show` command to be able to correctly display the model information. * gofumpt the linter * gofumpt the linter again * validate the model name
19 lines
513 B
Go
19 lines
513 B
Go
//go:build !mlx
|
|
|
|
package client
|
|
|
|
import (
|
|
"fmt"
|
|
"io"
|
|
)
|
|
|
|
// quantizeTensor is not available without MLX
|
|
func quantizeTensor(r io.Reader, name, dtype string, shape []int32, quantize string) (qweightData, scalesData, qbiasData []byte, qweightShape, scalesShape, qbiasShape []int32, err error) {
|
|
return nil, nil, nil, nil, nil, nil, fmt.Errorf("quantization requires MLX support (build with mlx tag)")
|
|
}
|
|
|
|
// QuantizeSupported returns false when MLX is not available
|
|
func QuantizeSupported() bool {
|
|
return false
|
|
}
|