Toggle Menu
Prev Up Next

scikit-learn 1.3.2
Other versions

Please cite us if you use the software.

# `sklearn.exceptions`.DataConversionWarning

class sklearn.exceptions.DataConversionWarning

  Warning used to notify implicit data conversions happening in the code.

  This warning occurs when some input data needs to be converted or interpreted in a way that may not match the user’s expectations.

  For example, this warning may occur when the user

    - passes an integer array to a function which expects float input and will convert the input

    - requests a non-copying operation, but a copy is required to meet the implementation’s data-type expectations;

    - passes an input whose shape can be interpreted ambiguously.

  Changed in version 0.18: Moved from sklearn.utils.validation.

  Attributes:
    args

  Methods

  `add_note` | Exception.add_note(note) -- add a note to the exception
  `with_traceback` | Exception.with_traceback(tb) -- set self.__traceback__ to tb and return self.

  add_note()

    Exception.add_note(note) – add a note to the exception

  with_traceback()

    Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.