Question
Logistic regression exercise using Google Collab or similar tool a. Import the tensorflow.keras libraries b. Using tensorflow.keras.datasets import the MNIST dataset. c. Plot in a
Logistic regression exercise using Google Collab or similar tool
a. Import the tensorflow.keras libraries
b. Using tensorflow.keras.datasets import the MNIST dataset.
c. Plot in a 3x3 figure, random images of the MNIST dataset items. i.e.
192
785
459
d. Using sklearn.datasets.fetch_openml import the MNIST 784 dataset
e. Using the MNIST 784 dataset split the data in x_train, y_train, x_test, y_test and print your ratio of training and testing data.
f. Create a logistic regression model (sklearn) and train it using your train and test data splits.
g. Propose two metrics to evaluate the models and give a brief justification for these.
h. Calculate and print the two metrics.
i. Create a new logistic regression model and train it using 40% of the training data.
j. Calculate and print the two metrics.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started