bluecast.ml_modelling.base_classes¶
Base classes for all ML models.
Module Contents¶
Classes¶
Base class for all ML models. |
|
Base class for all ML models. |
Attributes¶
- bluecast.ml_modelling.base_classes.PredictedProbas¶
- bluecast.ml_modelling.base_classes.PredictedClasses¶
- class bluecast.ml_modelling.base_classes.BaseClassMlModel¶
Bases:
abc.ABCBase class for all ML models.
Enforces the implementation of the fit and predict methods. If hyperparameter tuning is required, then the fit method should implement the tuning.
- abstract fit(x_train: pandas.DataFrame, x_test: pandas.DataFrame, y_train: pandas.Series, y_test: pandas.Series) Any | None¶
- abstract predict(df: pandas.DataFrame) Tuple[PredictedProbas, PredictedClasses]¶
Predict on unseen data.
:return tuple of predicted probabilities and predicted classes
- class bluecast.ml_modelling.base_classes.BaseClassMlRegressionModel¶
Bases:
abc.ABCBase class for all ML models.
Enforces the implementation of the fit and predict methods. If hyperparameter tuning is required, then the fit method should implement the tuning.
- abstract fit(x_train: pandas.DataFrame, x_test: pandas.DataFrame, y_train: pandas.Series, y_test: pandas.Series) Any | None¶
- abstract predict(df: pandas.DataFrame) numpy.ndarray¶
Predict on unseen data.
:return numpy array of predictions