diff options
| author | J08nY | 2025-03-10 18:07:29 +0100 |
|---|---|---|
| committer | J08nY | 2025-04-16 12:25:06 +0200 |
| commit | ca59db2917f9de89602c90673d08895a4d3f484d (patch) | |
| tree | a2a4ffa81ee2a78cc2098d8161ee2a0a7d7957b8 | |
| parent | a05b69373ddd548e52e04b978ef23ef03a448f13 (diff) | |
| download | ECTester-ca59db2917f9de89602c90673d08895a4d3f484d.tar.gz ECTester-ca59db2917f9de89602c90673d08895a4d3f484d.tar.zst ECTester-ca59db2917f9de89602c90673d08895a4d3f484d.zip | |
| -rw-r--r-- | epare/simulate.ipynb | 37 |
1 files changed, 28 insertions, 9 deletions
diff --git a/epare/simulate.ipynb b/epare/simulate.ipynb index 0acc8f6..186950b 100644 --- a/epare/simulate.ipynb +++ b/epare/simulate.ipynb @@ -10,7 +10,7 @@ }, { "cell_type": "code", - "execution_count": 4, + "execution_count": 1, "id": "b4386513-cc14-434b-a748-2863f8657452", "metadata": {}, "outputs": [], @@ -52,7 +52,7 @@ }, { "cell_type": "code", - "execution_count": 5, + "execution_count": 2, "id": "5c0e42dc-8c61-4e2e-962c-6af48f6eb321", "metadata": {}, "outputs": [], @@ -116,7 +116,7 @@ }, { "cell_type": "code", - "execution_count": 6, + "execution_count": 3, "id": "a660e3ac-401b-47a0-92de-55afe63c420a", "metadata": {}, "outputs": [ @@ -134,7 +134,7 @@ }, { "cell_type": "code", - "execution_count": 7, + "execution_count": 4, "id": "07bc266d-35eb-4f6d-bdba-e9f6f66827f1", "metadata": {}, "outputs": [], @@ -180,7 +180,7 @@ }, { "cell_type": "code", - "execution_count": 8, + "execution_count": 5, "id": "bb604b15-4ad6-43c0-9cfa-1b31611d73ce", "metadata": {}, "outputs": [], @@ -190,7 +190,7 @@ }, { "cell_type": "code", - "execution_count": 11, + "execution_count": 6, "id": "4d5c7f10-618f-4612-b594-81d1607b0d1d", "metadata": {}, "outputs": [], @@ -215,14 +215,14 @@ }, { "cell_type": "code", - "execution_count": null, + "execution_count": 7, "id": "84359084-4116-436c-92cd-d43fdfeca842", "metadata": {}, "outputs": [ { "data": { "application/vnd.jupyter.widget-view+json": { - "model_id": "8050887d56444467ae4a9e8345acaab5", + "model_id": "0f2977641ab546afafc38be4f638f92c", "version_major": 2, "version_minor": 0 }, @@ -232,6 +232,24 @@ }, "metadata": {}, "output_type": "display_data" + }, + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Got SlidingWindowMultiplier_()_{'width': 4}.\n" + ] + }, + { + "ename": "NameError", + "evalue": "name 'res' is not defined", + "output_type": "error", + "traceback": [ + "\u001b[31m---------------------------------------------------------------------------\u001b[39m", + "\u001b[31mNameError\u001b[39m Traceback (most recent call last)", + "\u001b[36mCell\u001b[39m\u001b[36m \u001b[39m\u001b[32mIn[7]\u001b[39m\u001b[32m, line 12\u001b[39m\n\u001b[32m 10\u001b[39m \u001b[38;5;28;01mcontinue\u001b[39;00m\n\u001b[32m 11\u001b[39m \u001b[38;5;28;01mif\u001b[39;00m mult \u001b[38;5;129;01mnot\u001b[39;00m \u001b[38;5;129;01min\u001b[39;00m multiples_mults:\n\u001b[32m---> \u001b[39m\u001b[32m12\u001b[39m multiples_mults[mult] = \u001b[43mres\u001b[49m\n\u001b[32m 13\u001b[39m \u001b[38;5;28;01melse\u001b[39;00m:\n\u001b[32m 14\u001b[39m \u001b[38;5;66;03m# Accumulate\u001b[39;00m\n\u001b[32m 15\u001b[39m multiples_mults[mult].merge(res)\n", + "\u001b[31mNameError\u001b[39m: name 'res' is not defined" + ] } ], "source": [ @@ -241,10 +259,11 @@ " target,\n", " mult, params, bits, samples)\n", " for mult, future in tqdm(pool.as_completed(), desc=\"Computing small scalar distributions.\", total=len(pool.tasks)):\n", - " print(f\"Got {mult_label(mult)}.\")\n", + " print(f\"Got {mult}.\")\n", " if error := future.exception():\n", " print(error)\n", " continue\n", + " res = future.result()\n", " if mult not in multiples_mults:\n", " multiples_mults[mult] = res\n", " else:\n", |
