ab 8: Deep Learning Overview For this exercise we will continue working with the Titanic data from the previous labs. Set-up 1. Load the Titanic and Titanic_hidden datasets Lab Steps 1. Create a training/test set using the Titanic data Note: If you’re using the technique shown in class: the matrix model will exclude 1 and Name 2. Set up a deep neural network with the following: two hidden layers with 30 units and ReLU activation and an output layer with a single unit and sigmoid activation 3. Compile the model with binary_crossentropy loss and the accuracy metric 4. Fit the model on the training set, evaluate it with the test set 5. Get the titanic_hidden in a form Keras can use: you’ll can set it up with code similar to this: new_data_x <- titanic_hidden %>% model.matrix(object = Survived ~ . -1 -Name) %>% scale() new_data_y <- titanic_hidden$Survived 6. Test the model’s accuracy with the hidden data it’s never seen before solve it using Python
Lab 8: Deep Learning
Overview
For this exercise we will continue working with the Titanic data from the previous labs.
Set-up
1. Load the Titanic and Titanic_hidden datasets
Lab Steps
1. Create a training/test set using the Titanic data Note: If you’re using the technique shown in class:
the matrix model will exclude 1 and Name
2. Set up a deep neural network with the following: two hidden layers with 30 units and ReLU activation
and an output layer with a single unit and sigmoid activation
3. Compile the model with binary_crossentropy loss and the accuracy metric
4. Fit the model on the training set, evaluate it with the test set
5. Get the titanic_hidden in a form Keras can use: you’ll can set it up with code similar to this:
new_data_x <- titanic_hidden %>% model.matrix(object = Survived ~ . -1 -Name) %>% scale()
new_data_y <- titanic_hidden$Survived
6. Test the model’s accuracy with the hidden data it’s never seen before
solve it using Python
![](/static/compass_v2/shared-icons/check-mark.png)
Step by step
Solved in 4 steps with 1 images
![Blurred answer](/static/compass_v2/solution-images/blurred-answer.jpg)
![Database System Concepts](https://www.bartleby.com/isbn_cover_images/9780078022159/9780078022159_smallCoverImage.jpg)
![Starting Out with Python (4th Edition)](https://www.bartleby.com/isbn_cover_images/9780134444321/9780134444321_smallCoverImage.gif)
![Digital Fundamentals (11th Edition)](https://www.bartleby.com/isbn_cover_images/9780132737968/9780132737968_smallCoverImage.gif)
![Database System Concepts](https://www.bartleby.com/isbn_cover_images/9780078022159/9780078022159_smallCoverImage.jpg)
![Starting Out with Python (4th Edition)](https://www.bartleby.com/isbn_cover_images/9780134444321/9780134444321_smallCoverImage.gif)
![Digital Fundamentals (11th Edition)](https://www.bartleby.com/isbn_cover_images/9780132737968/9780132737968_smallCoverImage.gif)
![C How to Program (8th Edition)](https://www.bartleby.com/isbn_cover_images/9780133976892/9780133976892_smallCoverImage.gif)
![Database Systems: Design, Implementation, & Manag…](https://www.bartleby.com/isbn_cover_images/9781337627900/9781337627900_smallCoverImage.gif)
![Programmable Logic Controllers](https://www.bartleby.com/isbn_cover_images/9780073373843/9780073373843_smallCoverImage.gif)