diff --git a/7506R-1C2023-GRUPO09-CHP04.ipynb b/7506R-1C2023-GRUPO09-CHP04.ipynb
new file mode 100644
index 0000000..39713a4
--- /dev/null
+++ b/7506R-1C2023-GRUPO09-CHP04.ipynb
@@ -0,0 +1,1731 @@
+{
+ "cells": [
+ {
+ "cell_type": "markdown",
+ "id": "bb1b4968",
+ "metadata": {},
+ "source": [
+ "# Importamos"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 1,
+ "id": "c283c681",
+ "metadata": {},
+ "outputs": [],
+ "source": [
+ "try:\n",
+ " import google.colab\n",
+ " IN_COLAB = True\n",
+ "except:\n",
+ " IN_COLAB = False\n",
+ "\n",
+ "import pandas as pd \n",
+ "import numpy as np\n",
+ "import sklearn as sk\n",
+ "import seaborn as sns\n",
+ "import pydotplus\n",
+ "from six import StringIO\n",
+ "from IPython.display import Image \n",
+ "from matplotlib import pyplot as plt\n",
+ "#TODO creo q no va:\n",
+ "from dict_paises import COUNTRY_ALPHA3_TO_COUNTRY_ALPHA2, COUNTRY_ALPHA2_TO_CONTINENT\n",
+ "from joblib import dump, load\n",
+ "from os.path import exists\n",
+ "\n",
+ "from sklearn.model_selection import StratifiedKFold, KFold,RandomizedSearchCV, train_test_split, cross_validate\n",
+ "from sklearn.tree import DecisionTreeClassifier, export_graphviz, export_text\n",
+ "from sklearn.metrics import confusion_matrix, classification_report , f1_score, make_scorer, precision_score, recall_score, accuracy_score,f1_score\n",
+ "from sklearn.preprocessing import MinMaxScaler\n",
+ "from sklearn import tree\n",
+ "from sklearn.preprocessing import OneHotEncoder, StandardScaler\n",
+ "\n",
+ "\n",
+ "from sklearn.model_selection import GridSearchCV\n",
+ "from sklearn.model_selection import train_test_split, RandomizedSearchCV, GridSearchCV, cross_val_score\n",
+ "from sklearn.model_selection import train_test_split\n",
+ "\n",
+ "from sklearn.metrics import confusion_matrix, classification_report\n",
+ "from sklearn.metrics import accuracy_score\n",
+ "\n",
+ "\n",
+ "\n",
+ "#Si estamos en colab tenemos que instalar la libreria \"dtreeviz\" aparte. \n",
+ "if IN_COLAB == True:\n",
+ " !pip install 'dtreeviz'\n",
+ "import dtreeviz as dtreeviz\n",
+ "\n",
+ "#Para eliminar los warnings\n",
+ "import warnings\n",
+ "warnings.simplefilter(action='ignore', category=FutureWarning)\n",
+ "warnings.simplefilter(action='ignore', category=UserWarning)\n",
+ "\n",
+ "import tensorflow as tf\n",
+ "from tensorflow import keras\n",
+ "from keras.utils.vis_utils import plot_model\n",
+ "\n",
+ "from keras.wrappers.scikit_learn import KerasClassifier #Libreria para usarg Grid Search con kerss"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "id": "e599699a",
+ "metadata": {},
+ "source": [
+ "Constantes"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 2,
+ "id": "135ff858",
+ "metadata": {},
+ "outputs": [],
+ "source": [
+ "# Constantes\n",
+ "JOBS=-2\n",
+ "SEED=9\n",
+ "\n",
+ "np.random.seed(SEED)\n",
+ "tf.random.set_seed(SEED) "
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "id": "eba624e8",
+ "metadata": {},
+ "source": [
+ "importo el dataframe original para tener los ids"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 3,
+ "id": "feb9d3a1",
+ "metadata": {},
+ "outputs": [],
+ "source": [
+ "hotelsdf_pruebasOriginal = pd.read_csv(\"./hotels_test.csv\")"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "id": "635841e6",
+ "metadata": {},
+ "source": [
+ "Importamos los dataframes ya filtrados que generamos en el checkpoint 1. De esta forma evitamos tener todo el codigo de homologacion de dataframes de testeo y train aqui de nuevo"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 4,
+ "id": "32efae1e",
+ "metadata": {},
+ "outputs": [],
+ "source": [
+ "hotelsdf_train_filtrado = pd.read_csv(\"hotels_filtrado_train.csv\")\n",
+ "hotelsdf_testeo_filtrado = pd.read_csv(\"hotels_filtrado_test.csv\")"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 5,
+ "id": "5b2cc4a6",
+ "metadata": {},
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Faltan en arbol: []\n",
+ "Sobran en arbol: ['is_canceled']\n"
+ ]
+ }
+ ],
+ "source": [
+ "set_test = set(hotelsdf_testeo_filtrado.columns)\n",
+ "set_modelo = set(hotelsdf_train_filtrado.columns)\n",
+ "\n",
+ "missing = list(sorted(set_test - set_modelo))\n",
+ "added = list(sorted(set_modelo - set_test))\n",
+ "\n",
+ "print('Faltan en arbol:', missing)\n",
+ "print('Sobran en arbol:', added)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "id": "1ae3598d",
+ "metadata": {},
+ "source": [
+ "Guardo datos antes de separacion train test"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "id": "f66e432d",
+ "metadata": {},
+ "source": [
+ "# Generacion de datos para el entrenamiento de los modelos\n",
+ "\n",
+ "Se genera un dataset con los datos necesarios para predecir la cancelacion y creamos un dataset conteniendo el target, para luego, generar conjuntos de test y train"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 6,
+ "id": "9dd01a2a",
+ "metadata": {},
+ "outputs": [],
+ "source": [
+ "hotelsdf_modelo_x=hotelsdf_train_filtrado.drop(['is_canceled'], axis='columns', inplace=False)\n",
+ "\n",
+ "hotelsdf_modelo_y = hotelsdf_train_filtrado['is_canceled'].copy()\n",
+ "\n",
+ "x_train, x_test, y_train, y_test = train_test_split(hotelsdf_modelo_x,\n",
+ " hotelsdf_modelo_y, \n",
+ " test_size=0.3, #proporcion 70/30\n",
+ " random_state=SEED) #Semilla 9, como el Equipo !!"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "id": "b2149472",
+ "metadata": {},
+ "source": [
+ "Buscamos los valores que no fueron generados por el one hot encoder"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 7,
+ "id": "06cd0ca4",
+ "metadata": {},
+ "outputs": [
+ {
+ "data": {
+ "text/plain": [
+ "Index(['lead_time', 'arrival_year', 'arrival_week_number', 'arrival_month_day',\n",
+ " 'weekend_nights_num', 'week_nights_num', 'adult_num', 'children_num',\n",
+ " 'babies_num', 'is_repeated_guest', 'previous_cancellations_num',\n",
+ " 'booking_changes_num', 'agent_id', 'days_in_waiting_list',\n",
+ " 'average_daily_rate', 'required_car_parking_spaces_num',\n",
+ " 'special_requests_num', 'dias_totales', 'hotel_name_Resort Hotel',\n",
+ " 'arrival_month_August', 'arrival_month_December',\n",
+ " 'arrival_month_February', 'arrival_month_January', 'arrival_month_July',\n",
+ " 'arrival_month_June', 'arrival_month_March', 'arrival_month_May',\n",
+ " 'arrival_month_November', 'arrival_month_October',\n",
+ " 'arrival_month_September', 'meal_type_FB', 'meal_type_HB',\n",
+ " 'meal_type_SC', 'meal_type_Undefined',\n",
+ " 'market_segment_type_Complementary', 'market_segment_type_Corporate',\n",
+ " 'market_segment_type_Direct', 'market_segment_type_Groups',\n",
+ " 'market_segment_type_Offline TA/TO', 'market_segment_type_Online TA',\n",
+ " 'distribution_channel_Direct', 'distribution_channel_GDS',\n",
+ " 'distribution_channel_TA/TO', 'reserved_room_type_B',\n",
+ " 'reserved_room_type_C', 'reserved_room_type_D', 'reserved_room_type_E',\n",
+ " 'reserved_room_type_F', 'reserved_room_type_G', 'reserved_room_type_H',\n",
+ " 'assigned_room_type_B', 'assigned_room_type_C', 'assigned_room_type_D',\n",
+ " 'assigned_room_type_E', 'assigned_room_type_F', 'assigned_room_type_G',\n",
+ " 'assigned_room_type_H', 'assigned_room_type_I', 'assigned_room_type_K',\n",
+ " 'deposit_type_Non Refund', 'deposit_type_Refundable',\n",
+ " 'customer_type_Group', 'customer_type_Transient',\n",
+ " 'customer_type_Transient-Party', 'continente_Asia', 'continente_Europe',\n",
+ " 'continente_North America', 'continente_Oceania',\n",
+ " 'continente_South America'],\n",
+ " dtype='object')"
+ ]
+ },
+ "execution_count": 7,
+ "metadata": {},
+ "output_type": "execute_result"
+ }
+ ],
+ "source": [
+ "x_train.columns"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 8,
+ "id": "4c39306f",
+ "metadata": {},
+ "outputs": [],
+ "source": [
+ "valoresNoBinarios = ['lead_time', 'arrival_year', 'arrival_week_number', 'arrival_month_day',\n",
+ " 'weekend_nights_num', 'week_nights_num', 'adult_num', 'children_num',\n",
+ " 'babies_num', 'previous_cancellations_num',\n",
+ " 'booking_changes_num', 'days_in_waiting_list',\n",
+ " 'average_daily_rate', 'required_car_parking_spaces_num',\n",
+ " 'special_requests_num', 'dias_totales']"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "id": "85ad1054",
+ "metadata": {},
+ "source": [
+ "Imports para armar la red"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "id": "fbe3493d",
+ "metadata": {},
+ "source": [
+ "Tenemos que escalar todos los valores de nuestro data set (excepto los valores producidos por el one hot encoding"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 9,
+ "id": "ad6fc897",
+ "metadata": {},
+ "outputs": [
+ {
+ "data": {
+ "text/html": [
+ "
StandardScaler() In a Jupyter environment, please rerun this cell to show the HTML representation or trust the notebook. On GitHub, the HTML representation is unable to render, please try loading this page with nbviewer.org. "
+ ],
+ "text/plain": [
+ "StandardScaler()"
+ ]
+ },
+ "execution_count": 9,
+ "metadata": {},
+ "output_type": "execute_result"
+ }
+ ],
+ "source": [
+ "sScaler = StandardScaler()\n",
+ "sScaler.fit(pd.DataFrame(x_train[valoresNoBinarios]))"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 10,
+ "id": "c7ffabf6",
+ "metadata": {},
+ "outputs": [],
+ "source": [
+ "x_train_transform_1=sScaler.transform(pd.DataFrame(x_train[valoresNoBinarios]))\n",
+ "x_test_transform_1=sScaler.transform(pd.DataFrame(x_test[valoresNoBinarios]))"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 11,
+ "id": "61bfb985",
+ "metadata": {},
+ "outputs": [
+ {
+ "data": {
+ "text/plain": [
+ "array([[-0.08993302, 1.20492525, -1.05091228, ..., -0.22125409,\n",
+ " 1.98006251, -0.19194279],\n",
+ " [-0.04922764, 1.20492525, 0.43392148, ..., -0.22125409,\n",
+ " 0.64636577, 1.6108728 ],\n",
+ " [ 0.3680026 , 1.20492525, -0.38273709, ..., -0.22125409,\n",
+ " 1.98006251, -0.19194279],\n",
+ " ...,\n",
+ " [-0.10010937, -0.20168049, -0.60546216, ..., -0.22125409,\n",
+ " -0.68733097, -1.09335058],\n",
+ " [-0.35451805, -0.20168049, 0.35967979, ..., -0.22125409,\n",
+ " 0.64636577, -0.64264669],\n",
+ " [-0.76157194, -1.60828624, 1.10209667, ..., -0.22125409,\n",
+ " 1.98006251, 1.16016891]])"
+ ]
+ },
+ "execution_count": 11,
+ "metadata": {},
+ "output_type": "execute_result"
+ }
+ ],
+ "source": [
+ "x_train_transform_1"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 12,
+ "id": "646832e5",
+ "metadata": {},
+ "outputs": [],
+ "source": [
+ "#Creamos un nuevo dataframe con los valores escalados\n",
+ "x_train_escalado = x_train.copy()\n",
+ "x_test_escalado = x_test.copy()"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 13,
+ "id": "359234db",
+ "metadata": {},
+ "outputs": [],
+ "source": [
+ "#Le asignamos los nuevos valores escalados y mantenemos los valores del one hot encoding\n",
+ "for i in range(len(valoresNoBinarios)):\n",
+ " x_train_escalado[valoresNoBinarios[i]]=x_train_transform_1[:,i]\n",
+ " x_test_escalado[valoresNoBinarios[i]]=x_test_transform_1[:,i]"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 14,
+ "id": "466127c4",
+ "metadata": {},
+ "outputs": [
+ {
+ "data": {
+ "text/html": [
+ "\n",
+ "\n",
+ "
\n",
+ " \n",
+ " \n",
+ " \n",
+ " lead_time \n",
+ " arrival_year \n",
+ " arrival_week_number \n",
+ " arrival_month_day \n",
+ " weekend_nights_num \n",
+ " week_nights_num \n",
+ " adult_num \n",
+ " children_num \n",
+ " babies_num \n",
+ " is_repeated_guest \n",
+ " ... \n",
+ " deposit_type_Non Refund \n",
+ " deposit_type_Refundable \n",
+ " customer_type_Group \n",
+ " customer_type_Transient \n",
+ " customer_type_Transient-Party \n",
+ " continente_Asia \n",
+ " continente_Europe \n",
+ " continente_North America \n",
+ " continente_Oceania \n",
+ " continente_South America \n",
+ " \n",
+ " \n",
+ " \n",
+ " \n",
+ " 15425 \n",
+ " -0.089933 \n",
+ " 1.204925 \n",
+ " -1.050912 \n",
+ " 1.728338 \n",
+ " 0.078225 \n",
+ " -0.297259 \n",
+ " 0.263118 \n",
+ " -0.250952 \n",
+ " -0.082681 \n",
+ " 0 \n",
+ " ... \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " 1 \n",
+ " 0 \n",
+ " 0 \n",
+ " 1 \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " \n",
+ " \n",
+ " 42050 \n",
+ " -0.049228 \n",
+ " 1.204925 \n",
+ " 0.433921 \n",
+ " 0.022526 \n",
+ " 1.145264 \n",
+ " 1.489213 \n",
+ " 2.437582 \n",
+ " -0.250952 \n",
+ " -0.082681 \n",
+ " 0 \n",
+ " ... \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " 1 \n",
+ " 0 \n",
+ " 0 \n",
+ " 1 \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " \n",
+ " \n",
+ " 25055 \n",
+ " 0.368003 \n",
+ " 1.204925 \n",
+ " -0.382737 \n",
+ " -1.683286 \n",
+ " -0.988814 \n",
+ " 0.298231 \n",
+ " 2.437582 \n",
+ " -0.250952 \n",
+ " -0.082681 \n",
+ " 0 \n",
+ " ... \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " 1 \n",
+ " 0 \n",
+ " 0 \n",
+ " 1 \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " \n",
+ " \n",
+ " 619 \n",
+ " 1.182110 \n",
+ " 1.204925 \n",
+ " -0.308495 \n",
+ " -1.114682 \n",
+ " -0.988814 \n",
+ " -0.297259 \n",
+ " 0.263118 \n",
+ " -0.250952 \n",
+ " -0.082681 \n",
+ " 0 \n",
+ " ... \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " 1 \n",
+ " 0 \n",
+ " 0 \n",
+ " 1 \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " \n",
+ " \n",
+ " 30470 \n",
+ " 0.011830 \n",
+ " -0.201680 \n",
+ " 0.582405 \n",
+ " 0.932292 \n",
+ " -0.988814 \n",
+ " 0.893722 \n",
+ " 0.263118 \n",
+ " -0.250952 \n",
+ " -0.082681 \n",
+ " 0 \n",
+ " ... \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " 1 \n",
+ " 0 \n",
+ " 0 \n",
+ " 1 \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " \n",
+ " \n",
+ " ... \n",
+ " ... \n",
+ " ... \n",
+ " ... \n",
+ " ... \n",
+ " ... \n",
+ " ... \n",
+ " ... \n",
+ " ... \n",
+ " ... \n",
+ " ... \n",
+ " ... \n",
+ " ... \n",
+ " ... \n",
+ " ... \n",
+ " ... \n",
+ " ... \n",
+ " ... \n",
+ " ... \n",
+ " ... \n",
+ " ... \n",
+ " ... \n",
+ " \n",
+ " \n",
+ " 42747 \n",
+ " -1.097391 \n",
+ " -0.201680 \n",
+ " 0.582405 \n",
+ " 1.046013 \n",
+ " -0.988814 \n",
+ " -0.892750 \n",
+ " 0.263118 \n",
+ " -0.250952 \n",
+ " -0.082681 \n",
+ " 0 \n",
+ " ... \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " 1 \n",
+ " 0 \n",
+ " 0 \n",
+ " 1 \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " \n",
+ " \n",
+ " 22584 \n",
+ " -0.232402 \n",
+ " 1.204925 \n",
+ " 0.062713 \n",
+ " -0.432357 \n",
+ " -0.988814 \n",
+ " -0.297259 \n",
+ " 0.263118 \n",
+ " -0.250952 \n",
+ " -0.082681 \n",
+ " 0 \n",
+ " ... \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " 1 \n",
+ " 0 \n",
+ " 0 \n",
+ " 1 \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " \n",
+ " \n",
+ " 501 \n",
+ " -0.100109 \n",
+ " -0.201680 \n",
+ " -0.605462 \n",
+ " -1.000961 \n",
+ " -0.988814 \n",
+ " -0.892750 \n",
+ " 0.263118 \n",
+ " -0.250952 \n",
+ " -0.082681 \n",
+ " 0 \n",
+ " ... \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " 1 \n",
+ " 0 \n",
+ " 0 \n",
+ " 1 \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " \n",
+ " \n",
+ " 55934 \n",
+ " -0.354518 \n",
+ " -0.201680 \n",
+ " 0.359680 \n",
+ " -1.114682 \n",
+ " 0.078225 \n",
+ " -0.892750 \n",
+ " 0.263118 \n",
+ " -0.250952 \n",
+ " -0.082681 \n",
+ " 0 \n",
+ " ... \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " 1 \n",
+ " 0 \n",
+ " 0 \n",
+ " 1 \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " \n",
+ " \n",
+ " 20828 \n",
+ " -0.761572 \n",
+ " -1.608286 \n",
+ " 1.102097 \n",
+ " 0.136247 \n",
+ " 1.145264 \n",
+ " 0.893722 \n",
+ " 0.263118 \n",
+ " -0.250952 \n",
+ " -0.082681 \n",
+ " 0 \n",
+ " ... \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " 1 \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " \n",
+ " \n",
+ "
\n",
+ "
39817 rows × 69 columns
\n",
+ "
"
+ ],
+ "text/plain": [
+ " lead_time arrival_year arrival_week_number arrival_month_day \\\n",
+ "15425 -0.089933 1.204925 -1.050912 1.728338 \n",
+ "42050 -0.049228 1.204925 0.433921 0.022526 \n",
+ "25055 0.368003 1.204925 -0.382737 -1.683286 \n",
+ "619 1.182110 1.204925 -0.308495 -1.114682 \n",
+ "30470 0.011830 -0.201680 0.582405 0.932292 \n",
+ "... ... ... ... ... \n",
+ "42747 -1.097391 -0.201680 0.582405 1.046013 \n",
+ "22584 -0.232402 1.204925 0.062713 -0.432357 \n",
+ "501 -0.100109 -0.201680 -0.605462 -1.000961 \n",
+ "55934 -0.354518 -0.201680 0.359680 -1.114682 \n",
+ "20828 -0.761572 -1.608286 1.102097 0.136247 \n",
+ "\n",
+ " weekend_nights_num week_nights_num adult_num children_num \\\n",
+ "15425 0.078225 -0.297259 0.263118 -0.250952 \n",
+ "42050 1.145264 1.489213 2.437582 -0.250952 \n",
+ "25055 -0.988814 0.298231 2.437582 -0.250952 \n",
+ "619 -0.988814 -0.297259 0.263118 -0.250952 \n",
+ "30470 -0.988814 0.893722 0.263118 -0.250952 \n",
+ "... ... ... ... ... \n",
+ "42747 -0.988814 -0.892750 0.263118 -0.250952 \n",
+ "22584 -0.988814 -0.297259 0.263118 -0.250952 \n",
+ "501 -0.988814 -0.892750 0.263118 -0.250952 \n",
+ "55934 0.078225 -0.892750 0.263118 -0.250952 \n",
+ "20828 1.145264 0.893722 0.263118 -0.250952 \n",
+ "\n",
+ " babies_num is_repeated_guest ... deposit_type_Non Refund \\\n",
+ "15425 -0.082681 0 ... 0 \n",
+ "42050 -0.082681 0 ... 0 \n",
+ "25055 -0.082681 0 ... 0 \n",
+ "619 -0.082681 0 ... 0 \n",
+ "30470 -0.082681 0 ... 0 \n",
+ "... ... ... ... ... \n",
+ "42747 -0.082681 0 ... 0 \n",
+ "22584 -0.082681 0 ... 0 \n",
+ "501 -0.082681 0 ... 0 \n",
+ "55934 -0.082681 0 ... 0 \n",
+ "20828 -0.082681 0 ... 0 \n",
+ "\n",
+ " deposit_type_Refundable customer_type_Group customer_type_Transient \\\n",
+ "15425 0 0 1 \n",
+ "42050 0 0 1 \n",
+ "25055 0 0 1 \n",
+ "619 0 0 1 \n",
+ "30470 0 0 1 \n",
+ "... ... ... ... \n",
+ "42747 0 0 1 \n",
+ "22584 0 0 1 \n",
+ "501 0 0 1 \n",
+ "55934 0 0 1 \n",
+ "20828 0 0 0 \n",
+ "\n",
+ " customer_type_Transient-Party continente_Asia continente_Europe \\\n",
+ "15425 0 0 1 \n",
+ "42050 0 0 1 \n",
+ "25055 0 0 1 \n",
+ "619 0 0 1 \n",
+ "30470 0 0 1 \n",
+ "... ... ... ... \n",
+ "42747 0 0 1 \n",
+ "22584 0 0 1 \n",
+ "501 0 0 1 \n",
+ "55934 0 0 1 \n",
+ "20828 0 0 1 \n",
+ "\n",
+ " continente_North America continente_Oceania continente_South America \n",
+ "15425 0 0 0 \n",
+ "42050 0 0 0 \n",
+ "25055 0 0 0 \n",
+ "619 0 0 0 \n",
+ "30470 0 0 0 \n",
+ "... ... ... ... \n",
+ "42747 0 0 0 \n",
+ "22584 0 0 0 \n",
+ "501 0 0 0 \n",
+ "55934 0 0 0 \n",
+ "20828 0 0 0 \n",
+ "\n",
+ "[39817 rows x 69 columns]"
+ ]
+ },
+ "execution_count": 14,
+ "metadata": {},
+ "output_type": "execute_result"
+ }
+ ],
+ "source": [
+ "x_train_escalado"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 15,
+ "id": "ae215ae3",
+ "metadata": {},
+ "outputs": [
+ {
+ "data": {
+ "text/html": [
+ "\n",
+ "\n",
+ "
\n",
+ " \n",
+ " \n",
+ " \n",
+ " lead_time \n",
+ " arrival_year \n",
+ " arrival_week_number \n",
+ " arrival_month_day \n",
+ " weekend_nights_num \n",
+ " week_nights_num \n",
+ " adult_num \n",
+ " children_num \n",
+ " babies_num \n",
+ " is_repeated_guest \n",
+ " ... \n",
+ " deposit_type_Non Refund \n",
+ " deposit_type_Refundable \n",
+ " customer_type_Group \n",
+ " customer_type_Transient \n",
+ " customer_type_Transient-Party \n",
+ " continente_Asia \n",
+ " continente_Europe \n",
+ " continente_North America \n",
+ " continente_Oceania \n",
+ " continente_South America \n",
+ " \n",
+ " \n",
+ " \n",
+ " \n",
+ " 52715 \n",
+ " -0.517340 \n",
+ " 1.204925 \n",
+ " -1.050912 \n",
+ " 1.500896 \n",
+ " 0.078225 \n",
+ " 0.893722 \n",
+ " 0.263118 \n",
+ " -0.250952 \n",
+ " 11.674810 \n",
+ " 0 \n",
+ " ... \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " 1 \n",
+ " 0 \n",
+ " 0 \n",
+ " 1 \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " \n",
+ " \n",
+ " 40651 \n",
+ " 2.087805 \n",
+ " -1.608286 \n",
+ " 0.582405 \n",
+ " 1.159734 \n",
+ " -0.988814 \n",
+ " -0.297259 \n",
+ " 0.263118 \n",
+ " -0.250952 \n",
+ " -0.082681 \n",
+ " 0 \n",
+ " ... \n",
+ " 1 \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " 1 \n",
+ " 0 \n",
+ " 1 \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " \n",
+ " \n",
+ " 39785 \n",
+ " 0.541001 \n",
+ " -0.201680 \n",
+ " -1.050912 \n",
+ " 1.046013 \n",
+ " 0.078225 \n",
+ " -0.297259 \n",
+ " 0.263118 \n",
+ " -0.250952 \n",
+ " -0.082681 \n",
+ " 0 \n",
+ " ... \n",
+ " 1 \n",
+ " 0 \n",
+ " 0 \n",
+ " 1 \n",
+ " 0 \n",
+ " 0 \n",
+ " 1 \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " \n",
+ " \n",
+ " 56079 \n",
+ " 0.805586 \n",
+ " 1.204925 \n",
+ " -0.456979 \n",
+ " 1.273454 \n",
+ " 1.145264 \n",
+ " -0.892750 \n",
+ " 0.263118 \n",
+ " -0.250952 \n",
+ " -0.082681 \n",
+ " 0 \n",
+ " ... \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " 1 \n",
+ " 0 \n",
+ " 0 \n",
+ " 1 \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " \n",
+ " \n",
+ " 47980 \n",
+ " 2.515212 \n",
+ " -1.608286 \n",
+ " 1.027855 \n",
+ " -1.000961 \n",
+ " -0.988814 \n",
+ " -0.297259 \n",
+ " 0.263118 \n",
+ " -0.250952 \n",
+ " -0.082681 \n",
+ " 0 \n",
+ " ... \n",
+ " 1 \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " 1 \n",
+ " 0 \n",
+ " 1 \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " \n",
+ " \n",
+ " ... \n",
+ " ... \n",
+ " ... \n",
+ " ... \n",
+ " ... \n",
+ " ... \n",
+ " ... \n",
+ " ... \n",
+ " ... \n",
+ " ... \n",
+ " ... \n",
+ " ... \n",
+ " ... \n",
+ " ... \n",
+ " ... \n",
+ " ... \n",
+ " ... \n",
+ " ... \n",
+ " ... \n",
+ " ... \n",
+ " ... \n",
+ " ... \n",
+ " \n",
+ " \n",
+ " 41901 \n",
+ " -1.087215 \n",
+ " -0.201680 \n",
+ " 0.211196 \n",
+ " 0.591130 \n",
+ " -0.988814 \n",
+ " -0.892750 \n",
+ " 0.263118 \n",
+ " -0.250952 \n",
+ " -0.082681 \n",
+ " 0 \n",
+ " ... \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " 1 \n",
+ " 0 \n",
+ " 0 \n",
+ " 1 \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " \n",
+ " \n",
+ " 42804 \n",
+ " 1.741809 \n",
+ " -0.201680 \n",
+ " 1.102097 \n",
+ " -0.432357 \n",
+ " -0.988814 \n",
+ " 0.298231 \n",
+ " 0.263118 \n",
+ " -0.250952 \n",
+ " -0.082681 \n",
+ " 0 \n",
+ " ... \n",
+ " 1 \n",
+ " 0 \n",
+ " 0 \n",
+ " 1 \n",
+ " 0 \n",
+ " 0 \n",
+ " 1 \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " \n",
+ " \n",
+ " 22168 \n",
+ " -1.015981 \n",
+ " -0.201680 \n",
+ " -1.273637 \n",
+ " -1.569565 \n",
+ " -0.988814 \n",
+ " -0.892750 \n",
+ " -1.911346 \n",
+ " -0.250952 \n",
+ " -0.082681 \n",
+ " 0 \n",
+ " ... \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " 1 \n",
+ " 0 \n",
+ " 1 \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " \n",
+ " \n",
+ " 36851 \n",
+ " -0.720867 \n",
+ " 1.204925 \n",
+ " 0.062713 \n",
+ " -0.773519 \n",
+ " 1.145264 \n",
+ " -1.488240 \n",
+ " 0.263118 \n",
+ " -0.250952 \n",
+ " -0.082681 \n",
+ " 0 \n",
+ " ... \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " 1 \n",
+ " 0 \n",
+ " 0 \n",
+ " 1 \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " \n",
+ " \n",
+ " 17270 \n",
+ " -1.077039 \n",
+ " 1.204925 \n",
+ " -0.976671 \n",
+ " -1.569565 \n",
+ " 0.078225 \n",
+ " -1.488240 \n",
+ " -1.911346 \n",
+ " -0.250952 \n",
+ " -0.082681 \n",
+ " 0 \n",
+ " ... \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " 1 \n",
+ " 0 \n",
+ " 0 \n",
+ " 1 \n",
+ " 0 \n",
+ " 0 \n",
+ " 0 \n",
+ " \n",
+ " \n",
+ "
\n",
+ "
17065 rows × 69 columns
\n",
+ "
"
+ ],
+ "text/plain": [
+ " lead_time arrival_year arrival_week_number arrival_month_day \\\n",
+ "52715 -0.517340 1.204925 -1.050912 1.500896 \n",
+ "40651 2.087805 -1.608286 0.582405 1.159734 \n",
+ "39785 0.541001 -0.201680 -1.050912 1.046013 \n",
+ "56079 0.805586 1.204925 -0.456979 1.273454 \n",
+ "47980 2.515212 -1.608286 1.027855 -1.000961 \n",
+ "... ... ... ... ... \n",
+ "41901 -1.087215 -0.201680 0.211196 0.591130 \n",
+ "42804 1.741809 -0.201680 1.102097 -0.432357 \n",
+ "22168 -1.015981 -0.201680 -1.273637 -1.569565 \n",
+ "36851 -0.720867 1.204925 0.062713 -0.773519 \n",
+ "17270 -1.077039 1.204925 -0.976671 -1.569565 \n",
+ "\n",
+ " weekend_nights_num week_nights_num adult_num children_num \\\n",
+ "52715 0.078225 0.893722 0.263118 -0.250952 \n",
+ "40651 -0.988814 -0.297259 0.263118 -0.250952 \n",
+ "39785 0.078225 -0.297259 0.263118 -0.250952 \n",
+ "56079 1.145264 -0.892750 0.263118 -0.250952 \n",
+ "47980 -0.988814 -0.297259 0.263118 -0.250952 \n",
+ "... ... ... ... ... \n",
+ "41901 -0.988814 -0.892750 0.263118 -0.250952 \n",
+ "42804 -0.988814 0.298231 0.263118 -0.250952 \n",
+ "22168 -0.988814 -0.892750 -1.911346 -0.250952 \n",
+ "36851 1.145264 -1.488240 0.263118 -0.250952 \n",
+ "17270 0.078225 -1.488240 -1.911346 -0.250952 \n",
+ "\n",
+ " babies_num is_repeated_guest ... deposit_type_Non Refund \\\n",
+ "52715 11.674810 0 ... 0 \n",
+ "40651 -0.082681 0 ... 1 \n",
+ "39785 -0.082681 0 ... 1 \n",
+ "56079 -0.082681 0 ... 0 \n",
+ "47980 -0.082681 0 ... 1 \n",
+ "... ... ... ... ... \n",
+ "41901 -0.082681 0 ... 0 \n",
+ "42804 -0.082681 0 ... 1 \n",
+ "22168 -0.082681 0 ... 0 \n",
+ "36851 -0.082681 0 ... 0 \n",
+ "17270 -0.082681 0 ... 0 \n",
+ "\n",
+ " deposit_type_Refundable customer_type_Group customer_type_Transient \\\n",
+ "52715 0 0 1 \n",
+ "40651 0 0 0 \n",
+ "39785 0 0 1 \n",
+ "56079 0 0 1 \n",
+ "47980 0 0 0 \n",
+ "... ... ... ... \n",
+ "41901 0 0 1 \n",
+ "42804 0 0 1 \n",
+ "22168 0 0 0 \n",
+ "36851 0 0 1 \n",
+ "17270 0 0 1 \n",
+ "\n",
+ " customer_type_Transient-Party continente_Asia continente_Europe \\\n",
+ "52715 0 0 1 \n",
+ "40651 1 0 1 \n",
+ "39785 0 0 1 \n",
+ "56079 0 0 1 \n",
+ "47980 1 0 1 \n",
+ "... ... ... ... \n",
+ "41901 0 0 1 \n",
+ "42804 0 0 1 \n",
+ "22168 1 0 1 \n",
+ "36851 0 0 1 \n",
+ "17270 0 0 1 \n",
+ "\n",
+ " continente_North America continente_Oceania continente_South America \n",
+ "52715 0 0 0 \n",
+ "40651 0 0 0 \n",
+ "39785 0 0 0 \n",
+ "56079 0 0 0 \n",
+ "47980 0 0 0 \n",
+ "... ... ... ... \n",
+ "41901 0 0 0 \n",
+ "42804 0 0 0 \n",
+ "22168 0 0 0 \n",
+ "36851 0 0 0 \n",
+ "17270 0 0 0 \n",
+ "\n",
+ "[17065 rows x 69 columns]"
+ ]
+ },
+ "execution_count": 15,
+ "metadata": {},
+ "output_type": "execute_result"
+ }
+ ],
+ "source": [
+ "x_test_escalado"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 16,
+ "id": "206d769c",
+ "metadata": {},
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Model: \"sequential\"\n",
+ "_________________________________________________________________\n",
+ " Layer (type) Output Shape Param # \n",
+ "=================================================================\n",
+ " dense (Dense) (None, 8) 560 \n",
+ " \n",
+ " dense_1 (Dense) (None, 1) 9 \n",
+ " \n",
+ "=================================================================\n",
+ "Total params: 569\n",
+ "Trainable params: 569\n",
+ "Non-trainable params: 0\n",
+ "_________________________________________________________________\n"
+ ]
+ }
+ ],
+ "source": [
+ "cant_clases = 1\n",
+ "\n",
+ "\n",
+ "#d_in=len(y_train)\n",
+ "d_in=len(x_train_escalado.columns)\n",
+ "\n",
+ "modelo_hotels_1 = keras.Sequential([\n",
+ " keras.layers.Dense(8,input_shape=(d_in,),activation ='relu'),\n",
+ " keras.layers.Dense(cant_clases, activation='sigmoid'),\n",
+ "])\n",
+ "\n",
+ "\n",
+ "modelo_hotels_1.summary()"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 17,
+ "id": "429a2337",
+ "metadata": {},
+ "outputs": [],
+ "source": [
+ "modelo_hotels_1.compile(\n",
+ " optimizer=keras.optimizers.SGD(learning_rate=0.1), \n",
+ " loss='binary_crossentropy', \n",
+ " # metricas para ir calculando en cada iteracion o batch \n",
+ " metrics=['AUC'], \n",
+ ")\n",
+ "\n",
+ "cant_epochs=10\n",
+ "\n",
+ "historia_modelo_hotel_1=modelo_hotels_1.fit(x_train_escalado,y_train,epochs=cant_epochs,batch_size=16,verbose=False)"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 18,
+ "id": "14fa7413",
+ "metadata": {},
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "534/534 [==============================] - 0s 631us/step\n"
+ ]
+ },
+ {
+ "data": {
+ "image/png": "iVBORw0KGgoAAAANSUhEUgAAAiQAAAGxCAYAAABSsK0dAAAAOXRFWHRTb2Z0d2FyZQBNYXRwbG90bGliIHZlcnNpb24zLjcuMSwgaHR0cHM6Ly9tYXRwbG90bGliLm9yZy/bCgiHAAAACXBIWXMAAA9hAAAPYQGoP6dpAABATklEQVR4nO3dfVxUdd7/8ffIzYQIo6IMUliU6GpqKbaI3WgpooXkbqWFsZamdlkaqWlsd26XC+l2SbuxmbmlZpZtN7aba6S2m+Uq3lC0ampWpqmMWOEoRgPC/P7w19lG1AGa40F8Pa/HeTzinM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G+cWL16sCy64QP369fP7+srKSi1atEg9evRQ9+7d9a9//UubN2/Wa6+9pl69eikhIUFPPvmkWrZsqddff12SdNlll2ncuHHq1q2bEhISNGPGDF188cU+oQgAzBBs9QAAnNqYMWN0xRVXaN++fTr//PM1f/583XHHHbLZbH5fe+GFF6pt27bGz0VFRSovL1dUVJRPXUVFhb744gtJ0tGjR/W73/1Oy5Yt0/79+3Xs2DFVVFTQIQFgOgIJ0Ij16NFDl112mV588UWlpqZq8+bNevvtt+v02vDwcJ+fa2pq1K5dO73//vu1alu2bClJeuCBB/Tuu+/qySefVIcOHRQWFqabb75ZlZWVP/ejAMBpEUiARu6uu+5SXl6e9u3bpwEDBiguLq5B9+nZs6dcLpeCg4N10UUXnbTmww8/1B133KFf/epXko6vKfnqq68aOHIAqDvWkACN3IgRI7Rv3z7NmzdPo0aNavB9BgwYoOTkZA0dOlTvvvuuvvrqK61du1YPP/ywNm3aJEnq0KGD3nzzTRUXF+uTTz5RRkaGampqAvVRAOCUCCRAIxcZGambbrpJLVq00NChQxt8H5vNpuXLl+uaa67RqFGj1LFjR91666366quv5HQ6JUl5eXlq1aqV+vTpoyFDhig1NVU9e/YM0CcBgFOzeb1er9WDAHB6KSkp6ty5s/70pz9ZPRQAMAWBBGjEvvvuO61YsUIjRozQp59+qk6dOlk9JAAwBYtagUasZ8+eKisr08yZM33CyKWXXqrdu3ef9DVz587ViBEjztQQASAg6JAAZ6Hdu3ef8vtpnE6nIiIizvCIAODnIZAAAADLscsGAABYjkACAAAsRyABAACWI5AAAADLEUgAAIDlCCQAAMByBBIAAGA5AgkAALDc/wM8Ldn5R322NwAAAABJRU5ErkJggg==",
+ "text/plain": [
+ ""
+ ]
+ },
+ "metadata": {},
+ "output_type": "display_data"
+ }
+ ],
+ "source": [
+ "y_pred = modelo_hotels_1.predict(x_test_escalado)\n",
+ "y_predic_cat_ej1 = np.where(y_pred>0.7,1,0)\n",
+ "\n",
+ "ds_validacion=pd.DataFrame(y_predic_cat_ej1,y_test).reset_index()\n",
+ "ds_validacion.columns=['y_pred','y_real']\n",
+ "\n",
+ "tabla=pd.crosstab(ds_validacion.y_pred, ds_validacion.y_real)\n",
+ "grf=sns.heatmap(tabla,annot=True, cmap = 'Blues', fmt='g')\n",
+ "plt.show()"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 19,
+ "id": "3e2334b8",
+ "metadata": {},
+ "outputs": [],
+ "source": [
+ "if not exists('submissions/red_neuronal_basica.csv'):\n",
+ " y_pred_testeo = modelo_hotels_1.predict(hotelsdf_testeo_filtrado)\n",
+ " y_pred_testeo_cat = np.where(y_pred_testeo>0.70,1,0)\n",
+ " df_resultados_pred = pd.DataFrame.from_records(y_pred_testeo_cat,columns = [\"resultado\"])\n",
+ " df_submission = pd.DataFrame({'id': hotelsdf_pruebasOriginal['id'], 'is_canceled': df_resultados_pred[\"resultado\"]})\n",
+ " df_submission.to_csv('submissions/red_neuronal_basica.csv', index=False)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "id": "f3c21a91",
+ "metadata": {},
+ "source": [
+ "# Validacion cruzada"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "id": "7f01b974",
+ "metadata": {},
+ "source": [
+ "En esta etapa vamos a realizar unas series de validaciones cruzadas en la busqueda de encontrar el mejor resultado"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "id": "0bad7ce4",
+ "metadata": {},
+ "source": [
+ "Para usar la libreria Keras Classifier necesitamos crear una funcion que cree una modelo."
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 20,
+ "id": "7759031a",
+ "metadata": {},
+ "outputs": [],
+ "source": [
+ "loss='binary_crossentropy'\n",
+ "metrics=['AUC']\n",
+ "optimizer=\"adam\"\n",
+ "\n",
+ "def creador_modelo(learning_rate = 0.1, \n",
+ " activation = 'sigmoid', \n",
+ " output = 2, \n",
+ " hidden_layers = 2\n",
+ " ):\n",
+ " model = keras.Sequential()\n",
+ " model.add(keras.layers.Dense(5, activation=activation, input_shape=(d_in,)))\n",
+ " \n",
+ " for i in range(hidden_layers):\n",
+ " model.add(keras.layers.Dense(output, activation=activation))\n",
+ "\n",
+ " model.add(keras.layers.Dense(1, activation=activation))\n",
+ " \n",
+ " model.compile(\n",
+ " optimizer=optimizer,\n",
+ " loss=loss, \n",
+ " metrics=metrics, \n",
+ " )\n",
+ " return model"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "id": "2ee7a66a",
+ "metadata": {},
+ "source": [
+ "Vamos a empezar con una baja cantidad de epochs y batch_size"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 21,
+ "id": "aefb38c7",
+ "metadata": {},
+ "outputs": [
+ {
+ "name": "stderr",
+ "output_type": "stream",
+ "text": [
+ "/tmp/ipykernel_6135/2109703127.py:1: DeprecationWarning: KerasClassifier is deprecated, use Sci-Keras (https://github.com/adriangb/scikeras) instead. See https://www.adriangb.com/scikeras/stable/migration.html for help migrating.\n"
+ ]
+ }
+ ],
+ "source": [
+ "model = KerasClassifier(build_fn=creador_modelo, \n",
+ " verbose=1)"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 22,
+ "id": "69986586",
+ "metadata": {},
+ "outputs": [],
+ "source": [
+ "param_grid = { \n",
+ " \"hidden_layers\" : [1, 5, 10, 15, 20], \n",
+ " \"output\" : [1, 2, 4, 8, 32, 64], \n",
+ " \"batch_size\" : [5, 10, 20],\n",
+ " \"epochs\" : [50, 100, 150],\n",
+ " \"activation\": [\"sigmoid\", \"relu\", \"softmax\", \"softplus\", \"elu\", ]\n",
+ " } "
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 23,
+ "id": "1774e6d4",
+ "metadata": {},
+ "outputs": [],
+ "source": [
+ "rs = RandomizedSearchCV(estimator=model, param_distributions=param_grid,n_jobs=JOBS, cv=3,n_iter=10)"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 24,
+ "id": "7bc790f9",
+ "metadata": {},
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Keras model archive loading:\n",
+ "File Name Modified Size\n",
+ "variables.h5 2023-05-25 21:37:40 270264\n",
+ "config.json 2023-05-25 21:37:40 7766\n",
+ "metadata.json 2023-05-25 21:37:40 64\n",
+ "Keras weights file () loading:\n",
+ "...layers\n",
+ "......dense\n",
+ ".........vars\n",
+ "............0\n",
+ "............1\n",
+ "......dense_1\n",
+ ".........vars\n",
+ "............0\n",
+ "............1\n",
+ "......dense_10\n",
+ ".........vars\n",
+ "............0\n",
+ "............1\n",
+ "......dense_11\n",
+ ".........vars\n",
+ "............0\n",
+ "............1\n",
+ "......dense_12\n",
+ ".........vars\n",
+ "............0\n",
+ "............1\n",
+ "......dense_13\n",
+ ".........vars\n",
+ "............0\n",
+ "............1\n",
+ "......dense_14\n",
+ ".........vars\n",
+ "............0\n",
+ "............1\n",
+ "......dense_15\n",
+ ".........vars\n",
+ "............0\n",
+ "............1\n",
+ "......dense_16\n",
+ ".........vars\n",
+ "............0\n",
+ "............1\n",
+ "......dense_2\n",
+ ".........vars\n",
+ "............0\n",
+ "............1\n",
+ "......dense_3\n",
+ ".........vars\n",
+ "............0\n",
+ "............1\n",
+ "......dense_4\n",
+ ".........vars\n",
+ "............0\n",
+ "............1\n",
+ "......dense_5\n",
+ ".........vars\n",
+ "............0\n",
+ "............1\n",
+ "......dense_6\n",
+ ".........vars\n",
+ "............0\n",
+ "............1\n",
+ "......dense_7\n",
+ ".........vars\n",
+ "............0\n",
+ "............1\n",
+ "......dense_8\n",
+ ".........vars\n",
+ "............0\n",
+ "............1\n",
+ "......dense_9\n",
+ ".........vars\n",
+ "............0\n",
+ "............1\n",
+ "...metrics\n",
+ "......auc\n",
+ ".........vars\n",
+ "............0\n",
+ "............1\n",
+ "............2\n",
+ "............3\n",
+ "......mean\n",
+ ".........vars\n",
+ "............0\n",
+ "............1\n",
+ "...optimizer\n",
+ "......vars\n",
+ ".........0\n",
+ ".........1\n",
+ ".........10\n",
+ ".........11\n",
+ ".........12\n",
+ ".........13\n",
+ ".........14\n",
+ ".........15\n",
+ ".........16\n",
+ ".........17\n",
+ ".........18\n",
+ ".........19\n",
+ ".........2\n",
+ ".........20\n",
+ ".........21\n",
+ ".........22\n",
+ ".........23\n",
+ ".........24\n",
+ ".........25\n",
+ ".........26\n",
+ ".........27\n",
+ ".........28\n",
+ ".........29\n",
+ ".........3\n",
+ ".........30\n",
+ ".........31\n",
+ ".........32\n",
+ ".........33\n",
+ ".........34\n",
+ ".........35\n",
+ ".........36\n",
+ ".........37\n",
+ ".........38\n",
+ ".........39\n",
+ ".........4\n",
+ ".........40\n",
+ ".........41\n",
+ ".........42\n",
+ ".........43\n",
+ ".........44\n",
+ ".........45\n",
+ ".........46\n",
+ ".........47\n",
+ ".........48\n",
+ ".........49\n",
+ ".........5\n",
+ ".........50\n",
+ ".........51\n",
+ ".........52\n",
+ ".........53\n",
+ ".........54\n",
+ ".........55\n",
+ ".........56\n",
+ ".........57\n",
+ ".........58\n",
+ ".........59\n",
+ ".........6\n",
+ ".........60\n",
+ ".........61\n",
+ ".........62\n",
+ ".........63\n",
+ ".........64\n",
+ ".........65\n",
+ ".........66\n",
+ ".........67\n",
+ ".........68\n",
+ ".........7\n",
+ ".........8\n",
+ ".........9\n",
+ "...vars\n"
+ ]
+ }
+ ],
+ "source": [
+ "if exists('modelos/rs_fit.joblib') == False:\n",
+ " rs_fit = rs.fit(X = x_train_escalado, y = y_train)\n",
+ " dump(rs_fit, 'modelos/rs_fit.joblib')\n",
+ "else:\n",
+ " rs_fit = load('modelos/rs_fit.joblib')"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 25,
+ "id": "b30a25a0",
+ "metadata": {},
+ "outputs": [
+ {
+ "data": {
+ "text/plain": [
+ "{'output': 32,\n",
+ " 'hidden_layers': 15,\n",
+ " 'epochs': 50,\n",
+ " 'batch_size': 10,\n",
+ " 'activation': 'relu'}"
+ ]
+ },
+ "execution_count": 25,
+ "metadata": {},
+ "output_type": "execute_result"
+ }
+ ],
+ "source": [
+ "rs_fit.best_params_"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 29,
+ "id": "3d16794a",
+ "metadata": {},
+ "outputs": [],
+ "source": [
+ "modelo_rs = keras.Sequential()\n",
+ "modelo_rs.add(keras.layers.Dense(5, activation=rs_fit.best_params_[\"activation\"], input_shape=(d_in,)))\n",
+ " \n",
+ "for i in range(rs_fit.best_params_[\"hidden_layers\"]):\n",
+ " # Add one hidden layer\n",
+ " modelo_rs.add(keras.layers.Dense(rs_fit.best_params_[\"output\"], activation=rs_fit.best_params_[\"activation\"]))\n",
+ "\n",
+ "modelo_rs.add(keras.layers.Dense(1, activation=\"sigmoid\"))\n",
+ "\n",
+ " \n",
+ "modelo_rs.compile(\n",
+ "# optimizer=keras.optimizers.SGD(learning_rate=rs_fit.best_params_[\"learning_rate\"]), \n",
+ " optimizer=optimizer,\n",
+ " loss=loss, \n",
+ " metrics=metrics, \n",
+ " )"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 30,
+ "id": "00028b2d",
+ "metadata": {},
+ "outputs": [],
+ "source": [
+ "# cant_epochs=10\n",
+ "cant_epochs=rs_fit.best_params_[\"epochs\"]\n",
+ "batch_size=rs_fit.best_params_[\"batch_size\"]\n",
+ "\n",
+ "historia_modelo_hotel_2=modelo_rs.fit(x_train_escalado,y_train,\n",
+ " epochs=cant_epochs,\n",
+ " batch_size=batch_size,verbose=False)\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 31,
+ "id": "759b6790",
+ "metadata": {},
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "534/534 [==============================] - 1s 759us/step\n"
+ ]
+ },
+ {
+ "data": {
+ "image/png": "iVBORw0KGgoAAAANSUhEUgAAAiQAAAGxCAYAAABSsK0dAAAAOXRFWHRTb2Z0d2FyZQBNYXRwbG90bGliIHZlcnNpb24zLjcuMSwgaHR0cHM6Ly9tYXRw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2dO1eJiYnaunWrgoKCFBERodOnT7tqYmNjlZSUpOXLl2v9+vXKy8tT//79VVxc7KqJjo5Wenq6kpOTlZycrPT0dMXExJTvM3I6nc5yveIK4NthvNVDACqlnC3PWz0EoNKpeRluXvC7b4lHznP67QfLXPvXv/5VX331lb788stSjzudTgUHBys2NlbTpk2T9Es3JDAwULNmzdKoUaOUm5urhg0b6o033tB9990nSTpy5IiaNGmijz76SH369NGePXvUpk0bbdq0SWFhYZKkTZs2KTw8XN9++61atWpVpvHSIQEAwGRWdEjef/99derUSffee68CAgLUvn17LVy40HX8wIEDcjgcioyMdO3z8fFRjx49tGHDBklSWlqaioqK3GqCg4MVGhrqqtm4caPsdrsrjEhSly5dZLfbXTVlQSABAMBkngokBQUFOnXqlNtWUFBQ6nvu379f8+fPV0hIiD755BONHj1a48eP1+uvvy5JcjgckqTAwEC31wUGBrqOORwO1ahRQ/Xq1btkTUBAQIn3DwgIcNWUBYEEAIArRFxcnOvG0V+3uLi4UmvPnz+vDh06aObMmWrfvr1GjRqlESNGaP78+W51F3ZenE6nYTfmwprS6stynt8ikAAAYDabZ7bp06crNzfXbZs+fXqpb9moUSO1adPGbV/r1q2VkZEhSQoKCpKkEl2M7OxsV9ckKChIhYWFysnJuWTN0aNHS7z/sWPHSnRfLoVAAgCAyTw1ZePj46M6deq4bT4+PqW+Z7du3bR37163fd99952aNm0qSWrevLmCgoKUmprqOl5YWKh169apa9eukqSOHTvK29vbrSYrK0s7d+501YSHhys3N1dbtmxx1WzevFm5ubmumrLgwWgAAFRBEyZMUNeuXTVz5kwNGTJEW7Zs0csvv6yXX35Z0i8hKTY2VjNnzlRISIhCQkI0c+ZM1apVS9HR0ZIku92u4cOHa9KkSWrQoIHq16+vyZMnq23bturdu7ekX7ouffv21YgRI7RgwQJJ0siRI9W/f/8yr7CRCCQAAJjOiu+y6dy5s5KSkjR9+nQ988wzat68uebNm6ehQ4e6aqZOnar8/HyNGTNGOTk5CgsLU0pKivz8/Fw1CQkJ8vL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T7d4QoUCyfnz51VcXFxif2Zmpvz8/H73oAAAqErII8YqNGUTERGhefPmuX622WzKy8vTU089pTvvvNNTYwMAAFeJCnVI5s6dqzvuuENt2rTRzz//rOjoaO3bt0/+/v566623PD1GAACuaFV9hYwnVCiQNG7cWOnp6Vq+fLnS0tJ0/vx5DR8+XEOHDnW7yRUAADBlUxblDiRFRUVq1aqVVq9erYcffphHxQMAYICbWo2V+x4Sb29vFRQU0H4CAAAeU6GbWseNG6dZs2bp3Llznh4PAABVjs3mma0qq9A9JJs3b9ann36qlJQUtW3bVrVr13Y7vnLlSo8MDgCAqoBZBWMVCiR169bV4MGDPT0WAABwlapQIFm0aJGnx+FRP23+l9VDACqlep3HWj0EoNLJ355o+ntU+JtsryIVCiS/ys7O1t69e2Wz2dSyZUsFBAR4alwAAFQZTNkYq1BoO3XqlGJiYtS4cWP16NFDt99+uxo3bqz7779fubm5nh4jAACo4ioUSB555BFt3rxZq1ev1smTJ5Wbm6vVq1dr27ZtGjFihKfHCADAFa2azTNbVVahKZsPP/xQn3zyibp37+7a16dPHy1cuFB9+/b12OAAAKgKqnqY8IQKdUgaNGggu91eYr/dble9evV+96AAAMDVpUKB5Mknn9TEiROVlZXl2udwODRlyhT97W9/89jgAACoCmw2m0e2qqxCUzbz58/X999/r6ZNm+q6666TJGVkZMjHx0fHjh3TggULXLVff/21Z0YKAMAViikbYxUKJAMHDvTwMAAAqLqqeHPDIyoUSJ566qky1b311ls6c+ZMiUfLAwAA/JapD48bNWqUjh49auZbAABQ6VWz2TyyVWW/60mtRpxOp5mnBwDgisCj443xGQEAAMuZ2iEBAADc1FoWBBIAAExW1e//8ASmbAAAuArExcXJZrMpNjbWtc/pdGrGjBkKDg6Wr6+vevbsqV27drm9rqCgQOPGjZO/v79q166tqKgoZWZmutXk5OQoJiZGdrtddrtdMTExOnnyZLnGV6FA8tBDD+mLL74wrGvatKm8vb0r8hYAAFQZNptntoraunWrXn75Zd18881u++Pj4zV37lwlJiZq69atCgoKUkREh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YNycnI0a9YstzBy00036dChQ6W+ZsGCBRo6dOjlGiIAeAQdEuAKdOjQoYt+P01gYKD8/Pwu84gA4PchkAAAAMuxygYAAFiOQAIAACxHIAEAAJYjkAAAAMsRSAAAgOUIJAAAwHIEEgAAYDkCCQAAsNz/A3l3tEgLjbLgAAAAAElFTkSuQmCC",
+ "text/plain": [
+ ""
+ ]
+ },
+ "metadata": {},
+ "output_type": "display_data"
+ }
+ ],
+ "source": [
+ "y_pred = modelo_rs.predict(x_test_escalado)\n",
+ "y_predic_cat_ej1 = np.where(y_pred>0.5,1,0)\n",
+ "\n",
+ "ds_validacion=pd.DataFrame(y_predic_cat_ej1,y_test).reset_index()\n",
+ "ds_validacion.columns=['y_pred','y_real']\n",
+ "\n",
+ "tabla=pd.crosstab(ds_validacion.y_pred, ds_validacion.y_real)\n",
+ "grf=sns.heatmap(tabla,annot=True, cmap = 'Blues', fmt='g')\n",
+ "#plt.ticklabel_format(style='plain', axis='both')\n",
+ "plt.show()"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": null,
+ "id": "34d3ca3f",
+ "metadata": {},
+ "outputs": [],
+ "source": []
+ }
+ ],
+ "metadata": {
+ "jupytext": {
+ "formats": "ipynb,md"
+ },
+ "kernelspec": {
+ "display_name": "Python 3 (ipykernel)",
+ "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"
+ }
+ },
+ "nbformat": 4,
+ "nbformat_minor": 5
+}