Skip to content

Commit

Permalink
Seep up pack operation on float vector (#889)
Browse files Browse the repository at this point in the history
Signed-off-by: zhenshan.cao <[email protected]>
  • Loading branch information
czs007 authored Feb 21, 2022
1 parent be65aa7 commit a6a8b8e
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
4 changes: 1 addition & 3 deletions pymilvus/client/blob.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,7 @@ def vectorBinaryToBytes(v):
return bytes(v)

def vectorFloatToBytes(v):
bs = bytes()
for f in v:
bs += floatToBytes(f)
bs = struct.pack('%sf'%len(v), *v)
return bs

def bytesToInt64(v):
Expand Down
2 changes: 1 addition & 1 deletion pymilvus/client/prepare.py
Original file line number Diff line number Diff line change
Expand Up @@ -369,7 +369,7 @@ def check_str(instr, prefix):

check_str(collection_name, "collection_name")
if partition_name is not None and partition_name != "":
check_str(partition_name, "partition_name")
check_str(partition_name, "partition_name")
check_str(expr, "expr")

request = milvus_types.DeleteRequest(collection_name=collection_name, expr=expr, partition_name=partition_name)
Expand Down

0 comments on commit a6a8b8e

Please sign in to comment.