Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make the clusterPlots notebook consistent with telemetry schema #68

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 8 additions & 6 deletions metrics/notebooks/clusterPlots.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"cells": [
{
"cell_type": "code",
"execution_count": null,
"execution_count": 4,
poojanilangekar marked this conversation as resolved.
Show resolved Hide resolved
"metadata": {},
"outputs": [],
"source": [
Expand Down Expand Up @@ -33,7 +33,7 @@
},
{
"cell_type": "code",
"execution_count": null,
"execution_count": 5,
"metadata": {},
"outputs": [],
"source": [
Expand All @@ -43,22 +43,24 @@
},
{
"cell_type": "code",
"execution_count": null,
"execution_count": 7,
"metadata": {},
"outputs": [],
"source": [
"# --- Data manipulations --- #\n",
"\n",
"# Retrieve relevant data from duckdb.\n",
"EXP_DATA = retrieve_experiment_df(con, EXPERIMENT_ID, EXPERIMENT_START_TIME)\n",
"EXP_DATA = pd.DataFrame()\n",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For cluster plots, we only plot one experiment at a time, thus we only have one experiment id (EXPERIMENT_ID = "" instead of EXPERIMENT_ID = [""] like in the other notebooks), so you wouldn't actually need the for-loop here. The reason is that you're plotting different phases as different lines in the plot (vs different experiments as different lines in the plot which is what we do in the latency plots), thus you can actually only plot one experiment at a time. If you have any suggestions on how to visualize multiple experiments in the same plot, let me know! :)

"for idx, id in enumerate(EXPERIMENT_ID):\n",
" EXP_DATA = pd.concat([EXP_DATA, retrieve_experiment_df(con, id, EXPERIMENT_START_TIME[idx])])\n",
"\n",
"# Remove superfluous entries from dataframe.\n",
"EXP_DATA = filterByEventIds(EXP_DATA, EVENT_IDS)"
]
},
{
"cell_type": "code",
"execution_count": null,
"execution_count": 8,
"metadata": {},
"outputs": [],
"source": [
Expand Down Expand Up @@ -105,7 +107,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.9.7"
"version": "3.9.6"
},
"orig_nbformat": 4
},
Expand Down