crumpets.timing module¶
- class crumpets.timing.ETATimer(goal)[source]¶
Bases:
crumpets.timing.RemainingTimerSimple modification of the RemainingTimer. When called, instead of returning remainin time, return ETA (estimated time of arrival).
- class crumpets.timing.RemainingTimer(goal)[source]¶
Bases:
objectEstimates remaining time of some operation. Each time it is called, an internal counter is increased by 1. The measured operation is assumed to be done once this counter reaches goal. Out of the frequency of the calls one can compute an estimated speed and thus remaining time.
- Parameters
goal – the number of calls until the operation is assumed to be done.