ray.util.metrics.Gauge#
- class ray.util.metrics.Gauge(name: str, description: str = '', tag_keys: Tuple[str, ...] | None = None)[source]#
Bases:
Metric
Gauges keep the last recorded value and drop everything before.
Unlike counters, gauges can go up or down over time.
This corresponds to Prometheus’ gauge metric: https://prometheus.io/docs/concepts/metric_types/#gauge
- Parameters:
name – Name of the metric.
description – Description of the metric.
tag_keys – Tag keys of the metric.
DeveloperAPI: This API may change across minor Ray releases.
Methods
Set the gauge to the given
value
.Set default tags of metrics.
Attributes
Return the information of this metric.