December 09, 2024
The code in section 6.2 contains the statement
import keras_preprocessing
Note that there is an underscore character in the name.
However, the command to install the package is
conda install -c conda-forge keras-preprocessing
Note that package has a hyphen in the name.
Make sure you are in the correct conda environment before installing, for example
conda activate jh_class
December 28, 2024
Validation data used in model.fit function
The preparation before model training in the model.fit function includes a step where the available data are
split into training data and verification data.
In some examples up to chapter 6.2, the model.fit function is called with the training data, and afterwards the
model.predict function is called in order to find the accuracy of the trained model.
A typical output shows a loss value:
10/10 [==============================] - 6s 486ms/step - loss: 1.0254
In other examples such as in chapter 3.4, the model.fit function is called with the train data as well as the
validation data.
A typical output shows a loss value:
112/112 - 0s - loss: 1.1940 - val_loss: 1.1126
In the resnet example in chapter 6.3, the model.fit function is called with the train data as well as the
validation data.
Here, a typical output shows a loss value as well as a validation loss value:
250/250 [==============================] - 70s 256ms/step - loss: 73.1411 - rmse: 8.5523 - val_loss: 701.4966
- val_rmse: 26.4858