def prepare_data(self) -> None:
        """Download and extract the dataset if not already available.

        The method checks if the dataset directory exists. If not, it downloads
        and extracts the dataset to the specified root directory.
        """
        if (self.root / self.category).is_dir():
            logger.info("Found the dataset.")
        else:
            download_and_extract(self.root, DOWNLOAD_INFO)

            # move contents to root
            extracted_folder = self.root / "UCSD_Anomaly_Dataset.v1p2"
            for filename in extracted_folder.glob("*"):
                move(str(filename), str(self.root / filename.name))
            extracted_folder.rmdir()
Download and extract the dataset if not already available.

        The method checks if the dataset directory exists. If not, it downloads
        and extracts the dataset to the specified root directory.
        
src/anomalib/data/datamodules/video/ucsd_ped.py