Giter Club home page Giter Club logo

Comments (6)

sonichi avatar sonichi commented on May 13, 2024

What's the definition of monotonicity? Assuming the data has only one feature x and requiring the model prediction as a monotonic function of x?

from flaml.

flippercy avatar flippercy commented on May 13, 2024

Yes. Ideally it would work as the monotone_constraints in xgboost.

from flaml.

sonichi avatar sonichi commented on May 13, 2024

It's easy to add your custom XGBoost learner by inheriting the class XGBoostEstimator (regression) or XGBoostSklearnEstimator (classification) from flaml.model. See section 3 of the notebook as an example.

In the constructor of the inherited estimator, set the monotonicity constraint you want to use in self.params,
after calling super().__init__(). For example, for regression, use

class MonotonicXGBoostEstimator(XGBoostEstimator):

----def __init__(self, **params):
--------super().__init__(**params)
--------self.params["monotone_constraints"] = "(1,-1)"

from flaml.

flippercy avatar flippercy commented on May 13, 2024

Thank you for the response!

One extra question: it seems that the goal of automl is to fit the best ML model rather than mere hyperparameter tuning, is there any plan to also test and return ensembles of base models built during the search (such as a linear ensemble of the best model of each algorithm) ?

Best,

from flaml.

sonichi avatar sonichi commented on May 13, 2024

You can set ensemble=True in the fit() function. It will build a stacked ensemble using the best models.

Please let me know if that works for you. Thanks.

from flaml.

flippercy avatar flippercy commented on May 13, 2024

It does. Thank you! For other questions, I will open a separate issue.

from flaml.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.