-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
egs: update test dataset configuration
- Loading branch information
1 parent
b81459f
commit 1f49043
Showing
4 changed files
with
155 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,144 @@ | ||
{ | ||
"cells": [ | ||
{ | ||
"cell_type": "code", | ||
"execution_count": 1, | ||
"metadata": {}, | ||
"outputs": [], | ||
"source": [ | ||
"import numpy as np" | ||
] | ||
}, | ||
{ | ||
"cell_type": "code", | ||
"execution_count": 3, | ||
"metadata": {}, | ||
"outputs": [], | ||
"source": [ | ||
"# Apply profit to the metrics\n", | ||
"def get_polyfit_val(self, sig, bak, ovr, is_personalized_MOS=False):\n", | ||
" if is_personalized_MOS:\n", | ||
" p_ovr = np.poly1d([-0.00533021, 0.005101, 1.18058466, -0.11236046])\n", | ||
" p_sig = np.poly1d([-0.01019296, 0.02751166, 1.19576786, -0.24348726])\n", | ||
" p_bak = np.poly1d([-0.04976499, 0.44276479, -0.1644611, 0.96883132])\n", | ||
" else:\n", | ||
" p_ovr = np.poly1d([-0.06766283, 1.11546468, 0.04602535])\n", | ||
" p_sig = np.poly1d([-0.08397278, 1.22083953, 0.0052439])\n", | ||
" p_bak = np.poly1d([-0.13166888, 1.60915514, -0.39604546])\n", | ||
"\n", | ||
" sig_poly = p_sig(sig)\n", | ||
" bak_poly = p_bak(bak)\n", | ||
" ovr_poly = p_ovr(ovr)\n", | ||
"\n", | ||
" return sig_poly, bak_poly, ovr_poly" | ||
] | ||
}, | ||
{ | ||
"cell_type": "code", | ||
"execution_count": 4, | ||
"metadata": {}, | ||
"outputs": [ | ||
{ | ||
"name": "stdout", | ||
"output_type": "stream", | ||
"text": [ | ||
"(3.163024522199478, 3.6073455928302955, 2.750688625478262)\n" | ||
] | ||
} | ||
], | ||
"source": [ | ||
"a_lif_metrics = (3.36576, 3.47725, 2.95402)\n", | ||
"a_lif_poly = get_polyfit_val(None, *a_lif_metrics)\n", | ||
"print(a_lif_poly)" | ||
] | ||
}, | ||
{ | ||
"cell_type": "code", | ||
"execution_count": 3, | ||
"metadata": {}, | ||
"outputs": [], | ||
"source": [ | ||
"synops = 419556 * 2\n", | ||
"neuronops = 2762\n", | ||
"buffer_latency = 0.032\n", | ||
"enc_dec_latency = 0.030 / 1000\n", | ||
"dns_latency = 0\n", | ||
"dt = 0.008" | ||
] | ||
}, | ||
{ | ||
"cell_type": "code", | ||
"execution_count": 4, | ||
"metadata": {}, | ||
"outputs": [ | ||
{ | ||
"name": "stdout", | ||
"output_type": "stream", | ||
"text": [ | ||
"866732\n", | ||
"Solution Latency : 32.030 ms\n", | ||
"Power proxy (Effective SynOPS) : 108341500.000 ops/s\n", | ||
"PDP proxy (SynOPS-delay product) : 1790.797 ops\n" | ||
] | ||
} | ||
], | ||
"source": [ | ||
"latency = buffer_latency + enc_dec_latency + dns_latency\n", | ||
"effective_synops_rate = (synops + 10 * neuronops) / dt\n", | ||
"synops_delay_product = 55.91 * 10**3 * latency\n", | ||
"\n", | ||
"print(synops + 10 * neuronops)\n", | ||
"print(f'Solution Latency : {latency * 1000: .3f} ms')\n", | ||
"print(f'Power proxy (Effective SynOPS) : {effective_synops_rate:.3f} ops/s')\n", | ||
"print(f'PDP proxy (SynOPS-delay product) : {synops_delay_product: .3f} ops')" | ||
] | ||
}, | ||
{ | ||
"cell_type": "code", | ||
"execution_count": 6, | ||
"metadata": {}, | ||
"outputs": [ | ||
{ | ||
"name": "stdout", | ||
"output_type": "stream", | ||
"text": [ | ||
"Solution Latency : 32.030 ms\n", | ||
"Power proxy (Effective SynOPS) : 108341500.000 ops/s\n", | ||
"PDP proxy (SynOPS-delay product) : 3470178.245 ops\n" | ||
] | ||
} | ||
], | ||
"source": [ | ||
"latency = buffer_latency + enc_dec_latency + dns_latency\n", | ||
"effective_synops_rate = (synops + 10 * neuronops) / dt\n", | ||
"synops_delay_product = effective_synops_rate * latency\n", | ||
"\n", | ||
"print(f'Solution Latency : {latency * 1000: .3f} ms')\n", | ||
"print(f'Power proxy (Effective SynOPS) : {effective_synops_rate:.3f} ops/s')\n", | ||
"print(f'PDP proxy (SynOPS-delay product) : {synops_delay_product: .3f} ops')" | ||
] | ||
} | ||
], | ||
"metadata": { | ||
"kernelspec": { | ||
"display_name": "audiozen", | ||
"language": "python", | ||
"name": "python3" | ||
}, | ||
"language_info": { | ||
"codemirror_mode": { | ||
"name": "ipython", | ||
"version": 3 | ||
}, | ||
"file_extension": ".py", | ||
"mimetype": "text/x-python", | ||
"name": "python", | ||
"nbconvert_exporter": "python", | ||
"pygments_lexer": "ipython3", | ||
"version": "3.10.11" | ||
}, | ||
"orig_nbformat": 4 | ||
}, | ||
"nbformat": 4, | ||
"nbformat_minor": 2 | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters