class_docstr: Dataset wraps pandas DataFrame together with ML related metadata.
  
  The Dataset class is containing additional data and methods intended for easily accessing
  metadata relevant for the training or validating of an ML models.
  
  Parameters
  ----------
  df : Any
      An object that can be casted to a pandas DataFrame
       - containing data relevant for the training or validating of a ML models.
  label : t.Union[Hashable, pd.Series, pd.DataFrame, np.ndarray] , default: None
      label column provided either as a string with the name of an existing column in the DataFrame or a label
      object including the label data (pandas Series/DataFrame or a numpy array) that will be concatenated to the
      data in the DataFrame. in case of label data the following logic is applied to set the label name:
  
      - Series: takes the series name or 'target' if name is empty
      - DataFrame: expect single column in the dataframe and use its name
      - numpy: use 'target'
  
  features : t.Optional[t.Sequence[Hashable]] , default: None
      List of names for the feature columns in the DataFrame.
  cat_features : t.Optional[t.Sequence[Hashable]] , default: None
      List of names for the categorical features in the DataFrame. In order to disable categorical.
      features inference, pass cat_features=[]
  index_name : t.Optional[Hashable] , default: None
      Name of the index column in the dataframe. If set_index_from_dataframe_index is True and index_name
      is not None, index will be created from the dataframe index level with the given name. If index levels
      have no names, an int must be used to select the appropriate level by order.
  set_index_from_dataframe_index : bool , default: False
      If set to true, index will be created from the dataframe index instead of dataframe columns (default).
      If index_name is None, first level of the index will be used in case of a multilevel index.
  datetime_name : t.Optional[Hashable] , default: None
      Name of the datetime column in the dataframe. If set_datetime_from_dataframe_index is True and datetime_name
      is not None, date will be created from the dataframe index level with the given name. If index levels
      have no names, an int must be used to select the appropriate level by order.
  set_datetime_from_dataframe_index : bool , default: False
      If set to true, date will be created from the dataframe index instead of dataframe columns (default).
      If datetime_name is None, first level of the index will be used in case of a multilevel index.
  convert_datetime : bool , default: True
      If set to true, date will be converted to datetime using pandas.to_datetime.
  datetime_args : t.Optional[t.Dict] , default: None
      pandas.to_datetime args used for conversion of the datetime column.
      (look at https://pandas.pydata.org/docs/reference/api/pandas.to_datetime.html for more documentation)
  max_categorical_ratio : float , default: 0.01
      The max ratio of unique values in a column in order for it to be inferred as a
      categorical feature.
  max_categories : int , default: None
      The maximum number of categories in a column in order for it to be inferred as a categorical
      feature. if None, uses is_categorical default inference mechanism.
  label_type : str , default: None
      Used to determine the task type. If None, inferred when running a check based on label column and model.
      Possible values are: 'multiclass', 'binary' and 'regression'.
docstr: Return True if label column exists.
  
  Returns
  -------
  bool
     True if label column exists.
docstr_tok: ["Return","True","if","label","column","exists",".","Returns","--","--","--","-","bool","True","if","label","column","exists","."]
code: def has_label(self) -> bool:
      """Return True if label column exists.
  
      Returns
      -------
      bool
         True if label column exists.
      """
      return self._label_name is not None
  
imports: import typing
  import warnings
  from collections import Counter
  import numpy
  import pandas
  from IPython.display import HTML, display_html
  from pandas.api.types import infer_dtype
  from sklearn.model_selection import train_test_split
  from typing_extensions import Literal
  from deepchecks.core.errors import DatasetValidationError, DeepchecksNotSupportedError, DeepchecksValueError
  from deepchecks.tabular.utils.task_type import TaskType
  from deepchecks.utils.dataframes import select_from_dataframe
  from deepchecks.utils.logger import get_logger
  from deepchecks.utils.strings import get_docs_link
  from deepchecks.utils.type_inference import infer_categorical_features, infer_numerical_features
  from deepchecks.utils.typing import Hashable
label_desc: Use image node_id 25 for calling the Dataset obj's underlying member method code with example usage: obj.has_label() and returns: unknown