From 62f074e9d0ad73f00d3dd1ac050916e505712611 Mon Sep 17 00:00:00 2001 From: guru4elephant Date: Thu, 12 Mar 2020 17:00:27 +0800 Subject: [PATCH] delete fetch key in feed --- python/paddle_serving_server_gpu/web_service.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/python/paddle_serving_server_gpu/web_service.py b/python/paddle_serving_server_gpu/web_service.py index 6d203904..d30f1bfb 100755 --- a/python/paddle_serving_server_gpu/web_service.py +++ b/python/paddle_serving_server_gpu/web_service.py @@ -107,6 +107,8 @@ class WebService(object): if "fetch" not in request.json: abort(400) feed, fetch = self.preprocess(request.json, request.json["fetch"]) + if "fetch" in feed: + del feed["fetch"] fetch_map = client_list[0].predict(feed=feed, fetch=fetch) fetch_map = self.postprocess( feed=request.json, fetch=fetch, fetch_map=fetch_map) -- GitLab