MlbendMetrics.count_pred.go: def of mlbend-metrics@0.1.0.0 Import: import mlbend-metrics@0.1.0.0/main.bend as MlbendMetrics Lines 62-68 of mlbend-metrics@0.1.0.0/main.bend: https://jend.leeeet.dev/read.txt?path=mlbend-metrics@0.1.0.0/main.bend&start_line=62&end_line=68 import Base # the number of samples whose predicted label is k def count_pred.go(ps: List<&2, Nat>, +k: Nat, n: Nat) -> Nat: match ps: case Nil{}: n case Con{p, pt}: count_pred.go(pt, k, (n + same(p, k) : Nat)) Uses (4): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=List https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Nat https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Nat.add https://jend.leeeet.dev/definition.txt?path=mlbend-metrics@0.1.0.0/main.bend&name=same