code: def _get_pareto_front_trials_by_trials(
      trials: Sequence[FrozenTrial],
      directions: Sequence[StudyDirection],
  ) -> List[FrozenTrial]:
      if len(directions) == 2:
          return _get_pareto_front_trials_2d(
              trials, directions
          )  # Log-linear in number of trials.
      return _get_pareto_front_trials_nd(trials, directions)
  
file_path: optuna/optuna/study/_multi_objective.py
imports: from typing import List
  from typing import Optional
  from typing import Sequence
  import optuna
  from optuna.study._study_direction import StudyDirection
  from optuna.trial import FrozenTrial
  from optuna.trial import TrialState
label_desc: Use image node_id 3 for calling a global function with example usage: _get_pareto_front_trials_by_trials(trials, directions) and returns: _get_pareto_front_trials_nd, _get_pareto_front_trials_2d