msl.io.readers.json_ module

Read a file that was created by JSONWriter.

class msl.io.readers.json_.JSONReader(file)[source]

Bases: Reader

Read a file that was created by JSONWriter.

Parameters:

file (path-like or file-like) – The file to read.

static can_read(file, **kwargs)[source]

Checks if the text MSL JSONWriter is in the first line of the file.

read(**kwargs)[source]

Read the file that was created by JSONWriter

If a Metadata key has a value that is a list then the list is converted to an ndarray with dtype = object

Parameters:

**kwargs – Accepts encoding and errors keyword arguments which are passed to open(). The default encoding value is 'utf-8' and the default errors value is 'strict'. All additional keyword arguments are passed to json.loads.