|
@@ -2,28 +2,9 @@
|
|
|
"cells": [
|
|
|
{
|
|
|
"cell_type": "code",
|
|
|
- "execution_count": 11,
|
|
|
+ "execution_count": null,
|
|
|
"metadata": {},
|
|
|
- "outputs": [
|
|
|
- {
|
|
|
- "name": "stdout",
|
|
|
- "output_type": "stream",
|
|
|
- "text": [
|
|
|
- "Collecting uvicorn\n",
|
|
|
- " Downloading uvicorn-0.17.5-py3-none-any.whl (53 kB)\n",
|
|
|
- "\u001b[2K \u001b[90m━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\u001b[0m \u001b[32m53.6/53.6 KB\u001b[0m \u001b[31m2.3 MB/s\u001b[0m eta \u001b[36m0:00:00\u001b[0m\n",
|
|
|
- "\u001b[?25hRequirement already satisfied: click>=7.0 in /home/ken/anaconda3/lib/python3.8/site-packages (from uvicorn) (7.1.2)\n",
|
|
|
- "Collecting asgiref>=3.4.0\n",
|
|
|
- " Downloading asgiref-3.5.0-py3-none-any.whl (22 kB)\n",
|
|
|
- "Collecting h11>=0.8\n",
|
|
|
- " Downloading h11-0.13.0-py3-none-any.whl (58 kB)\n",
|
|
|
- "\u001b[2K \u001b[90m━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\u001b[0m \u001b[32m58.2/58.2 KB\u001b[0m \u001b[31m5.1 MB/s\u001b[0m eta \u001b[36m0:00:00\u001b[0m\n",
|
|
|
- "\u001b[?25hInstalling collected packages: h11, asgiref, uvicorn\n",
|
|
|
- "Successfully installed asgiref-3.5.0 h11-0.13.0 uvicorn-0.17.5\n",
|
|
|
- "Note: you may need to restart the kernel to use updated packages.\n"
|
|
|
- ]
|
|
|
- }
|
|
|
- ],
|
|
|
+ "outputs": [],
|
|
|
"source": [
|
|
|
"%pip install fastapi\n",
|
|
|
"%pip install uvicorn\n",
|
|
@@ -34,7 +15,7 @@
|
|
|
},
|
|
|
{
|
|
|
"cell_type": "code",
|
|
|
- "execution_count": 1,
|
|
|
+ "execution_count": null,
|
|
|
"metadata": {},
|
|
|
"outputs": [],
|
|
|
"source": [
|
|
@@ -51,337 +32,9 @@
|
|
|
},
|
|
|
{
|
|
|
"cell_type": "code",
|
|
|
- "execution_count": 3,
|
|
|
+ "execution_count": null,
|
|
|
"metadata": {},
|
|
|
- "outputs": [
|
|
|
- {
|
|
|
- "data": {
|
|
|
- "text/html": [
|
|
|
- "<style type=\"text/css\">\n",
|
|
|
- "#T_7292e_row29_col1, #T_7292e_row44_col1 {\n",
|
|
|
- " background-color: lightgreen;\n",
|
|
|
- "}\n",
|
|
|
- "</style>\n",
|
|
|
- "<table id=\"T_7292e_\">\n",
|
|
|
- " <thead>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th class=\"blank level0\" > </th>\n",
|
|
|
- " <th class=\"col_heading level0 col0\" >Description</th>\n",
|
|
|
- " <th class=\"col_heading level0 col1\" >Value</th>\n",
|
|
|
- " </tr>\n",
|
|
|
- " </thead>\n",
|
|
|
- " <tbody>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row0\" class=\"row_heading level0 row0\" >0</th>\n",
|
|
|
- " <td id=\"T_7292e_row0_col0\" class=\"data row0 col0\" >session_id</td>\n",
|
|
|
- " <td id=\"T_7292e_row0_col1\" class=\"data row0 col1\" >3495</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row1\" class=\"row_heading level0 row1\" >1</th>\n",
|
|
|
- " <td id=\"T_7292e_row1_col0\" class=\"data row1 col0\" >Target</td>\n",
|
|
|
- " <td id=\"T_7292e_row1_col1\" class=\"data row1 col1\" >label</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row2\" class=\"row_heading level0 row2\" >2</th>\n",
|
|
|
- " <td id=\"T_7292e_row2_col0\" class=\"data row2 col0\" >Target Type</td>\n",
|
|
|
- " <td id=\"T_7292e_row2_col1\" class=\"data row2 col1\" >Binary</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row3\" class=\"row_heading level0 row3\" >3</th>\n",
|
|
|
- " <td id=\"T_7292e_row3_col0\" class=\"data row3 col0\" >Label Encoded</td>\n",
|
|
|
- " <td id=\"T_7292e_row3_col1\" class=\"data row3 col1\" >0.0: 0, 1.0: 1</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row4\" class=\"row_heading level0 row4\" >4</th>\n",
|
|
|
- " <td id=\"T_7292e_row4_col0\" class=\"data row4 col0\" >Original Data</td>\n",
|
|
|
- " <td id=\"T_7292e_row4_col1\" class=\"data row4 col1\" >(64800, 13)</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row5\" class=\"row_heading level0 row5\" >5</th>\n",
|
|
|
- " <td id=\"T_7292e_row5_col0\" class=\"data row5 col0\" >Missing Values</td>\n",
|
|
|
- " <td id=\"T_7292e_row5_col1\" class=\"data row5 col1\" >False</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row6\" class=\"row_heading level0 row6\" >6</th>\n",
|
|
|
- " <td id=\"T_7292e_row6_col0\" class=\"data row6 col0\" >Numeric Features</td>\n",
|
|
|
- " <td id=\"T_7292e_row6_col1\" class=\"data row6 col1\" >10</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row7\" class=\"row_heading level0 row7\" >7</th>\n",
|
|
|
- " <td id=\"T_7292e_row7_col0\" class=\"data row7 col0\" >Categorical Features</td>\n",
|
|
|
- " <td id=\"T_7292e_row7_col1\" class=\"data row7 col1\" >2</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row8\" class=\"row_heading level0 row8\" >8</th>\n",
|
|
|
- " <td id=\"T_7292e_row8_col0\" class=\"data row8 col0\" >Ordinal Features</td>\n",
|
|
|
- " <td id=\"T_7292e_row8_col1\" class=\"data row8 col1\" >False</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row9\" class=\"row_heading level0 row9\" >9</th>\n",
|
|
|
- " <td id=\"T_7292e_row9_col0\" class=\"data row9 col0\" >High Cardinality Features</td>\n",
|
|
|
- " <td id=\"T_7292e_row9_col1\" class=\"data row9 col1\" >False</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row10\" class=\"row_heading level0 row10\" >10</th>\n",
|
|
|
- " <td id=\"T_7292e_row10_col0\" class=\"data row10 col0\" >High Cardinality Method</td>\n",
|
|
|
- " <td id=\"T_7292e_row10_col1\" class=\"data row10 col1\" >None</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row11\" class=\"row_heading level0 row11\" >11</th>\n",
|
|
|
- " <td id=\"T_7292e_row11_col0\" class=\"data row11 col0\" >Transformed Train Set</td>\n",
|
|
|
- " <td id=\"T_7292e_row11_col1\" class=\"data row11 col1\" >(45359, 21)</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row12\" class=\"row_heading level0 row12\" >12</th>\n",
|
|
|
- " <td id=\"T_7292e_row12_col0\" class=\"data row12 col0\" >Transformed Test Set</td>\n",
|
|
|
- " <td id=\"T_7292e_row12_col1\" class=\"data row12 col1\" >(19441, 21)</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row13\" class=\"row_heading level0 row13\" >13</th>\n",
|
|
|
- " <td id=\"T_7292e_row13_col0\" class=\"data row13 col0\" >Shuffle Train-Test</td>\n",
|
|
|
- " <td id=\"T_7292e_row13_col1\" class=\"data row13 col1\" >True</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row14\" class=\"row_heading level0 row14\" >14</th>\n",
|
|
|
- " <td id=\"T_7292e_row14_col0\" class=\"data row14 col0\" >Stratify Train-Test</td>\n",
|
|
|
- " <td id=\"T_7292e_row14_col1\" class=\"data row14 col1\" >False</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row15\" class=\"row_heading level0 row15\" >15</th>\n",
|
|
|
- " <td id=\"T_7292e_row15_col0\" class=\"data row15 col0\" >Fold Generator</td>\n",
|
|
|
- " <td id=\"T_7292e_row15_col1\" class=\"data row15 col1\" >StratifiedKFold</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row16\" class=\"row_heading level0 row16\" >16</th>\n",
|
|
|
- " <td id=\"T_7292e_row16_col0\" class=\"data row16 col0\" >Fold Number</td>\n",
|
|
|
- " <td id=\"T_7292e_row16_col1\" class=\"data row16 col1\" >10</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row17\" class=\"row_heading level0 row17\" >17</th>\n",
|
|
|
- " <td id=\"T_7292e_row17_col0\" class=\"data row17 col0\" >CPU Jobs</td>\n",
|
|
|
- " <td id=\"T_7292e_row17_col1\" class=\"data row17 col1\" >-1</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row18\" class=\"row_heading level0 row18\" >18</th>\n",
|
|
|
- " <td id=\"T_7292e_row18_col0\" class=\"data row18 col0\" >Use GPU</td>\n",
|
|
|
- " <td id=\"T_7292e_row18_col1\" class=\"data row18 col1\" >False</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row19\" class=\"row_heading level0 row19\" >19</th>\n",
|
|
|
- " <td id=\"T_7292e_row19_col0\" class=\"data row19 col0\" >Log Experiment</td>\n",
|
|
|
- " <td id=\"T_7292e_row19_col1\" class=\"data row19 col1\" >False</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row20\" class=\"row_heading level0 row20\" >20</th>\n",
|
|
|
- " <td id=\"T_7292e_row20_col0\" class=\"data row20 col0\" >Experiment Name</td>\n",
|
|
|
- " <td id=\"T_7292e_row20_col1\" class=\"data row20 col1\" >clf-default-name</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row21\" class=\"row_heading level0 row21\" >21</th>\n",
|
|
|
- " <td id=\"T_7292e_row21_col0\" class=\"data row21 col0\" >USI</td>\n",
|
|
|
- " <td id=\"T_7292e_row21_col1\" class=\"data row21 col1\" >1c4f</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row22\" class=\"row_heading level0 row22\" >22</th>\n",
|
|
|
- " <td id=\"T_7292e_row22_col0\" class=\"data row22 col0\" >Imputation Type</td>\n",
|
|
|
- " <td id=\"T_7292e_row22_col1\" class=\"data row22 col1\" >simple</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row23\" class=\"row_heading level0 row23\" >23</th>\n",
|
|
|
- " <td id=\"T_7292e_row23_col0\" class=\"data row23 col0\" >Iterative Imputation Iteration</td>\n",
|
|
|
- " <td id=\"T_7292e_row23_col1\" class=\"data row23 col1\" >None</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row24\" class=\"row_heading level0 row24\" >24</th>\n",
|
|
|
- " <td id=\"T_7292e_row24_col0\" class=\"data row24 col0\" >Numeric Imputer</td>\n",
|
|
|
- " <td id=\"T_7292e_row24_col1\" class=\"data row24 col1\" >mean</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row25\" class=\"row_heading level0 row25\" >25</th>\n",
|
|
|
- " <td id=\"T_7292e_row25_col0\" class=\"data row25 col0\" >Iterative Imputation Numeric Model</td>\n",
|
|
|
- " <td id=\"T_7292e_row25_col1\" class=\"data row25 col1\" >None</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row26\" class=\"row_heading level0 row26\" >26</th>\n",
|
|
|
- " <td id=\"T_7292e_row26_col0\" class=\"data row26 col0\" >Categorical Imputer</td>\n",
|
|
|
- " <td id=\"T_7292e_row26_col1\" class=\"data row26 col1\" >constant</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row27\" class=\"row_heading level0 row27\" >27</th>\n",
|
|
|
- " <td id=\"T_7292e_row27_col0\" class=\"data row27 col0\" >Iterative Imputation Categorical Model</td>\n",
|
|
|
- " <td id=\"T_7292e_row27_col1\" class=\"data row27 col1\" >None</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row28\" class=\"row_heading level0 row28\" >28</th>\n",
|
|
|
- " <td id=\"T_7292e_row28_col0\" class=\"data row28 col0\" >Unknown Categoricals Handling</td>\n",
|
|
|
- " <td id=\"T_7292e_row28_col1\" class=\"data row28 col1\" >least_frequent</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row29\" class=\"row_heading level0 row29\" >29</th>\n",
|
|
|
- " <td id=\"T_7292e_row29_col0\" class=\"data row29 col0\" >Normalize</td>\n",
|
|
|
- " <td id=\"T_7292e_row29_col1\" class=\"data row29 col1\" >True</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row30\" class=\"row_heading level0 row30\" >30</th>\n",
|
|
|
- " <td id=\"T_7292e_row30_col0\" class=\"data row30 col0\" >Normalize Method</td>\n",
|
|
|
- " <td id=\"T_7292e_row30_col1\" class=\"data row30 col1\" >zscore</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row31\" class=\"row_heading level0 row31\" >31</th>\n",
|
|
|
- " <td id=\"T_7292e_row31_col0\" class=\"data row31 col0\" >Transformation</td>\n",
|
|
|
- " <td id=\"T_7292e_row31_col1\" class=\"data row31 col1\" >False</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row32\" class=\"row_heading level0 row32\" >32</th>\n",
|
|
|
- " <td id=\"T_7292e_row32_col0\" class=\"data row32 col0\" >Transformation Method</td>\n",
|
|
|
- " <td id=\"T_7292e_row32_col1\" class=\"data row32 col1\" >None</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row33\" class=\"row_heading level0 row33\" >33</th>\n",
|
|
|
- " <td id=\"T_7292e_row33_col0\" class=\"data row33 col0\" >PCA</td>\n",
|
|
|
- " <td id=\"T_7292e_row33_col1\" class=\"data row33 col1\" >False</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row34\" class=\"row_heading level0 row34\" >34</th>\n",
|
|
|
- " <td id=\"T_7292e_row34_col0\" class=\"data row34 col0\" >PCA Method</td>\n",
|
|
|
- " <td id=\"T_7292e_row34_col1\" class=\"data row34 col1\" >None</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row35\" class=\"row_heading level0 row35\" >35</th>\n",
|
|
|
- " <td id=\"T_7292e_row35_col0\" class=\"data row35 col0\" >PCA Components</td>\n",
|
|
|
- " <td id=\"T_7292e_row35_col1\" class=\"data row35 col1\" >None</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row36\" class=\"row_heading level0 row36\" >36</th>\n",
|
|
|
- " <td id=\"T_7292e_row36_col0\" class=\"data row36 col0\" >Ignore Low Variance</td>\n",
|
|
|
- " <td id=\"T_7292e_row36_col1\" class=\"data row36 col1\" >False</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row37\" class=\"row_heading level0 row37\" >37</th>\n",
|
|
|
- " <td id=\"T_7292e_row37_col0\" class=\"data row37 col0\" >Combine Rare Levels</td>\n",
|
|
|
- " <td id=\"T_7292e_row37_col1\" class=\"data row37 col1\" >False</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row38\" class=\"row_heading level0 row38\" >38</th>\n",
|
|
|
- " <td id=\"T_7292e_row38_col0\" class=\"data row38 col0\" >Rare Level Threshold</td>\n",
|
|
|
- " <td id=\"T_7292e_row38_col1\" class=\"data row38 col1\" >None</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row39\" class=\"row_heading level0 row39\" >39</th>\n",
|
|
|
- " <td id=\"T_7292e_row39_col0\" class=\"data row39 col0\" >Numeric Binning</td>\n",
|
|
|
- " <td id=\"T_7292e_row39_col1\" class=\"data row39 col1\" >False</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row40\" class=\"row_heading level0 row40\" >40</th>\n",
|
|
|
- " <td id=\"T_7292e_row40_col0\" class=\"data row40 col0\" >Remove Outliers</td>\n",
|
|
|
- " <td id=\"T_7292e_row40_col1\" class=\"data row40 col1\" >False</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row41\" class=\"row_heading level0 row41\" >41</th>\n",
|
|
|
- " <td id=\"T_7292e_row41_col0\" class=\"data row41 col0\" >Outliers Threshold</td>\n",
|
|
|
- " <td id=\"T_7292e_row41_col1\" class=\"data row41 col1\" >None</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row42\" class=\"row_heading level0 row42\" >42</th>\n",
|
|
|
- " <td id=\"T_7292e_row42_col0\" class=\"data row42 col0\" >Remove Multicollinearity</td>\n",
|
|
|
- " <td id=\"T_7292e_row42_col1\" class=\"data row42 col1\" >False</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row43\" class=\"row_heading level0 row43\" >43</th>\n",
|
|
|
- " <td id=\"T_7292e_row43_col0\" class=\"data row43 col0\" >Multicollinearity Threshold</td>\n",
|
|
|
- " <td id=\"T_7292e_row43_col1\" class=\"data row43 col1\" >None</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row44\" class=\"row_heading level0 row44\" >44</th>\n",
|
|
|
- " <td id=\"T_7292e_row44_col0\" class=\"data row44 col0\" >Remove Perfect Collinearity</td>\n",
|
|
|
- " <td id=\"T_7292e_row44_col1\" class=\"data row44 col1\" >True</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row45\" class=\"row_heading level0 row45\" >45</th>\n",
|
|
|
- " <td id=\"T_7292e_row45_col0\" class=\"data row45 col0\" >Clustering</td>\n",
|
|
|
- " <td id=\"T_7292e_row45_col1\" class=\"data row45 col1\" >False</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row46\" class=\"row_heading level0 row46\" >46</th>\n",
|
|
|
- " <td id=\"T_7292e_row46_col0\" class=\"data row46 col0\" >Clustering Iteration</td>\n",
|
|
|
- " <td id=\"T_7292e_row46_col1\" class=\"data row46 col1\" >None</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row47\" class=\"row_heading level0 row47\" >47</th>\n",
|
|
|
- " <td id=\"T_7292e_row47_col0\" class=\"data row47 col0\" >Polynomial Features</td>\n",
|
|
|
- " <td id=\"T_7292e_row47_col1\" class=\"data row47 col1\" >False</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row48\" class=\"row_heading level0 row48\" >48</th>\n",
|
|
|
- " <td id=\"T_7292e_row48_col0\" class=\"data row48 col0\" >Polynomial Degree</td>\n",
|
|
|
- " <td id=\"T_7292e_row48_col1\" class=\"data row48 col1\" >None</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row49\" class=\"row_heading level0 row49\" >49</th>\n",
|
|
|
- " <td id=\"T_7292e_row49_col0\" class=\"data row49 col0\" >Trignometry Features</td>\n",
|
|
|
- " <td id=\"T_7292e_row49_col1\" class=\"data row49 col1\" >False</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row50\" class=\"row_heading level0 row50\" >50</th>\n",
|
|
|
- " <td id=\"T_7292e_row50_col0\" class=\"data row50 col0\" >Polynomial Threshold</td>\n",
|
|
|
- " <td id=\"T_7292e_row50_col1\" class=\"data row50 col1\" >None</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row51\" class=\"row_heading level0 row51\" >51</th>\n",
|
|
|
- " <td id=\"T_7292e_row51_col0\" class=\"data row51 col0\" >Group Features</td>\n",
|
|
|
- " <td id=\"T_7292e_row51_col1\" class=\"data row51 col1\" >False</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row52\" class=\"row_heading level0 row52\" >52</th>\n",
|
|
|
- " <td id=\"T_7292e_row52_col0\" class=\"data row52 col0\" >Feature Selection</td>\n",
|
|
|
- " <td id=\"T_7292e_row52_col1\" class=\"data row52 col1\" >False</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row53\" class=\"row_heading level0 row53\" >53</th>\n",
|
|
|
- " <td id=\"T_7292e_row53_col0\" class=\"data row53 col0\" >Feature Selection Method</td>\n",
|
|
|
- " <td id=\"T_7292e_row53_col1\" class=\"data row53 col1\" >classic</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row54\" class=\"row_heading level0 row54\" >54</th>\n",
|
|
|
- " <td id=\"T_7292e_row54_col0\" class=\"data row54 col0\" >Features Selection Threshold</td>\n",
|
|
|
- " <td id=\"T_7292e_row54_col1\" class=\"data row54 col1\" >None</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row55\" class=\"row_heading level0 row55\" >55</th>\n",
|
|
|
- " <td id=\"T_7292e_row55_col0\" class=\"data row55 col0\" >Feature Interaction</td>\n",
|
|
|
- " <td id=\"T_7292e_row55_col1\" class=\"data row55 col1\" >False</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row56\" class=\"row_heading level0 row56\" >56</th>\n",
|
|
|
- " <td id=\"T_7292e_row56_col0\" class=\"data row56 col0\" >Feature Ratio</td>\n",
|
|
|
- " <td id=\"T_7292e_row56_col1\" class=\"data row56 col1\" >False</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row57\" class=\"row_heading level0 row57\" >57</th>\n",
|
|
|
- " <td id=\"T_7292e_row57_col0\" class=\"data row57 col0\" >Interaction Threshold</td>\n",
|
|
|
- " <td id=\"T_7292e_row57_col1\" class=\"data row57 col1\" >None</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row58\" class=\"row_heading level0 row58\" >58</th>\n",
|
|
|
- " <td id=\"T_7292e_row58_col0\" class=\"data row58 col0\" >Fix Imbalance</td>\n",
|
|
|
- " <td id=\"T_7292e_row58_col1\" class=\"data row58 col1\" >False</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " <tr>\n",
|
|
|
- " <th id=\"T_7292e_level0_row59\" class=\"row_heading level0 row59\" >59</th>\n",
|
|
|
- " <td id=\"T_7292e_row59_col0\" class=\"data row59 col0\" >Fix Imbalance Method</td>\n",
|
|
|
- " <td id=\"T_7292e_row59_col1\" class=\"data row59 col1\" >SMOTE</td>\n",
|
|
|
- " </tr>\n",
|
|
|
- " </tbody>\n",
|
|
|
- "</table>\n"
|
|
|
- ],
|
|
|
- "text/plain": [
|
|
|
- "<pandas.io.formats.style.Styler at 0x7f6b70ae48e0>"
|
|
|
- ]
|
|
|
- },
|
|
|
- "metadata": {},
|
|
|
- "output_type": "display_data"
|
|
|
- }
|
|
|
- ],
|
|
|
+ "outputs": [],
|
|
|
"source": [
|
|
|
"data = pd.read_csv('data/data_feature_eng.csv')\n",
|
|
|
"# print(data)\n",
|
|
@@ -394,17 +47,9 @@
|
|
|
},
|
|
|
{
|
|
|
"cell_type": "code",
|
|
|
- "execution_count": 4,
|
|
|
+ "execution_count": null,
|
|
|
"metadata": {},
|
|
|
- "outputs": [
|
|
|
- {
|
|
|
- "name": "stdout",
|
|
|
- "output_type": "stream",
|
|
|
- "text": [
|
|
|
- "Transformation Pipeline and Model Successfully Loaded\n"
|
|
|
- ]
|
|
|
- }
|
|
|
- ],
|
|
|
+ "outputs": [],
|
|
|
"source": [
|
|
|
"# plot_model(tuned_dt, plot='auc')\n",
|
|
|
"mdl = load_model('tuned_xgboost_0207')"
|
|
@@ -412,20 +57,9 @@
|
|
|
},
|
|
|
{
|
|
|
"cell_type": "code",
|
|
|
- "execution_count": 5,
|
|
|
+ "execution_count": null,
|
|
|
"metadata": {},
|
|
|
- "outputs": [
|
|
|
- {
|
|
|
- "data": {
|
|
|
- "text/plain": [
|
|
|
- "1.0"
|
|
|
- ]
|
|
|
- },
|
|
|
- "execution_count": 5,
|
|
|
- "metadata": {},
|
|
|
- "output_type": "execute_result"
|
|
|
- }
|
|
|
- ],
|
|
|
+ "outputs": [],
|
|
|
"source": [
|
|
|
"# plot_model(mdl, plot='auc')\n",
|
|
|
"# evaluate_model(mdl)\n",
|
|
@@ -436,21 +70,9 @@
|
|
|
},
|
|
|
{
|
|
|
"cell_type": "code",
|
|
|
- "execution_count": 6,
|
|
|
+ "execution_count": null,
|
|
|
"metadata": {},
|
|
|
- "outputs": [
|
|
|
- {
|
|
|
- "name": "stdout",
|
|
|
- "output_type": "stream",
|
|
|
- "text": [
|
|
|
- "\n",
|
|
|
- "API sucessfully created. This function only creates a POST API, it doesn't run it automatically.\n",
|
|
|
- "\n",
|
|
|
- "To run your API, please run this command --> !python my_api.py\n",
|
|
|
- " \n"
|
|
|
- ]
|
|
|
- }
|
|
|
- ],
|
|
|
+ "outputs": [],
|
|
|
"source": [
|
|
|
"create_api(mdl, 'my_api')\n",
|
|
|
"# !python my_api.py"
|
|
@@ -458,21 +80,9 @@
|
|
|
},
|
|
|
{
|
|
|
"cell_type": "code",
|
|
|
- "execution_count": 7,
|
|
|
+ "execution_count": null,
|
|
|
"metadata": {},
|
|
|
- "outputs": [
|
|
|
- {
|
|
|
- "name": "stdout",
|
|
|
- "output_type": "stream",
|
|
|
- "text": [
|
|
|
- "Writing requirements.txt\n",
|
|
|
- "Writing Dockerfile\n",
|
|
|
- "Dockerfile and requirements.txt successfully created.\n",
|
|
|
- "To build image you have to run --> !docker image build -f \"Dockerfile\" -t IMAGE_NAME:IMAGE_TAG .\n",
|
|
|
- " \n"
|
|
|
- ]
|
|
|
- }
|
|
|
- ],
|
|
|
+ "outputs": [],
|
|
|
"source": [
|
|
|
"create_docker('my_api')\n",
|
|
|
"# !docker image build -f \"Dockerfile\" -t my_api:latest ."
|