Skip to content

Enable DataHandler to save nested dictionaries of numpy arrays #252

@arthurostrauss

Description

@arthurostrauss

In some use cases, one is interested to save data types related to different qubits such as:

my_data = {"I": {"q1": np.array([...]),
                              "q2": np.array([...]),
                               ....}}
DataHandler.save_data(my_data)

At the moment, this will fail because numpy array is not directly serializable in JSON, and is not parsed correctly as it is done for the not nested case.

One should therefore be able to build according references in a nested fashion like in this example.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions