code: def validate_dataset(ml_task_type=None, dataset_name=None):
      if ml_task_type is None:
          raise MLTaskTypeMissing(
              "ML Task type is missing. Please provide a valid 'ml_task_type'."
          )
  
      if dataset_name is None:
          raise DatasetNameMissing(
              "Dataset name is missing. Please provide a valid 'dataset_name'."
          )
  
      if ml_task_type not in SUPPORTED_TASK_TYPES:
          raise UnsupportedMLTaskType(
              f"ML Task type '{ml_task_type}' is not supported. Supported types are: {SUPPORTED_TASK_TYPES}"
          )
  
      dataset_path = (
          DATASETS_BASE_PATH / ml_task_type / f"{dataset_name}.csv"
      )
  
      if not dataset_path.exists():
          raise DatasetNotFound(
              f"Dataset '{dataset_name}' for ML Task type '{ml_task_type}' not found '{dataset_path}'."
          )
  
      return dataset_path
  
file_path: mindsdb/mindsdb/integrations/utilities/datasets/dataset.py
imports: from pathlib import Path
  import pandas
label_desc: Use image node_id 1 for calling a global function with example usage: validate_dataset(ml_task_type, dataset_name) and returns: dataset_path