diff --git a/tensorizer/serialization.py b/tensorizer/serialization.py index b831bf8..59c3e84 100644 --- a/tensorizer/serialization.py +++ b/tensorizer/serialization.py @@ -3510,7 +3510,7 @@ def _mv_suffix(data: "collections.abc.Buffer", start: int): if not isinstance(data, memoryview): data = memoryview(data) try: - if data.ndim != 1: + if data.ndim != 1 or data.format != "B": data = data.cast("B") return data[start:] finally: