MCPcopy
hub / github.com/stas00/ml-engineering / elapsed_time

Method elapsed_time

compute/accelerator/benchmarks/mamf-finder.py:168–171  ·  view source on GitHub ↗
(self, other)

Source from the content-addressed store, hash-verified

166 self._timestamp = time.perf_counter()
167
168 def elapsed_time(self, other):
169 if self._timestamp is None or other._timestamp is None:
170 raise RuntimeError("Attempted to measure elapsed time before events were recorded")
171 return (other._timestamp - self._timestamp) * 1000.0
172
173class MPSArch(Arch):
174 """ Apple Silicon GPUs via Metal Performance Shaders """

Callers 6

timed_allreduceFunction · 0.80
timed_allreduceFunction · 0.80
benchmark_bmmFunction · 0.80
func_wrapperFunction · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected