def METHOD_NAME(
    self,
    _mode: str,
    cached_results: List[dict],
    _dump_dir: str = None,
):
    result = self.parse_cached_results(cached_results)
    target = torch.stack(result["label"], dim=0)
    prediction_logit = torch.stack(result["logit"], dim=0)
    prediction = torch.stack(result["prediction"], dim=0)
    loss = self.logit_loss(prediction_logit, target)
    logs = dict(
        loss=loss.detach().cpu().item(),
    )
    if _mode in ["valid", "test"]:
        logs.update(
            self.log_scores(
                score_args=(
                    prediction.detach().cpu().numpy(),
                    target.detach().cpu().numpy(),
                ),
            )
        )
    return logs