surfaces


Namesurfaces JSON
Version 0.4.0 PyPI version JSON
download
home_pageNone
SummaryA collection and visualization of black-box objective functions
upload_time2024-05-09 11:50:57
maintainerNone
docs_urlNone
authorNone
requires_python>=3.8
licenseMIT License Copyright (c) 2021 Simon Blanke Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
keywords visualization data-science
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            <H1 align="center">
    Surfaces
</H1>

<br>

<H2 align="center">
    A collection and visualization of single objective black-box functions for optimization benchmarking
</H2>


<br>

## Visualizations

<table style="width:100%">
  <tr>
    <th> <b>Objective Function</b> </th>
    <th> <b>Heatmap</b> </th> 
    <th> <b>Surface Plot</b> </th>
  </tr>
  <tr>
    <th> <ins>Sphere function</ins> <br><br>  </th>
    <td> <img src="./doc/images/sphere_function_heatmap.jpg" width="90%"> </td>
    <td> <img src="./doc/images/sphere_function_surface.jpg" width="100%"> </td>
  </tr>
  <tr>
    <th> <ins>Rastrigin function</ins> <br><br> </th>
    <td> <img src="./doc/images/rastrigin_function_heatmap.jpg" width="90%"> </td>
    <td> <img src="./doc/images/rastrigin_function_surface.jpg" width="100%"> </td>
  </tr>
  <tr>
    <th> <ins>Ackley function</ins> <br><br> </th>
    <td> <img src="./doc/images/ackley_function_heatmap.jpg" width="90%"> </td>
    <td> <img src="./doc/images/ackley_function_surface.jpg" width="100%"> </td>
  </tr>
  <tr>
    <th> <ins>Rosenbrock function</ins> <br><br> </th>
    <td> <img src="./doc/images/rosenbrock_function_heatmap.jpg" width="90%"> </td>
    <td> <img src="./doc/images/rosenbrock_function_surface.jpg" width="100%"> </td>
  </tr>
  <tr>
    <th> <ins>Beale function</ins> <br><br> </th>
    <td> <img src="./doc/images/beale_function_heatmap.jpg" width="90%"> </td>
    <td> <img src="./doc/images/beale_function_surface.jpg" width="100%"> </td>
  </tr>
  <tr>
    <th> <ins>Himmelblaus function</ins> <br><br> </th>
    <td> <img src="./doc/images/himmelblaus_function_heatmap.jpg" width="90%"> </td>
    <td> <img src="./doc/images/himmelblaus_function_surface.jpg" width="100%"> </td>
  </tr>
  <tr>
    <th> <ins>Hölder Table function</ins> <br><br> </th>
    <td> <img src="./doc/images/hölder_table_function_heatmap.jpg" width="90%"> </td>
    <td> <img src="./doc/images/hölder_table_function_surface.jpg" width="100%"> </td>
  </tr>
  <tr>
    <th> <ins>Cross-In-Tray function</ins> <br><br> </th>
    <td> <img src="./doc/images/cross_in_tray_function_heatmap.jpg" width="90%"> </td>
    <td> <img src="./doc/images/cross_in_tray_function_surface.jpg" width="100%"> </td>
  </tr>
</table>




<br>

## Installation

The most recent version of Surfaces is available on PyPi:

```console
pip install surfaces
```

## Example
```python
import numpy as np

from surfaces.mathematical_functions import SphereFunction, AckleyFunction
from surfaces.visualize import plotly_surface


sphere_function = SphereFunction(n_dim=2, metric="score")
ackley_function = AckleyFunction(metric="loss")


step_ = 0.05
min_ = 10
max_ = 10
search_space = {
    "x0": np.arange(-min_, max_, step_),
    "x1": np.arange(-min_, max_, step_),
}

plotly_surface(sphere_function.objective_function, search_space).show()
plotly_surface(ackley_function.objective_function, search_space).show()
```


            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "surfaces",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.8",
    "maintainer_email": "Simon Blanke <simon.blanke@yahoo.com>",
    "keywords": "visualization, data-science",
    "author": null,
    "author_email": "Simon Blanke <simon.blanke@yahoo.com>",
    "download_url": null,
    "platform": null,
    "description": "<H1 align=\"center\">\n    Surfaces\n</H1>\n\n<br>\n\n<H2 align=\"center\">\n    A collection and visualization of single objective black-box functions for optimization benchmarking\n</H2>\n\n\n<br>\n\n## Visualizations\n\n<table style=\"width:100%\">\n  <tr>\n    <th> <b>Objective Function</b> </th>\n    <th> <b>Heatmap</b> </th> \n    <th> <b>Surface Plot</b> </th>\n  </tr>\n  <tr>\n    <th> <ins>Sphere function</ins> <br><br>  </th>\n    <td> <img src=\"./doc/images/sphere_function_heatmap.jpg\" width=\"90%\"> </td>\n    <td> <img src=\"./doc/images/sphere_function_surface.jpg\" width=\"100%\"> </td>\n  </tr>\n  <tr>\n    <th> <ins>Rastrigin function</ins> <br><br> </th>\n    <td> <img src=\"./doc/images/rastrigin_function_heatmap.jpg\" width=\"90%\"> </td>\n    <td> <img src=\"./doc/images/rastrigin_function_surface.jpg\" width=\"100%\"> </td>\n  </tr>\n  <tr>\n    <th> <ins>Ackley function</ins> <br><br> </th>\n    <td> <img src=\"./doc/images/ackley_function_heatmap.jpg\" width=\"90%\"> </td>\n    <td> <img src=\"./doc/images/ackley_function_surface.jpg\" width=\"100%\"> </td>\n  </tr>\n  <tr>\n    <th> <ins>Rosenbrock function</ins> <br><br> </th>\n    <td> <img src=\"./doc/images/rosenbrock_function_heatmap.jpg\" width=\"90%\"> </td>\n    <td> <img src=\"./doc/images/rosenbrock_function_surface.jpg\" width=\"100%\"> </td>\n  </tr>\n  <tr>\n    <th> <ins>Beale function</ins> <br><br> </th>\n    <td> <img src=\"./doc/images/beale_function_heatmap.jpg\" width=\"90%\"> </td>\n    <td> <img src=\"./doc/images/beale_function_surface.jpg\" width=\"100%\"> </td>\n  </tr>\n  <tr>\n    <th> <ins>Himmelblaus function</ins> <br><br> </th>\n    <td> <img src=\"./doc/images/himmelblaus_function_heatmap.jpg\" width=\"90%\"> </td>\n    <td> <img src=\"./doc/images/himmelblaus_function_surface.jpg\" width=\"100%\"> </td>\n  </tr>\n  <tr>\n    <th> <ins>H\u00f6lder Table function</ins> <br><br> </th>\n    <td> <img src=\"./doc/images/h\u00f6lder_table_function_heatmap.jpg\" width=\"90%\"> </td>\n    <td> <img src=\"./doc/images/h\u00f6lder_table_function_surface.jpg\" width=\"100%\"> </td>\n  </tr>\n  <tr>\n    <th> <ins>Cross-In-Tray function</ins> <br><br> </th>\n    <td> <img src=\"./doc/images/cross_in_tray_function_heatmap.jpg\" width=\"90%\"> </td>\n    <td> <img src=\"./doc/images/cross_in_tray_function_surface.jpg\" width=\"100%\"> </td>\n  </tr>\n</table>\n\n\n\n\n<br>\n\n## Installation\n\nThe most recent version of Surfaces is available on PyPi:\n\n```console\npip install surfaces\n```\n\n## Example\n```python\nimport numpy as np\n\nfrom surfaces.mathematical_functions import SphereFunction, AckleyFunction\nfrom surfaces.visualize import plotly_surface\n\n\nsphere_function = SphereFunction(n_dim=2, metric=\"score\")\nackley_function = AckleyFunction(metric=\"loss\")\n\n\nstep_ = 0.05\nmin_ = 10\nmax_ = 10\nsearch_space = {\n    \"x0\": np.arange(-min_, max_, step_),\n    \"x1\": np.arange(-min_, max_, step_),\n}\n\nplotly_surface(sphere_function.objective_function, search_space).show()\nplotly_surface(ackley_function.objective_function, search_space).show()\n```\n\n",
    "bugtrack_url": null,
    "license": "MIT License  Copyright (c) 2021 Simon Blanke  Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:  The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.  THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ",
    "summary": "A collection and visualization of black-box objective functions",
    "version": "0.4.0",
    "project_urls": {
        "Bug Reports": "https://github.com/SimonBlanke/Surfaces/issues",
        "Homepage": "https://github.com/SimonBlanke/Surfaces",
        "Source": "https://github.com/SimonBlanke/Surfaces/"
    },
    "split_keywords": [
        "visualization",
        " data-science"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "a92cc0dc91edf7ee8156f6ea65ec51c93dcd9cb4f5f7ea6ca8f5e9dbe9379be3",
                "md5": "6e7763b1d1c44de5ef20314c01af128a",
                "sha256": "90b8278a128a46c84694b0a87650fe803419381e394fe682b571dcf59ebe0cc7"
            },
            "downloads": -1,
            "filename": "surfaces-0.4.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "6e7763b1d1c44de5ef20314c01af128a",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8",
            "size": 2960196,
            "upload_time": "2024-05-09T11:50:57",
            "upload_time_iso_8601": "2024-05-09T11:50:57.805494Z",
            "url": "https://files.pythonhosted.org/packages/a9/2c/c0dc91edf7ee8156f6ea65ec51c93dcd9cb4f5f7ea6ca8f5e9dbe9379be3/surfaces-0.4.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-05-09 11:50:57",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "SimonBlanke",
    "github_project": "Surfaces",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "tox": true,
    "lcname": "surfaces"
}
        
Elapsed time: 0.34626s