A web-based dashboard for Deep Learning
HyperBoard is a simple visualization tool to facilitate hyperparameter tuning for Deep Learning players. It helps you to
HyperBoard resembles Tensorboard and Tensorboard for MXNet. However, HyperBoard is independent from any specific Deep Learning platform and provides extra functions.
Watch a 3-minute demonstration on Youtube or Bilibili.
Screenshot:
# install dependencies pip install flask requests numpy pip install flask-httpauth # depend on flask git clone https://github.com/WarBean/hyperboard.git cd hyperboard/ python setup.py install
HyperBoard is easy to use. It is composed of three parts: Server, Agent and Dashboard. In general, when playing with deep neural networks on some remote server, you can
You can also run HyperBoard Server on your local PC. Currently, HyperBoard Server and Agent have been tested on Mac OS and Ubuntu. HyperBoard Dashboard has been tested on Firefox, Chrome and Safari.
Here are the details:
cd ~ mkdir my_records
cd my_records hyperboard-run --user --password
You can use HyperBoard without security authentication by simply using
hyperboard-runwithout any arguments. Also use
hyperboard-run -hfor more help info.
For this part, you are recommended to run a simulation script
example/run_agent.pyfirst. Detailed usage of HyperBoard Agent will be explained below.
If
hyperboard-runis run with argument
--local, open
http://127.0.0.1:5000, otherwise
http://:5000.
The dashboard provides convenient interactive controls on visualization. Feel free to play with them - except the Delete from Server button :).
from hyperboard import Agent agent = Agent(username = '', password = '', address = '127.0.0.1', port = 5000)
usernameand
passwordcan be omitted if you have launched HyperBoard Server without security authentication.
addressand
portcan be omitted to use default value.
name = agent.register(hyperparameters, metric, overwrite = False)
hyperparametersshould be a dictionary.
metricis a string label indicating the numerical range of the values you send next. Curves sharing the same
metricwill share one y-axis on the dashboard. It helps you properly visualize cross entropy and accuracy in the same graph.
overwrite = Falselets Agent to ask you for confirmation before removing existing records with the same hyperparameter setup.
agent.append(name, index, value)
Each curve is saved as a file with a suffix
.record, in the very directory where you launch HyperBoard Server. The content of record file is simple:
$ head my_records/fd8e3e27e4ef661488932e9a58197d90.record {"batch size": 256, "corpus": "PennTreeBank", "criteria": "train accu", "learning rate": 0.001, "momentum": 0.9, "num hidden": 300, "optimizer": "Adam"} accuracy 0 -0.22079159783278235 1 -0.15177436116678278 2 -0.0847468825330926 3 -0.009928149024110766 4 0.07511021349995883 5 0.16286792223048174 6 0.22981841687923243 7 0.25812625639630005
The first line is hyperparameters. The second line is metric. Each line below contains the iteration index and the criteria value.
The next time you launch HyperBoard Server, it will reload all
.recordfiles (except those you delete manually) into memory.