decode

function of dascore.workflow.serialize source

decode(
    obj: Any ,
)-> ‘Any’

Return the object a document-mode encoding stands for.

Values which a document cannot carry – an array reduced to its digest, a function, a dataframe – raise rather than come back as the tagged mapping which stands for them.

Examples

import numpy as np
from dascore.workflow.serialize import encode, decode
decode(encode(np.datetime64("2020-01-01"), mode="document"))
np.datetime64('2020-01-01T00:00:00.000000000')