code: def _get_distribution(
      param_name: str, study: Study
  ) -> BaseDistribution:
      for trial in study.trials:
          if param_name in trial.distributions:
              return trial.distributions[param_name]
      assert False
  
imports: from __future__ import annotations
  from typing import Callable
  from typing import NamedTuple
  import optuna
  from optuna.distributions import BaseDistribution
  from optuna.importance._base import BaseImportanceEvaluator
  from optuna.logging import get_logger
  from optuna.study import Study
  from optuna.trial import FrozenTrial
  from optuna.trial import TrialState
  from optuna.visualization._plotly_imports import _imports
  from optuna.visualization._utils import _check_plot_args
  from optuna.visualization._utils import _filter_nonfinite
label_desc: Use image node_id 5 for calling a global function with example usage: _get_distribution(param_name, study) and returns: trial