提交 f97c2097 编写于 作者: G guru4elephant

remove unused comments

上级 c1c897ce
......@@ -18,7 +18,12 @@ import os
import base64
from image_reader import ImageReader
class ImageService(WebService):
"""
preprocessing function for image classification
"""
def preprocess(self, feed={}, fetch=[]):
reader = ImageReader()
if "image" not in feed:
......
......@@ -17,12 +17,12 @@ import base64
import json
import time
def predict(image_path, server):
image = base64.b64encode(open(image_path).read())
req = json.dumps({"image": image, "fetch": ["score"]})
r = requests.post(
server, data=req, headers={"Content-Type": "application/json"})
#print(r.json()["score"])
if __name__ == "__main__":
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册