milvus-io / milvus-sdk-go

Go SDK for Milvus.
Apache License 2.0
340 stars 107 forks source link

[Bug]: The BinFlat index does not require nlist parameter #354

Open ThreadDao opened 1 year ago

ThreadDao commented 1 year ago

Is there an existing issue for this?

Current Behavior

BinFlat index does not supported nlist params like Flat index

func NewIndexBinFlat(metricType MetricType, 
    nlist int,
) (*IndexBinFlat, error) {
    // auto generate parameters validation code, if any
    if nlist < 1 {
        return nil, errors.New("nlist not valid")
    }
    if nlist > 65536 {
        return nil, errors.New("nlist not valid")
    }

    return &IndexBinFlat{ 
    //auto generated setting
    nlist: nlist,
    metricType: metricType,
    }, nil
}

Expected Behavior

No response

Steps To Reproduce

No response

Environment

No response

Anything else?

No response

ThreadDao commented 1 year ago

/assign @congqixia