code: def _model_attributes_to_dataframe(model):
      """Return an HTML table with pertinent model attributes & information.
  
      Parameters
      ----------
      model : FirstLevelModel or SecondLevelModel object.
  
      Returns
      -------
      HTML Table : String
          HTML table with the pertinent attributes of the model.
  
      """
      selected_attributes = [
          "subject_label",
          "drift_model",
          "hrf_model",
          "standardize",
          "noise_model",
          "t_r",
          "high_pass",
          "target_shape",
          "signal_scaling",
          "drift_order",
          "scaling_axis",
          "smoothing_fwhm",
          "target_affine",
          "slice_time_ref",
          "fir_delays",
      ]
      attribute_units = {
          "t_r": "s",
          "high_pass": "Hz",
      }
  
      selected_attributes.sort()
      display_attributes = OrderedDict(
          (attr_name, getattr(model, attr_name))
          for attr_name in selected_attributes
          if hasattr(model, attr_name)
      )
      model_attributes = pd.DataFrame.from_dict(
          display_attributes,
          orient="index",
      )
      attribute_names_with_units = {
          attribute_name_: attribute_name_ + f" ({attribute_unit_})"
          for attribute_name_, attribute_unit_ in attribute_units.items()
      }
      model_attributes.rename(
          index=attribute_names_with_units, inplace=True
      )
      return model_attributes
  
imports: import os
  import string
  import warnings
  from collections import OrderedDict
  from collections.abc import Iterable
  from html import escape
  import numpy
  import pandas
  from matplotlib import pyplot
  from nilearn.plotting import plot_glass_brain, plot_roi, plot_stat_map
  from nilearn.plotting.img_plotting import MNI152TEMPLATE
  from nilearn.plotting.matrix_plotting import plot_contrast_matrix, plot_design_matrix
  from nilearn.reporting.html_report import HTMLReport
  from .._utils import fill_doc
  from nilearn._utils import check_niimg
  from nilearn.maskers import NiftiMasker
  from nilearn.reporting.get_clusters_table import get_clusters_table
  from nilearn.reporting.utils import figure_to_svg_quoted
label_desc: Use image node_id 7 for calling a global function with example usage: _model_attributes_to_dataframe(model) and returns: model_attributes