MCPcopy Create free account
hub / github.com/OpenBitSys/BitDistiller / process_results

Method process_results

test/general/lm_eval/base.py:754–764  ·  view source on GitHub ↗
(self, doc, results)

Source from the content-addressed store, hash-verified

752 return lls
753
754 def process_results(self, doc, results):
755 gold = doc["gold"]
756
757 acc = 1.0 if np.argmax(results) == gold else 0.0
758 completion_len = np.array([float(len(i)) for i in doc["choices"]])
759 acc_norm = 1.0 if np.argmax(results / completion_len) == gold else 0.0
760
761 return {
762 "acc": acc,
763 "acc_norm": acc_norm,
764 }
765
766 def higher_is_better(self):
767 return {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected