def __init_subclass__(cls, **kwargs) -> None:
        """Ensure that the subclass has the required attributes.

        Args:
            **kwargs: Additional keyword arguments passed to the parent class.

        Raises:
            AttributeError: If the subclass does not define ``numpy_class``.
        """
        super().__init_subclass__(**kwargs)
        if not hasattr(cls, "numpy_class"):
            msg = f"{cls.__name__} must have a 'numpy_class' attribute."
            raise AttributeError(msg)
Ensure that the subclass has the required attributes.

        Args:
            **kwargs: Additional keyword arguments passed to the parent class.

        Raises:
            AttributeError: If the subclass does not define ``numpy_class``.
        
src/anomalib/data/dataclasses/torch/base.py