{"id":18790986,"url":"https://github.com/hansbug/hbayes","last_synced_at":"2025-04-13T14:21:59.975Z","repository":{"id":62591890,"uuid":"497607603","full_name":"HansBug/hbayes","owner":"HansBug","description":"A Python implementation of global optimization with gaussian processes.","archived":false,"fork":false,"pushed_at":"2022-05-31T16:49:14.000Z","size":32949,"stargazers_count":2,"open_issues_count":0,"forks_count":1,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-03-27T05:23:55.170Z","etag":null,"topics":["bayesian-optimization"],"latest_commit_sha":null,"homepage":"https://hansbug.github.io/hbayes/","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/HansBug.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2022-05-29T14:01:42.000Z","updated_at":"2022-06-14T05:24:27.000Z","dependencies_parsed_at":"2022-11-04T02:49:36.738Z","dependency_job_id":null,"html_url":"https://github.com/HansBug/hbayes","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/HansBug%2Fhbayes","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/HansBug%2Fhbayes/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/HansBug%2Fhbayes/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/HansBug%2Fhbayes/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/HansBug","download_url":"https://codeload.github.com/HansBug/hbayes/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248725103,"owners_count":21151630,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["bayesian-optimization"],"created_at":"2024-11-07T21:14:19.132Z","updated_at":"2025-04-13T14:21:59.948Z","avatar_url":"https://github.com/HansBug.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Bayesian Optimization\n\n[![PyPI](https://img.shields.io/pypi/v/hbayes)](https://pypi.org/project/hbayes/)\n[![PyPI - Python Version](https://img.shields.io/pypi/pyversions/hbayes)](https://pypi.org/project/hbayes/)\n![Loc](https://img.shields.io/endpoint?url=https://gist.githubusercontent.com/HansBug/d9b45d4c1b12045384046990db092098/raw/loc.json)\n![Comments](https://img.shields.io/endpoint?url=https://gist.githubusercontent.com/HansBug/d9b45d4c1b12045384046990db092098/raw/comments.json)\n\n[![Code Test](https://github.com/HansBug/hbayes/workflows/Code%20Test/badge.svg)](https://github.com/HansBug/hbayes/actions?query=workflow%3A%22Code+Test%22)\n[![Badge Creation](https://github.com/HansBug/hbayes/workflows/Badge%20Creation/badge.svg)](https://github.com/HansBug/hbayes/actions?query=workflow%3A%22Badge+Creation%22)\n[![Package Release](https://github.com/HansBug/hbayes/workflows/Package%20Release/badge.svg)](https://github.com/HansBug/hbayes/actions?query=workflow%3A%22Package+Release%22)\n[![codecov](https://codecov.io/gh/HansBug/BayesianOptimization/branch/main/graph/badge.svg?token=LGB44A91FL)](https://codecov.io/gh/HansBug/BayesianOptimization)\n\n[![GitHub stars](https://img.shields.io/github/stars/HansBug/hbayes)](https://github.com/HansBug/hbayes/stargazers)\n[![GitHub forks](https://img.shields.io/github/forks/HansBug/hbayes)](https://github.com/HansBug/hbayes/network)\n![GitHub commit activity](https://img.shields.io/github/commit-activity/m/HansBug/hbayes)\n[![GitHub issues](https://img.shields.io/github/issues/HansBug/hbayes)](https://github.com/HansBug/hbayes/issues)\n[![GitHub pulls](https://img.shields.io/github/issues-pr/HansBug/hbayes)](https://github.com/HansBug/hbayes/pulls)\n[![Contributors](https://img.shields.io/github/contributors/HansBug/hbayes)](https://github.com/HansBug/hbayes/graphs/contributors)\n[![GitHub license](https://img.shields.io/github/license/HansBug/hbayes)](https://github.com/HansBug/hbayes/blob/master/LICENSE)\n\nAn extended implementation of Bayesian Optimization.\n\nThis is a forked project based on [fmfn/BayesianOptimization v1.2.0](https://github.com/fmfn/BayesianOptimization). Most of the usage and features from the original repository will be kept for a long time.\n\n## Installation\n\nYou can simply install it with `pip` command line from the official PyPI site.\n\n```shell\npip install hbayes\n```\n\nFor more information about installation, you can refer to [Installation](https://hansbug.github.io/hbayes/main/tutorials/installation/index.html).\n\n\n## Documentation\n\nThe detailed documentation are hosted on [https://hansbug.github.io/hbayes/main/index.html](https://hansbug.github.io/hbayes/main/index.html).\n\nOnly english version is provided now, the chinese documentation is still under development.\n\n\n## Quick Start\n\nA painless example\n\n```python\nfrom hbayes import BayesianOptimization\n\n\ndef black_box_function(x, y):\n    \"\"\"Function with unknown internals we wish to maximize.\n\n    This is just serving as an example, for all intents and\n    purposes think of the internals of this function, i.e.: the process\n    which generates its output values, as unknown.\n    \"\"\"\n    return -x ** 2 - (y - 1) ** 2 + 1\n\n\n# Bounded region of parameter space\npbounds = {'x': (2, 4), 'y': (-3, 3)}\n\noptimizer = BayesianOptimization(\n    f=black_box_function,\n    pbounds=pbounds,\n    random_state=1,\n    verbose=2,\n)\n\noptimizer.maximize(\n    init_points=10,\n    n_iter=25,\n)\n\nprint(optimizer.max)\n\n```\n\nThe output should be\n\n```\n|   iter    |  target   |     x     |     y     |\n-------------------------------------------------\n|  1        | -7.135    |  2.834    |  1.322    |\n|  2        | -7.78     |  2.0      | -1.186    |\n|  3        | -16.13    |  2.294    | -2.446    |\n|  4        | -8.341    |  2.373    | -0.9266   |\n|  5        | -7.392    |  2.794    |  0.2329   |\n|  6        | -7.069    |  2.838    |  1.111    |\n|  7        | -6.412    |  2.409    |  2.269    |\n|  8        | -3.223    |  2.055    |  1.023    |\n|  9        | -7.455    |  2.835    |  0.3521   |\n|  10       | -12.11    |  2.281    | -1.811    |\n|  11       | -7.0      |  2.0      |  3.0      |\n|  12       | -19.0     |  4.0      |  3.0      |\n|  13       | -3.383    |  2.0      |  0.3812   |\n|  14       | -3.43     |  2.0      |  1.656    |\n|  15       | -3.035    |  2.0      |  0.8129   |\n|  16       | -17.03    |  4.0      | -0.4244   |\n|  17       | -3.012    |  2.0      |  1.109    |\n|  18       | -3.0      |  2.0      |  0.9813   |\n|  19       | -3.0      |  2.0      |  0.9911   |\n|  20       | -3.0      |  2.0      |  0.994    |\n|  21       | -3.0      |  2.0      |  0.9957   |\n|  22       | -3.0      |  2.0      |  0.9971   |\n|  23       | -3.0      |  2.0      |  0.9994   |\n|  24       | -3.0      |  2.0      |  1.004    |\n|  25       | -3.0      |  2.0      |  0.978    |\n|  26       | -3.001    |  2.0      |  1.024    |\n|  27       | -3.001    |  2.0      |  0.9735   |\n|  28       | -3.001    |  2.0      |  1.024    |\n|  29       | -3.001    |  2.0      |  0.9729   |\n|  30       | -3.001    |  2.0      |  1.024    |\n|  31       | -3.0      |  2.0      |  1.021    |\n|  32       | -3.001    |  2.0      |  0.9709   |\n|  33       | -3.001    |  2.0      |  0.9749   |\n|  34       | -3.001    |  2.0      |  1.023    |\n|  35       | -3.001    |  2.0      |  0.9755   |\n=================================================\n{'target': -3.00000039014846, 'params': {'x': 2.0, 'y': 0.9993753813483197}}\n```\n\nFor more tutorial of usages and practices, take a look at [Best Practice](https://hansbug.github.io/hbayes/main/best_practice/advanced-tour.html) in documentation.\n\n\n# Contributing\n\nWe appreciate all contributions to improve `hbayes`, both logic and system designs. Please refer to CONTRIBUTING.md for more guides.\n\n\n# License\n\n`hbayes` released under the MIT license.\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhansbug%2Fhbayes","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhansbug%2Fhbayes","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhansbug%2Fhbayes/lists"}