MsgPack.jl icon indicating copy to clipboard operation
MsgPack.jl copied to clipboard

Multi-dimensional array serialization drops shape and eltype information

Open lassepe opened this issue 3 years ago • 1 comments

When serializing a multi-dimensional array, the shape and eltype information is lost. For example

import MsgPack
matrix_a = rand(10, 10)
bytes = MsgPack.pack(matrix_a)
matrix_b = MsgPack.unpack(bytes)

results in:

julia> size(matrix_b)
(100,)
julia> eltype(matrix_b)
Any

lassepe avatar Apr 29 '21 09:04 lassepe

@lassepe Looking back at this, I am not sure that MessagePack currently supports more than vectors, though ND arrays seem to be in development. See the discussion there https://github.com/msgpack/msgpack/pull/267.

BambOoxX avatar May 26 '21 17:05 BambOoxX