code: def extend_pending_observations(
      experiment: Experiment,
      pending_observations: Dict[str, List[ObservationFeatures]],
      generator_run: GeneratorRun,
  ) -> None:
      """Extend given pending observations dict (from metric name to observations
      that are pending for that metric), with arms in a given generator run.
      """
      for m in experiment.metrics:
          if m not in pending_observations:
              pending_observations[m] = []
          pending_observations[m].extend(
              ObservationFeatures.from_arm(a)
              for a in generator_run.arms
          )
  
imports: from collections import defaultdict
  from typing import Dict, Iterable, List, NamedTuple, Optional, Set, Tuple
  import numpy
  from ax.core.arm import Arm
  from ax.core.base_trial import BaseTrial, TrialStatus
  from ax.core.batch_trial import BatchTrial
  from ax.core.data import Data
  from ax.core.experiment import Experiment
  from ax.core.generator_run import GeneratorRun
  from ax.core.objective import MultiObjective
  from ax.core.observation import ObservationFeatures
  from ax.core.optimization_config import OptimizationConfig
  from ax.core.trial import Trial
  from ax.core.types import ComparisonOp
  from ax.utils.common.typeutils import not_none
  from pyre_extensions import none_throws
label_desc: Use image node_id 11 for calling a global function with example usage: extend_pending_observations(experiment, pending_observations, generator_run) without return types