pymodulon.io

Functions for reading and writing data into files.

Module Contents

Functions

save_to_json(data, filename, compress=False)

Save IcaData object to a json file

load_json_model(filename)

Load IcaData object from a file in JSON format.

pymodulon.io.save_to_json(data, filename, compress=False)[source]

Save IcaData object to a json file

Parameters
  • data (IcaData) – ICA dataset to be saved to json file

  • filename (str) – Path to json file where the data will be saved

  • compress (bool) – Indicates if the JSON file should be compressed into a gzip archive

Returns

None

Return type

None

pymodulon.io.load_json_model(filename)[source]

Load IcaData object from a file in JSON format.

Parameters

filename (str or StringIO) – File path or descriptor that contains the JSON document describing the ICA dataset.

Returns

IcaData – The IcaData object as represented in the JSON document.

Return type

IcaData