diff --git a/python/examples/imdb/benchmark_batch.py b/python/examples/imdb/benchmark_batch.py index 99b8ec56ca74e72cb58d81f3a55b0fe7c19e4902..57ee6816989d4a807a328342f188a7298b7772de 100644 --- a/python/examples/imdb/benchmark_batch.py +++ b/python/examples/imdb/benchmark_batch.py @@ -64,4 +64,4 @@ result = multi_thread_runner.run(single_func, args.thread, {}) avg_cost = 0 for cost in result[0]: avg_cost += cost -print("total cost of each thread".format(avg_cost / args.thread)) +print("total cost {} s of each thread".format(avg_cost / args.thread)) diff --git a/python/paddle_serving_server_gpu/__init__.py b/python/paddle_serving_server_gpu/__init__.py index 6f0ece74eeccc40eaf9676738e15e7b52b9da9ce..93a167b949cfaaabf900aba5c6f1376e9568ca60 100644 --- a/python/paddle_serving_server_gpu/__init__.py +++ b/python/paddle_serving_server_gpu/__init__.py @@ -116,7 +116,7 @@ class Server(object): self.reload_interval_s = 10 self.module_path = os.path.dirname(paddle_serving_server.__file__) self.cur_path = os.getcwd() - self.check_cuda + self.check_cuda() self.use_local_bin = False self.gpuid = 0 @@ -144,7 +144,7 @@ class Server(object): self.bin_path = os.environ["SERVING_BIN"] def check_cuda(self): - r = os.system("whereis cuda") + r = os.system("whereis cuda > /dev/null") if r != 0: raise SystemExit( "CUDA not found, please check your environment or use cpu version by \"pip install paddle_serving_server\""