milvus/client
Yinzuo Jiang 1ce609834a
feat: [GoSDK] fp32 <-> fp16/bf16 vector conversion (#37978)
Add the following methods for convenient fp32 vector <-> fp16/bf16
vector conversion

fp32 <-> fp16/bf16 vector conversion:

- `func (fv FloatVector) ToFloat16Vector() Float16Vector`
- `func (fv FloatVector) ToBFloat16Vector() BFloat16Vector`
- `func (fv Float16Vector) ToFloat32Vector() FloatVector`
- `func (fv BFloat16Vector) ToFloat32Vector() FloatVector`

`columnBasedDataOption`:

- `func (opt *columnBasedDataOption) WithFloat16VectorColumn(colName
string, dim int, data [][]float32) *columnBasedDataOption`
- `func (opt *columnBasedDataOption) WithBFloat16VectorColumn(colName
string, dim int, data [][]float32) *columnBasedDataOption`

`ColumnFloat16Vector`/`ColumnBFloat16Vector`:

- `func NewColumnFloat16VectorFromFp32Vector(fieldName string, dim int,
data [][]float32) *ColumnFloat16Vector`
- `func NewColumnBFloat16VectorFromFp32Vector(fieldName string, dim int,
data [][]float32) *ColumnBFloat16Vector`
- support []float32 or `entity.FloatVector` in
    - `func (c *ColumnFloat16Vector) AppendValue(i interface{}) error`
    - `func (c *ColumnFloat16Vector) AppendValue(i interface{}) error`

issue: #37448

Signed-off-by: Yinzuo Jiang <yinzuo.jiang@zilliz.com>
Signed-off-by: Yinzuo Jiang <jiangyinzuo@foxmail.com>
2024-11-29 08:00:37 +08:00
..
column feat: [GoSDK] fp32 <-> fp16/bf16 vector conversion (#37978) 2024-11-29 08:00:37 +08:00
common
entity feat: [GoSDK] fp32 <-> fp16/bf16 vector conversion (#37978) 2024-11-29 08:00:37 +08:00
index enhance: add an unify vector index config checker (#36844) 2024-10-28 10:11:37 +08:00
milvusclient feat: [GoSDK] fp32 <-> fp16/bf16 vector conversion (#37978) 2024-11-29 08:00:37 +08:00
row enhance: [GoSDK] write back auto id value to row based input (#36964) 2024-10-18 11:19:24 +08:00
ruleguard enhance: Add lint rules for client pkg and fix problems (#33180) 2024-05-20 20:47:38 +08:00
.golangci.yml enhance: update checker for go version (#33351) 2024-05-24 14:23:40 +08:00
go.mod feat: [GoSDK] fp32 <-> fp16/bf16 vector conversion (#37978) 2024-11-29 08:00:37 +08:00
go.sum feat: [GoSDK] fp32 <-> fp16/bf16 vector conversion (#37978) 2024-11-29 08:00:37 +08:00
Makefile enhance: Generate milvusclient mockery with latest proto (#37567) 2024-11-11 14:28:30 +08:00
OWNERS