October 2018
Intermediate to advanced
134 pages
2h 39m
English
We'll now start building our Keras model, which is a deep learning algorithm:
from sklearn.model_selection import GridSearchCV, KFoldfrom keras.models import Sequentialfrom keras.layers import Densefrom keras.wrappers.scikit_learn import KerasClassifierfrom keras.optimizers import Adam
In the preceding code snippet , GridSearchCV is the function we will use to perform a grid search, and KFold will be used for performing the k-fold cross-validation. KerasClassifier is used as the wrapper. Adam is the optimizer that we will be using for this model; the rest of the functions are ...
Read now
Unlock full access