diff --git a/pyspark/bigdl/common/util/common.py b/pyspark/bigdl/common/util/common.py index a58d61629dd..f15d7a554af 100644 --- a/pyspark/bigdl/common/util/common.py +++ b/pyspark/bigdl/common/util/common.py @@ -634,8 +634,8 @@ def _java2py(gateway, r, encoding="bytes"): except Py4JJavaError: pass # not pickable - if isinstance(r, (bytearray, bytes)): - r = PickleSerializer().loads(bytes(r), encoding=encoding) + if isinstance(r, (bytearray, bytes)): + r = PickleSerializer().loads(bytes(r), encoding=encoding) return r