pygsti.serialization.msgpack

Defines msgpack package interface capable of encoding pyGSTi objects

Module Contents

Functions

dumps(obj, **kwargs)

An overload of msgpack.dumps that works with pyGSTi types

dump(obj, f, **kwargs)

An overload of msgpack.dump that works with pyGSTi types

loads(s, **kwargs)

An overload of msgpack.loads that works with pyGSTi types

load(f, **kwargs)

An overload of msgpack.load that works with pyGSTi types

Attributes

msgpack_uses_binary_strs

pygsti.serialization.msgpack.msgpack_uses_binary_strs
pygsti.serialization.msgpack.dumps(obj, **kwargs)

An overload of msgpack.dumps that works with pyGSTi types

Parameters

obj (object) – object to serialize.

Returns

str

pygsti.serialization.msgpack.dump(obj, f, **kwargs)

An overload of msgpack.dump that works with pyGSTi types

Parameters
  • obj (object) – object to serialize

  • f (file) – output file

Returns

None

pygsti.serialization.msgpack.loads(s, **kwargs)

An overload of msgpack.loads that works with pyGSTi types

Parameters

s (str) – serialized object(s)

Returns

object

pygsti.serialization.msgpack.load(f, **kwargs)

An overload of msgpack.load that works with pyGSTi types

Parameters

f (file) – open file to read from

Returns

object