MCPcopy Create free account
hub / github.com/twitter/the-algorithm-ml / Count

Class Count

core/test_metrics.py:17–19  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

15
16
17class Count(MetricMixin, SumMetric):
18 def transform(self, outputs):
19 return {"value": 1}
20
21
22Max = prepend_transform(MaxMetric, lambda outputs: {"value": outputs["value"]})

Callers 2

test_count_metricFunction · 0.70
test_collectionsFunction · 0.70

Calls

no outgoing calls

Tested by 2

test_count_metricFunction · 0.56
test_collectionsFunction · 0.56