code: def dataset_list_from_config(config: DictConfig) -> List[str]:
      if "datasets" not in config:
          warnings.warn(
              "No datasets attribute present. Setting default to vqa2."
          )
          datasets = "vqa2"
      else:
          datasets = config.datasets
  
      if type(datasets) == str:
          datasets = list(map(lambda x: x.strip(), datasets.split(",")))
  
      return datasets
  
imports: import warnings
  from typing import List
  import torch
  from mmf.common.sample import Sample
  from omegaconf import DictConfig
label_desc: Use image node_id 3 for calling a global function with example usage: dataset_list_from_config(config) and returns: datasets