def update(
        self, outputs: torch.Tensor, targets: torch.Tensor
    ) -> Tuple[Any, Any, Any, Any]:
        """
        Update statistics and return intermediate metrics results

        Args:
            outputs: prediction values
            targets: true answers

        Returns:
            tuple of metrics intermediate results with per-class, micro, macro and
                weighted averaging

        """
        tn, fp, fn, tp, support, num_classes = super().update(
            outputs=outputs, targets=targets
        )
        per_class, micro, macro, weighted = get_aggregated_metrics(
            tp=tp, fp=fp, fn=fn, support=support, zero_division=self.zero_division
        )
        if self.num_classes is None:
            self.num_classes = num_classes

        return per_class, micro, macro, weighted

        Update statistics and return intermediate metrics results

        Args:
            outputs: prediction values
            targets: true answers

        Returns:
            tuple of metrics intermediate results with per-class, micro, macro and
                weighted averaging

        
catalyst/metrics/_classification.py