code: def _compute_percentiles(
      durations: Dict[str, List[float]], percentiles: Sequence[float]
  ) -> Dict[str, Dict[str, float]]:
      ret = {}
      for name, values in durations.items():
          ret[name] = _compute_percentile(
              name, values, percentiles=percentiles
          )
      return ret
  
imports: import datetime
  import logging
  import os
  from collections import defaultdict
  from contextlib import contextmanager
  from time import perf_counter
  from typing import Any, Dict, Generator, List, Optional, Protocol, runtime_checkable, Sequence, Tuple, TypeVar
  import numpy
  import torch
  import torch.distributed
  from tabulate import tabulate
  from torchtnt.utils.distributed import PGWrapper
label_desc: Use image node_id 9 for calling a global function with example usage: _compute_percentiles(durations, percentiles) and returns: ret