class_docstr: Base class that defines the default pipeline for loading a ludwig dataset.
  
  Clients will typically call load(), which processes the dataset according to the config.
  
  A dataset is processed in 4 phases:
      1. Download       - The dataset files are downloaded to the cache.
      2. Verify         - Hashes of downloaded files are verified.
      3. Extract        - The dataset files are extracted from an archive (may be a no-op if data is not archived).
      4. Transform      - The dataset is transformed into a format usable for training and is ready to load.
          a. Transform Files      (Files -> Files)
          b. Load Dataframe       (Files -> DataFrame)
          c. Transform Dataframe  (DataFrame -> DataFrame)
          d. Save Processed       (DataFrame -> File)
  
  The download and extract phases are run for each URL based on the URL type and file extension. After extraction, the
  full set of downloaded and extracted files are collected and passed as a list to the transform stage.
  
  The transform phase offers customization points for datasets which require preprocessing before they are usable for
  training.
class_docstr_tok: ["Base","class","that","defines","the","default","pipeline","for","loading","a","ludwig","dataset",".","Clients","will","typically","call","load","(",")",",","which","processes","the","dataset","according","to","the","config",".","A","dataset","is","processed","in","4","phases",":","1",".","Download","-","The","dataset","files","are","downloaded","to","the","cache",".","2",".","Verify","-","Hashes","of","downloaded","files","are","verified",".","3",".","Extract","-","The","dataset","files","are","extracted","from","an","archive","(","may","be","a","no-op","if","data","is","not","archived",")",".","4",".","Transform","-","The","dataset","is","transformed","into","a","format","usable","for","training","and","is","ready","to","load",".","a.","Transform","Files","(","Files","-",">","Files",")","b",".","Load","Dataframe","(","Files","-",">","DataFrame",")","c.","Transform","Dataframe","(","DataFrame","-",">","DataFrame",")","d.","Save","Processed","(","DataFrame","-",">","File",")","The","download","and","extract","phases","are","run","for","each","URL","based","on","the","URL","type","and","file","extension",".","After","extraction",",","the","full","set","of","downloaded","and","extracted","files","are","collected","and","passed","as","a","list","to","the","transform","stage",".","The","transform","phase","offers","customization","points","for","datasets","which","require","preprocessing","before","they","are","usable","for","training","."]
code: def download(
      self,
      kaggle_username: str | None = None,
      kaggle_key: str | None = None,
  ) -> list[str]:
      if not os.path.exists(self.raw_dataset_dir):
          os.makedirs(self.raw_dataset_dir)
      if self.is_kaggle_dataset:
          return download_kaggle_dataset(
              self.raw_dataset_dir,
              kaggle_dataset_id=self.config.kaggle_dataset_id,
              kaggle_competition=self.config.kaggle_competition,
              kaggle_username=kaggle_username,
              kaggle_key=kaggle_key,
          )
      else:
          for url, filename in zip(
              self.download_urls, self.download_filenames
          ):
              downloaded_file_path = os.path.join(
                  self.raw_dataset_dir, filename
              )
              with TqdmUpTo(
                  unit="B",
                  unit_scale=True,
                  unit_divisor=1024,
                  miniters=1,
                  desc=filename,
              ) as t:
                  urllib.request.urlretrieve(
                      url, downloaded_file_path, t.update_to
                  )
  
imports: from __future__ import annotations
  import glob
  import hashlib
  import logging
  import os
  import shutil
  import urllib
  from enum import Enum
  from urllib.parse import urlparse
  import pandas
  from tqdm import tqdm
  from ludwig.api_annotations import DeveloperAPI, PublicAPI
  from ludwig.constants import SPLIT
  from ludwig.datasets.archives import extract_archive, is_archive, list_archive
  from ludwig.datasets.dataset_config import DatasetConfig, DatasetFallbackMirror
  from ludwig.datasets.kaggle import download_kaggle_dataset
  from ludwig.datasets.utils import model_configs_for_dataset
  from ludwig.utils.fs_utils import get_default_cache_location, get_fs_and_path
  from ludwig.utils.strings_utils import make_safe_filename
label_desc: Use image node_id 24 for calling the DatasetLoader obj's underlying member method code with example usage: obj.download(kaggle_username, kaggle_key) and returns: download_kaggle_dataset