How to use the phylib.utils._bunchify function in phylib

To help you get started, we’ve selected a few phylib examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github cortex-lab / phy / phy / gui / state.py View on Github external
def _load_state(path):
    """Load a GUI state from a JSON file."""
    try:
        logger.debug("Load %s for GUIState.", path)
        data = load_json(str(path))
    except json.decoder.JSONDecodeError as e:  # pragma: no cover
        logger.warning("Error decoding JSON: %s", e)
        data = {}
    return _bunchify(data)