From e204f2300c41485f1180e117a29e9c153799d5fc Mon Sep 17 00:00:00 2001 From: HexToString <506181616@qq.com> Date: Fri, 16 Apr 2021 15:23:44 +0800 Subject: [PATCH] fix bug --- python/examples/fit_a_line/benchmark.py | 2 +- python/paddle_serving_client/client.py | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/python/examples/fit_a_line/benchmark.py b/python/examples/fit_a_line/benchmark.py index 0ddda2a0..5cc094dc 100644 --- a/python/examples/fit_a_line/benchmark.py +++ b/python/examples/fit_a_line/benchmark.py @@ -35,7 +35,7 @@ def single_func(idx, resource): batch_size=1) start = time.time() for data in train_reader(): - fetch_map = client.predict(feed={"x": data[0][0]}, fetch=["price"]) + fetch_map = client.predict(feed={"x": data[0][0]}, fetch=["price"],batch=True) end = time.time() return [[end - start]] elif args.request == "http": diff --git a/python/paddle_serving_client/client.py b/python/paddle_serving_client/client.py index 88dcf28c..8f1218b8 100755 --- a/python/paddle_serving_client/client.py +++ b/python/paddle_serving_client/client.py @@ -155,7 +155,7 @@ class Client(object): file_path_list = [] for single_model_config in model_config_path_list: if os.path.isdir(single_model_config): - file_path_list.append("{}/serving_server_conf.prototxt".format( + file_path_list.append("{}/serving_client_conf.prototxt".format( single_model_config)) elif os.path.isfile(single_model_config): file_path_list.append(single_model_config) @@ -574,7 +574,7 @@ class MultiLangClient(object): file_path_list = [] for single_model_config in model_config_path_list: if os.path.isdir(single_model_config): - file_path_list.append("{}/serving_server_conf.prototxt".format( + file_path_list.append("{}/serving_client_conf.prototxt".format( single_model_config)) elif os.path.isfile(single_model_config): file_path_list.append(single_model_config) -- GitLab