mirror of https://github.com/milvus-io/milvus.git
Fix gen_vectors typo issue (#22117)
Signed-off-by: yanliang567 <yanliang.qiao@zilliz.com>pull/22125/head
parent
9950cacd10
commit
2a19f4927d
|
@ -14,6 +14,8 @@ from utils.util_log import test_log as log
|
||||||
from common import common_func as cf
|
from common import common_func as cf
|
||||||
from common import common_type as ct
|
from common import common_type as ct
|
||||||
|
|
||||||
|
from pymilvus import ResourceGroupInfo
|
||||||
|
|
||||||
|
|
||||||
class Base:
|
class Base:
|
||||||
""" Initialize class object """
|
""" Initialize class object """
|
||||||
|
@ -67,8 +69,8 @@ class Base:
|
||||||
|
|
||||||
""" Clean up the rgs before disconnect """
|
""" Clean up the rgs before disconnect """
|
||||||
for rg_name in self.resource_group_list:
|
for rg_name in self.resource_group_list:
|
||||||
rg = self.utility_wrap.describe_resource_group(name=rg_name)[0]
|
rg = self.utility_wrap.describe_resource_group(name=rg_name, check_task=ct.CheckTasks.check_nothing)[0]
|
||||||
if rg is not None:
|
if isinstance(rg, ResourceGroupInfo):
|
||||||
if rg.num_available_node > 0:
|
if rg.num_available_node > 0:
|
||||||
self.utility_wrap.transfer_node(source=rg_name,
|
self.utility_wrap.transfer_node(source=rg_name,
|
||||||
target=ct.default_resource_group_name,
|
target=ct.default_resource_group_name,
|
||||||
|
|
|
@ -327,7 +327,7 @@ def gen_default_list_data(nb=ct.default_nb, dim=ct.default_dim, start=0):
|
||||||
int_values = [i for i in range(start, start + nb)]
|
int_values = [i for i in range(start, start + nb)]
|
||||||
float_values = [np.float32(i) for i in range(start, start + nb)]
|
float_values = [np.float32(i) for i in range(start, start + nb)]
|
||||||
string_values = [str(i) for i in range(start, start + nb)]
|
string_values = [str(i) for i in range(start, start + nb)]
|
||||||
float_vec_values = gen_vectors(start + nb, dim)
|
float_vec_values = gen_vectors(nb, dim)
|
||||||
data = [int_values, float_values, string_values, float_vec_values]
|
data = [int_values, float_values, string_values, float_vec_values]
|
||||||
return data
|
return data
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue