grogupy.batch.DefaultTimer

class grogupy.batch.DefaultTimer[source]

This class measures and stores the runtime of each object.

Upon initialization the clock is started.

Methods

restart() :

It restarts the timer

measure(function) :

It measures the runtime and writes to times[function]

Attributes

times: dict

It contains the runtimes

__init__()[source]

Initialize timer.

Methods

__init__()

Initialize timer.

measure(key[, restart])

Saves the measurement time.

restart()

Resets the measurement time.

Attributes

times