# ---
# jupyter:
#   jupytext:
#     text_representation:
#       extension: .py
#       format_name: light
#       format_version: '1.5'
#       jupytext_version: 1.14.4
#   kernelspec:
#     display_name: Python 3
#     language: python
#     name: python3
# ---

# # GML - Regressor

# Install it first

# !pip install GML

# Loading Regression dataset from sklearn

from sklearn.datasets import load_boston

# Importing GML

from GML.Ghalat_Machine_Learning import Ghalat_Machine_Learning

# Making object with 100 estimators

# Also importing another model from sklearn to make it compete with GML's models

from sklearn.neural_network import MLPRegressor

model = Ghalat_Machine_Learning(n_estimators=100)

# storing data in X,y

X,y = load_boston(return_X_y=True)

# Passing the data to classifier

best_model = model.GMLRegressor(X,y,neural_net='Yes',epochs=50,
                                 verbose=0,models=[MLPRegressor()])

best_model

# So from above results, we can see 
#
# ExtraTreesRegressor CV performed really well! and our custom model, MLPRegressor ended up 11th.
#
# Ranks are based upon validation loss

# See how easy it was!

StarcoderdataJupyterScriptsDedupFiltered