def forward(self, batch: torch.Tensor, quantization: Callable) -> tuple[torch.Tensor, torch.Tensor]:
        """Generate the quantized anomaly-free representation of an anomalous image.

        Args:
            batch (torch.Tensor): Batch of input images.
            quantization (function | object): Quantization function.

        Returns:
            Reconstructed batch of non-quantized features and corresponding quantized features.
        """
        batch = self.unet(batch)
        quantized_b = quantization(batch)
        return batch, quantized_b
Generate the quantized anomaly-free representation of an anomalous image.

        Args:
            batch (torch.Tensor): Batch of input images.
            quantization (function | object): Quantization function.

        Returns:
            Reconstructed batch of non-quantized features and corresponding quantized features.
        
src/anomalib/models/image/dsr/torch_model.py