def _create_zip_file(self, directory):
        """Helper function to create a zip file."""
        text_file_path = os.path.join(directory, "test.txt")
        zip_file_path = os.path.join(directory, "test.zip")
        with open(text_file_path, "w") as text_file:
            text_file.write("Float like a butterfly, sting like a bee.")

        with zipfile.ZipFile(zip_file_path, "w") as zip_file:
            zip_file.write(text_file_path, arcname="test.txt")

        return text_file_path, zip_file_path
Helper function to create a zip file.
keras/src/utils/file_utils_test.py