Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/seba-1511/randopt_plugins
A bunch of plugins for randopt
https://github.com/seba-1511/randopt_plugins
Last synced: 8 days ago
JSON representation
A bunch of plugins for randopt
- Host: GitHub
- URL: https://github.com/seba-1511/randopt_plugins
- Owner: seba-1511
- License: apache-2.0
- Created: 2018-03-16T13:54:06.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2018-04-03T22:12:04.000Z (over 6 years ago)
- Last Synced: 2024-10-07T11:21:03.301Z (29 days ago)
- Language: Python
- Size: 98.6 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Randopt Plugins
A bunch of plugins for randoptTo install all:
~~~shell
pip install -r requirements.txt
pip install .
~~~## Live Wrapper
The live wrapper allows to print / plot experimental metrics live.
### Install
~~~shell
pip install matploblib terminaltables
~~~### Usage
~~~python
import randopt as ro
from randopt_plugins.live import Liveexp = ro.Experiment('live_example', params={
'x': ro.Gaussian(),
'y': ro.Gaussian()
})
live = Live(exp, metrics=['square', 'norm', 'xminusy', 'time'])start = time()
for i in range(100):
live.sample_all_params()
live.update('square', live.x**2)
live.update({
'norm': abs(exp.y),
'xminusy': exp.x - exp.y,
'time': time() - start
})
print(live.table_metrics())
live.plot_metrics()
sleep(1)live.add_result(exp.x - exp.y)
live.add_result(exp.x - exp.y, {'useless': [0, 0, 0, 0]})
live.add_result(exp.x - exp.y, data={'useless': [0, 0, 0, 0]})
~~~### Screenshots
**Live Plotting**
![](./assets/images/live_plot.png)
**Live Table**
![](./assets/images/live_table.png)