Skip to content

Commit c605b07

Browse files
committed
fix image preprocessing
1 parent 0fb3244 commit c605b07

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

torch_serve/image/handler.py

+4-1
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ def initialize(self, ctx):
6666
logger.debug(f"Model file {serialized_file} loaded successfully")
6767
self.initialized = True
6868

69-
@staticmethod
69+
@staticmethod
7070
def preprocess(data):
7171
"""
7272
Scales and normalizes a PIL image for an U-net model
@@ -131,7 +131,10 @@ def handle(data, context):
131131
return None
132132

133133
data = _service.preprocess(data)
134+
logger.info(f"preprocessed data: {data}")
134135
data = _service.inference(data)
136+
logger.info(f"infered data: {data}")
135137
data = _service.postprocess(data)
138+
logger.info(f"postprocessed data: {data}")
136139

137140
return data

0 commit comments

Comments
 (0)