removed cell output

This commit is contained in:
Michael Weig 2025-12-10 19:35:20 +01:00
parent fd7981f244
commit 15b32a9792

View File

@ -10,29 +10,10 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 61, "execution_count": null,
"id": "53b10294", "id": "53b10294",
"metadata": {}, "metadata": {},
"outputs": [ "outputs": [],
{
"name": "stdout",
"output_type": "stream",
"text": [
"/home\n"
]
},
{
"ename": "ImportError",
"evalue": "cannot import name 'mad_outlier_removal' from 'Fahrsimulator_MSY2526_AI.model_training.tools' (unknown location)",
"output_type": "error",
"traceback": [
"\u001b[31m---------------------------------------------------------------------------\u001b[39m",
"\u001b[31mImportError\u001b[39m Traceback (most recent call last)",
"\u001b[36mCell\u001b[39m\u001b[36m \u001b[39m\u001b[32mIn[61]\u001b[39m\u001b[32m, line 11\u001b[39m\n\u001b[32m 8\u001b[39m sys.path.append(base_dir)\n\u001b[32m 9\u001b[39m \u001b[38;5;28mprint\u001b[39m(base_dir)\n\u001b[32m---> \u001b[39m\u001b[32m11\u001b[39m \u001b[38;5;28;01mfrom\u001b[39;00m\u001b[38;5;250m \u001b[39m\u001b[34;01mFahrsimulator_MSY2526_AI\u001b[39;00m\u001b[34;01m.\u001b[39;00m\u001b[34;01mmodel_training\u001b[39;00m\u001b[34;01m.\u001b[39;00m\u001b[34;01mtools\u001b[39;00m\u001b[38;5;250m \u001b[39m\u001b[38;5;28;01mimport\u001b[39;00m evaluation_tools, scaler, mad_outlier_removal\n\u001b[32m 12\u001b[39m \u001b[38;5;28;01mfrom\u001b[39;00m\u001b[38;5;250m \u001b[39m\u001b[34;01msklearn\u001b[39;00m\u001b[34;01m.\u001b[39;00m\u001b[34;01mpreprocessing\u001b[39;00m\u001b[38;5;250m \u001b[39m\u001b[38;5;28;01mimport\u001b[39;00m StandardScaler, MinMaxScaler\n\u001b[32m 13\u001b[39m \u001b[38;5;28;01mfrom\u001b[39;00m\u001b[38;5;250m \u001b[39m\u001b[34;01msklearn\u001b[39;00m\u001b[34;01m.\u001b[39;00m\u001b[34;01msvm\u001b[39;00m\u001b[38;5;250m \u001b[39m\u001b[38;5;28;01mimport\u001b[39;00m OneClassSVM\n",
"\u001b[31mImportError\u001b[39m: cannot import name 'mad_outlier_removal' from 'Fahrsimulator_MSY2526_AI.model_training.tools' (unknown location)"
]
}
],
"source": [ "source": [
"import pandas as pd\n", "import pandas as pd\n",
"import numpy as np\n", "import numpy as np\n",
@ -65,7 +46,7 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 12, "execution_count": null,
"id": "24a765e8", "id": "24a765e8",
"metadata": {}, "metadata": {},
"outputs": [], "outputs": [],
@ -75,7 +56,7 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 13, "execution_count": null,
"id": "471001b0", "id": "471001b0",
"metadata": {}, "metadata": {},
"outputs": [], "outputs": [],
@ -93,7 +74,7 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 32, "execution_count": null,
"id": "692d1b47", "id": "692d1b47",
"metadata": {}, "metadata": {},
"outputs": [], "outputs": [],
@ -104,7 +85,7 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 33, "execution_count": null,
"id": "ea617e3f", "id": "ea617e3f",
"metadata": {}, "metadata": {},
"outputs": [], "outputs": [],
@ -130,20 +111,10 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 52, "execution_count": null,
"id": "ae43df8d", "id": "ae43df8d",
"metadata": {}, "metadata": {},
"outputs": [ "outputs": [],
{
"name": "stdout",
"output_type": "stream",
"text": [
"Finale Score-Differenz: 0.0020961590397180485\n",
"Größe Gruppe 1: 6\n",
"Größe Gruppe 2: 12\n"
]
}
],
"source": [ "source": [
"merged_sorted = merged.sort_values(\"overall_score\", ascending=False).reset_index(drop=True)\n", "merged_sorted = merged.sort_values(\"overall_score\", ascending=False).reset_index(drop=True)\n",
"\n", "\n",
@ -202,61 +173,30 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 53, "execution_count": null,
"id": "9d1b414e", "id": "9d1b414e",
"metadata": {}, "metadata": {},
"outputs": [ "outputs": [],
{
"data": {
"text/plain": [
"0.7895307985978888"
]
},
"execution_count": 53,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [ "source": [
"group_large['overall_score'].mean()" "group_large['overall_score'].mean()"
] ]
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 54, "execution_count": null,
"id": "fa71f9a5", "id": "fa71f9a5",
"metadata": {}, "metadata": {},
"outputs": [ "outputs": [],
{
"data": {
"text/plain": [
"0.7874346395581707"
]
},
"execution_count": 54,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [ "source": [
"group_small['overall_score'].mean()" "group_small['overall_score'].mean()"
] ]
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 55, "execution_count": null,
"id": "79ecb4a2", "id": "79ecb4a2",
"metadata": {}, "metadata": {},
"outputs": [ "outputs": [],
{
"name": "stdout",
"output_type": "stream",
"text": [
"[22 4 26 16 3 11 18 14 24 13 9 28]\n",
"[ 5 6 29 0 7 17]\n"
]
}
],
"source": [ "source": [
"training_subjects = group_large['subjectID'].values\n", "training_subjects = group_large['subjectID'].values\n",
"test_subjects = group_small['subjectID'].values\n", "test_subjects = group_small['subjectID'].values\n",
@ -274,19 +214,10 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 60, "execution_count": null,
"id": "76610052", "id": "76610052",
"metadata": {}, "metadata": {},
"outputs": [ "outputs": [],
{
"name": "stdout",
"output_type": "stream",
"text": [
"(7115, 25)\n",
"(7320, 25)\n"
]
}
],
"source": [ "source": [
"# SET\n", "# SET\n",
"threshold_mad = 100\n", "threshold_mad = 100\n",