code: def _list_available_datasets(extract_path, origin_repo=None):
      """Return a list of all the currently downloaded datasets.
  
      Forecastingorg datasets are in the format <dataset_name>.tsf while classification
      are in the format <dataset_name>_TRAIN.ts and <dataset_name>_TEST.ts.
      To count as available, each directory <dir_name>
      in the extract_path must contain files called
      1. <dir_name>_TRAIN.ts and <dir_name>_TEST.ts if datasets from classification repo.
      2. <dir_name>.tsf if datasets from forecasting repo.
  
      Parameters
      ----------
      extract_path: string
          root directory where to look for files, if None defaults to sktime/datasets/data
      origin_repo: string, optional (default=None)
          if None, returns all available classification datasets in extract_path,
          if string (must be "forecastingorg"), returns all available
          forecastingorg datasets in extract_path.
  
      Returns
      -------
      datasets : List
          List of the names of datasets downloaded
      """
      if extract_path is None:
          data_dir = os.path.join(MODULE, "data")
      else:
          data_dir = extract_path
      datasets = []
      for name in os.listdir(data_dir):
          sub_dir = os.path.join(data_dir, name)
          if os.path.isdir(sub_dir):
              all_files = os.listdir(sub_dir)
              if origin_repo == "forecastingorg":
                  if name + ".tsf" in all_files:
                      datasets.append(name)
              else:
                  if (
                      name + "_TRAIN.ts" in all_files
                      and name + "_TEST.ts" in all_files
                  ):
                      datasets.append(name)
      return datasets
  
file_path: sktime/sktime/datasets/_data_io.py
imports: import os
  import shutil
  import tempfile
  import zipfile
  from urllib.request import urlretrieve
  import numpy
  import pandas
  from sktime.datasets._readers_writers.ts import load_from_tsfile
  from sktime.datasets._readers_writers.utils import _alias_mtype_check
  from sktime.datatypes import convert
  from sktime.datatypes._panel._convert import _make_column_names
label_desc: Use image node_id 2 for calling a global function with example usage: _list_available_datasets(extract_path, origin_repo) and returns: datasets