MCPcopy Create free account
hub / github.com/huggingface/evaluate / __call__

Method __call__

tests/test_evaluator.py:76–79  ·  view source on GitHub ↗
(self, inputs, **kwargs)

Source from the content-addressed store, hash-verified

74 self.sleep_time = sleep_time
75
76 def __call__(self, inputs, **kwargs):
77 if self.sleep_time is not None:
78 sleep(self.sleep_time)
79 return [{"label": "NEGATIVE"} if i % 2 == 1 else {"label": "POSITIVE"} for i, _ in enumerate(inputs)]
80
81
82class DummyImageClassificationPipeline:

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected