code: def load_hdf5(path):
      
  
      with h5py.File(path, 'r') as f:
          is_sparse = f['issparse'][...]
          if is_sparse:
              shape = tuple(f['shape'][...])
              data = f['data'][...]
              indices = f['indices'][...]
              indptr = f['indptr'][...]
              X = sparse.csr_matrix((data, indices, indptr), shape=shape)
          else:
              X = f['data'][...]
  
          y = f['target'][...]
  
      return X, y
docs: Load data from a HDF5 file.
  
      Args:
          path (str): A path to the HDF5 format file containing data.
          dense (boolean): An optional variable indicating if the return matrix
                           should be dense.  By default, it is false.
  
      Returns:
          Data matrix X and target vector y