code: def plot_contour(
      study: Study,
      params: list[str] | None = None,
      *,
      target: Callable[[FrozenTrial], float] | None = None,
      target_name: str = "Objective Value",
  ) -> "Axes":
      """Plot the parameter relationship as contour plot in a study with Matplotlib.
  
      Note that, if a parameter contains missing values, a trial with missing values is not plotted.
  
      .. seealso::
          Please refer to :func:`optuna.visualization.plot_contour` for an example.
  
      Warnings:
          Output figures of this Matplotlib-based
          :func:`~optuna.visualization.matplotlib.plot_contour` function would be different from
          those of the Plotly-based :func:`~optuna.visualization.plot_contour`.
  
      Example:
  
          The following code snippet shows how to plot the parameter relationship as contour plot.
  
          .. plot::
  
              import optuna
  
  
              def objective(trial):
                  x = trial.suggest_float("x", -100, 100)
                  y = trial.suggest_categorical("y", [-1, 0, 1])
                  return x ** 2 + y
  
  
              sampler = optuna.samplers.TPESampler(seed=10)
              study = optuna.create_study(sampler=sampler)
              study.optimize(objective, n_trials=30)
  
              optuna.visualization.matplotlib.plot_contour(study, params=["x", "y"])
  
      Args:
          study:
              A :class:`~optuna.study.Study` object whose trials are plotted for their target values.
          params:
              Parameter list to visualize. The default is all parameters.
          target:
              A function to specify the value to display. If it is :obj:`None` and ``study`` is being
              used for single-objective optimization, the objective values are plotted.
  
              .. note::
                  Specify this argument if ``study`` is being used for multi-objective optimization.
          target_name:
              Target's name to display on the color bar.
  
      Returns:
          A :class:`matplotlib.axes.Axes` object.
  
      .. note::
          The colormap is reversed when the ``target`` argument isn't :obj:`None` or ``direction``
          of :class:`~optuna.study.Study` is ``minimize``.
      """
  
      _imports.check()
      _logger.warning(
          "Output figures of this Matplotlib-based `plot_contour` function would be different from "
          "those of the Plotly-based `plot_contour`."
      )
      info = _get_contour_info(study, params, target, target_name)
      return _get_contour_plot(info)
  
imports: from __future__ import annotations
  from typing import Callable
  from typing import Sequence
  import numpy
  from optuna._experimental import experimental_func
  from optuna._imports import try_import
  from optuna.logging import get_logger
  from optuna.study import Study
  from optuna.trial import FrozenTrial
  from optuna.visualization._contour import _AxisInfo
  from optuna.visualization._contour import _ContourInfo
  from optuna.visualization._contour import _get_contour_info
  from optuna.visualization._contour import _PlotValues
  from optuna.visualization._contour import _SubContourInfo
  from optuna.visualization.matplotlib._matplotlib_imports import _imports
label_desc: Use image node_id 1 for calling a global function with example usage: plot_contour(study, params) and returns: _get_contour_plot