def load(cls, path): """Load a saved ImagingDataset object.""" try: return cls(None, path) except ImportError: from sima.misc.convert import _load_version0 return _load_version0(path)
def load(cls, path): """Load a saved ImagingDataset object.""" try: return cls(None, path) except (ImportError, KeyError): from sima.misc.convert import _load_version0 # Load a read-only copy of the converted dataset ds = _load_version0(path) ds._read_only = True return ds
def load(cls, path): """Load a saved ImagingDataset object.""" try: return cls(None, path) except ImportError as error: if not error.args[0] == 'No module named iterables': raise error from sima.misc.convert import _load_version0 # Load a read-only copy of the converted dataset ds = _load_version0(path) ds._read_only = True return ds
def load(cls, path): """Load a saved ImagingDataset object.""" try: return cls(None, path) except ImportError as error: if not (error.args[0].endswith('iterables') or error.args[0].endswith("iterables'")): raise error from sima.misc.convert import _load_version0 # Load a read-only copy of the converted dataset ds = _load_version0(path) ds._read_only = True return ds