docs: def load(path, include_core=True, path_in_arc=''):
      """ Loads a IOSystem or Extension previously saved with pymrio
  
      This function can be used to load a IOSystem or Extension specified in a
      metadata file (as defined in DEFAULT_FILE_NAMES['filepara']: metadata.json)
  
      DataFrames (tables) are loaded from text or binary pickle files.
      For the latter, the extension .pkl or .pickle is assumed, in all other case
      the tables are assumed to be in .txt format.
  
      Parameters
      ----------
      path : pathlib.Path or string
          Path or path with para file name for the data to load. This must
          either point to the directory containing the uncompressed data or
          the location of a compressed zip file with the data. In the
          later case the parameter 'path_in_arc' need to be specific to
          further indicate the location of the data in the compressed file.
  
      include_core : boolean, optional
          If False the load method does not include A, L and Z matrix. This
          significantly reduces the required memory if the purpose is only
          to analyse the results calculated beforehand.
  
      path_in_arc: string, optional
          Path to the data in the zip file (where the fileparameters file is
          located). path_in_arc must be given without leading dot and slash;
          thus to point to the data in the root of the compressed file pass '',
          for data in e.g. the folder 'emissions' pass 'emissions/'.  Only used
          if parameter 'path' points to an compressed zip file.
  
      Returns
      -------
  
          IOSystem or Extension class depending on systemtype in the json file
          None in case of errors
  
      """
      path = Path(path)
  
      if not path.exists():
          raise ReadError('Given path does not exist')
  
      file_para = get_file_para(path=path, path_in_arc=path_in_arc)
  
      if file_para.content['systemtype'] == GENERIC_NAMES['iosys']:
          if zipfile.is_zipfile(str(path)):
              ret_system = IOSystem(meta=MRIOMetaData(
                  location=path,
                  path_in_arc=os.path.join(file_para.folder,
                                           DEFAULT_FILE_NAMES['metadata'])))
              ret_system.meta._add_fileio(
                  "Loaded IO system from {} - {}".format(path, path_in_arc))
          else:
              ret_system = IOSystem(meta=MRIOMetaData(
                  location=path / DEFAULT_FILE_NAMES['metadata']))
              ret_system.meta._add_fileio(
                  "Loaded IO system from {}".format(path))
  
      elif file_para.content['systemtype'] == GENERIC_NAMES['ext']:
          ret_system = Extension(file_para.content['name'])
  
      else:
          raise ReadError('Type of system no defined in the file parameters')
          return None
  
      for key in file_para.content['files']:
          if not include_core and key not in ['A', 'L', 'Z']:
                  continue
  
          file_name = file_para.content['files'][key]['name']
          nr_index_col = file_para.content['files'][key]['nr_index_col']
          nr_header = file_para.content['files'][key]['nr_header']
          _index_col = list(range(int(nr_index_col)))
          _header = list(range(int(nr_header)))
          _index_col = 0 if _index_col == [0] else _index_col
          _header = 0 if _header == [0] else _header
  
          if zipfile.is_zipfile(str(path)):
              full_file_name = os.path.join(file_para.folder, file_name)
              logging.info('Load data from {}'.format(full_file_name))
  
              with zipfile.ZipFile(file=str(path)) as zf:
                  if (os.path.splitext(str(full_file_name))[1] == '.pkl' or
                          os.path.splitext(str(full_file_name))[1] == '.pickle'):
                      setattr(ret_system, key,
                              pd.read_pickle(zf.open(full_file_name)))
                  else:
                      setattr(ret_system, key,
                              pd.read_table(zf.open(full_file_name),
                                            index_col=_index_col,
                                            header=_header))
          else:
              full_file_name = path / file_name
              logging.info('Load data from {}'.format(full_file_name))
  
              if (os.path.splitext(str(full_file_name))[1] == '.pkl' or
                      os.path.splitext(str(full_file_name))[1] == '.pickle'):
                  setattr(ret_system, key,
                          pd.read_pickle(full_file_name))
              else:
                  setattr(ret_system, key,
                          pd.read_table(full_file_name,
                                        index_col=_index_col,
                                        header=_header))
      return ret_system