def training_step(self, batch: Batch, *args, **kwargs) -> None:
        """Perform the training step of PADIM.

        For each batch, hierarchical features are extracted from the CNN.

        Args:
            batch (Batch): Input batch containing image and metadata
            args: Additional arguments (unused)
            kwargs: Additional keyword arguments (unused)

        Returns:
            torch.Tensor: Dummy loss tensor for Lightning compatibility
        """
        del args, kwargs  # These variables are not used.

        embedding = self.model(batch.image)
        self.embeddings.append(embedding)

        # Return a dummy loss tensor
        return torch.tensor(0.0, requires_grad=True, device=self.device)
Perform the training step of PADIM.

        For each batch, hierarchical features are extracted from the CNN.

        Args:
            batch (Batch): Input batch containing image and metadata
            args: Additional arguments (unused)
            kwargs: Additional keyword arguments (unused)

        Returns:
            torch.Tensor: Dummy loss tensor for Lightning compatibility
        
src/anomalib/models/image/padim/lightning_model.py