mirror of
https://github.com/open-compass/opencompass.git
synced 2025-05-30 16:03:24 +08:00
fix potential oom issue (#387)
This commit is contained in:
parent
b9b145c335
commit
722eb39526
@ -141,6 +141,7 @@ class MDLRetriever(TopkRetriever):
|
||||
"""Retrieve the in-context example index for each test example."""
|
||||
return self.topk_search()
|
||||
|
||||
@torch.no_grad()
|
||||
def cal_ce(self, input_texts: List[str], mask_length=None):
|
||||
if self.metric_model is None:
|
||||
logger.info(
|
||||
|
Loading…
Reference in New Issue
Block a user