MCPcopy Create free account
hub / github.com/tensorpack/tensorpack / display_results

Function display_results

tests/benchmark-serializer.py:40–47  ·  view source on GitHub ↗
(name, results)

Source from the content-addressed store, hash-verified

38
39
40def display_results(name, results):
41 logger.info("Encoding benchmark for {}:".format(name))
42 data = sorted(((x, y[0]) for x, y in results), key=operator.itemgetter(1))
43 print(tabulate(data, floatfmt='.5f'))
44
45 logger.info("Decoding benchmark for {}:".format(name))
46 data = sorted(((x, y[1]) for x, y in results), key=operator.itemgetter(1))
47 print(tabulate(data, floatfmt='.5f'))
48
49
50def benchmark_all(name, serializers, data, num=30):

Callers 1

benchmark_allFunction · 0.85

Calls 1

formatMethod · 0.80

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…