Skip to content

Commit

Permalink
Merge pull request #837 from MRXLT/release/0.3
Browse files Browse the repository at this point in the history
[cherry pick] to release 0.3
  • Loading branch information
MRXLT authored Sep 14, 2020
2 parents 633a771 + 4f14b18 commit 48f7e4f
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 3 deletions.
1 change: 1 addition & 0 deletions python/examples/blazeface/test_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
from paddle_serving_app.reader import *
import sys
import numpy as np
from paddle_serving_app.reader import BlazeFacePostprocess

preprocess = Sequential([
File2Image(),
Expand Down
2 changes: 1 addition & 1 deletion python/examples/imagenet/resnet50_web_service.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
class ImageService(WebService):
def init_imagenet_setting(self):
self.seq = Sequential([
Base64ToImage(), Resize(256), CenterCrop(224), RGB2BGR(), Transpose(
URL2Image(), Resize(256), CenterCrop(224), RGB2BGR(), Transpose(
(2, 0, 1)), Div(255), Normalize([0.485, 0.456, 0.406],
[0.229, 0.224, 0.225], True)
])
Expand Down
2 changes: 1 addition & 1 deletion python/paddle_serving_app/reader/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
from .chinese_bert_reader import ChineseBertReader
from .image_reader import ImageReader, File2Image, URL2Image, Sequential, Normalize, Base64ToImage
from .image_reader import CenterCrop, Resize, Transpose, Div, RGB2BGR, BGR2RGB, ResizeByFactor
from .image_reader import RCNNPostprocess, SegPostprocess, PadStride
from .image_reader import RCNNPostprocess, SegPostprocess, PadStride, BlazeFacePostprocess
from .image_reader import DBPostProcess, FilterBoxes, GetRotateCropImage, SortedBoxes
from .lac_reader import LACReader
from .senta_reader import SentaReader
Expand Down
2 changes: 1 addition & 1 deletion python/paddle_serving_server_gpu/web_service.py
Original file line number Diff line number Diff line change
Expand Up @@ -221,6 +221,6 @@ def preprocess(self, feed=[], fetch=[]):
return feed, fetch

def postprocess(self, feed=[], fetch=[], fetch_map=None):
for key in fetch_map.iterkeys():
for key in fetch_map:
fetch_map[key] = fetch_map[key].tolist()
return fetch_map

0 comments on commit 48f7e4f

Please sign in to comment.