code: def fetch_surf_fsaverage(mesh="fsaverage5", data_dir=None):
      """Download a Freesurfer fsaverage surface.
  
      File names are subject to change and only attribute names
      are guaranteed to be stable across nilearn versions.
      See :footcite:t:`Fischl1999`.
  
      Parameters
      ----------
      mesh : str, default='fsaverage5'
          Which :term:`mesh` to fetch.
          Should be one of the following values:
          %(fsaverage_options)s
      %(data_dir)s
  
      Returns
      -------
      data : sklearn.datasets.base.Bunch
          Dictionary-like object, the interest attributes are :
           - 'area_left': Gifti file, left hemisphere area data
           - 'area_right': Gifti file, right hemisphere area data
           - 'curv_left': Gifti file, left hemisphere curvature data
           - 'curv_right': Gifti file, right hemisphere curvature data
           - 'flat_left': Gifti file, left hemisphere flat surface :term:`mesh`
           - 'flat_right': Gifti file, right hemisphere flat surface :term:`mesh`
           - 'pial_left': Gifti file, left hemisphere pial surface :term:`mesh`
           - 'pial_right': Gifti file, right hemisphere pial surface :term:`mesh`
           - 'infl_left': Gifti file, left hemisphere inflated pial surface
             :term:`mesh`
           - 'infl_right': Gifti file, right hemisphere inflated pial
                           surface :term:`mesh`
           - 'sphere_left': Gifti file, left hemisphere sphere surface
             :term:`mesh`
           - 'sphere_right': Gifti file, right hemisphere sphere surface
             :term:`mesh`
           - 'sulc_left': Gifti file, left hemisphere sulcal depth data
           - 'sulc_right': Gifti file, right hemisphere sulcal depth data
           - 'thick_left': Gifti file, left hemisphere cortical thickness data
           - 'thick_right': Gifti file, right hemisphere cortical thickness data
           - 'white_left': Gifti file, left hemisphere
             white surface :term:`mesh`
           - 'white_right': Gifti file, right hemisphere*
             white surface :term:`mesh`
  
      References
      ----------
      .. footbibliography::
  
      """
      available_meshes = (
          "fsaverage3",
          "fsaverage4",
          "fsaverage5",
          "fsaverage6",
          "fsaverage7",
          "fsaverage",
      )
  
      # Call a dataset loader depending on the value of mesh
      if mesh in (
          "fsaverage3",
          "fsaverage4",
          "fsaverage6",
          "fsaverage7",
          "fsaverage",
      ):
          # rename mesh to "fsaverage" to download it once
          # regardless of whether mesh equals "fsaverage" or "fsaverage7"
          if mesh == "fsaverage7":
              mesh = "fsaverage"
  
          return _fetch_surf_fsaverage(mesh, data_dir=data_dir)
      elif mesh == "fsaverage5":
          return _fetch_surf_fsaverage5()
      else:
          raise ValueError(
              f"'mesh' should be one of {available_meshes}; "
              f"{mesh!r} was provided"
          )
  
imports: import functools
  import os
  import warnings
  from pathlib import Path
  import numpy
  import pandas
  from scipy.ndimage import binary_closing
  from sklearn.utils import Bunch
  from .._utils import check_niimg, fill_doc
  from ..image import get_data, new_img_like, resampling
  from ._utils import fetch_files, get_dataset_descr, get_dataset_dir
label_desc: Use image node_id 11 for calling a global function with example usage: fetch_surf_fsaverage(mesh, data_dir) and returns: _fetch_surf_fsaverage, _fetch_surf_fsaverage5