pyconstruct.learners.BaseLearner.fit

BaseLearner.fit(X, Y, Y_pred=None, **kwargs)

Fit a model with data (X, Y).

Parameters:
  • X (numpy.ndarray) – Input examples. The first dimension must be the dataset size.
  • Y (numpy.ndarray) – Output objects. The first dimension must be the dataset size. This must coincide with batch size for X.
  • Y_pred (numpy.ndarray) – Predictions of the algorithm. The first dimension must be the batch size. This must coincide with dataset size for X. If None, either not needed or done internally.
Returns:

Return type:

self