Project

General

Profile

View metrics with jupyterlab » History » Version 4

Pengfei Ding, 10/02/2019 03:49 PM

1 4 Pengfei Ding
h1. Getting setup with docker and jupyterlab
2 1 Ron Rechenmacher
3 4 Pengfei Ding
Assuming you have docker ready, the following script will pull start a docker container (by default named as "metrics_nb"), and start jupyter notebook in the container. The URL to the jupyter notebook instance will be displayed in your terminal.
4 1 Ron Rechenmacher
5 1 Ron Rechenmacher
<pre>
6 4 Pengfei Ding
wget http://home.fnal.gov/~dingpf/start_artdaq_metrics_nb.sh
7 4 Pengfei Ding
chmod +x start_artdaq_metrics.sh
8 1 Ron Rechenmacher
</pre>
9 1 Ron Rechenmacher
10 4 Pengfei Ding
Then run it with:
11 1 Ron Rechenmacher
<pre>
12 4 Pengfei Ding
# ./start_artdaq_metrics_nb.sh <metrics_dir_path> <notebook_dir_path> [notebook_name]
13 4 Pengfei Ding
# e.g.
14 4 Pengfei Ding
./start_artdaq_metrics_nb.sh /home/ron/work/artdaqPrj/demo2-develop/daqlogs/metrics /home/dingpf/notebooks
15 1 Ron Rechenmacher
</pre>
16 1 Ron Rechenmacher
17 4 Pengfei Ding
Once the container is up, you can open a browser to the link displayed in your terminal, open and run the "notebooks/Plot_metrics-single_plot.ipynb" notebook. There will be two drop-down boxes asking you which log file you want to parse and which metrics you want to plot.