From 2d6de470e683547b14fee7eaf6244db508d259b2 Mon Sep 17 00:00:00 2001 From: Weisu Yin Date: Fri, 9 Jun 2023 19:58:34 +0000 Subject: [PATCH] fix --- .../cloud/scripts/sagemaker_scripts/multimodal_serve.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/autogluon/cloud/scripts/sagemaker_scripts/multimodal_serve.py b/src/autogluon/cloud/scripts/sagemaker_scripts/multimodal_serve.py index 4f8e180..647e239 100644 --- a/src/autogluon/cloud/scripts/sagemaker_scripts/multimodal_serve.py +++ b/src/autogluon/cloud/scripts/sagemaker_scripts/multimodal_serve.py @@ -63,6 +63,8 @@ def transform_fn(model, request_body, input_content_type, output_content_type="a payload = pickle.loads(buf) data = pd.read_parquet(BytesIO(payload["data"])) inference_kwargs = payload["inference_kwargs"] + if inference_kwargs is None: + inference_kwargs = {} elif input_content_type == "application/x-autogluon-npy": buf = bytes(request_body)