ts.metrics package¶
Submodules¶
ts.metrics.dimension module¶
Dimension class for model server metrics
ts.metrics.metric module¶
Metric class for model server
ts.metrics.metric_collector module¶
Single start point for system metrics and process metrics script
ts.metrics.metric_encoder module¶
Metric Encoder class for json dumps
ts.metrics.metrics_store module¶
Metrics collection module
- class ts.metrics.metrics_store.MetricsStore(request_ids, model_name)[source]¶
Bases:
object
DEPRECATED Class for creating, modifying different metrics. And keep them in a dictionary
- add_counter(name, value, idx=None, dimensions=None)[source]¶
Add a counter metric or increment an existing counter metric
- add_error(name, value, dimensions=None)[source]¶
Add a Error Metric :param name: metric name :type name: str :param value: value of metric, in this case a str :type value: str :param dimensions: list of dimensions for the metric :type dimensions: list
- add_metric(name, value, unit, idx=None, dimensions=None)[source]¶
Add a metric which is generic with custom metrics
ts.metrics.process_memory_metric module¶
Collect process memory usage metrics here Pass a json, collection of pids and gpuID
ts.metrics.system_metrics module¶
Module to collect system metrics for front-end
- ts.metrics.system_metrics.collect_all(mod, num_of_gpu)[source]¶
Collect all system metrics.
- Parameters:
mod –
num_of_gpu –
- Returns:
ts.metrics.unit module¶
Module to define Unit mappings
Module contents¶
This is a folder for all python worker metrics.