code: def fetch_miyawaki2008(
      data_dir=None, url=None, resume=True, verbose=1
  ):
      """Download and loads Miyawaki et al. 2008 dataset (153MB).
  
      See :footcite:t:`Miyawaki2008`.
  
      Parameters
      ----------
      %(data_dir)s
      %(url)s
      %(resume)s
      %(verbose)s
  
      Returns
      -------
      data : Bunch
          Dictionary-like object, the interest attributes are :
  
          - 'func': :obj:`list` of :obj:`str`
              Paths to nifti file with :term:`BOLD` data
          - 'label': :obj:`list` of :obj:`str`
              Paths to text file containing run and target data
          - 'mask': :obj:`str`
              Path to nifti mask file to define target volume in visual
              cortex
          - 'background': :obj:`str`
              Path to nifti file containing a background image usable as a
              background image for miyawaki images.
  
      References
      ----------
      .. footbibliography::
  
      Notes
      -----
      This dataset is available on the `brainliner website
      <http://brainliner.jp/data/brainliner-admin/Reconstruct>`_
  
      See `additional information
      <http://www.cns.atr.jp/dni/en/downloads/
      fmri-data-set-for-visual-image-reconstruction/>`_
  
      """
      url = (
          "https://www.nitrc.org/frs/download.php"
          "/8486/miyawaki2008.tgz?i_agree=1&download_now=1"
      )
      opts = {"uncompress": True}
  
      # Dataset files
  
      # Functional MRI:
      #   * 20 random scans (usually used for training)
      #   * 12 figure scans (usually used for testing)
  
      func_figure = [
          (
              os.path.join(
                  "func", f"data_figure_run{int(i):02}.nii.gz"
              ),
              url,
              opts,
          )
          for i in range(1, 13)
      ]
  
      func_random = [
          (
              os.path.join(
                  "func", f"data_random_run{int(i):02}.nii.gz"
              ),
              url,
              opts,
          )
          for i in range(1, 21)
      ]
  
      # Labels, 10x10 patches, stimuli shown to the subject:
      #   * 20 random labels
      #   * 12 figure labels (letters and shapes)
  
      label_filename = "data_%s_run%02d_label.csv"
      label_figure = [
          (
              os.path.join("label", label_filename % ("figure", i)),
              url,
              opts,
          )
          for i in range(1, 13)
      ]
  
      label_random = [
          (
              os.path.join("label", label_filename % ("random", i)),
              url,
              opts,
          )
          for i in range(1, 21)
      ]
  
      # Masks
      file_mask = [
          (os.path.join("mask", m), url, opts)
          for m in miyawaki2008_file_mask()
      ]
  
      file_names = (
          func_figure
          + func_random
          + label_figure
          + label_random
          + file_mask
      )
  
      dataset_name = "miyawaki2008"
      data_dir = get_dataset_dir(
          dataset_name, data_dir=data_dir, verbose=verbose
      )
      files = fetch_files(
          data_dir, file_names, resume=resume, verbose=verbose
      )
  
      # Fetch the background image
      bg_img = fetch_files(
          data_dir,
          [("bg.nii.gz", url, opts)],
          resume=resume,
          verbose=verbose,
      )[0]
  
      fdescr = get_dataset_descr(dataset_name)
  
      # Return the data
      return Bunch(
          func=files[:32],
          label=files[32:64],
          mask=files[64],
          mask_roi=files[65:],
          background=bg_img,
          description=fdescr,
      )
  
imports: import fnmatch
  import glob
  import json
  import numbers
  import os
  import re
  import warnings
  from io import BytesIO
  from pathlib import Path
  import nibabel
  import nibabel
  import numpy
  import pandas
  from scipy.io import loadmat
  from sklearn.utils import Bunch
  from nilearn.image import get_data
  from .._utils import check_niimg, fill_doc
  from .._utils.numpy_conversions import csv_to_array
  from ._utils import fetch_files, fetch_single_file, filter_columns, get_dataset_descr, get_dataset_dir, read_md5_sum_file, tree, uncompress_file
label_desc: Use image node_id 5 for calling a global function with example usage: fetch_miyawaki2008(data_dir, url, resume, verbose) and returns: Bunch