How to use the bbopt.backends.skopt.SkoptBackend function in bbopt

To help you get started, we’ve selected a few bbopt examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github evhub / bbopt / bbopt / optimizer.py View on Github external
def _get_skopt_backend(self):
        """Get a scikit-optimize backend regardless of whether currently using one."""
        if isinstance(self.backend, SkoptBackend):
            return self.backend

        skopt_backend_args = (self._examples, self._old_params)
        if self._skopt_backend_args == skopt_backend_args:
            return self._skopt_backend

        self._skopt_backend_args = skopt_backend_args
        self._skopt_backend = SkoptBackend(*skopt_backend_args)
        return self._skopt_backend
github evhub / bbopt / bbopt / backends / skopt.py View on Github external
return self.optimizer.space

    @property
    def model(self):
        """Get the most recently fit model."""
        return self.optimizer.models[-1]


# Registered names:

SkoptBackend.register()
SkoptBackend.register_alias("skopt")
SkoptBackend.register_alg("gaussian_process", base_estimator="GP")
SkoptBackend.register_alg("random_forest", base_estimator="RF")
SkoptBackend.register_alg("extra_trees", base_estimator="ET")
SkoptBackend.register_alg("gradient_boosted_regression_trees", base_estimator="GBRT")
github evhub / bbopt / bbopt / optimizer.py View on Github external
def _get_skopt_backend(self):
        """Get a scikit-optimize backend regardless of whether currently using one."""
        if isinstance(self.backend, SkoptBackend):
            return self.backend

        skopt_backend_args = (self._examples, self._old_params)
        if self._skopt_backend_args == skopt_backend_args:
            return self._skopt_backend

        self._skopt_backend_args = skopt_backend_args
        self._skopt_backend = SkoptBackend(*skopt_backend_args)
        return self._skopt_backend
github evhub / bbopt / bbopt / backends / skopt.py View on Github external
self.current_values = make_values(params, current_point)

    @property
    def space(self):
        """The space over which optimization was performed."""
        return self.optimizer.space

    @property
    def model(self):
        """Get the most recently fit model."""
        return self.optimizer.models[-1]


# Registered names:

SkoptBackend.register()
SkoptBackend.register_alias("skopt")
SkoptBackend.register_alg("gaussian_process", base_estimator="GP")
SkoptBackend.register_alg("random_forest", base_estimator="RF")
SkoptBackend.register_alg("extra_trees", base_estimator="ET")
SkoptBackend.register_alg("gradient_boosted_regression_trees", base_estimator="GBRT")
github evhub / bbopt / bbopt / backends / skopt.py View on Github external
    @property
    def space(self):
        """The space over which optimization was performed."""
        return self.optimizer.space

    @property
    def model(self):
        """Get the most recently fit model."""
        return self.optimizer.models[-1]


# Registered names:

SkoptBackend.register()
SkoptBackend.register_alias("skopt")
SkoptBackend.register_alg("gaussian_process", base_estimator="GP")
SkoptBackend.register_alg("random_forest", base_estimator="RF")
SkoptBackend.register_alg("extra_trees", base_estimator="ET")
SkoptBackend.register_alg("gradient_boosted_regression_trees", base_estimator="GBRT")