code: def _select_parents(
      crossover: BaseCrossover,
      study: Study,
      parent_population: Sequence[FrozenTrial],
      rng: np.random.RandomState,
      dominates: Callable[
          [FrozenTrial, FrozenTrial, Sequence[StudyDirection]], bool
      ],
  ) -> List[FrozenTrial]:
      parents: List[FrozenTrial] = []
      for _ in range(crossover.n_parents):
          parent = _select_parent(
              study,
              [t for t in parent_population if t not in parents],
              rng,
              dominates,
          )
          parents.append(parent)
  
      return parents
  
imports: from typing import Any
  from typing import Callable
  from typing import Dict
  from typing import List
  from typing import Optional
  from typing import Sequence
  import numpy
  from optuna._transform import _SearchSpaceTransform
  from optuna.distributions import BaseDistribution
  from optuna.distributions import FloatDistribution
  from optuna.distributions import IntDistribution
  from optuna.samplers.nsgaii._crossovers._base import BaseCrossover
  from optuna.study import Study
  from optuna.study import StudyDirection
  from optuna.trial import FrozenTrial
label_desc: Use image node_id 3 for calling a global function with example usage: _select_parents(crossover, study, parent_population, rng, dominates) and returns: parents