Commit 956abea5 authored by Andreas Schmidt's avatar Andreas Schmidt
Browse files

Merge branch 'develop'

parents 96a298a8 5ba62919
*.ipynb filter=nbstripout
*.ipynb diff=ipynb
build/
dist/
xlap.egg-info/
.ipynb_checkpoints/
\ No newline at end of file
.ipynb_checkpoints/
.venv/
[[source]]
name = "pypi"
url = "https://pypi.org/simple"
verify_ssl = true
[dev-packages]
[packages]
jupyter = "*"
matplotlib = "*"
pandas = "*"
numpy = "*"
scipy = "*"
ruamel-yaml = "*"
scikit-learn = "*"
graphviz = "*"
jupyterlab = "*"
nbstripout = "*"
nbconvert = "*"
[requires]
python_version = "3.6"
This diff is collapsed.
......@@ -7,41 +7,48 @@
"# X-Lap in Action"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
"%matplotlib inline"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Imports"
"## Data Retrieval"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"collapsed": true
},
"metadata": {},
"outputs": [],
"source": [
"import logging\n",
"logger = logging.getLogger()\n",
"logger.setLevel(logging.DEBUG)\n",
"from ipywidgets import interact, interactive, fixed, interact_manual\n",
"import ipywidgets as widgets\n",
"from xlap.parse import evaluate, evaluate_side, parse_config\n",
"import xlap.analyse.jitter as jitter\n",
"from xlap.analyse.regress import linear as linear_regression\n",
"from xlap.analyse.trace import traces\n",
"from xlap.analyse.correlation import correlation\n",
"from xlap.analyse.latency import analyse\n",
"import pandas as pd\n",
"%matplotlib inline"
"from xlap.parse import evaluate, parse_config\n",
"config = parse_config()\n",
"data_files = {\n",
" \"sender\": \"rtn2018/20180417_testbed/\",\n",
" \"receiver\": \"rtn2018/20180417_testbed/\"\n",
"}\n",
"df_1GHz = evaluate(data_files[\"sender\"] + \"sender-1000000.csv\", data_files[\"receiver\"] + \"receiver-1000000.csv\", config=config, kind=0)\n",
"df_1GHz.name = \"1GHz\"\n",
"df_2GHz = evaluate(data_files[\"sender\"] + \"sender-2000000.csv\", data_files[\"receiver\"] + \"receiver-2000000.csv\", config=config, kind=0)\n",
"df_2GHz.name = \"2GHz\"\n",
"df_3GHz = evaluate(data_files[\"sender\"] + \"sender-3000000.csv\", data_files[\"receiver\"] + \"receiver-3000000.csv\", config=config, kind=0)\n",
"df_3GHz.name = \"3GHz\"\n",
"dfs = [df_1GHz, df_2GHz, df_3GHz]"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Data Retrieval"
"## Individual Packet Traces"
]
},
{
......@@ -50,16 +57,15 @@
"metadata": {},
"outputs": [],
"source": [
"config = parse_config()\n",
"data_files = config[\"data_files\"]\n",
"original = evaluate(data_files[\"sender\"], data_files[\"receiver\"], config=config, kind=0)"
"from xlap.analyse.trace import traces\n",
"traces(df_1GHz, config, global_xaxis=True)"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Traces"
"## Trace Jitter Analysis"
]
},
{
......@@ -68,14 +74,15 @@
"metadata": {},
"outputs": [],
"source": [
"traces(original, config)"
"from xlap.analyse.jitter import multi_trace_jitter\n",
"multi_trace_jitter(dfs, config)"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Jitter Analysis"
"## Latency Distributions"
]
},
{
......@@ -84,15 +91,25 @@
"metadata": {},
"outputs": [],
"source": [
"df = jitter.prep(original, config=config)\n",
"jitter.trace_jitter(df, threshold=500)"
"from xlap.analyse.cdf import multi_cdf\n",
"from xlap.analyse.util import colors\n",
"import copy\n",
"cfg = copy.deepcopy(config)\n",
"list(map(cfg[\"durations\"].pop, (\"Decoding\",\n",
" \"ReceiverIPC\",\n",
" \"HandlePacket\", \n",
" \"Feedback\", \n",
" \"SenderIPC\",\n",
" \"SenderEnqueued\",\n",
" \"Enqueue\")))\n",
"multi_cdf(dfs, cfg, colors=colors)"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Correlation"
"## Correlation with E2E Latency"
]
},
{
......@@ -101,15 +118,15 @@
"metadata": {},
"outputs": [],
"source": [
"correlation(df[df[\"EndToEnd_D\"] < 500], config)"
"from xlap.analyse.correlation import multi_correlation\n",
"multi_correlation(dfs, config, colors=colors, figsize=(3.0,2.0), cols=4)"
]
},
{
"cell_type": "markdown",
"metadata": {
"collapsed": true
},
"metadata": {},
"source": [
"# $\\Delta$elta\n",
"## Latency Criticality"
]
},
......@@ -119,7 +136,8 @@
"metadata": {},
"outputs": [],
"source": [
"d = analyse(original, config)"
"from xlap.analyse.latency import analyse\n",
"d = analyse(df_1GHz, config)"
]
},
{
......@@ -153,6 +171,41 @@
"source": [
"d.cfg"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Timing Behaviour"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
"from xlap.analyse.timing import timing_behaviour\n",
"timing_behaviour(df_1GHz, df_2GHz, config)"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
"timing_behaviour(df_1GHz, df_3GHz, config)"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
"timing_behaviour(df_2GHz, df_3GHz, config)"
]
}
],
"metadata": {
......@@ -171,21 +224,9 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.5.2"
},
"widgets": {
"state": {
"df95aa8c42974dfeaf8e0a2c05100645": {
"views": [
{
"cell_index": 6
}
]
}
},
"version": "1.2.0"
"version": "3.6.8"
}
},
"nbformat": 4,
"nbformat_minor": 2
"nbformat_minor": 4
}
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
1 40.112488 0.28655806569935959455261300
2 37.635804 0.13545612357162314105068459
3 44.867554 0.15736979554175162807913194
Setting cpu: 0
Setting cpu: 1
Setting cpu: 2
Setting cpu: 3
Setting cpu: 4
Setting cpu: 5
Setting cpu: 6
Setting cpu: 7
analyzing CPU 0:
996816
analyzing CPU 1:
998867
analyzing CPU 2:
999414
analyzing CPU 3:
997363
analyzing CPU 4:
1000507
analyzing CPU 5:
999687
analyzing CPU 6:
1000234
analyzing CPU 7:
997089
Setting cpu: 0
Setting cpu: 1
Setting cpu: 2
Setting cpu: 3
Setting cpu: 4
Setting cpu: 5
Setting cpu: 6
Setting cpu: 7
analyzing CPU 0:
925859
analyzing CPU 1:
1000097
analyzing CPU 2:
999960
analyzing CPU 3:
993535
analyzing CPU 4:
1000371
analyzing CPU 5:
998046
analyzing CPU 6:
993261
analyzing CPU 7:
992578
RAPL::Package energy {0}: 16.163391J
RAPL::PowerPlane0 (core) {0}: 1.458923J
RAPL::PowerPlane1 (on-core GPU if avail) {0}: 0.000000J
RAPL::DRAM energy {0}: 4.892883J
Time: 5.087s
Found Haswell CPU
RAPL::Package energy {0}: 23.949097J
RAPL::PowerPlane0 (core) {0}: 1.922913J
RAPL::PowerPlane1 (on-core GPU if avail) {0}: 0.000000J
RAPL::DRAM energy {0}: 5.827271J
Time: 5.729s
Found Haswell CPU
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment