docs: def abspath(path, ref=None):
      """
      Create an absolute path.
  
      Parameters
      ----------
      path : str
          absolute or relative path with respect to `ref`
      ref : str or None
          reference path if `path` is relative
  
      Returns
      -------
      path : str
          absolute path
  
      Raises
      ------
      ValueError
          if an absolute path cannot be constructed
      """
      if ref:
          path = os.path.join(ref, path)
      if not os.path.isabs(path):
          raise ValueError("expected an absolute path but got '%s'" %  path)
      return path