bluecast.blueprints.custom_model_recipes

Module Contents

Classes

LogisticRegressionModel

Base class for all ML models.

LinearRegressionModel

Base class for all ML models.

class bluecast.blueprints.custom_model_recipes.LogisticRegressionModel(max_iter=100000, random_state=300)

Bases: bluecast.ml_modelling.base_classes.BaseClassMlModel

Base 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.

autotune(x_train: pandas.DataFrame, x_test: pandas.DataFrame, y_train: pandas.Series, y_test: pandas.Series)
fit(x_train: pandas.DataFrame, x_test: pandas.DataFrame, y_train: pandas.Series, y_test: pandas.Series) None
predict(df: pandas.DataFrame) Tuple[bluecast.ml_modelling.base_classes.PredictedProbas, bluecast.ml_modelling.base_classes.PredictedClasses]

Predict on unseen data.

:return tuple of predicted probabilities and predicted classes

class bluecast.blueprints.custom_model_recipes.LinearRegressionModel

Bases: bluecast.ml_modelling.base_classes.BaseClassMlModel

Base 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.

autotune(x_train: pandas.DataFrame, x_test: pandas.DataFrame, y_train: pandas.Series, y_test: pandas.Series)
fit(x_train: pandas.DataFrame, x_test: pandas.DataFrame, y_train: pandas.Series, y_test: pandas.Series) None
predict(df: pandas.DataFrame) Tuple[bluecast.ml_modelling.base_classes.PredictedProbas, bluecast.ml_modelling.base_classes.PredictedClasses]

Predict on unseen data.

:return tuple of predicted probabilities and predicted classes