lenskit.logging.resource#

Measure resource consumption.

Functions

reset_linux_hwm()

Classes

ResourceMeasurement(wall_time, perf_time, ...)

Single measurement of resources.

class lenskit.logging.resource.ResourceMeasurement(wall_time, perf_time, user_time, system_time, max_rss=None, max_gpu=None)#

Bases: object

Single measurement of resources. Two measurements can be subtracted to compute the time resources consumed in an interval (memory resources are left unchanged).

Parameters:
classmethod current()#

Get the current resource measurements.

property cpu_time: float#

Total CPU time (user + system).