<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def update_metric(self, eval_metric, labels, pre_sliced=False):
 """Evaluates and accumulates evaluation metric on outputs of the last forward computation. Subclass should override this method if needed. Parameters eval_metric : EvalMetric labels : list of NDArray Typically ``data_batch.label``. """

        if self._label_shapes is None:
            # since we do not need labels, we are probably not a module with a loss
            # function or predictions, so just ignore this call
            return

        if pre_sliced:
            raise RuntimeError("PythonModule does not support presliced labels")

        # by default we expect our outputs are some scores that could be evaluated
        eval_metric.update(labels, self.get_outputs())