• Docs >
  • Utils >
  • torchtnt.utils.timer.get_durations_histogram
Shortcuts

torchtnt.utils.timer.get_durations_histogram

torchtnt.utils.timer.get_durations_histogram(recorded_durations: Dict[str, List[float]], percentiles: Sequence[float]) Dict[str, Dict[str, float]]

Computes a histogram of percentiles from the recorded durations passed in.

Parameters:
  • recorded_durations – The mapping of durations to sync and compute histograms from.
  • percentiles – The percentiles to compute. Values should be in the range [0, 100].
Returns:

A dictionary mapping the action names to a dictionary of the computed percentiles, along with the mean duration of each action.

Raises:

ValueError – If the input percentiles are not in the range [0, 100].

Docs

Access comprehensive developer documentation for PyTorch

View Docs

Tutorials

Get in-depth tutorials for beginners and advanced developers

View Tutorials

Resources

Find development resources and get your questions answered

View Resources