Neural Networks
Neural network learning was originally inspired by neurons in human (mammal) brains
Linear threshold unit
This first model was introduced by McCulloch and Pitts in 1943. The idea is to do logical
processing similar to computers (note that back in that time computers were gaining
momentum the first time in history). Once again we fit a line 🙂
Perceptron (Päättelin)
Perceptron included also a model, similar to Linear Threshold Unit, and a training algorithm
based on Hebbian rule:
Home brewed solutions
y = { 1, if w0 + w1 ⋅ x1 + w2 ⋅ x2 ≥ θ
0, if w0 + w1 ⋅ x1 + w2 ⋅ x2 < θ
. (1)
w
t+1
i
= wt
i
+ η(y − ŷ)x (2)
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
1 of 113 9/23/21, 09:01
In [29]:
import matplotlib.pyplot as plt
import numpy as np
# Coodinate system
plt.xlabel('pituus [m]')
plt.ylabel('paino [kg]')
plt.axis([0,2,0,150])
# Generate random points
np.random.seed(42) # to always get the same points
N = 50
x = np.random.normal(1.1,0.3,N)
a_gt = 50.0
b_gt = 20.0
y_noise = np.random.normal(0,8,N) # Measurements from the class 1\n",
y = a_gt*x+b_gt+y_noise
plt.plot(x,y,'rx')
plt.title('Training data for Perceptron')
plt.show()
# Compute MSE heat map for different a and b
a_t = 0
b_t = 0
num_of_epochs = 10
learning_rate = 0.005
y_h = a_t*x+b_t
MSE = np.sum((y-y_h)**2)/N
plt.title(f'Epoch={0} a={a_t:.2f} b={b_t:.2f} MSE={MSE:.2f}')
plt.xlabel('height [m]')
plt.ylabel('weight [kg]')
plt.axis([0,2,0,150])
plt.plot(x,y,'rx')
plt.plot(x,a_t*x+b_t,'k-')
plt.show()
for e in range(num_of_epochs):
for x_e_ind,x_e in enumerate(x):
y_e = a_t*x_e+b_t
a_t = a_t+learning_rate*(y[x_e_ind]-y_e)*x_e
b_t = b_t+learning_rate*(y[x_e_ind]-y_e)*x_e
# Compute train error
y_h = a_t*x+b_t
MSE = np.sum((y-y_h)**2)/N
plt.title(f'Epoch={e+1} a={a_t:.2f} b={b_t:.2f} MSE={MSE:.2f}')
plt.xlabel('height [m]')
plt.ylabel('weight [kg]')
plt.axis([0,2,0,150])
plt.plot(x,y,'rx')
plt.plot(x,a_t*x+b_t,'k-')
plt.show()
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
2 of 113 9/23/21, 09:01
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
3 of 113 9/23/21, 09:01
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
4 of 113 9/23/21, 09:01
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
5 of 113 9/23/21, 09:01
TensorFlow Perceptron
Epoch 1/30
In [30]:
import tensorflow as tf
from tensorflow.keras.models import Sequential
from tensorflow.keras.layers import Dense
import keras
# Model sequential
model = Sequential()
# 1st hidden layer (we also need to tell the input dimension)
# 10 neurons, but you can change to play a bit
model.add(Dense(1, input_dim=1, activation='linear'))
## 2nd hidden layer - YOU MAY TEST THIS
#model.add(Dense(10, activation='sigmoid'))
# Output layer
#model.add(Dense(1, activation='sigmoid'))
#model.add(Dense(1, activation='tanh'))
# Learning rate has huge effect
keras.optimizers.SGD(lr=0.5)
model.compile(optimizer='sgd', loss='mse', metrics=['mse'])
num_of_epochs = 30
tr_hist = model.fit(x, y, epochs=num_of_epochs, verbose=1)
plt.plot(tr_hist.history['loss'])
plt.ylabel('loss')
plt.xlabel('epoch')
#plt.legend(['opetus'], loc='upper right')
plt.show()
y_h = np.squeeze(model.predict(x))
MSE = np.sum((y-y_h)**2)/N
plt.xlabel('height [m]')
plt.ylabel('weight [kg]')
plt.title(f'Epoch={num_of_epochs} MSE={MSE:.2f}')
plt.axis([0,2,0,150])
plt.plot(x,y,'rx')
plt.plot(x,y_h,'k-')
plt.show()
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
6 of 113 9/23/21, 09:01
2/2 [==============================] - 0s 1ms/step - loss: 5539.2524 - mse:
5539.2524
Epoch 2/30
2/2 [==============================] - 0s 1ms/step - loss: 4487.9268 - mse:
4487.9268
Epoch 3/30
2/2 [==============================] - 0s 1ms/step - loss: 3956.1613 - mse:
3956.1610
Epoch 4/30
2/2 [==============================] - 0s 2ms/step - loss: 3329.0870 - mse:
3329.0870
Epoch 5/30
2/2 [==============================] - 0s 1ms/step - loss: 2776.9401 - mse:
2776.9401
Epoch 6/30
2/2 [==============================] - 0s 1ms/step - loss: 2307.4514 - mse:
2307.4514
Epoch 7/30
2/2 [==============================] - 0s 2ms/step - loss: 2009.3061 - mse:
2009.3061
Epoch 8/30
2/2 [==============================] - 0s 2ms/step - loss: 1725.1364 - mse:
1725.1364
Epoch 9/30
2/2 [==============================] - 0s 1ms/step - loss: 1446.1152 - mse:
1446.1153
Epoch 10/30
2/2 [==============================] - 0s 1ms/step - loss: 1234.3830 - mse:
1234.3830
Epoch 11/30
2/2 [==============================] - 0s 2ms/step - loss: 995.9856 - mse:
995.9856
Epoch 12/30
2/2 [==============================] - 0s 2ms/step - loss: 856.8014 - mse:
856.8014
Epoch 13/30
2/2 [==============================] - 0s 1ms/step - loss: 789.1910 - mse:
789.1910
Epoch 14/30
2/2 [==============================] - 0s 2ms/step - loss: 659.9764 - mse:
659.9764
Epoch 15/30
2/2 [==============================] - 0s 2ms/step - loss: 549.3777 - mse:
549.3777
Epoch 16/30
2/2 [==============================] - 0s 1ms/step - loss: 485.2985 - mse:
485.2985
Epoch 17/30
2/2 [==============================] - 0s 3ms/step - loss: 430.5877 - mse:
430.5877
Epoch 18/30
2/2 [==============================] - 0s 2ms/step - loss: 361.1825 - mse:
361.1825
Epoch 19/30
2/2 [==============================] - 0s 2ms/step - loss: 319.3545 - mse:
319.3545
Epoch 20/30
2/2 [==============================] - 0s 1ms/step - loss: 285.4843 - mse:
285.4843
Epoch 21/30
2/2 [==============================] - 0s 2ms/step - loss: 245.5997 - mse:
245.5997
Epoch 22/30
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
7 of 113 9/23/21, 09:01
2/2 [==============================] - 0s 2ms/step - loss: 209.1196 - mse:
209.1196
Epoch 23/30
2/2 [==============================] - 0s 2ms/step - loss: 187.9709 - mse:
187.9709
Epoch 24/30
2/2 [==============================] - 0s 2ms/step - loss: 171.7510 - mse:
171.7510
Epoch 25/30
2/2 [==============================] - 0s 2ms/step - loss: 156.2699 - mse:
156.2699
Epoch 26/30
2/2 [==============================] - 0s 2ms/step - loss: 147.0012 - mse:
147.0012
Epoch 27/30
2/2 [==============================] - 0s 2ms/step - loss: 132.0897 - mse:
132.0897
Epoch 28/30
2/2 [==============================] - 0s 2ms/step - loss: 120.3029 - mse:
120.3029
Epoch 29/30
2/2 [==============================] - 0s 1ms/step - loss: 115.6506 - mse:
115.6506
Epoch 30/30
2/2 [==============================] - 0s 2ms/step - loss: 97.2201 - mse: 9
7.2201
Multi-layer Perceptron (MLP)
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
8 of 113 9/23/21, 09:01
Multi-layer Perceptron is the father of modern convolutional neural networks (CNNs) - the
principal idea of training MLPs and CNNs is same.
MLP regression
We train the network for number of epochs (10-10000, but you
may test different values)
In [31]:
# Generate a sine wave
t = np.arange(0, 10, 0.1);
y = np.sin(t)
plt.plot(t, y)
plt.title('Training data for regression y=f(t)')
plt.xlabel('Time')
plt.ylabel('y = sin(t)')
plt.grid(True, which='both')
plt.show()
In [32]:
import tensorflow as tf
from tensorflow.keras.models import Sequential
from tensorflow.keras.layers import Dense
import keras
# Model sequential
model = Sequential()
# 1st hidden layer (we also need to tell the input dimension)
# 10 neurons, but you can change to play a bit
model.add(Dense(10, input_dim=1, activation='sigmoid'))
## 2nd hidden layer - YOU MAY TEST THIS
#model.add(Dense(10, activation='sigmoid'))
# Output layer
#model.add(Dense(1, activation='sigmoid'))
model.add(Dense(1, activation='tanh'))
# Learning rate has huge effect
keras.optimizers.SGD(lr=0.2)
model.compile(optimizer='sgd', loss='mse', metrics=['mse'])
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
9 of 113 9/23/21, 09:01
Epoch 1/2000
4/4 [==============================] - 0s 922us/step - loss: 0.2997 - mse:
0.2997
Epoch 2/2000
4/4 [==============================] - 0s 719us/step - loss: 0.2981 - mse:
0.2981
Epoch 3/2000
4/4 [==============================] - 0s 842us/step - loss: 0.2983 - mse:
0.2983
Epoch 4/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2984 - mse: 0.
2984
Epoch 5/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2988 - mse: 0.
2988
Epoch 6/2000
4/4 [==============================] - 0s 960us/step - loss: 0.3028 - mse:
0.3028
Epoch 7/2000
4/4 [==============================] - 0s 2ms/step - loss: 0.2989 - mse: 0.
2989
Epoch 8/2000
4/4 [==============================] - 0s 843us/step - loss: 0.2981 - mse:
0.2981
Epoch 9/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2980 - mse: 0.
2980
Epoch 10/2000
4/4 [==============================] - 0s 963us/step - loss: 0.2979 - mse:
0.2979
Epoch 11/2000
4/4 [==============================] - 0s 994us/step - loss: 0.3002 - mse:
0.3002
Epoch 12/2000
4/4 [==============================] - 0s 2ms/step - loss: 0.2975 - mse: 0.
2975
Epoch 13/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2984 - mse: 0.
2984
Epoch 14/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.3013 - mse: 0.
3013
Epoch 15/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2989 - mse: 0.
2989
Epoch 16/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.3001 - mse: 0.
3001
Epoch 17/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2981 - mse: 0.
2981
Epoch 18/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2976 - mse: 0.
2976
In [37]:
tr_hist = model.fit(t, y, epochs=2000, verbose=1)
plt.plot(tr_hist.history['loss'])
plt.ylabel('loss')
plt.xlabel('epoch')
#plt.legend(['opetus'], loc='upper right')
plt.show()
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
10 of 113 9/23/21, 09:01
Epoch 19/2000
4/4 [==============================] - 0s 820us/step - loss: 0.2996 - mse:
0.2996
Epoch 20/2000
4/4 [==============================] - 0s 915us/step - loss: 0.3031 - mse:
0.3031
Epoch 21/2000
4/4 [==============================] - 0s 981us/step - loss: 0.2978 - mse:
0.2978
Epoch 22/2000
4/4 [==============================] - 0s 967us/step - loss: 0.3030 - mse:
0.3030
Epoch 23/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.3006 - mse: 0.
3006
Epoch 24/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2987 - mse: 0.
2987
Epoch 25/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2997 - mse: 0.
2997
Epoch 26/2000
4/4 [==============================] - 0s 923us/step - loss: 0.3049 - mse:
0.3049
Epoch 27/2000
4/4 [==============================] - 0s 994us/step - loss: 0.2977 - mse:
0.2977
Epoch 28/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2975 - mse: 0.
2975
Epoch 29/2000
4/4 [==============================] - 0s 987us/step - loss: 0.2992 - mse:
0.2992
Epoch 30/2000
4/4 [==============================] - 0s 954us/step - loss: 0.2974 - mse:
0.2974
Epoch 31/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2982 - mse: 0.
2982
Epoch 32/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2977 - mse: 0.
2977
Epoch 33/2000
4/4 [==============================] - 0s 763us/step - loss: 0.2979 - mse:
0.2979
Epoch 34/2000
4/4 [==============================] - 0s 2ms/step - loss: 0.3019 - mse: 0.
3019
Epoch 35/2000
4/4 [==============================] - 0s 1000us/step - loss: 0.3044 - mse:
0.3044
Epoch 36/2000
4/4 [==============================] - 0s 755us/step - loss: 0.3005 - mse:
0.3005
Epoch 37/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2973 - mse: 0.
2973
Epoch 38/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2974 - mse: 0.
2974
Epoch 39/2000
4/4 [==============================] - 0s 757us/step - loss: 0.2963 - mse:
0.2963
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
11 of 113 9/23/21, 09:01
Epoch 40/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2968 - mse: 0.
2968
Epoch 41/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2961 - mse: 0.
2961
Epoch 42/2000
4/4 [==============================] - 0s 762us/step - loss: 0.2966 - mse:
0.2966
Epoch 43/2000
4/4 [==============================] - 0s 983us/step - loss: 0.2966 - mse:
0.2966
Epoch 44/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.3007 - mse: 0.
3007
Epoch 45/2000
4/4 [==============================] - 0s 918us/step - loss: 0.2982 - mse:
0.2982
Epoch 46/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2971 - mse: 0.
2971
Epoch 47/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2970 - mse: 0.
2970
Epoch 48/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.3003 - mse: 0.
3003
Epoch 49/2000
4/4 [==============================] - 0s 2ms/step - loss: 0.2971 - mse: 0.
2971
Epoch 50/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2967 - mse: 0.
2967
Epoch 51/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2982 - mse: 0.
2982
Epoch 52/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2972 - mse: 0.
2972
Epoch 53/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2956 - mse: 0.
2956
Epoch 54/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2991 - mse: 0.
2991
Epoch 55/2000
4/4 [==============================] - 0s 931us/step - loss: 0.2955 - mse:
0.2955
Epoch 56/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2960 - mse: 0.
2960
Epoch 57/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2982 - mse: 0.
2982
Epoch 58/2000
4/4 [==============================] - 0s 726us/step - loss: 0.2972 - mse:
0.2972
Epoch 59/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2968 - mse: 0.
2968
Epoch 60/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2977 - mse: 0.
2977
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
12 of 113 9/23/21, 09:01
Epoch 61/2000
4/4 [==============================] - 0s 689us/step - loss: 0.2969 - mse:
0.2969
Epoch 62/2000
4/4 [==============================] - 0s 892us/step - loss: 0.2957 - mse:
0.2957
Epoch 63/2000
4/4 [==============================] - 0s 818us/step - loss: 0.2961 - mse:
0.2961
Epoch 64/2000
4/4 [==============================] - 0s 713us/step - loss: 0.2970 - mse:
0.2970
Epoch 65/2000
4/4 [==============================] - 0s 935us/step - loss: 0.2953 - mse:
0.2953
Epoch 66/2000
4/4 [==============================] - 0s 993us/step - loss: 0.2966 - mse:
0.2966
Epoch 67/2000
4/4 [==============================] - 0s 766us/step - loss: 0.2958 - mse:
0.2958
Epoch 68/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2949 - mse: 0.
2949
Epoch 69/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2972 - mse: 0.
2972
Epoch 70/2000
4/4 [==============================] - 0s 651us/step - loss: 0.2954 - mse:
0.2954
Epoch 71/2000
4/4 [==============================] - 0s 707us/step - loss: 0.2947 - mse:
0.2947
Epoch 72/2000
4/4 [==============================] - 0s 964us/step - loss: 0.2949 - mse:
0.2949
Epoch 73/2000
4/4 [==============================] - 0s 954us/step - loss: 0.2960 - mse:
0.2960
Epoch 74/2000
4/4 [==============================] - 0s 649us/step - loss: 0.2984 - mse:
0.2984
Epoch 75/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2948 - mse: 0.
2948
Epoch 76/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2947 - mse: 0.
2947
Epoch 77/2000
4/4 [==============================] - 0s 657us/step - loss: 0.2946 - mse:
0.2946
Epoch 78/2000
4/4 [==============================] - 0s 728us/step - loss: 0.2954 - mse:
0.2954
Epoch 79/2000
4/4 [==============================] - 0s 908us/step - loss: 0.2943 - mse:
0.2943
Epoch 80/2000
4/4 [==============================] - 0s 840us/step - loss: 0.2942 - mse:
0.2942
Epoch 81/2000
4/4 [==============================] - 0s 634us/step - loss: 0.2943 - mse:
0.2943
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
13 of 113 9/23/21, 09:01
Epoch 82/2000
4/4 [==============================] - 0s 916us/step - loss: 0.2971 - mse:
0.2971
Epoch 83/2000
4/4 [==============================] - 0s 818us/step - loss: 0.3008 - mse:
0.3008
Epoch 84/2000
4/4 [==============================] - 0s 653us/step - loss: 0.2965 - mse:
0.2965
Epoch 85/2000
4/4 [==============================] - 0s 924us/step - loss: 0.2943 - mse:
0.2943
Epoch 86/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2957 - mse: 0.
2957
Epoch 87/2000
4/4 [==============================] - 0s 739us/step - loss: 0.2949 - mse:
0.2949
Epoch 88/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2966 - mse: 0.
2966
Epoch 89/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2948 - mse: 0.
2948
Epoch 90/2000
4/4 [==============================] - 0s 642us/step - loss: 0.2959 - mse:
0.2959
Epoch 91/2000
4/4 [==============================] - 0s 766us/step - loss: 0.2936 - mse:
0.2936
Epoch 92/2000
4/4 [==============================] - 0s 926us/step - loss: 0.2953 - mse:
0.2953
Epoch 93/2000
4/4 [==============================] - 0s 897us/step - loss: 0.2942 - mse:
0.2942
Epoch 94/2000
4/4 [==============================] - 0s 667us/step - loss: 0.2963 - mse:
0.2963
Epoch 95/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2954 - mse: 0.
2954
Epoch 96/2000
4/4 [==============================] - 0s 810us/step - loss: 0.2941 - mse:
0.2941
Epoch 97/2000
4/4 [==============================] - 0s 726us/step - loss: 0.2952 - mse:
0.2952
Epoch 98/2000
4/4 [==============================] - 0s 851us/step - loss: 0.2959 - mse:
0.2959
Epoch 99/2000
4/4 [==============================] - 0s 943us/step - loss: 0.2947 - mse:
0.2947
Epoch 100/2000
4/4 [==============================] - 0s 708us/step - loss: 0.2970 - mse:
0.2970
Epoch 101/2000
4/4 [==============================] - 0s 796us/step - loss: 0.3006 - mse:
0.3006
Epoch 102/2000
4/4 [==============================] - 0s 919us/step - loss: 0.2960 - mse:
0.2960
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
14 of 113 9/23/21, 09:01
Epoch 103/2000
4/4 [==============================] - 0s 947us/step - loss: 0.2976 - mse:
0.2976
Epoch 104/2000
4/4 [==============================] - 0s 733us/step - loss: 0.2930 - mse:
0.2930
Epoch 105/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2993 - mse: 0.
2993
Epoch 106/2000
4/4 [==============================] - 0s 919us/step - loss: 0.3008 - mse:
0.3008
Epoch 107/2000
4/4 [==============================] - 0s 720us/step - loss: 0.2976 - mse:
0.2976
Epoch 108/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2940 - mse: 0.
2940
Epoch 109/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2932 - mse: 0.
2932
Epoch 110/2000
4/4 [==============================] - 0s 681us/step - loss: 0.2932 - mse:
0.2932
Epoch 111/2000
4/4 [==============================] - 0s 996us/step - loss: 0.2921 - mse:
0.2921
Epoch 112/2000
4/4 [==============================] - 0s 978us/step - loss: 0.2933 - mse:
0.2933
Epoch 113/2000
4/4 [==============================] - 0s 805us/step - loss: 0.2926 - mse:
0.2926
Epoch 114/2000
4/4 [==============================] - 0s 704us/step - loss: 0.2962 - mse:
0.2962
Epoch 115/2000
4/4 [==============================] - 0s 976us/step - loss: 0.2929 - mse:
0.2929
Epoch 116/2000
4/4 [==============================] - 0s 889us/step - loss: 0.2966 - mse:
0.2966
Epoch 117/2000
4/4 [==============================] - 0s 716us/step - loss: 0.2925 - mse:
0.2925
Epoch 118/2000
4/4 [==============================] - 0s 954us/step - loss: 0.2924 - mse:
0.2924
Epoch 119/2000
4/4 [==============================] - 0s 920us/step - loss: 0.2950 - mse:
0.2950
Epoch 120/2000
4/4 [==============================] - 0s 754us/step - loss: 0.2923 - mse:
0.2923
Epoch 121/2000
4/4 [==============================] - 0s 969us/step - loss: 0.2951 - mse:
0.2951
Epoch 122/2000
4/4 [==============================] - 0s 986us/step - loss: 0.2933 - mse:
0.2933
Epoch 123/2000
4/4 [==============================] - 0s 799us/step - loss: 0.2927 - mse:
0.2927
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
15 of 113 9/23/21, 09:01
Epoch 124/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2919 - mse: 0.
2919
Epoch 125/2000
4/4 [==============================] - 0s 940us/step - loss: 0.2920 - mse:
0.2920
Epoch 126/2000
4/4 [==============================] - 0s 853us/step - loss: 0.2973 - mse:
0.2973
Epoch 127/2000
4/4 [==============================] - 0s 938us/step - loss: 0.2943 - mse:
0.2943
Epoch 128/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2949 - mse: 0.
2949
Epoch 129/2000
4/4 [==============================] - 0s 815us/step - loss: 0.2919 - mse:
0.2919
Epoch 130/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2914 - mse: 0.
2914
Epoch 131/2000
4/4 [==============================] - 0s 974us/step - loss: 0.2938 - mse:
0.2938
Epoch 132/2000
4/4 [==============================] - 0s 745us/step - loss: 0.2939 - mse:
0.2939
Epoch 133/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2930 - mse: 0.
2930
Epoch 134/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2940 - mse: 0.
2940
Epoch 135/2000
4/4 [==============================] - 0s 701us/step - loss: 0.2933 - mse:
0.2933
Epoch 136/2000
4/4 [==============================] - 0s 806us/step - loss: 0.3012 - mse:
0.3012
Epoch 137/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.3053 - mse: 0.
3053
Epoch 138/2000
4/4 [==============================] - 0s 744us/step - loss: 0.2946 - mse:
0.2946
Epoch 139/2000
4/4 [==============================] - 0s 711us/step - loss: 0.2945 - mse:
0.2945
Epoch 140/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2914 - mse: 0.
2914
Epoch 141/2000
4/4 [==============================] - 0s 769us/step - loss: 0.2925 - mse:
0.2925
Epoch 142/2000
4/4 [==============================] - 0s 671us/step - loss: 0.2925 - mse:
0.2925
Epoch 143/2000
4/4 [==============================] - 0s 988us/step - loss: 0.2948 - mse:
0.2948
Epoch 144/2000
4/4 [==============================] - 0s 972us/step - loss: 0.2979 - mse:
0.2979
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
16 of 113 9/23/21, 09:01
Epoch 145/2000
4/4 [==============================] - 0s 866us/step - loss: 0.2946 - mse:
0.2946
Epoch 146/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2951 - mse: 0.
2951
Epoch 147/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2912 - mse: 0.
2912
Epoch 148/2000
4/4 [==============================] - 0s 674us/step - loss: 0.2928 - mse:
0.2928
Epoch 149/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2913 - mse: 0.
2913
Epoch 150/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2923 - mse: 0.
2923
Epoch 151/2000
4/4 [==============================] - 0s 748us/step - loss: 0.2914 - mse:
0.2914
Epoch 152/2000
4/4 [==============================] - 0s 759us/step - loss: 0.2946 - mse:
0.2946
Epoch 153/2000
4/4 [==============================] - 0s 958us/step - loss: 0.2990 - mse:
0.2990
Epoch 154/2000
4/4 [==============================] - 0s 741us/step - loss: 0.2944 - mse:
0.2944
Epoch 155/2000
4/4 [==============================] - 0s 869us/step - loss: 0.2917 - mse:
0.2917
Epoch 156/2000
4/4 [==============================] - 0s 835us/step - loss: 0.2926 - mse:
0.2926
Epoch 157/2000
4/4 [==============================] - 0s 860us/step - loss: 0.2924 - mse:
0.2924
Epoch 158/2000
4/4 [==============================] - 0s 764us/step - loss: 0.2954 - mse:
0.2954
Epoch 159/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2958 - mse: 0.
2958
Epoch 160/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2912 - mse: 0.
2912
Epoch 161/2000
4/4 [==============================] - 0s 991us/step - loss: 0.2905 - mse:
0.2905
Epoch 162/2000
4/4 [==============================] - 0s 993us/step - loss: 0.2918 - mse:
0.2918
Epoch 163/2000
4/4 [==============================] - 0s 913us/step - loss: 0.2900 - mse:
0.2900
Epoch 164/2000
4/4 [==============================] - 0s 722us/step - loss: 0.2903 - mse:
0.2903
Epoch 165/2000
4/4 [==============================] - 0s 742us/step - loss: 0.2945 - mse:
0.2945
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
17 of 113 9/23/21, 09:01
Epoch 166/2000
4/4 [==============================] - 0s 2ms/step - loss: 0.2926 - mse: 0.
2926
Epoch 167/2000
4/4 [==============================] - 0s 820us/step - loss: 0.2901 - mse:
0.2901
Epoch 168/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2900 - mse: 0.
2900
Epoch 169/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2908 - mse: 0.
2908
Epoch 170/2000
4/4 [==============================] - 0s 710us/step - loss: 0.2936 - mse:
0.2936
Epoch 171/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2923 - mse: 0.
2923
Epoch 172/2000
4/4 [==============================] - 0s 867us/step - loss: 0.2941 - mse:
0.2941
Epoch 173/2000
4/4 [==============================] - 0s 725us/step - loss: 0.2930 - mse:
0.2930
Epoch 174/2000
4/4 [==============================] - 0s 789us/step - loss: 0.2891 - mse:
0.2891
Epoch 175/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2926 - mse: 0.
2926
Epoch 176/2000
4/4 [==============================] - 0s 777us/step - loss: 0.2904 - mse:
0.2904
Epoch 177/2000
4/4 [==============================] - 0s 702us/step - loss: 0.2897 - mse:
0.2897
Epoch 178/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2885 - mse: 0.
2885
Epoch 179/2000
4/4 [==============================] - 0s 720us/step - loss: 0.2902 - mse:
0.2902
Epoch 180/2000
4/4 [==============================] - 0s 947us/step - loss: 0.2957 - mse:
0.2957
Epoch 181/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2908 - mse: 0.
2908
Epoch 182/2000
4/4 [==============================] - 0s 865us/step - loss: 0.2917 - mse:
0.2917
Epoch 183/2000
4/4 [==============================] - 0s 938us/step - loss: 0.2994 - mse:
0.2994
Epoch 184/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2916 - mse: 0.
2916
Epoch 185/2000
4/4 [==============================] - 0s 693us/step - loss: 0.2882 - mse:
0.2882
Epoch 186/2000
4/4 [==============================] - 0s 935us/step - loss: 0.2896 - mse:
0.2896
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
18 of 113 9/23/21, 09:01
Epoch 187/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2888 - mse: 0.
2888
Epoch 188/2000
4/4 [==============================] - 0s 712us/step - loss: 0.2948 - mse:
0.2948
Epoch 189/2000
4/4 [==============================] - 0s 646us/step - loss: 0.2928 - mse:
0.2928
Epoch 190/2000
4/4 [==============================] - 0s 917us/step - loss: 0.2880 - mse:
0.2880
Epoch 191/2000
4/4 [==============================] - 0s 838us/step - loss: 0.2910 - mse:
0.2910
Epoch 192/2000
4/4 [==============================] - 0s 830us/step - loss: 0.2898 - mse:
0.2898
Epoch 193/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2882 - mse: 0.
2882
Epoch 194/2000
4/4 [==============================] - 0s 661us/step - loss: 0.2882 - mse:
0.2882
Epoch 195/2000
4/4 [==============================] - 0s 711us/step - loss: 0.2891 - mse:
0.2891
Epoch 196/2000
4/4 [==============================] - 0s 994us/step - loss: 0.2955 - mse:
0.2955
Epoch 197/2000
4/4 [==============================] - 0s 862us/step - loss: 0.2892 - mse:
0.2892
Epoch 198/2000
4/4 [==============================] - 0s 732us/step - loss: 0.2888 - mse:
0.2888
Epoch 199/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2875 - mse: 0.
2875
Epoch 200/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2886 - mse: 0.
2886
Epoch 201/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2901 - mse: 0.
2901
Epoch 202/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2906 - mse: 0.
2906
Epoch 203/2000
4/4 [==============================] - 0s 828us/step - loss: 0.2891 - mse:
0.2891
Epoch 204/2000
4/4 [==============================] - 0s 818us/step - loss: 0.2880 - mse:
0.2880
Epoch 205/2000
4/4 [==============================] - 0s 943us/step - loss: 0.2929 - mse:
0.2929
Epoch 206/2000
4/4 [==============================] - 0s 862us/step - loss: 0.2897 - mse:
0.2897
Epoch 207/2000
4/4 [==============================] - 0s 994us/step - loss: 0.2896 - mse:
0.2896
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
19 of 113 9/23/21, 09:01
Epoch 208/2000
4/4 [==============================] - 0s 906us/step - loss: 0.2947 - mse:
0.2947
Epoch 209/2000
4/4 [==============================] - 0s 904us/step - loss: 0.3019 - mse:
0.3019
Epoch 210/2000
4/4 [==============================] - 0s 714us/step - loss: 0.3017 - mse:
0.3017
Epoch 211/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2913 - mse: 0.
2913
Epoch 212/2000
4/4 [==============================] - 0s 899us/step - loss: 0.2911 - mse:
0.2911
Epoch 213/2000
4/4 [==============================] - 0s 678us/step - loss: 0.2869 - mse:
0.2869
Epoch 214/2000
4/4 [==============================] - 0s 748us/step - loss: 0.2941 - mse:
0.2941
Epoch 215/2000
4/4 [==============================] - 0s 998us/step - loss: 0.2871 - mse:
0.2871
Epoch 216/2000
4/4 [==============================] - 0s 690us/step - loss: 0.2877 - mse:
0.2877
Epoch 217/2000
4/4 [==============================] - 0s 691us/step - loss: 0.2899 - mse:
0.2899
Epoch 218/2000
4/4 [==============================] - 0s 901us/step - loss: 0.2876 - mse:
0.2876
Epoch 219/2000
4/4 [==============================] - 0s 868us/step - loss: 0.2887 - mse:
0.2887
Epoch 220/2000
4/4 [==============================] - 0s 657us/step - loss: 0.2908 - mse:
0.2908
Epoch 221/2000
4/4 [==============================] - 0s 882us/step - loss: 0.2871 - mse:
0.2871
Epoch 222/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2885 - mse: 0.
2885
Epoch 223/2000
4/4 [==============================] - 0s 833us/step - loss: 0.2868 - mse:
0.2868
Epoch 224/2000
4/4 [==============================] - 0s 746us/step - loss: 0.2885 - mse:
0.2885
Epoch 225/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2871 - mse: 0.
2871
Epoch 226/2000
4/4 [==============================] - 0s 726us/step - loss: 0.2880 - mse:
0.2880
Epoch 227/2000
4/4 [==============================] - 0s 719us/step - loss: 0.2869 - mse:
0.2869
Epoch 228/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2864 - mse: 0.
2864
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
20 of 113 9/23/21, 09:01
Epoch 229/2000
4/4 [==============================] - 0s 804us/step - loss: 0.2893 - mse:
0.2893
Epoch 230/2000
4/4 [==============================] - 0s 687us/step - loss: 0.2873 - mse:
0.2873
Epoch 231/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2875 - mse: 0.
2875
Epoch 232/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2888 - mse: 0.
2888
Epoch 233/2000
4/4 [==============================] - 0s 667us/step - loss: 0.2869 - mse:
0.2869
Epoch 234/2000
4/4 [==============================] - 0s 700us/step - loss: 0.2861 - mse:
0.2861
Epoch 235/2000
4/4 [==============================] - 0s 978us/step - loss: 0.2874 - mse:
0.2874
Epoch 236/2000
4/4 [==============================] - 0s 831us/step - loss: 0.2887 - mse:
0.2887
Epoch 237/2000
4/4 [==============================] - 0s 666us/step - loss: 0.2886 - mse:
0.2886
Epoch 238/2000
4/4 [==============================] - 0s 879us/step - loss: 0.2867 - mse:
0.2867
Epoch 239/2000
4/4 [==============================] - 0s 983us/step - loss: 0.2868 - mse:
0.2868
Epoch 240/2000
4/4 [==============================] - 0s 701us/step - loss: 0.2902 - mse:
0.2902
Epoch 241/2000
4/4 [==============================] - 0s 941us/step - loss: 0.2857 - mse:
0.2857
Epoch 242/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2862 - mse: 0.
2862
Epoch 243/2000
4/4 [==============================] - 0s 747us/step - loss: 0.2869 - mse:
0.2869
Epoch 244/2000
4/4 [==============================] - 0s 832us/step - loss: 0.2853 - mse:
0.2853
Epoch 245/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2859 - mse: 0.
2859
Epoch 246/2000
4/4 [==============================] - 0s 829us/step - loss: 0.2854 - mse:
0.2854
Epoch 247/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2854 - mse: 0.
2854
Epoch 248/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2867 - mse: 0.
2867
Epoch 249/2000
4/4 [==============================] - 0s 739us/step - loss: 0.2872 - mse:
0.2872
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
21 of 113 9/23/21, 09:01
Epoch 250/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2853 - mse: 0.
2853
Epoch 251/2000
4/4 [==============================] - 0s 971us/step - loss: 0.2857 - mse:
0.2857
Epoch 252/2000
4/4 [==============================] - 0s 856us/step - loss: 0.2898 - mse:
0.2898
Epoch 253/2000
4/4 [==============================] - 0s 832us/step - loss: 0.2927 - mse:
0.2927
Epoch 254/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2874 - mse: 0.
2874
Epoch 255/2000
4/4 [==============================] - 0s 727us/step - loss: 0.2857 - mse:
0.2857
Epoch 256/2000
4/4 [==============================] - 0s 671us/step - loss: 0.2853 - mse:
0.2853
Epoch 257/2000
4/4 [==============================] - 0s 852us/step - loss: 0.2862 - mse:
0.2862
Epoch 258/2000
4/4 [==============================] - 0s 981us/step - loss: 0.2847 - mse:
0.2847
Epoch 259/2000
4/4 [==============================] - 0s 694us/step - loss: 0.2842 - mse:
0.2842
Epoch 260/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2860 - mse: 0.
2860
Epoch 261/2000
4/4 [==============================] - 0s 975us/step - loss: 0.2873 - mse:
0.2873
Epoch 262/2000
4/4 [==============================] - 0s 692us/step - loss: 0.2864 - mse:
0.2864
Epoch 263/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2839 - mse: 0.
2839
Epoch 264/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2842 - mse: 0.
2842
Epoch 265/2000
4/4 [==============================] - 0s 653us/step - loss: 0.2860 - mse:
0.2860
Epoch 266/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2847 - mse: 0.
2847
Epoch 267/2000
4/4 [==============================] - 0s 967us/step - loss: 0.2892 - mse:
0.2892
Epoch 268/2000
4/4 [==============================] - 0s 746us/step - loss: 0.2853 - mse:
0.2853
Epoch 269/2000
4/4 [==============================] - 0s 969us/step - loss: 0.2849 - mse:
0.2849
Epoch 270/2000
4/4 [==============================] - 0s 999us/step - loss: 0.2846 - mse:
0.2846
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
22 of 113 9/23/21, 09:01
Epoch 271/2000
4/4 [==============================] - 0s 841us/step - loss: 0.2865 - mse:
0.2865
Epoch 272/2000
4/4 [==============================] - 0s 673us/step - loss: 0.2852 - mse:
0.2852
Epoch 273/2000
4/4 [==============================] - 0s 2ms/step - loss: 0.2844 - mse: 0.
2844
Epoch 274/2000
4/4 [==============================] - 0s 722us/step - loss: 0.2858 - mse:
0.2858
Epoch 275/2000
4/4 [==============================] - 0s 769us/step - loss: 0.2842 - mse:
0.2842
Epoch 276/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2845 - mse: 0.
2845
Epoch 277/2000
4/4 [==============================] - 0s 780us/step - loss: 0.2879 - mse:
0.2879
Epoch 278/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2846 - mse: 0.
2846
Epoch 279/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2837 - mse: 0.
2837
Epoch 280/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2886 - mse: 0.
2886
Epoch 281/2000
4/4 [==============================] - 0s 872us/step - loss: 0.2863 - mse:
0.2863
Epoch 282/2000
4/4 [==============================] - 0s 999us/step - loss: 0.2920 - mse:
0.2920
Epoch 283/2000
4/4 [==============================] - 0s 774us/step - loss: 0.2863 - mse:
0.2863
Epoch 284/2000
4/4 [==============================] - 0s 685us/step - loss: 0.2887 - mse:
0.2887
Epoch 285/2000
4/4 [==============================] - 0s 981us/step - loss: 0.2833 - mse:
0.2833
Epoch 286/2000
4/4 [==============================] - 0s 843us/step - loss: 0.2835 - mse:
0.2835
Epoch 287/2000
4/4 [==============================] - 0s 860us/step - loss: 0.2859 - mse:
0.2859
Epoch 288/2000
4/4 [==============================] - 0s 793us/step - loss: 0.2854 - mse:
0.2854
Epoch 289/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2835 - mse: 0.
2835
Epoch 290/2000
4/4 [==============================] - 0s 720us/step - loss: 0.2844 - mse:
0.2844
Epoch 291/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2844 - mse: 0.
2844
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
23 of 113 9/23/21, 09:01
Epoch 292/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2848 - mse: 0.
2848
Epoch 293/2000
4/4 [==============================] - 0s 763us/step - loss: 0.2885 - mse:
0.2885
Epoch 294/2000
4/4 [==============================] - 0s 660us/step - loss: 0.2892 - mse:
0.2892
Epoch 295/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2929 - mse: 0.
2929
Epoch 296/2000
4/4 [==============================] - 0s 845us/step - loss: 0.2921 - mse:
0.2921
Epoch 297/2000
4/4 [==============================] - 0s 679us/step - loss: 0.2828 - mse:
0.2828
Epoch 298/2000
4/4 [==============================] - 0s 823us/step - loss: 0.2821 - mse:
0.2821
Epoch 299/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2832 - mse: 0.
2832
Epoch 300/2000
4/4 [==============================] - 0s 644us/step - loss: 0.2872 - mse:
0.2872
Epoch 301/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2859 - mse: 0.
2859
Epoch 302/2000
4/4 [==============================] - 0s 934us/step - loss: 0.2833 - mse:
0.2833
Epoch 303/2000
4/4 [==============================] - 0s 696us/step - loss: 0.2821 - mse:
0.2821
Epoch 304/2000
4/4 [==============================] - 0s 729us/step - loss: 0.2848 - mse:
0.2848
Epoch 305/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2854 - mse: 0.
2854
Epoch 306/2000
4/4 [==============================] - 0s 785us/step - loss: 0.2898 - mse:
0.2898
Epoch 307/2000
4/4 [==============================] - 0s 687us/step - loss: 0.2817 - mse:
0.2817
Epoch 308/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2841 - mse: 0.
2841
Epoch 309/2000
4/4 [==============================] - 0s 854us/step - loss: 0.2847 - mse:
0.2847
Epoch 310/2000
4/4 [==============================] - 0s 694us/step - loss: 0.2825 - mse:
0.2825
Epoch 311/2000
4/4 [==============================] - 0s 878us/step - loss: 0.2829 - mse:
0.2829
Epoch 312/2000
4/4 [==============================] - 0s 819us/step - loss: 0.2853 - mse:
0.2853
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
24 of 113 9/23/21, 09:01
Epoch 313/2000
4/4 [==============================] - 0s 684us/step - loss: 0.2822 - mse:
0.2822
Epoch 314/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2829 - mse: 0.
2829
Epoch 315/2000
4/4 [==============================] - 0s 883us/step - loss: 0.2817 - mse:
0.2817
Epoch 316/2000
4/4 [==============================] - 0s 777us/step - loss: 0.2875 - mse:
0.2875
Epoch 317/2000
4/4 [==============================] - 0s 692us/step - loss: 0.2827 - mse:
0.2827
Epoch 318/2000
4/4 [==============================] - 0s 755us/step - loss: 0.2820 - mse:
0.2820
Epoch 319/2000
4/4 [==============================] - 0s 914us/step - loss: 0.2821 - mse:
0.2821
Epoch 320/2000
4/4 [==============================] - 0s 700us/step - loss: 0.2824 - mse:
0.2824
Epoch 321/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2811 - mse: 0.
2811
Epoch 322/2000
4/4 [==============================] - 0s 843us/step - loss: 0.2843 - mse:
0.2843
Epoch 323/2000
4/4 [==============================] - 0s 770us/step - loss: 0.2820 - mse:
0.2820
Epoch 324/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2813 - mse: 0.
2813
Epoch 325/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2809 - mse: 0.
2809
Epoch 326/2000
4/4 [==============================] - 0s 791us/step - loss: 0.2810 - mse:
0.2810
Epoch 327/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2809 - mse: 0.
2809
Epoch 328/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2812 - mse: 0.
2812
Epoch 329/2000
4/4 [==============================] - 0s 709us/step - loss: 0.2822 - mse:
0.2822
Epoch 330/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2818 - mse: 0.
2818
Epoch 331/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2815 - mse: 0.
2815
Epoch 332/2000
4/4 [==============================] - 0s 709us/step - loss: 0.2833 - mse:
0.2833
Epoch 333/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2842 - mse: 0.
2842
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
25 of 113 9/23/21, 09:01
Epoch 334/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2856 - mse: 0.
2856
Epoch 335/2000
4/4 [==============================] - 0s 765us/step - loss: 0.2840 - mse:
0.2840
Epoch 336/2000
4/4 [==============================] - 0s 986us/step - loss: 0.2807 - mse:
0.2807
Epoch 337/2000
4/4 [==============================] - 0s 801us/step - loss: 0.2821 - mse:
0.2821
Epoch 338/2000
4/4 [==============================] - 0s 739us/step - loss: 0.2819 - mse:
0.2819
Epoch 339/2000
4/4 [==============================] - 0s 694us/step - loss: 0.2817 - mse:
0.2817
Epoch 340/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2824 - mse: 0.
2824
Epoch 341/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2804 - mse: 0.
2804
Epoch 342/2000
4/4 [==============================] - 0s 715us/step - loss: 0.2815 - mse:
0.2815
Epoch 343/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2824 - mse: 0.
2824
Epoch 344/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2824 - mse: 0.
2824
Epoch 345/2000
4/4 [==============================] - 0s 687us/step - loss: 0.2811 - mse:
0.2811
Epoch 346/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2796 - mse: 0.
2796
Epoch 347/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2805 - mse: 0.
2805
Epoch 348/2000
4/4 [==============================] - 0s 935us/step - loss: 0.2800 - mse:
0.2800
Epoch 349/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2814 - mse: 0.
2814
Epoch 350/2000
4/4 [==============================] - 0s 838us/step - loss: 0.2814 - mse:
0.2814
Epoch 351/2000
4/4 [==============================] - 0s 750us/step - loss: 0.2826 - mse:
0.2826
Epoch 352/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2820 - mse: 0.
2820
Epoch 353/2000
4/4 [==============================] - 0s 915us/step - loss: 0.2805 - mse:
0.2805
Epoch 354/2000
4/4 [==============================] - 0s 630us/step - loss: 0.2812 - mse:
0.2812
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
26 of 113 9/23/21, 09:01
Epoch 355/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2811 - mse: 0.
2811
Epoch 356/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2812 - mse: 0.
2812
Epoch 357/2000
4/4 [==============================] - 0s 732us/step - loss: 0.2808 - mse:
0.2808
Epoch 358/2000
4/4 [==============================] - 0s 993us/step - loss: 0.2821 - mse:
0.2821
Epoch 359/2000
4/4 [==============================] - 0s 841us/step - loss: 0.2856 - mse:
0.2856
Epoch 360/2000
4/4 [==============================] - 0s 768us/step - loss: 0.2794 - mse:
0.2794
Epoch 361/2000
4/4 [==============================] - 0s 766us/step - loss: 0.2800 - mse:
0.2800
Epoch 362/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2795 - mse: 0.
2795
Epoch 363/2000
4/4 [==============================] - 0s 985us/step - loss: 0.2797 - mse:
0.2797
Epoch 364/2000
4/4 [==============================] - 0s 752us/step - loss: 0.2802 - mse:
0.2802
Epoch 365/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2800 - mse: 0.
2800
Epoch 366/2000
4/4 [==============================] - 0s 661us/step - loss: 0.2828 - mse:
0.2828
Epoch 367/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2826 - mse: 0.
2826
Epoch 368/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2805 - mse: 0.
2805
Epoch 369/2000
4/4 [==============================] - 0s 703us/step - loss: 0.2797 - mse:
0.2797
Epoch 370/2000
4/4 [==============================] - 0s 848us/step - loss: 0.2791 - mse:
0.2791
Epoch 371/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2803 - mse: 0.
2803
Epoch 372/2000
4/4 [==============================] - 0s 848us/step - loss: 0.2787 - mse:
0.2787
Epoch 373/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2781 - mse: 0.
2781
Epoch 374/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2793 - mse: 0.
2793
Epoch 375/2000
4/4 [==============================] - 0s 731us/step - loss: 0.2870 - mse:
0.2870
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
27 of 113 9/23/21, 09:01
Epoch 376/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2897 - mse: 0.
2897
Epoch 377/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2890 - mse: 0.
2890
Epoch 378/2000
4/4 [==============================] - 0s 835us/step - loss: 0.2806 - mse:
0.2806
Epoch 379/2000
4/4 [==============================] - 0s 679us/step - loss: 0.2832 - mse:
0.2832
Epoch 380/2000
4/4 [==============================] - 0s 820us/step - loss: 0.2793 - mse:
0.2793
Epoch 381/2000
4/4 [==============================] - 0s 707us/step - loss: 0.2783 - mse:
0.2783
Epoch 382/2000
4/4 [==============================] - 0s 790us/step - loss: 0.2816 - mse:
0.2816
Epoch 383/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2797 - mse: 0.
2797
Epoch 384/2000
4/4 [==============================] - 0s 887us/step - loss: 0.2785 - mse:
0.2785
Epoch 385/2000
4/4 [==============================] - 0s 892us/step - loss: 0.2788 - mse:
0.2788
Epoch 386/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2834 - mse: 0.
2834
Epoch 387/2000
4/4 [==============================] - 0s 957us/step - loss: 0.2851 - mse:
0.2851
Epoch 388/2000
4/4 [==============================] - 0s 716us/step - loss: 0.2826 - mse:
0.2826
Epoch 389/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2795 - mse: 0.
2795
Epoch 390/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2820 - mse: 0.
2820
Epoch 391/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2830 - mse: 0.
2830
Epoch 392/2000
4/4 [==============================] - 0s 733us/step - loss: 0.2849 - mse:
0.2849
Epoch 393/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2819 - mse: 0.
2819
Epoch 394/2000
4/4 [==============================] - 0s 723us/step - loss: 0.2771 - mse:
0.2771
Epoch 395/2000
4/4 [==============================] - 0s 914us/step - loss: 0.2778 - mse:
0.2778
Epoch 396/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2808 - mse: 0.
2808
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
28 of 113 9/23/21, 09:01
Epoch 397/2000
4/4 [==============================] - 0s 950us/step - loss: 0.2786 - mse:
0.2786
Epoch 398/2000
4/4 [==============================] - 0s 719us/step - loss: 0.2786 - mse:
0.2786
Epoch 399/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2805 - mse: 0.
2805
Epoch 400/2000
4/4 [==============================] - 0s 825us/step - loss: 0.2839 - mse:
0.2839
Epoch 401/2000
4/4 [==============================] - 0s 821us/step - loss: 0.2768 - mse:
0.2768
Epoch 402/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2779 - mse: 0.
2779
Epoch 403/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2787 - mse: 0.
2787
Epoch 404/2000
4/4 [==============================] - 0s 826us/step - loss: 0.2783 - mse:
0.2783
Epoch 405/2000
4/4 [==============================] - 0s 968us/step - loss: 0.2767 - mse:
0.2767
Epoch 406/2000
4/4 [==============================] - 0s 950us/step - loss: 0.2774 - mse:
0.2774
Epoch 407/2000
4/4 [==============================] - 0s 796us/step - loss: 0.2764 - mse:
0.2764
Epoch 408/2000
4/4 [==============================] - 0s 847us/step - loss: 0.2772 - mse:
0.2772
Epoch 409/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2783 - mse: 0.
2783
Epoch 410/2000
4/4 [==============================] - 0s 751us/step - loss: 0.2762 - mse:
0.2762
Epoch 411/2000
4/4 [==============================] - 0s 669us/step - loss: 0.2760 - mse:
0.2760
Epoch 412/2000
4/4 [==============================] - 0s 943us/step - loss: 0.2767 - mse:
0.2767
Epoch 413/2000
4/4 [==============================] - 0s 893us/step - loss: 0.2786 - mse:
0.2786
Epoch 414/2000
4/4 [==============================] - 0s 882us/step - loss: 0.2774 - mse:
0.2774
Epoch 415/2000
4/4 [==============================] - 0s 948us/step - loss: 0.2790 - mse:
0.2790
Epoch 416/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2769 - mse: 0.
2769
Epoch 417/2000
4/4 [==============================] - 0s 659us/step - loss: 0.2772 - mse:
0.2772
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
29 of 113 9/23/21, 09:01
Epoch 418/2000
4/4 [==============================] - 0s 948us/step - loss: 0.2794 - mse:
0.2794
Epoch 419/2000
4/4 [==============================] - 0s 906us/step - loss: 0.2806 - mse:
0.2806
Epoch 420/2000
4/4 [==============================] - 0s 691us/step - loss: 0.2771 - mse:
0.2771
Epoch 421/2000
4/4 [==============================] - 0s 680us/step - loss: 0.2784 - mse:
0.2784
Epoch 422/2000
4/4 [==============================] - 0s 907us/step - loss: 0.2772 - mse:
0.2772
Epoch 423/2000
4/4 [==============================] - 0s 941us/step - loss: 0.2762 - mse:
0.2762
Epoch 424/2000
4/4 [==============================] - 0s 730us/step - loss: 0.2850 - mse:
0.2850
Epoch 425/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2758 - mse: 0.
2758
Epoch 426/2000
4/4 [==============================] - 0s 963us/step - loss: 0.2767 - mse:
0.2767
Epoch 427/2000
4/4 [==============================] - 0s 747us/step - loss: 0.2759 - mse:
0.2759
Epoch 428/2000
4/4 [==============================] - 0s 962us/step - loss: 0.2825 - mse:
0.2825
Epoch 429/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2751 - mse: 0.
2751
Epoch 430/2000
4/4 [==============================] - 0s 741us/step - loss: 0.2756 - mse:
0.2756
Epoch 431/2000
4/4 [==============================] - 0s 893us/step - loss: 0.2763 - mse:
0.2763
Epoch 432/2000
4/4 [==============================] - 0s 794us/step - loss: 0.2759 - mse:
0.2759
Epoch 433/2000
4/4 [==============================] - 0s 825us/step - loss: 0.2758 - mse:
0.2758
Epoch 434/2000
4/4 [==============================] - 0s 853us/step - loss: 0.2763 - mse:
0.2763
Epoch 435/2000
4/4 [==============================] - 0s 832us/step - loss: 0.2769 - mse:
0.2769
Epoch 436/2000
4/4 [==============================] - 0s 873us/step - loss: 0.2789 - mse:
0.2789
Epoch 437/2000
4/4 [==============================] - 0s 721us/step - loss: 0.2770 - mse:
0.2770
Epoch 438/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2761 - mse: 0.
2761
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
30 of 113 9/23/21, 09:01
Epoch 439/2000
4/4 [==============================] - 0s 944us/step - loss: 0.2782 - mse:
0.2782
Epoch 440/2000
4/4 [==============================] - 0s 787us/step - loss: 0.2816 - mse:
0.2816
Epoch 441/2000
4/4 [==============================] - 0s 743us/step - loss: 0.2759 - mse:
0.2759
Epoch 442/2000
4/4 [==============================] - 0s 876us/step - loss: 0.2749 - mse:
0.2749
Epoch 443/2000
4/4 [==============================] - 0s 780us/step - loss: 0.2817 - mse:
0.2817
Epoch 444/2000
4/4 [==============================] - 0s 692us/step - loss: 0.2770 - mse:
0.2770
Epoch 445/2000
4/4 [==============================] - 0s 862us/step - loss: 0.2760 - mse:
0.2760
Epoch 446/2000
4/4 [==============================] - 0s 940us/step - loss: 0.2779 - mse:
0.2779
Epoch 447/2000
4/4 [==============================] - 0s 766us/step - loss: 0.2775 - mse:
0.2775
Epoch 448/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2749 - mse: 0.
2749
Epoch 449/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2757 - mse: 0.
2757
Epoch 450/2000
4/4 [==============================] - 0s 691us/step - loss: 0.2751 - mse:
0.2751
Epoch 451/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2760 - mse: 0.
2760
Epoch 452/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2743 - mse: 0.
2743
Epoch 453/2000
4/4 [==============================] - 0s 807us/step - loss: 0.2742 - mse:
0.2742
Epoch 454/2000
4/4 [==============================] - 0s 687us/step - loss: 0.2739 - mse:
0.2739
Epoch 455/2000
4/4 [==============================] - 0s 796us/step - loss: 0.2755 - mse:
0.2755
Epoch 456/2000
4/4 [==============================] - 0s 864us/step - loss: 0.2745 - mse:
0.2745
Epoch 457/2000
4/4 [==============================] - 0s 766us/step - loss: 0.2738 - mse:
0.2738
Epoch 458/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2782 - mse: 0.
2782
Epoch 459/2000
4/4 [==============================] - 0s 967us/step - loss: 0.2805 - mse:
0.2805
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
31 of 113 9/23/21, 09:01
Epoch 460/2000
4/4 [==============================] - 0s 820us/step - loss: 0.2757 - mse:
0.2757
Epoch 461/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2760 - mse: 0.
2760
Epoch 462/2000
4/4 [==============================] - 0s 988us/step - loss: 0.2733 - mse:
0.2733
Epoch 463/2000
4/4 [==============================] - 0s 977us/step - loss: 0.2743 - mse:
0.2743
Epoch 464/2000
4/4 [==============================] - 0s 2ms/step - loss: 0.2745 - mse: 0.
2745
Epoch 465/2000
4/4 [==============================] - 0s 789us/step - loss: 0.2762 - mse:
0.2762
Epoch 466/2000
4/4 [==============================] - 0s 844us/step - loss: 0.2732 - mse:
0.2732
Epoch 467/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2750 - mse: 0.
2750
Epoch 468/2000
4/4 [==============================] - 0s 784us/step - loss: 0.2741 - mse:
0.2741
Epoch 469/2000
4/4 [==============================] - 0s 651us/step - loss: 0.2748 - mse:
0.2748
Epoch 470/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2740 - mse: 0.
2740
Epoch 471/2000
4/4 [==============================] - 0s 906us/step - loss: 0.2749 - mse:
0.2749
Epoch 472/2000
4/4 [==============================] - 0s 708us/step - loss: 0.2764 - mse:
0.2764
Epoch 473/2000
4/4 [==============================] - 0s 986us/step - loss: 0.2736 - mse:
0.2736
Epoch 474/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2741 - mse: 0.
2741
Epoch 475/2000
4/4 [==============================] - 0s 990us/step - loss: 0.2762 - mse:
0.2762
Epoch 476/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2759 - mse: 0.
2759
Epoch 477/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2748 - mse: 0.
2748
Epoch 478/2000
4/4 [==============================] - 0s 775us/step - loss: 0.2736 - mse:
0.2736
Epoch 479/2000
4/4 [==============================] - 0s 964us/step - loss: 0.2729 - mse:
0.2729
Epoch 480/2000
4/4 [==============================] - 0s 913us/step - loss: 0.2736 - mse:
0.2736
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
32 of 113 9/23/21, 09:01
Epoch 481/2000
4/4 [==============================] - 0s 744us/step - loss: 0.2735 - mse:
0.2735
Epoch 482/2000
4/4 [==============================] - 0s 649us/step - loss: 0.2728 - mse:
0.2728
Epoch 483/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2736 - mse: 0.
2736
Epoch 484/2000
4/4 [==============================] - 0s 776us/step - loss: 0.2726 - mse:
0.2726
Epoch 485/2000
4/4 [==============================] - 0s 722us/step - loss: 0.2736 - mse:
0.2736
Epoch 486/2000
4/4 [==============================] - 0s 943us/step - loss: 0.2729 - mse:
0.2729
Epoch 487/2000
4/4 [==============================] - 0s 914us/step - loss: 0.2730 - mse:
0.2730
Epoch 488/2000
4/4 [==============================] - 0s 722us/step - loss: 0.2734 - mse:
0.2734
Epoch 489/2000
4/4 [==============================] - 0s 717us/step - loss: 0.2734 - mse:
0.2734
Epoch 490/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2724 - mse: 0.
2724
Epoch 491/2000
4/4 [==============================] - 0s 687us/step - loss: 0.2723 - mse:
0.2723
Epoch 492/2000
4/4 [==============================] - 0s 865us/step - loss: 0.2720 - mse:
0.2720
Epoch 493/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2755 - mse: 0.
2755
Epoch 494/2000
4/4 [==============================] - 0s 714us/step - loss: 0.2734 - mse:
0.2734
Epoch 495/2000
4/4 [==============================] - 0s 748us/step - loss: 0.2729 - mse:
0.2729
Epoch 496/2000
4/4 [==============================] - 0s 819us/step - loss: 0.2733 - mse:
0.2733
Epoch 497/2000
4/4 [==============================] - 0s 778us/step - loss: 0.2720 - mse:
0.2720
Epoch 498/2000
4/4 [==============================] - 0s 736us/step - loss: 0.2721 - mse:
0.2721
Epoch 499/2000
4/4 [==============================] - 0s 998us/step - loss: 0.2728 - mse:
0.2728
Epoch 500/2000
4/4 [==============================] - 0s 874us/step - loss: 0.2766 - mse:
0.2766
Epoch 501/2000
4/4 [==============================] - 0s 912us/step - loss: 0.2720 - mse:
0.2720
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
33 of 113 9/23/21, 09:01
Epoch 502/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2725 - mse: 0.
2725
Epoch 503/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2722 - mse: 0.
2722
Epoch 504/2000
4/4 [==============================] - 0s 806us/step - loss: 0.2737 - mse:
0.2737
Epoch 505/2000
4/4 [==============================] - 0s 700us/step - loss: 0.2752 - mse:
0.2752
Epoch 506/2000
4/4 [==============================] - 0s 811us/step - loss: 0.2730 - mse:
0.2730
Epoch 507/2000
4/4 [==============================] - 0s 695us/step - loss: 0.2769 - mse:
0.2769
Epoch 508/2000
4/4 [==============================] - 0s 820us/step - loss: 0.2722 - mse:
0.2722
Epoch 509/2000
4/4 [==============================] - 0s 901us/step - loss: 0.2760 - mse:
0.2760
Epoch 510/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2735 - mse: 0.
2735
Epoch 511/2000
4/4 [==============================] - 0s 679us/step - loss: 0.2735 - mse:
0.2735
Epoch 512/2000
4/4 [==============================] - 0s 987us/step - loss: 0.2733 - mse:
0.2733
Epoch 513/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2726 - mse: 0.
2726
Epoch 514/2000
4/4 [==============================] - 0s 980us/step - loss: 0.2735 - mse:
0.2735
Epoch 515/2000
4/4 [==============================] - 0s 978us/step - loss: 0.2714 - mse:
0.2714
Epoch 516/2000
4/4 [==============================] - 0s 913us/step - loss: 0.2709 - mse:
0.2709
Epoch 517/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2727 - mse: 0.
2727
Epoch 518/2000
4/4 [==============================] - 0s 945us/step - loss: 0.2801 - mse:
0.2801
Epoch 519/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2738 - mse: 0.
2738
Epoch 520/2000
4/4 [==============================] - 0s 716us/step - loss: 0.2746 - mse:
0.2746
Epoch 521/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2718 - mse: 0.
2718
Epoch 522/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2782 - mse: 0.
2782
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
34 of 113 9/23/21, 09:01
Epoch 523/2000
4/4 [==============================] - 0s 851us/step - loss: 0.2716 - mse:
0.2716
Epoch 524/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2739 - mse: 0.
2739
Epoch 525/2000
4/4 [==============================] - 0s 862us/step - loss: 0.2720 - mse:
0.2720
Epoch 526/2000
4/4 [==============================] - 0s 916us/step - loss: 0.2708 - mse:
0.2708
Epoch 527/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2716 - mse: 0.
2716
Epoch 528/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2703 - mse: 0.
2703
Epoch 529/2000
4/4 [==============================] - 0s 750us/step - loss: 0.2749 - mse:
0.2749
Epoch 530/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2712 - mse: 0.
2712
Epoch 531/2000
4/4 [==============================] - 0s 937us/step - loss: 0.2713 - mse:
0.2713
Epoch 532/2000
4/4 [==============================] - 0s 779us/step - loss: 0.2707 - mse:
0.2707
Epoch 533/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2705 - mse: 0.
2705
Epoch 534/2000
4/4 [==============================] - 0s 908us/step - loss: 0.2716 - mse:
0.2716
Epoch 535/2000
4/4 [==============================] - 0s 778us/step - loss: 0.2721 - mse:
0.2721
Epoch 536/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2700 - mse: 0.
2700
Epoch 537/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2709 - mse: 0.
2709
Epoch 538/2000
4/4 [==============================] - 0s 648us/step - loss: 0.2712 - mse:
0.2712
Epoch 539/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2732 - mse: 0.
2732
Epoch 540/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2726 - mse: 0.
2726
Epoch 541/2000
4/4 [==============================] - 0s 660us/step - loss: 0.2713 - mse:
0.2713
Epoch 542/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2718 - mse: 0.
2718
Epoch 543/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2738 - mse: 0.
2738
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
35 of 113 9/23/21, 09:01
Epoch 544/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2703 - mse: 0.
2703
Epoch 545/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2704 - mse: 0.
2704
Epoch 546/2000
4/4 [==============================] - 0s 936us/step - loss: 0.2706 - mse:
0.2706
Epoch 547/2000
4/4 [==============================] - 0s 630us/step - loss: 0.2694 - mse:
0.2694
Epoch 548/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2705 - mse: 0.
2705
Epoch 549/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2695 - mse: 0.
2695
Epoch 550/2000
4/4 [==============================] - 0s 698us/step - loss: 0.2717 - mse:
0.2717
Epoch 551/2000
4/4 [==============================] - 0s 997us/step - loss: 0.2721 - mse:
0.2721
Epoch 552/2000
4/4 [==============================] - 0s 856us/step - loss: 0.2775 - mse:
0.2775
Epoch 553/2000
4/4 [==============================] - 0s 784us/step - loss: 0.2701 - mse:
0.2701
Epoch 554/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2725 - mse: 0.
2725
Epoch 555/2000
4/4 [==============================] - 0s 845us/step - loss: 0.2689 - mse:
0.2689
Epoch 556/2000
4/4 [==============================] - 0s 720us/step - loss: 0.2691 - mse:
0.2691
Epoch 557/2000
4/4 [==============================] - 0s 2ms/step - loss: 0.2702 - mse: 0.
2702
Epoch 558/2000
4/4 [==============================] - 0s 740us/step - loss: 0.2752 - mse:
0.2752
Epoch 559/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2697 - mse: 0.
2697
Epoch 560/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2730 - mse: 0.
2730
Epoch 561/2000
4/4 [==============================] - 0s 657us/step - loss: 0.2698 - mse:
0.2698
Epoch 562/2000
4/4 [==============================] - 0s 785us/step - loss: 0.2697 - mse:
0.2697
Epoch 563/2000
4/4 [==============================] - 0s 2ms/step - loss: 0.2687 - mse: 0.
2687
Epoch 564/2000
4/4 [==============================] - 0s 769us/step - loss: 0.2705 - mse:
0.2705
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
36 of 113 9/23/21, 09:01
Epoch 565/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2704 - mse: 0.
2704
Epoch 566/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2695 - mse: 0.
2695
Epoch 567/2000
4/4 [==============================] - 0s 668us/step - loss: 0.2707 - mse:
0.2707
Epoch 568/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2743 - mse: 0.
2743
Epoch 569/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2716 - mse: 0.
2716
Epoch 570/2000
4/4 [==============================] - 0s 802us/step - loss: 0.2703 - mse:
0.2703
Epoch 571/2000
4/4 [==============================] - 0s 725us/step - loss: 0.2687 - mse:
0.2687
Epoch 572/2000
4/4 [==============================] - 0s 828us/step - loss: 0.2690 - mse:
0.2690
Epoch 573/2000
4/4 [==============================] - 0s 724us/step - loss: 0.2696 - mse:
0.2696
Epoch 574/2000
4/4 [==============================] - 0s 708us/step - loss: 0.2691 - mse:
0.2691
Epoch 575/2000
4/4 [==============================] - 0s 762us/step - loss: 0.2698 - mse:
0.2698
Epoch 576/2000
4/4 [==============================] - 0s 950us/step - loss: 0.2680 - mse:
0.2680
Epoch 577/2000
4/4 [==============================] - 0s 819us/step - loss: 0.2709 - mse:
0.2709
Epoch 578/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2680 - mse: 0.
2680
Epoch 579/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2689 - mse: 0.
2689
Epoch 580/2000
4/4 [==============================] - 0s 802us/step - loss: 0.2706 - mse:
0.2706
Epoch 581/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2691 - mse: 0.
2691
Epoch 582/2000
4/4 [==============================] - 0s 810us/step - loss: 0.2688 - mse:
0.2688
Epoch 583/2000
4/4 [==============================] - 0s 705us/step - loss: 0.2684 - mse:
0.2684
Epoch 584/2000
4/4 [==============================] - 0s 702us/step - loss: 0.2707 - mse:
0.2707
Epoch 585/2000
4/4 [==============================] - 0s 844us/step - loss: 0.2679 - mse:
0.2679
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
37 of 113 9/23/21, 09:01
Epoch 586/2000
4/4 [==============================] - 0s 673us/step - loss: 0.2689 - mse:
0.2689
Epoch 587/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2733 - mse: 0.
2733
Epoch 588/2000
4/4 [==============================] - 0s 808us/step - loss: 0.2684 - mse:
0.2684
Epoch 589/2000
4/4 [==============================] - 0s 989us/step - loss: 0.2712 - mse:
0.2712
Epoch 590/2000
4/4 [==============================] - 0s 738us/step - loss: 0.2710 - mse:
0.2710
Epoch 591/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2694 - mse: 0.
2694
Epoch 592/2000
4/4 [==============================] - 0s 950us/step - loss: 0.2683 - mse:
0.2683
Epoch 593/2000
4/4 [==============================] - 0s 776us/step - loss: 0.2705 - mse:
0.2705
Epoch 594/2000
4/4 [==============================] - 0s 935us/step - loss: 0.2707 - mse:
0.2707
Epoch 595/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2708 - mse: 0.
2708
Epoch 596/2000
4/4 [==============================] - 0s 729us/step - loss: 0.2671 - mse:
0.2671
Epoch 597/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2676 - mse: 0.
2676
Epoch 598/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2710 - mse: 0.
2710
Epoch 599/2000
4/4 [==============================] - 0s 758us/step - loss: 0.2689 - mse:
0.2689
Epoch 600/2000
4/4 [==============================] - 0s 994us/step - loss: 0.2692 - mse:
0.2692
Epoch 601/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2703 - mse: 0.
2703
Epoch 602/2000
4/4 [==============================] - 0s 823us/step - loss: 0.2699 - mse:
0.2699
Epoch 603/2000
4/4 [==============================] - 0s 818us/step - loss: 0.2674 - mse:
0.2674
Epoch 604/2000
4/4 [==============================] - 0s 876us/step - loss: 0.2668 - mse:
0.2668
Epoch 605/2000
4/4 [==============================] - 0s 786us/step - loss: 0.2668 - mse:
0.2668
Epoch 606/2000
4/4 [==============================] - 0s 708us/step - loss: 0.2714 - mse:
0.2714
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
38 of 113 9/23/21, 09:01
Epoch 607/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2695 - mse: 0.
2695
Epoch 608/2000
4/4 [==============================] - 0s 969us/step - loss: 0.2732 - mse:
0.2732
Epoch 609/2000
4/4 [==============================] - 0s 707us/step - loss: 0.2690 - mse:
0.2690
Epoch 610/2000
4/4 [==============================] - 0s 816us/step - loss: 0.2752 - mse:
0.2752
Epoch 611/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2663 - mse: 0.
2663
Epoch 612/2000
4/4 [==============================] - 0s 744us/step - loss: 0.2673 - mse:
0.2673
Epoch 613/2000
4/4 [==============================] - 0s 769us/step - loss: 0.2663 - mse:
0.2663
Epoch 614/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2672 - mse: 0.
2672
Epoch 615/2000
4/4 [==============================] - 0s 958us/step - loss: 0.2664 - mse:
0.2664
Epoch 616/2000
4/4 [==============================] - 0s 863us/step - loss: 0.2657 - mse:
0.2657
Epoch 617/2000
4/4 [==============================] - 0s 855us/step - loss: 0.2660 - mse:
0.2660
Epoch 618/2000
4/4 [==============================] - 0s 897us/step - loss: 0.2665 - mse:
0.2665
Epoch 619/2000
4/4 [==============================] - 0s 780us/step - loss: 0.2688 - mse:
0.2688
Epoch 620/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2673 - mse: 0.
2673
Epoch 621/2000
4/4 [==============================] - 0s 994us/step - loss: 0.2681 - mse:
0.2681
Epoch 622/2000
4/4 [==============================] - 0s 822us/step - loss: 0.2659 - mse:
0.2659
Epoch 623/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2657 - mse: 0.
2657
Epoch 624/2000
4/4 [==============================] - 0s 903us/step - loss: 0.2654 - mse:
0.2654
Epoch 625/2000
4/4 [==============================] - 0s 813us/step - loss: 0.2670 - mse:
0.2670
Epoch 626/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2659 - mse: 0.
2659
Epoch 627/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2667 - mse: 0.
2667
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
39 of 113 9/23/21, 09:01
Epoch 628/2000
4/4 [==============================] - 0s 804us/step - loss: 0.2674 - mse:
0.2674
Epoch 629/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2661 - mse: 0.
2661
Epoch 630/2000
4/4 [==============================] - 0s 2ms/step - loss: 0.2675 - mse: 0.
2675
Epoch 631/2000
4/4 [==============================] - 0s 753us/step - loss: 0.2656 - mse:
0.2656
Epoch 632/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2675 - mse: 0.
2675
Epoch 633/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2685 - mse: 0.
2685
Epoch 634/2000
4/4 [==============================] - 0s 842us/step - loss: 0.2657 - mse:
0.2657
Epoch 635/2000
4/4 [==============================] - 0s 2ms/step - loss: 0.2724 - mse: 0.
2724
Epoch 636/2000
4/4 [==============================] - 0s 898us/step - loss: 0.2664 - mse:
0.2664
Epoch 637/2000
4/4 [==============================] - 0s 668us/step - loss: 0.2650 - mse:
0.2650
Epoch 638/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2687 - mse: 0.
2687
Epoch 639/2000
4/4 [==============================] - 0s 773us/step - loss: 0.2693 - mse:
0.2693
Epoch 640/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2681 - mse: 0.
2681
Epoch 641/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2652 - mse: 0.
2652
Epoch 642/2000
4/4 [==============================] - 0s 966us/step - loss: 0.2668 - mse:
0.2668
Epoch 643/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2665 - mse: 0.
2665
Epoch 644/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2672 - mse: 0.
2672
Epoch 645/2000
4/4 [==============================] - 0s 705us/step - loss: 0.2653 - mse:
0.2653
Epoch 646/2000
4/4 [==============================] - 0s 945us/step - loss: 0.2664 - mse:
0.2664
Epoch 647/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2673 - mse: 0.
2673
Epoch 648/2000
4/4 [==============================] - 0s 734us/step - loss: 0.2650 - mse:
0.2650
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
40 of 113 9/23/21, 09:01
Epoch 649/2000
4/4 [==============================] - 0s 789us/step - loss: 0.2700 - mse:
0.2700
Epoch 650/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2651 - mse: 0.
2651
Epoch 651/2000
4/4 [==============================] - 0s 845us/step - loss: 0.2651 - mse:
0.2651
Epoch 652/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2650 - mse: 0.
2650
Epoch 653/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2654 - mse: 0.
2654
Epoch 654/2000
4/4 [==============================] - 0s 708us/step - loss: 0.2676 - mse:
0.2676
Epoch 655/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2669 - mse: 0.
2669
Epoch 656/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2659 - mse: 0.
2659
Epoch 657/2000
4/4 [==============================] - 0s 699us/step - loss: 0.2666 - mse:
0.2666
Epoch 658/2000
4/4 [==============================] - 0s 990us/step - loss: 0.2654 - mse:
0.2654
Epoch 659/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2670 - mse: 0.
2670
Epoch 660/2000
4/4 [==============================] - 0s 821us/step - loss: 0.2648 - mse:
0.2648
Epoch 661/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2658 - mse: 0.
2658
Epoch 662/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2665 - mse: 0.
2665
Epoch 663/2000
4/4 [==============================] - 0s 993us/step - loss: 0.2689 - mse:
0.2689
Epoch 664/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2669 - mse: 0.
2669
Epoch 665/2000
4/4 [==============================] - 0s 819us/step - loss: 0.2641 - mse:
0.2641
Epoch 666/2000
4/4 [==============================] - 0s 686us/step - loss: 0.2674 - mse:
0.2674
Epoch 667/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2647 - mse: 0.
2647
Epoch 668/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2648 - mse: 0.
2648
Epoch 669/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2633 - mse: 0.
2633
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
41 of 113 9/23/21, 09:01
Epoch 670/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2656 - mse: 0.
2656
Epoch 671/2000
4/4 [==============================] - 0s 696us/step - loss: 0.2640 - mse:
0.2640
Epoch 672/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2655 - mse: 0.
2655
Epoch 673/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2694 - mse: 0.
2694
Epoch 674/2000
4/4 [==============================] - 0s 809us/step - loss: 0.2670 - mse:
0.2670
Epoch 675/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2632 - mse: 0.
2632
Epoch 676/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2666 - mse: 0.
2666
Epoch 677/2000
4/4 [==============================] - 0s 825us/step - loss: 0.2642 - mse:
0.2642
Epoch 678/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2639 - mse: 0.
2639
Epoch 679/2000
4/4 [==============================] - 0s 926us/step - loss: 0.2654 - mse:
0.2654
Epoch 680/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2629 - mse: 0.
2629
Epoch 681/2000
4/4 [==============================] - 0s 2ms/step - loss: 0.2632 - mse: 0.
2632
Epoch 682/2000
4/4 [==============================] - 0s 739us/step - loss: 0.2631 - mse:
0.2631
Epoch 683/2000
4/4 [==============================] - 0s 732us/step - loss: 0.2634 - mse:
0.2634
Epoch 684/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2700 - mse: 0.
2700
Epoch 685/2000
4/4 [==============================] - 0s 756us/step - loss: 0.2642 - mse:
0.2642
Epoch 686/2000
4/4 [==============================] - 0s 764us/step - loss: 0.2631 - mse:
0.2631
Epoch 687/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2645 - mse: 0.
2645
Epoch 688/2000
4/4 [==============================] - 0s 750us/step - loss: 0.2678 - mse:
0.2678
Epoch 689/2000
4/4 [==============================] - 0s 819us/step - loss: 0.2638 - mse:
0.2638
Epoch 690/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2646 - mse: 0.
2646
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
42 of 113 9/23/21, 09:01
Epoch 691/2000
4/4 [==============================] - 0s 851us/step - loss: 0.2676 - mse:
0.2676
Epoch 692/2000
4/4 [==============================] - 0s 758us/step - loss: 0.2633 - mse:
0.2633
Epoch 693/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2624 - mse: 0.
2624
Epoch 694/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2652 - mse: 0.
2652
Epoch 695/2000
4/4 [==============================] - 0s 673us/step - loss: 0.2652 - mse:
0.2652
Epoch 696/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2683 - mse: 0.
2683
Epoch 697/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2663 - mse: 0.
2663
Epoch 698/2000
4/4 [==============================] - 0s 696us/step - loss: 0.2690 - mse:
0.2690
Epoch 699/2000
4/4 [==============================] - 0s 2ms/step - loss: 0.2636 - mse: 0.
2636
Epoch 700/2000
4/4 [==============================] - 0s 741us/step - loss: 0.2627 - mse:
0.2627
Epoch 701/2000
4/4 [==============================] - 0s 730us/step - loss: 0.2634 - mse:
0.2634
Epoch 702/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2641 - mse: 0.
2641
Epoch 703/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2640 - mse: 0.
2640
Epoch 704/2000
4/4 [==============================] - 0s 674us/step - loss: 0.2627 - mse:
0.2627
Epoch 705/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2618 - mse: 0.
2618
Epoch 706/2000
4/4 [==============================] - 0s 794us/step - loss: 0.2621 - mse:
0.2621
Epoch 707/2000
4/4 [==============================] - 0s 775us/step - loss: 0.2640 - mse:
0.2640
Epoch 708/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2619 - mse: 0.
2619
Epoch 709/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2655 - mse: 0.
2655
Epoch 710/2000
4/4 [==============================] - 0s 839us/step - loss: 0.2648 - mse:
0.2648
Epoch 711/2000
4/4 [==============================] - 0s 954us/step - loss: 0.2634 - mse:
0.2634
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
43 of 113 9/23/21, 09:01
Epoch 712/2000
4/4 [==============================] - 0s 2ms/step - loss: 0.2625 - mse: 0.
2625
Epoch 713/2000
4/4 [==============================] - 0s 944us/step - loss: 0.2615 - mse:
0.2615
Epoch 714/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2618 - mse: 0.
2618
Epoch 715/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2619 - mse: 0.
2619
Epoch 716/2000
4/4 [==============================] - 0s 719us/step - loss: 0.2620 - mse:
0.2620
Epoch 717/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2611 - mse: 0.
2611
Epoch 718/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2647 - mse: 0.
2647
Epoch 719/2000
4/4 [==============================] - 0s 850us/step - loss: 0.2626 - mse:
0.2626
Epoch 720/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2631 - mse: 0.
2631
Epoch 721/2000
4/4 [==============================] - 0s 827us/step - loss: 0.2619 - mse:
0.2619
Epoch 722/2000
4/4 [==============================] - 0s 736us/step - loss: 0.2653 - mse:
0.2653
Epoch 723/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2616 - mse: 0.
2616
Epoch 724/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2641 - mse: 0.
2641
Epoch 725/2000
4/4 [==============================] - 0s 692us/step - loss: 0.2614 - mse:
0.2614
Epoch 726/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2609 - mse: 0.
2609
Epoch 727/2000
4/4 [==============================] - 0s 767us/step - loss: 0.2619 - mse:
0.2619
Epoch 728/2000
4/4 [==============================] - 0s 987us/step - loss: 0.2641 - mse:
0.2641
Epoch 729/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2638 - mse: 0.
2638
Epoch 730/2000
4/4 [==============================] - 0s 726us/step - loss: 0.2758 - mse:
0.2758
Epoch 731/2000
4/4 [==============================] - 0s 659us/step - loss: 0.2608 - mse:
0.2608
Epoch 732/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2623 - mse: 0.
2623
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
44 of 113 9/23/21, 09:01
Epoch 733/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2664 - mse: 0.
2664
Epoch 734/2000
4/4 [==============================] - 0s 742us/step - loss: 0.2606 - mse:
0.2606
Epoch 735/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2638 - mse: 0.
2638
Epoch 736/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2616 - mse: 0.
2616
Epoch 737/2000
4/4 [==============================] - 0s 757us/step - loss: 0.2634 - mse:
0.2634
Epoch 738/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2632 - mse: 0.
2632
Epoch 739/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2709 - mse: 0.
2709
Epoch 740/2000
4/4 [==============================] - 0s 799us/step - loss: 0.2623 - mse:
0.2623
Epoch 741/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2606 - mse: 0.
2606
Epoch 742/2000
4/4 [==============================] - 0s 781us/step - loss: 0.2619 - mse:
0.2619
Epoch 743/2000
4/4 [==============================] - 0s 676us/step - loss: 0.2605 - mse:
0.2605
Epoch 744/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2596 - mse: 0.
2596
Epoch 745/2000
4/4 [==============================] - 0s 957us/step - loss: 0.2606 - mse:
0.2606
Epoch 746/2000
4/4 [==============================] - 0s 770us/step - loss: 0.2604 - mse:
0.2604
Epoch 747/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2678 - mse: 0.
2678
Epoch 748/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2647 - mse: 0.
2647
Epoch 749/2000
4/4 [==============================] - 0s 695us/step - loss: 0.2614 - mse:
0.2614
Epoch 750/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2664 - mse: 0.
2664
Epoch 751/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2703 - mse: 0.
2703
Epoch 752/2000
4/4 [==============================] - 0s 763us/step - loss: 0.2611 - mse:
0.2611
Epoch 753/2000
4/4 [==============================] - 0s 943us/step - loss: 0.2600 - mse:
0.2600
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
45 of 113 9/23/21, 09:01
Epoch 754/2000
4/4 [==============================] - 0s 921us/step - loss: 0.2591 - mse:
0.2591
Epoch 755/2000
4/4 [==============================] - 0s 748us/step - loss: 0.2601 - mse:
0.2601
Epoch 756/2000
4/4 [==============================] - 0s 2ms/step - loss: 0.2595 - mse: 0.
2595
Epoch 757/2000
4/4 [==============================] - 0s 973us/step - loss: 0.2599 - mse:
0.2599
Epoch 758/2000
4/4 [==============================] - 0s 876us/step - loss: 0.2608 - mse:
0.2608
Epoch 759/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2645 - mse: 0.
2645
Epoch 760/2000
4/4 [==============================] - 0s 944us/step - loss: 0.2605 - mse:
0.2605
Epoch 761/2000
4/4 [==============================] - 0s 786us/step - loss: 0.2588 - mse:
0.2588
Epoch 762/2000
4/4 [==============================] - 0s 981us/step - loss: 0.2590 - mse:
0.2590
Epoch 763/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2592 - mse: 0.
2592
Epoch 764/2000
4/4 [==============================] - 0s 771us/step - loss: 0.2623 - mse:
0.2623
Epoch 765/2000
4/4 [==============================] - 0s 932us/step - loss: 0.2626 - mse:
0.2626
Epoch 766/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2603 - mse: 0.
2603
Epoch 767/2000
4/4 [==============================] - 0s 795us/step - loss: 0.2611 - mse:
0.2611
Epoch 768/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2600 - mse: 0.
2600
Epoch 769/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2659 - mse: 0.
2659
Epoch 770/2000
4/4 [==============================] - 0s 676us/step - loss: 0.2581 - mse:
0.2581
Epoch 771/2000
4/4 [==============================] - 0s 803us/step - loss: 0.2597 - mse:
0.2597
Epoch 772/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2592 - mse: 0.
2592
Epoch 773/2000
4/4 [==============================] - 0s 789us/step - loss: 0.2589 - mse:
0.2589
Epoch 774/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2605 - mse: 0.
2605
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
46 of 113 9/23/21, 09:01
Epoch 775/2000
4/4 [==============================] - 0s 889us/step - loss: 0.2591 - mse:
0.2591
Epoch 776/2000
4/4 [==============================] - 0s 848us/step - loss: 0.2591 - mse:
0.2591
Epoch 777/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2618 - mse: 0.
2618
Epoch 778/2000
4/4 [==============================] - 0s 804us/step - loss: 0.2651 - mse:
0.2651
Epoch 779/2000
4/4 [==============================] - 0s 852us/step - loss: 0.2589 - mse:
0.2589
Epoch 780/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2599 - mse: 0.
2599
Epoch 781/2000
4/4 [==============================] - 0s 947us/step - loss: 0.2635 - mse:
0.2635
Epoch 782/2000
4/4 [==============================] - 0s 785us/step - loss: 0.2588 - mse:
0.2588
Epoch 783/2000
4/4 [==============================] - 0s 984us/step - loss: 0.2601 - mse:
0.2601
Epoch 784/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2578 - mse: 0.
2578
Epoch 785/2000
4/4 [==============================] - 0s 681us/step - loss: 0.2596 - mse:
0.2596
Epoch 786/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2577 - mse: 0.
2577
Epoch 787/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2583 - mse: 0.
2583
Epoch 788/2000
4/4 [==============================] - 0s 733us/step - loss: 0.2580 - mse:
0.2580
Epoch 789/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2575 - mse: 0.
2575
Epoch 790/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2573 - mse: 0.
2573
Epoch 791/2000
4/4 [==============================] - 0s 676us/step - loss: 0.2580 - mse:
0.2580
Epoch 792/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2653 - mse: 0.
2653
Epoch 793/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2587 - mse: 0.
2587
Epoch 794/2000
4/4 [==============================] - 0s 707us/step - loss: 0.2584 - mse:
0.2584
Epoch 795/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2575 - mse: 0.
2575
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
47 of 113 9/23/21, 09:01
Epoch 796/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2658 - mse: 0.
2658
Epoch 797/2000
4/4 [==============================] - 0s 843us/step - loss: 0.2594 - mse:
0.2594
Epoch 798/2000
4/4 [==============================] - 0s 871us/step - loss: 0.2572 - mse:
0.2572
Epoch 799/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2597 - mse: 0.
2597
Epoch 800/2000
4/4 [==============================] - 0s 904us/step - loss: 0.2597 - mse:
0.2597
Epoch 801/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2576 - mse: 0.
2576
Epoch 802/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2567 - mse: 0.
2567
Epoch 803/2000
4/4 [==============================] - 0s 700us/step - loss: 0.2603 - mse:
0.2603
Epoch 804/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2577 - mse: 0.
2577
Epoch 805/2000
4/4 [==============================] - 0s 879us/step - loss: 0.2583 - mse:
0.2583
Epoch 806/2000
4/4 [==============================] - 0s 792us/step - loss: 0.2572 - mse:
0.2572
Epoch 807/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2599 - mse: 0.
2599
Epoch 808/2000
4/4 [==============================] - 0s 839us/step - loss: 0.2583 - mse:
0.2583
Epoch 809/2000
4/4 [==============================] - 0s 651us/step - loss: 0.2587 - mse:
0.2587
Epoch 810/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2594 - mse: 0.
2594
Epoch 811/2000
4/4 [==============================] - 0s 978us/step - loss: 0.2580 - mse:
0.2580
Epoch 812/2000
4/4 [==============================] - 0s 785us/step - loss: 0.2564 - mse:
0.2564
Epoch 813/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2600 - mse: 0.
2600
Epoch 814/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2574 - mse: 0.
2574
Epoch 815/2000
4/4 [==============================] - 0s 703us/step - loss: 0.2569 - mse:
0.2569
Epoch 816/2000
4/4 [==============================] - 0s 986us/step - loss: 0.2562 - mse:
0.2562
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
48 of 113 9/23/21, 09:01
Epoch 817/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2568 - mse: 0.
2568
Epoch 818/2000
4/4 [==============================] - 0s 650us/step - loss: 0.2631 - mse:
0.2631
Epoch 819/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2563 - mse: 0.
2563
Epoch 820/2000
4/4 [==============================] - 0s 943us/step - loss: 0.2581 - mse:
0.2581
Epoch 821/2000
4/4 [==============================] - 0s 751us/step - loss: 0.2592 - mse:
0.2592
Epoch 822/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2588 - mse: 0.
2588
Epoch 823/2000
4/4 [==============================] - 0s 958us/step - loss: 0.2575 - mse:
0.2575
Epoch 824/2000
4/4 [==============================] - 0s 901us/step - loss: 0.2593 - mse:
0.2593
Epoch 825/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2559 - mse: 0.
2559
Epoch 826/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2566 - mse: 0.
2566
Epoch 827/2000
4/4 [==============================] - 0s 746us/step - loss: 0.2559 - mse:
0.2559
Epoch 828/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2567 - mse: 0.
2567
Epoch 829/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2556 - mse: 0.
2556
Epoch 830/2000
4/4 [==============================] - 0s 731us/step - loss: 0.2557 - mse:
0.2557
Epoch 831/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2569 - mse: 0.
2569
Epoch 832/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2563 - mse: 0.
2563
Epoch 833/2000
4/4 [==============================] - 0s 811us/step - loss: 0.2581 - mse:
0.2581
Epoch 834/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2585 - mse: 0.
2585
Epoch 835/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2560 - mse: 0.
2560
Epoch 836/2000
4/4 [==============================] - 0s 809us/step - loss: 0.2552 - mse:
0.2552
Epoch 837/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2588 - mse: 0.
2588
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
49 of 113 9/23/21, 09:01
Epoch 838/2000
4/4 [==============================] - 0s 848us/step - loss: 0.2577 - mse:
0.2577
Epoch 839/2000
4/4 [==============================] - 0s 917us/step - loss: 0.2578 - mse:
0.2578
Epoch 840/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2564 - mse: 0.
2564
Epoch 841/2000
4/4 [==============================] - 0s 985us/step - loss: 0.2559 - mse:
0.2559
Epoch 842/2000
4/4 [==============================] - 0s 716us/step - loss: 0.2553 - mse:
0.2553
Epoch 843/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2552 - mse: 0.
2552
Epoch 844/2000
4/4 [==============================] - 0s 897us/step - loss: 0.2557 - mse:
0.2557
Epoch 845/2000
4/4 [==============================] - 0s 764us/step - loss: 0.2550 - mse:
0.2550
Epoch 846/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2566 - mse: 0.
2566
Epoch 847/2000
4/4 [==============================] - 0s 739us/step - loss: 0.2591 - mse:
0.2591
Epoch 848/2000
4/4 [==============================] - 0s 758us/step - loss: 0.2571 - mse:
0.2571
Epoch 849/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2568 - mse: 0.
2568
Epoch 850/2000
4/4 [==============================] - 0s 733us/step - loss: 0.2550 - mse:
0.2550
Epoch 851/2000
4/4 [==============================] - 0s 639us/step - loss: 0.2555 - mse:
0.2555
Epoch 852/2000
4/4 [==============================] - 0s 993us/step - loss: 0.2555 - mse:
0.2555
Epoch 853/2000
4/4 [==============================] - 0s 832us/step - loss: 0.2548 - mse:
0.2548
Epoch 854/2000
4/4 [==============================] - 0s 717us/step - loss: 0.2552 - mse:
0.2552
Epoch 855/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2583 - mse: 0.
2583
Epoch 856/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2554 - mse: 0.
2554
Epoch 857/2000
4/4 [==============================] - 0s 751us/step - loss: 0.2559 - mse:
0.2559
Epoch 858/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2558 - mse: 0.
2558
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
50 of 113 9/23/21, 09:01
Epoch 859/2000
4/4 [==============================] - 0s 719us/step - loss: 0.2546 - mse:
0.2546
Epoch 860/2000
4/4 [==============================] - 0s 697us/step - loss: 0.2567 - mse:
0.2567
Epoch 861/2000
4/4 [==============================] - 0s 2ms/step - loss: 0.2550 - mse: 0.
2550
Epoch 862/2000
4/4 [==============================] - 0s 779us/step - loss: 0.2544 - mse:
0.2544
Epoch 863/2000
4/4 [==============================] - 0s 693us/step - loss: 0.2556 - mse:
0.2556
Epoch 864/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2545 - mse: 0.
2545
Epoch 865/2000
4/4 [==============================] - 0s 779us/step - loss: 0.2585 - mse:
0.2585
Epoch 866/2000
4/4 [==============================] - 0s 876us/step - loss: 0.2541 - mse:
0.2541
Epoch 867/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2556 - mse: 0.
2556
Epoch 868/2000
4/4 [==============================] - 0s 858us/step - loss: 0.2552 - mse:
0.2552
Epoch 869/2000
4/4 [==============================] - 0s 737us/step - loss: 0.2549 - mse:
0.2549
Epoch 870/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2555 - mse: 0.
2555
Epoch 871/2000
4/4 [==============================] - 0s 676us/step - loss: 0.2538 - mse:
0.2538
Epoch 872/2000
4/4 [==============================] - 0s 919us/step - loss: 0.2547 - mse:
0.2547
Epoch 873/2000
4/4 [==============================] - 0s 2ms/step - loss: 0.2541 - mse: 0.
2541
Epoch 874/2000
4/4 [==============================] - 0s 750us/step - loss: 0.2550 - mse:
0.2550
Epoch 875/2000
4/4 [==============================] - 0s 734us/step - loss: 0.2540 - mse:
0.2540
Epoch 876/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2541 - mse: 0.
2541
Epoch 877/2000
4/4 [==============================] - 0s 883us/step - loss: 0.2562 - mse:
0.2562
Epoch 878/2000
4/4 [==============================] - 0s 811us/step - loss: 0.2536 - mse:
0.2536
Epoch 879/2000
4/4 [==============================] - 0s 2ms/step - loss: 0.2543 - mse: 0.
2543
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
51 of 113 9/23/21, 09:01
Epoch 880/2000
4/4 [==============================] - 0s 715us/step - loss: 0.2545 - mse:
0.2545
Epoch 881/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2544 - mse: 0.
2544
Epoch 882/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2545 - mse: 0.
2545
Epoch 883/2000
4/4 [==============================] - 0s 759us/step - loss: 0.2539 - mse:
0.2539
Epoch 884/2000
4/4 [==============================] - 0s 704us/step - loss: 0.2530 - mse:
0.2530
Epoch 885/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2542 - mse: 0.
2542
Epoch 886/2000
4/4 [==============================] - 0s 772us/step - loss: 0.2561 - mse:
0.2561
Epoch 887/2000
4/4 [==============================] - 0s 720us/step - loss: 0.2538 - mse:
0.2538
Epoch 888/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2537 - mse: 0.
2537
Epoch 889/2000
4/4 [==============================] - 0s 920us/step - loss: 0.2546 - mse:
0.2546
Epoch 890/2000
4/4 [==============================] - 0s 905us/step - loss: 0.2546 - mse:
0.2546
Epoch 891/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2697 - mse: 0.
2697
Epoch 892/2000
4/4 [==============================] - 0s 880us/step - loss: 0.2561 - mse:
0.2561
Epoch 893/2000
4/4 [==============================] - 0s 707us/step - loss: 0.2541 - mse:
0.2541
Epoch 894/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2551 - mse: 0.
2551
Epoch 895/2000
4/4 [==============================] - 0s 916us/step - loss: 0.2544 - mse:
0.2544
Epoch 896/2000
4/4 [==============================] - 0s 781us/step - loss: 0.2530 - mse:
0.2530
Epoch 897/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2548 - mse: 0.
2548
Epoch 898/2000
4/4 [==============================] - 0s 697us/step - loss: 0.2562 - mse:
0.2562
Epoch 899/2000
4/4 [==============================] - 0s 710us/step - loss: 0.2535 - mse:
0.2535
Epoch 900/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2553 - mse: 0.
2553
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
52 of 113 9/23/21, 09:01
Epoch 901/2000
4/4 [==============================] - 0s 661us/step - loss: 0.2541 - mse:
0.2541
Epoch 902/2000
4/4 [==============================] - 0s 635us/step - loss: 0.2528 - mse:
0.2528
Epoch 903/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2522 - mse: 0.
2522
Epoch 904/2000
4/4 [==============================] - 0s 832us/step - loss: 0.2533 - mse:
0.2533
Epoch 905/2000
4/4 [==============================] - 0s 678us/step - loss: 0.2538 - mse:
0.2538
Epoch 906/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2541 - mse: 0.
2541
Epoch 907/2000
4/4 [==============================] - 0s 677us/step - loss: 0.2540 - mse:
0.2540
Epoch 908/2000
4/4 [==============================] - 0s 812us/step - loss: 0.2535 - mse:
0.2535
Epoch 909/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2545 - mse: 0.
2545
Epoch 910/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2522 - mse: 0.
2522
Epoch 911/2000
4/4 [==============================] - 0s 845us/step - loss: 0.2561 - mse:
0.2561
Epoch 912/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2558 - mse: 0.
2558
Epoch 913/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2524 - mse: 0.
2524
Epoch 914/2000
4/4 [==============================] - 0s 748us/step - loss: 0.2515 - mse:
0.2515
Epoch 915/2000
4/4 [==============================] - 0s 792us/step - loss: 0.2531 - mse:
0.2531
Epoch 916/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2532 - mse: 0.
2532
Epoch 917/2000
4/4 [==============================] - 0s 703us/step - loss: 0.2530 - mse:
0.2530
Epoch 918/2000
4/4 [==============================] - 0s 795us/step - loss: 0.2523 - mse:
0.2523
Epoch 919/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2514 - mse: 0.
2514
Epoch 920/2000
4/4 [==============================] - 0s 683us/step - loss: 0.2557 - mse:
0.2557
Epoch 921/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2571 - mse: 0.
2571
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
53 of 113 9/23/21, 09:01
Epoch 922/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2562 - mse: 0.
2562
Epoch 923/2000
4/4 [==============================] - 0s 874us/step - loss: 0.2582 - mse:
0.2582
Epoch 924/2000
4/4 [==============================] - 0s 728us/step - loss: 0.2575 - mse:
0.2575
Epoch 925/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2533 - mse: 0.
2533
Epoch 926/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2516 - mse: 0.
2516
Epoch 927/2000
4/4 [==============================] - 0s 900us/step - loss: 0.2530 - mse:
0.2530
Epoch 928/2000
4/4 [==============================] - 0s 2ms/step - loss: 0.2521 - mse: 0.
2521
Epoch 929/2000
4/4 [==============================] - 0s 664us/step - loss: 0.2521 - mse:
0.2521
Epoch 930/2000
4/4 [==============================] - 0s 903us/step - loss: 0.2525 - mse:
0.2525
Epoch 931/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2548 - mse: 0.
2548
Epoch 932/2000
4/4 [==============================] - 0s 748us/step - loss: 0.2521 - mse:
0.2521
Epoch 933/2000
4/4 [==============================] - 0s 649us/step - loss: 0.2511 - mse:
0.2511
Epoch 934/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2529 - mse: 0.
2529
Epoch 935/2000
4/4 [==============================] - 0s 818us/step - loss: 0.2557 - mse:
0.2557
Epoch 936/2000
4/4 [==============================] - 0s 685us/step - loss: 0.2522 - mse:
0.2522
Epoch 937/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2533 - mse: 0.
2533
Epoch 938/2000
4/4 [==============================] - 0s 817us/step - loss: 0.2517 - mse:
0.2517
Epoch 939/2000
4/4 [==============================] - 0s 905us/step - loss: 0.2516 - mse:
0.2516
Epoch 940/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2519 - mse: 0.
2519
Epoch 941/2000
4/4 [==============================] - 0s 945us/step - loss: 0.2510 - mse:
0.2510
Epoch 942/2000
4/4 [==============================] - 0s 840us/step - loss: 0.2507 - mse:
0.2507
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
54 of 113 9/23/21, 09:01
Epoch 943/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2508 - mse: 0.
2508
Epoch 944/2000
4/4 [==============================] - 0s 857us/step - loss: 0.2524 - mse:
0.2524
Epoch 945/2000
4/4 [==============================] - 0s 636us/step - loss: 0.2506 - mse:
0.2506
Epoch 946/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2520 - mse: 0.
2520
Epoch 947/2000
4/4 [==============================] - 0s 938us/step - loss: 0.2541 - mse:
0.2541
Epoch 948/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2527 - mse: 0.
2527
Epoch 949/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2532 - mse: 0.
2532
Epoch 950/2000
4/4 [==============================] - 0s 966us/step - loss: 0.2507 - mse:
0.2507
Epoch 951/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2504 - mse: 0.
2504
Epoch 952/2000
4/4 [==============================] - 0s 929us/step - loss: 0.2512 - mse:
0.2512
Epoch 953/2000
4/4 [==============================] - 0s 678us/step - loss: 0.2511 - mse:
0.2511
Epoch 954/2000
4/4 [==============================] - 0s 2ms/step - loss: 0.2513 - mse: 0.
2513
Epoch 955/2000
4/4 [==============================] - 0s 881us/step - loss: 0.2497 - mse:
0.2497
Epoch 956/2000
4/4 [==============================] - 0s 999us/step - loss: 0.2502 - mse:
0.2502
Epoch 957/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2506 - mse: 0.
2506
Epoch 958/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2514 - mse: 0.
2514
Epoch 959/2000
4/4 [==============================] - 0s 944us/step - loss: 0.2508 - mse:
0.2508
Epoch 960/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2523 - mse: 0.
2523
Epoch 961/2000
4/4 [==============================] - 0s 760us/step - loss: 0.2571 - mse:
0.2571
Epoch 962/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2571 - mse: 0.
2571
Epoch 963/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2504 - mse: 0.
2504
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
55 of 113 9/23/21, 09:01
Epoch 964/2000
4/4 [==============================] - 0s 793us/step - loss: 0.2499 - mse:
0.2499
Epoch 965/2000
4/4 [==============================] - 0s 998us/step - loss: 0.2519 - mse:
0.2519
Epoch 966/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2512 - mse: 0.
2512
Epoch 967/2000
4/4 [==============================] - 0s 656us/step - loss: 0.2507 - mse:
0.2507
Epoch 968/2000
4/4 [==============================] - 0s 803us/step - loss: 0.2494 - mse:
0.2494
Epoch 969/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2540 - mse: 0.
2540
Epoch 970/2000
4/4 [==============================] - 0s 859us/step - loss: 0.2507 - mse:
0.2507
Epoch 971/2000
4/4 [==============================] - 0s 970us/step - loss: 0.2510 - mse:
0.2510
Epoch 972/2000
4/4 [==============================] - 0s 932us/step - loss: 0.2496 - mse:
0.2496
Epoch 973/2000
4/4 [==============================] - 0s 910us/step - loss: 0.2493 - mse:
0.2493
Epoch 974/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2495 - mse: 0.
2495
Epoch 975/2000
4/4 [==============================] - 0s 976us/step - loss: 0.2501 - mse:
0.2501
Epoch 976/2000
4/4 [==============================] - 0s 701us/step - loss: 0.2554 - mse:
0.2554
Epoch 977/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2517 - mse: 0.
2517
Epoch 978/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2559 - mse: 0.
2559
Epoch 979/2000
4/4 [==============================] - 0s 661us/step - loss: 0.2496 - mse:
0.2496
Epoch 980/2000
4/4 [==============================] - 0s 922us/step - loss: 0.2510 - mse:
0.2510
Epoch 981/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2539 - mse: 0.
2539
Epoch 982/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2488 - mse: 0.
2488
Epoch 983/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2495 - mse: 0.
2495
Epoch 984/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2543 - mse: 0.
2543
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
56 of 113 9/23/21, 09:01
Epoch 985/2000
4/4 [==============================] - 0s 898us/step - loss: 0.2492 - mse:
0.2492
Epoch 986/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2491 - mse: 0.
2491
Epoch 987/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2495 - mse: 0.
2495
Epoch 988/2000
4/4 [==============================] - 0s 847us/step - loss: 0.2504 - mse:
0.2504
Epoch 989/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2484 - mse: 0.
2484
Epoch 990/2000
4/4 [==============================] - 0s 964us/step - loss: 0.2485 - mse:
0.2485
Epoch 991/2000
4/4 [==============================] - 0s 910us/step - loss: 0.2483 - mse:
0.2483
Epoch 992/2000
4/4 [==============================] - 0s 986us/step - loss: 0.2487 - mse:
0.2487
Epoch 993/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2500 - mse: 0.
2500
Epoch 994/2000
4/4 [==============================] - 0s 637us/step - loss: 0.2499 - mse:
0.2499
Epoch 995/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2489 - mse: 0.
2489
Epoch 996/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2485 - mse: 0.
2485
Epoch 997/2000
4/4 [==============================] - 0s 963us/step - loss: 0.2504 - mse:
0.2504
Epoch 998/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2498 - mse: 0.
2498
Epoch 999/2000
4/4 [==============================] - 0s 884us/step - loss: 0.2491 - mse:
0.2491
Epoch 1000/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2497 - mse: 0.
2497
Epoch 1001/2000
4/4 [==============================] - 0s 993us/step - loss: 0.2483 - mse:
0.2483
Epoch 1002/2000
4/4 [==============================] - 0s 642us/step - loss: 0.2525 - mse:
0.2525
Epoch 1003/2000
4/4 [==============================] - 0s 816us/step - loss: 0.2511 - mse:
0.2511
Epoch 1004/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2477 - mse: 0.
2477
Epoch 1005/2000
4/4 [==============================] - 0s 867us/step - loss: 0.2511 - mse:
0.2511
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
57 of 113 9/23/21, 09:01
Epoch 1006/2000
4/4 [==============================] - 0s 977us/step - loss: 0.2572 - mse:
0.2572
Epoch 1007/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2597 - mse: 0.
2597
Epoch 1008/2000
4/4 [==============================] - 0s 999us/step - loss: 0.2524 - mse:
0.2524
Epoch 1009/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2482 - mse: 0.
2482
Epoch 1010/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2529 - mse: 0.
2529
Epoch 1011/2000
4/4 [==============================] - 0s 854us/step - loss: 0.2483 - mse:
0.2483
Epoch 1012/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2503 - mse: 0.
2503
Epoch 1013/2000
4/4 [==============================] - 0s 649us/step - loss: 0.2517 - mse:
0.2517
Epoch 1014/2000
4/4 [==============================] - 0s 753us/step - loss: 0.2478 - mse:
0.2478
Epoch 1015/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2480 - mse: 0.
2480
Epoch 1016/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2507 - mse: 0.
2507
Epoch 1017/2000
4/4 [==============================] - 0s 694us/step - loss: 0.2475 - mse:
0.2475
Epoch 1018/2000
4/4 [==============================] - 0s 929us/step - loss: 0.2507 - mse:
0.2507
Epoch 1019/2000
4/4 [==============================] - 0s 919us/step - loss: 0.2474 - mse:
0.2474
Epoch 1020/2000
4/4 [==============================] - 0s 733us/step - loss: 0.2473 - mse:
0.2473
Epoch 1021/2000
4/4 [==============================] - 0s 992us/step - loss: 0.2526 - mse:
0.2526
Epoch 1022/2000
4/4 [==============================] - 0s 971us/step - loss: 0.2523 - mse:
0.2523
Epoch 1023/2000
4/4 [==============================] - 0s 739us/step - loss: 0.2528 - mse:
0.2528
Epoch 1024/2000
4/4 [==============================] - 0s 799us/step - loss: 0.2517 - mse:
0.2517
Epoch 1025/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2467 - mse: 0.
2467
Epoch 1026/2000
4/4 [==============================] - 0s 741us/step - loss: 0.2468 - mse:
0.2468
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
58 of 113 9/23/21, 09:01
Epoch 1027/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2467 - mse: 0.
2467
Epoch 1028/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2502 - mse: 0.
2502
Epoch 1029/2000
4/4 [==============================] - 0s 881us/step - loss: 0.2473 - mse:
0.2473
Epoch 1030/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2467 - mse: 0.
2467
Epoch 1031/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2504 - mse: 0.
2504
Epoch 1032/2000
4/4 [==============================] - 0s 890us/step - loss: 0.2477 - mse:
0.2477
Epoch 1033/2000
4/4 [==============================] - 0s 797us/step - loss: 0.2476 - mse:
0.2476
Epoch 1034/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2480 - mse: 0.
2480
Epoch 1035/2000
4/4 [==============================] - 0s 679us/step - loss: 0.2468 - mse:
0.2468
Epoch 1036/2000
4/4 [==============================] - 0s 763us/step - loss: 0.2482 - mse:
0.2482
Epoch 1037/2000
4/4 [==============================] - 0s 2ms/step - loss: 0.2535 - mse: 0.
2535
Epoch 1038/2000
4/4 [==============================] - 0s 810us/step - loss: 0.2498 - mse:
0.2498
Epoch 1039/2000
4/4 [==============================] - 0s 654us/step - loss: 0.2516 - mse:
0.2516
Epoch 1040/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2468 - mse: 0.
2468
Epoch 1041/2000
4/4 [==============================] - 0s 868us/step - loss: 0.2461 - mse:
0.2461
Epoch 1042/2000
4/4 [==============================] - 0s 671us/step - loss: 0.2475 - mse:
0.2475
Epoch 1043/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2460 - mse: 0.
2460
Epoch 1044/2000
4/4 [==============================] - 0s 838us/step - loss: 0.2468 - mse:
0.2468
Epoch 1045/2000
4/4 [==============================] - 0s 797us/step - loss: 0.2461 - mse:
0.2461
Epoch 1046/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2467 - mse: 0.
2467
Epoch 1047/2000
4/4 [==============================] - 0s 902us/step - loss: 0.2509 - mse:
0.2509
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
59 of 113 9/23/21, 09:01
Epoch 1048/2000
4/4 [==============================] - 0s 727us/step - loss: 0.2530 - mse:
0.2530
Epoch 1049/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2512 - mse: 0.
2512
Epoch 1050/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2481 - mse: 0.
2481
Epoch 1051/2000
4/4 [==============================] - 0s 739us/step - loss: 0.2467 - mse:
0.2467
Epoch 1052/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2463 - mse: 0.
2463
Epoch 1053/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2507 - mse: 0.
2507
Epoch 1054/2000
4/4 [==============================] - 0s 769us/step - loss: 0.2486 - mse:
0.2486
Epoch 1055/2000
4/4 [==============================] - 0s 833us/step - loss: 0.2520 - mse:
0.2520
Epoch 1056/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2458 - mse: 0.
2458
Epoch 1057/2000
4/4 [==============================] - 0s 841us/step - loss: 0.2526 - mse:
0.2526
Epoch 1058/2000
4/4 [==============================] - 0s 733us/step - loss: 0.2460 - mse:
0.2460
Epoch 1059/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2504 - mse: 0.
2504
Epoch 1060/2000
4/4 [==============================] - 0s 721us/step - loss: 0.2545 - mse:
0.2545
Epoch 1061/2000
4/4 [==============================] - 0s 751us/step - loss: 0.2451 - mse:
0.2451
Epoch 1062/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2461 - mse: 0.
2461
Epoch 1063/2000
4/4 [==============================] - 0s 931us/step - loss: 0.2455 - mse:
0.2455
Epoch 1064/2000
4/4 [==============================] - 0s 702us/step - loss: 0.2452 - mse:
0.2452
Epoch 1065/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2467 - mse: 0.
2467
Epoch 1066/2000
4/4 [==============================] - 0s 925us/step - loss: 0.2465 - mse:
0.2465
Epoch 1067/2000
4/4 [==============================] - 0s 628us/step - loss: 0.2523 - mse:
0.2523
Epoch 1068/2000
4/4 [==============================] - 0s 970us/step - loss: 0.2522 - mse:
0.2522
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
60 of 113 9/23/21, 09:01
Epoch 1069/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2488 - mse: 0.
2488
Epoch 1070/2000
4/4 [==============================] - 0s 791us/step - loss: 0.2470 - mse:
0.2470
Epoch 1071/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2500 - mse: 0.
2500
Epoch 1072/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2492 - mse: 0.
2492
Epoch 1073/2000
4/4 [==============================] - 0s 718us/step - loss: 0.2466 - mse:
0.2466
Epoch 1074/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2453 - mse: 0.
2453
Epoch 1075/2000
4/4 [==============================] - 0s 948us/step - loss: 0.2465 - mse:
0.2465
Epoch 1076/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2475 - mse: 0.
2475
Epoch 1077/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2454 - mse: 0.
2454
Epoch 1078/2000
4/4 [==============================] - 0s 908us/step - loss: 0.2457 - mse:
0.2457
Epoch 1079/2000
4/4 [==============================] - 0s 717us/step - loss: 0.2461 - mse:
0.2461
Epoch 1080/2000
4/4 [==============================] - 0s 853us/step - loss: 0.2450 - mse:
0.2450
Epoch 1081/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2448 - mse: 0.
2448
Epoch 1082/2000
4/4 [==============================] - 0s 821us/step - loss: 0.2459 - mse:
0.2459
Epoch 1083/2000
4/4 [==============================] - 0s 649us/step - loss: 0.2484 - mse:
0.2484
Epoch 1084/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2465 - mse: 0.
2465
Epoch 1085/2000
4/4 [==============================] - 0s 767us/step - loss: 0.2463 - mse:
0.2463
Epoch 1086/2000
4/4 [==============================] - 0s 692us/step - loss: 0.2454 - mse:
0.2454
Epoch 1087/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2453 - mse: 0.
2453
Epoch 1088/2000
4/4 [==============================] - 0s 798us/step - loss: 0.2463 - mse:
0.2463
Epoch 1089/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2470 - mse: 0.
2470
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
61 of 113 9/23/21, 09:01
Epoch 1090/2000
4/4 [==============================] - 0s 2ms/step - loss: 0.2447 - mse: 0.
2447
Epoch 1091/2000
4/4 [==============================] - 0s 824us/step - loss: 0.2480 - mse:
0.2480
Epoch 1092/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2506 - mse: 0.
2506
Epoch 1093/2000
4/4 [==============================] - 0s 798us/step - loss: 0.2469 - mse:
0.2469
Epoch 1094/2000
4/4 [==============================] - 0s 734us/step - loss: 0.2461 - mse:
0.2461
Epoch 1095/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2439 - mse: 0.
2439
Epoch 1096/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2497 - mse: 0.
2497
Epoch 1097/2000
4/4 [==============================] - 0s 751us/step - loss: 0.2463 - mse:
0.2463
Epoch 1098/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2503 - mse: 0.
2503
Epoch 1099/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2458 - mse: 0.
2458
Epoch 1100/2000
4/4 [==============================] - 0s 857us/step - loss: 0.2460 - mse:
0.2460
Epoch 1101/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2459 - mse: 0.
2459
Epoch 1102/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2458 - mse: 0.
2458
Epoch 1103/2000
4/4 [==============================] - 0s 758us/step - loss: 0.2462 - mse:
0.2462
Epoch 1104/2000
4/4 [==============================] - 0s 882us/step - loss: 0.2509 - mse:
0.2509
Epoch 1105/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2438 - mse: 0.
2438
Epoch 1106/2000
4/4 [==============================] - 0s 717us/step - loss: 0.2446 - mse:
0.2446
Epoch 1107/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2436 - mse: 0.
2436
Epoch 1108/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2436 - mse: 0.
2436
Epoch 1109/2000
4/4 [==============================] - 0s 733us/step - loss: 0.2437 - mse:
0.2437
Epoch 1110/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2454 - mse: 0.
2454
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
62 of 113 9/23/21, 09:01
Epoch 1111/2000
4/4 [==============================] - 0s 975us/step - loss: 0.2440 - mse:
0.2440
Epoch 1112/2000
4/4 [==============================] - 0s 681us/step - loss: 0.2430 - mse:
0.2430
Epoch 1113/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2445 - mse: 0.
2445
Epoch 1114/2000
4/4 [==============================] - 0s 821us/step - loss: 0.2466 - mse:
0.2466
Epoch 1115/2000
4/4 [==============================] - 0s 769us/step - loss: 0.2428 - mse:
0.2428
Epoch 1116/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2436 - mse: 0.
2436
Epoch 1117/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2434 - mse: 0.
2434
Epoch 1118/2000
4/4 [==============================] - 0s 709us/step - loss: 0.2476 - mse:
0.2476
Epoch 1119/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2525 - mse: 0.
2525
Epoch 1120/2000
4/4 [==============================] - 0s 974us/step - loss: 0.2564 - mse:
0.2564
Epoch 1121/2000
4/4 [==============================] - 0s 665us/step - loss: 0.2435 - mse:
0.2435
Epoch 1122/2000
4/4 [==============================] - 0s 935us/step - loss: 0.2449 - mse:
0.2449
Epoch 1123/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2491 - mse: 0.
2491
Epoch 1124/2000
4/4 [==============================] - 0s 938us/step - loss: 0.2428 - mse:
0.2428
Epoch 1125/2000
4/4 [==============================] - 0s 2ms/step - loss: 0.2432 - mse: 0.
2432
Epoch 1126/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2434 - mse: 0.
2434
Epoch 1127/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2459 - mse: 0.
2459
Epoch 1128/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2431 - mse: 0.
2431
Epoch 1129/2000
4/4 [==============================] - 0s 771us/step - loss: 0.2434 - mse:
0.2434
Epoch 1130/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2451 - mse: 0.
2451
Epoch 1131/2000
4/4 [==============================] - 0s 918us/step - loss: 0.2427 - mse:
0.2427
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
63 of 113 9/23/21, 09:01
Epoch 1132/2000
4/4 [==============================] - 0s 781us/step - loss: 0.2480 - mse:
0.2480
Epoch 1133/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2436 - mse: 0.
2436
Epoch 1134/2000
4/4 [==============================] - 0s 988us/step - loss: 0.2480 - mse:
0.2480
Epoch 1135/2000
4/4 [==============================] - 0s 704us/step - loss: 0.2488 - mse:
0.2488
Epoch 1136/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2446 - mse: 0.
2446
Epoch 1137/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2443 - mse: 0.
2443
Epoch 1138/2000
4/4 [==============================] - 0s 699us/step - loss: 0.2438 - mse:
0.2438
Epoch 1139/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2430 - mse: 0.
2430
Epoch 1140/2000
4/4 [==============================] - 0s 930us/step - loss: 0.2421 - mse:
0.2421
Epoch 1141/2000
4/4 [==============================] - 0s 857us/step - loss: 0.2435 - mse:
0.2435
Epoch 1142/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2530 - mse: 0.
2530
Epoch 1143/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2431 - mse: 0.
2431
Epoch 1144/2000
4/4 [==============================] - 0s 837us/step - loss: 0.2424 - mse:
0.2424
Epoch 1145/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2430 - mse: 0.
2430
Epoch 1146/2000
4/4 [==============================] - 0s 896us/step - loss: 0.2442 - mse:
0.2442
Epoch 1147/2000
4/4 [==============================] - 0s 766us/step - loss: 0.2444 - mse:
0.2444
Epoch 1148/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2426 - mse: 0.
2426
Epoch 1149/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2435 - mse: 0.
2435
Epoch 1150/2000
4/4 [==============================] - 0s 731us/step - loss: 0.2450 - mse:
0.2450
Epoch 1151/2000
4/4 [==============================] - 0s 2ms/step - loss: 0.2417 - mse: 0.
2417
Epoch 1152/2000
4/4 [==============================] - 0s 791us/step - loss: 0.2416 - mse:
0.2416
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
64 of 113 9/23/21, 09:01
Epoch 1153/2000
4/4 [==============================] - 0s 912us/step - loss: 0.2414 - mse:
0.2414
Epoch 1154/2000
4/4 [==============================] - 0s 2ms/step - loss: 0.2447 - mse: 0.
2447
Epoch 1155/2000
4/4 [==============================] - 0s 820us/step - loss: 0.2422 - mse:
0.2422
Epoch 1156/2000
4/4 [==============================] - 0s 780us/step - loss: 0.2461 - mse:
0.2461
Epoch 1157/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2476 - mse: 0.
2476
Epoch 1158/2000
4/4 [==============================] - 0s 815us/step - loss: 0.2461 - mse:
0.2461
Epoch 1159/2000
4/4 [==============================] - 0s 678us/step - loss: 0.2421 - mse:
0.2421
Epoch 1160/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2462 - mse: 0.
2462
Epoch 1161/2000
4/4 [==============================] - 0s 974us/step - loss: 0.2428 - mse:
0.2428
Epoch 1162/2000
4/4 [==============================] - 0s 768us/step - loss: 0.2425 - mse:
0.2425
Epoch 1163/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2412 - mse: 0.
2412
Epoch 1164/2000
4/4 [==============================] - 0s 711us/step - loss: 0.2409 - mse:
0.2409
Epoch 1165/2000
4/4 [==============================] - 0s 642us/step - loss: 0.2408 - mse:
0.2408
Epoch 1166/2000
4/4 [==============================] - 0s 2ms/step - loss: 0.2409 - mse: 0.
2409
Epoch 1167/2000
4/4 [==============================] - 0s 714us/step - loss: 0.2406 - mse:
0.2406
Epoch 1168/2000
4/4 [==============================] - 0s 658us/step - loss: 0.2420 - mse:
0.2420
Epoch 1169/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2424 - mse: 0.
2424
Epoch 1170/2000
4/4 [==============================] - 0s 770us/step - loss: 0.2411 - mse:
0.2411
Epoch 1171/2000
4/4 [==============================] - 0s 803us/step - loss: 0.2411 - mse:
0.2411
Epoch 1172/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2412 - mse: 0.
2412
Epoch 1173/2000
4/4 [==============================] - 0s 711us/step - loss: 0.2426 - mse:
0.2426
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
65 of 113 9/23/21, 09:01
Epoch 1174/2000
4/4 [==============================] - 0s 801us/step - loss: 0.2423 - mse:
0.2423
Epoch 1175/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2425 - mse: 0.
2425
Epoch 1176/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2444 - mse: 0.
2444
Epoch 1177/2000
4/4 [==============================] - 0s 677us/step - loss: 0.2420 - mse:
0.2420
Epoch 1178/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2404 - mse: 0.
2404
Epoch 1179/2000
4/4 [==============================] - 0s 872us/step - loss: 0.2416 - mse:
0.2416
Epoch 1180/2000
4/4 [==============================] - 0s 694us/step - loss: 0.2458 - mse:
0.2458
Epoch 1181/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2407 - mse: 0.
2407
Epoch 1182/2000
4/4 [==============================] - 0s 911us/step - loss: 0.2420 - mse:
0.2420
Epoch 1183/2000
4/4 [==============================] - 0s 758us/step - loss: 0.2427 - mse:
0.2427
Epoch 1184/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2421 - mse: 0.
2421
Epoch 1185/2000
4/4 [==============================] - 0s 726us/step - loss: 0.2452 - mse:
0.2452
Epoch 1186/2000
4/4 [==============================] - 0s 682us/step - loss: 0.2423 - mse:
0.2423
Epoch 1187/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2419 - mse: 0.
2419
Epoch 1188/2000
4/4 [==============================] - 0s 795us/step - loss: 0.2409 - mse:
0.2409
Epoch 1189/2000
4/4 [==============================] - 0s 811us/step - loss: 0.2406 - mse:
0.2406
Epoch 1190/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2401 - mse: 0.
2401
Epoch 1191/2000
4/4 [==============================] - 0s 980us/step - loss: 0.2407 - mse:
0.2407
Epoch 1192/2000
4/4 [==============================] - 0s 728us/step - loss: 0.2400 - mse:
0.2400
Epoch 1193/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2427 - mse: 0.
2427
Epoch 1194/2000
4/4 [==============================] - 0s 758us/step - loss: 0.2407 - mse:
0.2407
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
66 of 113 9/23/21, 09:01
Epoch 1195/2000
4/4 [==============================] - 0s 785us/step - loss: 0.2397 - mse:
0.2397
Epoch 1196/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2400 - mse: 0.
2400
Epoch 1197/2000
4/4 [==============================] - 0s 779us/step - loss: 0.2399 - mse:
0.2399
Epoch 1198/2000
4/4 [==============================] - 0s 692us/step - loss: 0.2409 - mse:
0.2409
Epoch 1199/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2413 - mse: 0.
2413
Epoch 1200/2000
4/4 [==============================] - 0s 721us/step - loss: 0.2406 - mse:
0.2406
Epoch 1201/2000
4/4 [==============================] - 0s 692us/step - loss: 0.2420 - mse:
0.2420
Epoch 1202/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2432 - mse: 0.
2432
Epoch 1203/2000
4/4 [==============================] - 0s 667us/step - loss: 0.2410 - mse:
0.2410
Epoch 1204/2000
4/4 [==============================] - 0s 684us/step - loss: 0.2422 - mse:
0.2422
Epoch 1205/2000
4/4 [==============================] - 0s 2ms/step - loss: 0.2447 - mse: 0.
2447
Epoch 1206/2000
4/4 [==============================] - 0s 710us/step - loss: 0.2391 - mse:
0.2391
Epoch 1207/2000
4/4 [==============================] - 0s 658us/step - loss: 0.2435 - mse:
0.2435
Epoch 1208/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2506 - mse: 0.
2506
Epoch 1209/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2407 - mse: 0.
2407
Epoch 1210/2000
4/4 [==============================] - 0s 750us/step - loss: 0.2435 - mse:
0.2435
Epoch 1211/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2400 - mse: 0.
2400
Epoch 1212/2000
4/4 [==============================] - 0s 751us/step - loss: 0.2405 - mse:
0.2405
Epoch 1213/2000
4/4 [==============================] - 0s 709us/step - loss: 0.2416 - mse:
0.2416
Epoch 1214/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2440 - mse: 0.
2440
Epoch 1215/2000
4/4 [==============================] - 0s 823us/step - loss: 0.2471 - mse:
0.2471
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
67 of 113 9/23/21, 09:01
Epoch 1216/2000
4/4 [==============================] - 0s 650us/step - loss: 0.2405 - mse:
0.2405
Epoch 1217/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2392 - mse: 0.
2392
Epoch 1218/2000
4/4 [==============================] - 0s 992us/step - loss: 0.2445 - mse:
0.2445
Epoch 1219/2000
4/4 [==============================] - 0s 650us/step - loss: 0.2419 - mse:
0.2419
Epoch 1220/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2438 - mse: 0.
2438
Epoch 1221/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2536 - mse: 0.
2536
Epoch 1222/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2401 - mse: 0.
2401
Epoch 1223/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2386 - mse: 0.
2386
Epoch 1224/2000
4/4 [==============================] - 0s 995us/step - loss: 0.2385 - mse:
0.2385
Epoch 1225/2000
4/4 [==============================] - 0s 699us/step - loss: 0.2405 - mse:
0.2405
Epoch 1226/2000
4/4 [==============================] - 0s 986us/step - loss: 0.2427 - mse:
0.2427
Epoch 1227/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2415 - mse: 0.
2415
Epoch 1228/2000
4/4 [==============================] - 0s 757us/step - loss: 0.2396 - mse:
0.2396
Epoch 1229/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2405 - mse: 0.
2405
Epoch 1230/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2401 - mse: 0.
2401
Epoch 1231/2000
4/4 [==============================] - 0s 797us/step - loss: 0.2421 - mse:
0.2421
Epoch 1232/2000
4/4 [==============================] - 0s 792us/step - loss: 0.2386 - mse:
0.2386
Epoch 1233/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2418 - mse: 0.
2418
Epoch 1234/2000
4/4 [==============================] - 0s 849us/step - loss: 0.2402 - mse:
0.2402
Epoch 1235/2000
4/4 [==============================] - 0s 824us/step - loss: 0.2396 - mse:
0.2396
Epoch 1236/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2388 - mse: 0.
2388
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
68 of 113 9/23/21, 09:01
Epoch 1237/2000
4/4 [==============================] - 0s 659us/step - loss: 0.2397 - mse:
0.2397
Epoch 1238/2000
4/4 [==============================] - 0s 897us/step - loss: 0.2404 - mse:
0.2404
Epoch 1239/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2402 - mse: 0.
2402
Epoch 1240/2000
4/4 [==============================] - 0s 796us/step - loss: 0.2383 - mse:
0.2383
Epoch 1241/2000
4/4 [==============================] - 0s 666us/step - loss: 0.2385 - mse:
0.2385
Epoch 1242/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2383 - mse: 0.
2383
Epoch 1243/2000
4/4 [==============================] - 0s 829us/step - loss: 0.2383 - mse:
0.2383
Epoch 1244/2000
4/4 [==============================] - 0s 709us/step - loss: 0.2378 - mse:
0.2378
Epoch 1245/2000
4/4 [==============================] - 0s 907us/step - loss: 0.2377 - mse:
0.2377
Epoch 1246/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2381 - mse: 0.
2381
Epoch 1247/2000
4/4 [==============================] - 0s 794us/step - loss: 0.2407 - mse:
0.2407
Epoch 1248/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2385 - mse: 0.
2385
Epoch 1249/2000
4/4 [==============================] - 0s 766us/step - loss: 0.2392 - mse:
0.2392
Epoch 1250/2000
4/4 [==============================] - 0s 717us/step - loss: 0.2390 - mse:
0.2390
Epoch 1251/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2390 - mse: 0.
2390
Epoch 1252/2000
4/4 [==============================] - 0s 803us/step - loss: 0.2414 - mse:
0.2414
Epoch 1253/2000
4/4 [==============================] - 0s 842us/step - loss: 0.2391 - mse:
0.2391
Epoch 1254/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2374 - mse: 0.
2374
Epoch 1255/2000
4/4 [==============================] - 0s 817us/step - loss: 0.2383 - mse:
0.2383
Epoch 1256/2000
4/4 [==============================] - 0s 827us/step - loss: 0.2383 - mse:
0.2383
Epoch 1257/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2378 - mse: 0.
2378
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
69 of 113 9/23/21, 09:01
Epoch 1258/2000
4/4 [==============================] - 0s 857us/step - loss: 0.2376 - mse:
0.2376
Epoch 1259/2000
4/4 [==============================] - 0s 685us/step - loss: 0.2374 - mse:
0.2374
Epoch 1260/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2390 - mse: 0.
2390
Epoch 1261/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2378 - mse: 0.
2378
Epoch 1262/2000
4/4 [==============================] - 0s 783us/step - loss: 0.2371 - mse:
0.2371
Epoch 1263/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2414 - mse: 0.
2414
Epoch 1264/2000
4/4 [==============================] - 0s 886us/step - loss: 0.2461 - mse:
0.2461
Epoch 1265/2000
4/4 [==============================] - 0s 971us/step - loss: 0.2369 - mse:
0.2369
Epoch 1266/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2387 - mse: 0.
2387
Epoch 1267/2000
4/4 [==============================] - 0s 674us/step - loss: 0.2370 - mse:
0.2370
Epoch 1268/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2415 - mse: 0.
2415
Epoch 1269/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2376 - mse: 0.
2376
Epoch 1270/2000
4/4 [==============================] - 0s 865us/step - loss: 0.2380 - mse:
0.2380
Epoch 1271/2000
4/4 [==============================] - 0s 933us/step - loss: 0.2405 - mse:
0.2405
Epoch 1272/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2393 - mse: 0.
2393
Epoch 1273/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2439 - mse: 0.
2439
Epoch 1274/2000
4/4 [==============================] - 0s 747us/step - loss: 0.2374 - mse:
0.2374
Epoch 1275/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2371 - mse: 0.
2371
Epoch 1276/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2384 - mse: 0.
2384
Epoch 1277/2000
4/4 [==============================] - 0s 765us/step - loss: 0.2392 - mse:
0.2392
Epoch 1278/2000
4/4 [==============================] - 0s 753us/step - loss: 0.2365 - mse:
0.2365
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
70 of 113 9/23/21, 09:01
Epoch 1279/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2381 - mse: 0.
2381
Epoch 1280/2000
4/4 [==============================] - 0s 720us/step - loss: 0.2380 - mse:
0.2380
Epoch 1281/2000
4/4 [==============================] - 0s 730us/step - loss: 0.2370 - mse:
0.2370
Epoch 1282/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2380 - mse: 0.
2380
Epoch 1283/2000
4/4 [==============================] - 0s 724us/step - loss: 0.2366 - mse:
0.2366
Epoch 1284/2000
4/4 [==============================] - 0s 814us/step - loss: 0.2370 - mse:
0.2370
Epoch 1285/2000
4/4 [==============================] - 0s 987us/step - loss: 0.2390 - mse:
0.2390
Epoch 1286/2000
4/4 [==============================] - 0s 784us/step - loss: 0.2406 - mse:
0.2406
Epoch 1287/2000
4/4 [==============================] - 0s 771us/step - loss: 0.2405 - mse:
0.2405
Epoch 1288/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2382 - mse: 0.
2382
Epoch 1289/2000
4/4 [==============================] - 0s 927us/step - loss: 0.2387 - mse:
0.2387
Epoch 1290/2000
4/4 [==============================] - 0s 873us/step - loss: 0.2394 - mse:
0.2394
Epoch 1291/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2390 - mse: 0.
2390
Epoch 1292/2000
4/4 [==============================] - 0s 958us/step - loss: 0.2384 - mse:
0.2384
Epoch 1293/2000
4/4 [==============================] - 0s 644us/step - loss: 0.2364 - mse:
0.2364
Epoch 1294/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2368 - mse: 0.
2368
Epoch 1295/2000
4/4 [==============================] - 0s 736us/step - loss: 0.2365 - mse:
0.2365
Epoch 1296/2000
4/4 [==============================] - 0s 640us/step - loss: 0.2369 - mse:
0.2369
Epoch 1297/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2376 - mse: 0.
2376
Epoch 1298/2000
4/4 [==============================] - 0s 784us/step - loss: 0.2406 - mse:
0.2406
Epoch 1299/2000
4/4 [==============================] - 0s 727us/step - loss: 0.2437 - mse:
0.2437
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
71 of 113 9/23/21, 09:01
Epoch 1300/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2383 - mse: 0.
2383
Epoch 1301/2000
4/4 [==============================] - 0s 960us/step - loss: 0.2407 - mse:
0.2407
Epoch 1302/2000
4/4 [==============================] - 0s 815us/step - loss: 0.2374 - mse:
0.2374
Epoch 1303/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2355 - mse: 0.
2355
Epoch 1304/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2370 - mse: 0.
2370
Epoch 1305/2000
4/4 [==============================] - 0s 891us/step - loss: 0.2378 - mse:
0.2378
Epoch 1306/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2365 - mse: 0.
2365
Epoch 1307/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2350 - mse: 0.
2350
Epoch 1308/2000
4/4 [==============================] - 0s 829us/step - loss: 0.2365 - mse:
0.2365
Epoch 1309/2000
4/4 [==============================] - 0s 684us/step - loss: 0.2419 - mse:
0.2419
Epoch 1310/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2427 - mse: 0.
2427
Epoch 1311/2000
4/4 [==============================] - 0s 692us/step - loss: 0.2355 - mse:
0.2355
Epoch 1312/2000
4/4 [==============================] - 0s 681us/step - loss: 0.2355 - mse:
0.2355
Epoch 1313/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2356 - mse: 0.
2356
Epoch 1314/2000
4/4 [==============================] - 0s 834us/step - loss: 0.2368 - mse:
0.2368
Epoch 1315/2000
4/4 [==============================] - 0s 677us/step - loss: 0.2366 - mse:
0.2366
Epoch 1316/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2370 - mse: 0.
2370
Epoch 1317/2000
4/4 [==============================] - 0s 933us/step - loss: 0.2357 - mse:
0.2357
Epoch 1318/2000
4/4 [==============================] - 0s 670us/step - loss: 0.2363 - mse:
0.2363
Epoch 1319/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2374 - mse: 0.
2374
Epoch 1320/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2397 - mse: 0.
2397
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
72 of 113 9/23/21, 09:01
Epoch 1321/2000
4/4 [==============================] - 0s 728us/step - loss: 0.2348 - mse:
0.2348
Epoch 1322/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2370 - mse: 0.
2370
Epoch 1323/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2347 - mse: 0.
2347
Epoch 1324/2000
4/4 [==============================] - 0s 836us/step - loss: 0.2350 - mse:
0.2350
Epoch 1325/2000
4/4 [==============================] - 0s 851us/step - loss: 0.2345 - mse:
0.2345
Epoch 1326/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2353 - mse: 0.
2353
Epoch 1327/2000
4/4 [==============================] - 0s 762us/step - loss: 0.2403 - mse:
0.2403
Epoch 1328/2000
4/4 [==============================] - 0s 877us/step - loss: 0.2349 - mse:
0.2349
Epoch 1329/2000
4/4 [==============================] - 0s 982us/step - loss: 0.2376 - mse:
0.2376
Epoch 1330/2000
4/4 [==============================] - 0s 829us/step - loss: 0.2348 - mse:
0.2348
Epoch 1331/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2363 - mse: 0.
2363
Epoch 1332/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2357 - mse: 0.
2357
Epoch 1333/2000
4/4 [==============================] - 0s 821us/step - loss: 0.2356 - mse:
0.2356
Epoch 1334/2000
4/4 [==============================] - 0s 803us/step - loss: 0.2356 - mse:
0.2356
Epoch 1335/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2379 - mse: 0.
2379
Epoch 1336/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2362 - mse: 0.
2362
Epoch 1337/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2348 - mse: 0.
2348
Epoch 1338/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2405 - mse: 0.
2405
Epoch 1339/2000
4/4 [==============================] - 0s 760us/step - loss: 0.2346 - mse:
0.2346
Epoch 1340/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2355 - mse: 0.
2355
Epoch 1341/2000
4/4 [==============================] - 0s 938us/step - loss: 0.2423 - mse:
0.2423
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
73 of 113 9/23/21, 09:01
Epoch 1342/2000
4/4 [==============================] - 0s 790us/step - loss: 0.2341 - mse:
0.2341
Epoch 1343/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2360 - mse: 0.
2360
Epoch 1344/2000
4/4 [==============================] - 0s 979us/step - loss: 0.2349 - mse:
0.2349
Epoch 1345/2000
4/4 [==============================] - 0s 794us/step - loss: 0.2355 - mse:
0.2355
Epoch 1346/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2342 - mse: 0.
2342
Epoch 1347/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2357 - mse: 0.
2357
Epoch 1348/2000
4/4 [==============================] - 0s 747us/step - loss: 0.2341 - mse:
0.2341
Epoch 1349/2000
4/4 [==============================] - 0s 694us/step - loss: 0.2339 - mse:
0.2339
Epoch 1350/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2342 - mse: 0.
2342
Epoch 1351/2000
4/4 [==============================] - 0s 757us/step - loss: 0.2363 - mse:
0.2363
Epoch 1352/2000
4/4 [==============================] - 0s 705us/step - loss: 0.2361 - mse:
0.2361
Epoch 1353/2000
4/4 [==============================] - 0s 2ms/step - loss: 0.2345 - mse: 0.
2345
Epoch 1354/2000
4/4 [==============================] - 0s 793us/step - loss: 0.2336 - mse:
0.2336
Epoch 1355/2000
4/4 [==============================] - 0s 691us/step - loss: 0.2352 - mse:
0.2352
Epoch 1356/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2333 - mse: 0.
2333
Epoch 1357/2000
4/4 [==============================] - 0s 736us/step - loss: 0.2363 - mse:
0.2363
Epoch 1358/2000
4/4 [==============================] - 0s 646us/step - loss: 0.2332 - mse:
0.2332
Epoch 1359/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2348 - mse: 0.
2348
Epoch 1360/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2357 - mse: 0.
2357
Epoch 1361/2000
4/4 [==============================] - 0s 747us/step - loss: 0.2339 - mse:
0.2339
Epoch 1362/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2369 - mse: 0.
2369
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
74 of 113 9/23/21, 09:01
Epoch 1363/2000
4/4 [==============================] - 0s 903us/step - loss: 0.2434 - mse:
0.2434
Epoch 1364/2000
4/4 [==============================] - 0s 779us/step - loss: 0.2375 - mse:
0.2375
Epoch 1365/2000
4/4 [==============================] - ETA: 0s - loss: 0.1992 - mse: 0.199
- 0s 1ms/step - loss: 0.2387 - mse: 0.2387
Epoch 1366/2000
4/4 [==============================] - 0s 853us/step - loss: 0.2343 - mse:
0.2343
Epoch 1367/2000
4/4 [==============================] - 0s 678us/step - loss: 0.2379 - mse:
0.2379
Epoch 1368/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2368 - mse: 0.
2368
Epoch 1369/2000
4/4 [==============================] - 0s 972us/step - loss: 0.2367 - mse:
0.2367
Epoch 1370/2000
4/4 [==============================] - 0s 832us/step - loss: 0.2345 - mse:
0.2345
Epoch 1371/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2335 - mse: 0.
2335
Epoch 1372/2000
4/4 [==============================] - 0s 840us/step - loss: 0.2330 - mse:
0.2330
Epoch 1373/2000
4/4 [==============================] - 0s 691us/step - loss: 0.2359 - mse:
0.2359
Epoch 1374/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2372 - mse: 0.
2372
Epoch 1375/2000
4/4 [==============================] - 0s 960us/step - loss: 0.2327 - mse:
0.2327
Epoch 1376/2000
4/4 [==============================] - 0s 716us/step - loss: 0.2355 - mse:
0.2355
Epoch 1377/2000
4/4 [==============================] - 0s 831us/step - loss: 0.2346 - mse:
0.2346
Epoch 1378/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2462 - mse: 0.
2462
Epoch 1379/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2426 - mse: 0.
2426
Epoch 1380/2000
4/4 [==============================] - 0s 684us/step - loss: 0.2338 - mse:
0.2338
Epoch 1381/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2334 - mse: 0.
2334
Epoch 1382/2000
4/4 [==============================] - 0s 728us/step - loss: 0.2364 - mse:
0.2364
Epoch 1383/2000
4/4 [==============================] - 0s 793us/step - loss: 0.2386 - mse:
0.2386
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
75 of 113 9/23/21, 09:01
Epoch 1384/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2326 - mse: 0.
2326
Epoch 1385/2000
4/4 [==============================] - 0s 868us/step - loss: 0.2340 - mse:
0.2340
Epoch 1386/2000
4/4 [==============================] - 0s 705us/step - loss: 0.2327 - mse:
0.2327
Epoch 1387/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2330 - mse: 0.
2330
Epoch 1388/2000
4/4 [==============================] - 0s 830us/step - loss: 0.2324 - mse:
0.2324
Epoch 1389/2000
4/4 [==============================] - 0s 781us/step - loss: 0.2359 - mse:
0.2359
Epoch 1390/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2353 - mse: 0.
2353
Epoch 1391/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2326 - mse: 0.
2326
Epoch 1392/2000
4/4 [==============================] - 0s 806us/step - loss: 0.2335 - mse:
0.2335
Epoch 1393/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2370 - mse: 0.
2370
Epoch 1394/2000
4/4 [==============================] - 0s 913us/step - loss: 0.2319 - mse:
0.2319
Epoch 1395/2000
4/4 [==============================] - 0s 788us/step - loss: 0.2334 - mse:
0.2334
Epoch 1396/2000
4/4 [==============================] - 0s 670us/step - loss: 0.2356 - mse:
0.2356
Epoch 1397/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2331 - mse: 0.
2331
Epoch 1398/2000
4/4 [==============================] - 0s 679us/step - loss: 0.2340 - mse:
0.2340
Epoch 1399/2000
4/4 [==============================] - 0s 738us/step - loss: 0.2340 - mse:
0.2340
Epoch 1400/2000
4/4 [==============================] - 0s 2ms/step - loss: 0.2359 - mse: 0.
2359
Epoch 1401/2000
4/4 [==============================] - 0s 664us/step - loss: 0.2363 - mse:
0.2363
Epoch 1402/2000
4/4 [==============================] - 0s 647us/step - loss: 0.2337 - mse:
0.2337
Epoch 1403/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2338 - mse: 0.
2338
Epoch 1404/2000
4/4 [==============================] - 0s 783us/step - loss: 0.2341 - mse:
0.2341
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
76 of 113 9/23/21, 09:01
Epoch 1405/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2320 - mse: 0.
2320
Epoch 1406/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2313 - mse: 0.
2313
Epoch 1407/2000
4/4 [==============================] - 0s 771us/step - loss: 0.2316 - mse:
0.2316
Epoch 1408/2000
4/4 [==============================] - 0s 996us/step - loss: 0.2357 - mse:
0.2357
Epoch 1409/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2318 - mse: 0.
2318
Epoch 1410/2000
4/4 [==============================] - 0s 841us/step - loss: 0.2324 - mse:
0.2324
Epoch 1411/2000
4/4 [==============================] - 0s 717us/step - loss: 0.2326 - mse:
0.2326
Epoch 1412/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2317 - mse: 0.
2317
Epoch 1413/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2327 - mse: 0.
2327
Epoch 1414/2000
4/4 [==============================] - 0s 886us/step - loss: 0.2319 - mse:
0.2319
Epoch 1415/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2312 - mse: 0.
2312
Epoch 1416/2000
4/4 [==============================] - 0s 802us/step - loss: 0.2339 - mse:
0.2339
Epoch 1417/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2334 - mse: 0.
2334
Epoch 1418/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2343 - mse: 0.
2343
Epoch 1419/2000
4/4 [==============================] - 0s 703us/step - loss: 0.2369 - mse:
0.2369
Epoch 1420/2000
4/4 [==============================] - 0s 770us/step - loss: 0.2340 - mse:
0.2340
Epoch 1421/2000
4/4 [==============================] - 0s 931us/step - loss: 0.2354 - mse:
0.2354
Epoch 1422/2000
4/4 [==============================] - 0s 884us/step - loss: 0.2323 - mse:
0.2323
Epoch 1423/2000
4/4 [==============================] - 0s 631us/step - loss: 0.2318 - mse:
0.2318
Epoch 1424/2000
4/4 [==============================] - 0s 932us/step - loss: 0.2319 - mse:
0.2319
Epoch 1425/2000
4/4 [==============================] - 0s 915us/step - loss: 0.2330 - mse:
0.2330
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
77 of 113 9/23/21, 09:01
Epoch 1426/2000
4/4 [==============================] - 0s 875us/step - loss: 0.2319 - mse:
0.2319
Epoch 1427/2000
4/4 [==============================] - 0s 978us/step - loss: 0.2316 - mse:
0.2316
Epoch 1428/2000
4/4 [==============================] - 0s 802us/step - loss: 0.2346 - mse:
0.2346
Epoch 1429/2000
4/4 [==============================] - 0s 633us/step - loss: 0.2323 - mse:
0.2323
Epoch 1430/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2333 - mse: 0.
2333
Epoch 1431/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2357 - mse: 0.
2357
Epoch 1432/2000
4/4 [==============================] - 0s 651us/step - loss: 0.2327 - mse:
0.2327
Epoch 1433/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2304 - mse: 0.
2304
Epoch 1434/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2313 - mse: 0.
2313
Epoch 1435/2000
4/4 [==============================] - 0s 857us/step - loss: 0.2310 - mse:
0.2310
Epoch 1436/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2339 - mse: 0.
2339
Epoch 1437/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2306 - mse: 0.
2306
Epoch 1438/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2310 - mse: 0.
2310
Epoch 1439/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2315 - mse: 0.
2315
Epoch 1440/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2314 - mse: 0.
2314
Epoch 1441/2000
4/4 [==============================] - 0s 684us/step - loss: 0.2315 - mse:
0.2315
Epoch 1442/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2309 - mse: 0.
2309
Epoch 1443/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2312 - mse: 0.
2312
Epoch 1444/2000
4/4 [==============================] - 0s 838us/step - loss: 0.2314 - mse:
0.2314
Epoch 1445/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2315 - mse: 0.
2315
Epoch 1446/2000
4/4 [==============================] - 0s 865us/step - loss: 0.2321 - mse:
0.2321
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
78 of 113 9/23/21, 09:01
Epoch 1447/2000
4/4 [==============================] - 0s 827us/step - loss: 0.2306 - mse:
0.2306
Epoch 1448/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2306 - mse: 0.
2306
Epoch 1449/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2310 - mse: 0.
2310
Epoch 1450/2000
4/4 [==============================] - 0s 736us/step - loss: 0.2339 - mse:
0.2339
Epoch 1451/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2330 - mse: 0.
2330
Epoch 1452/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2334 - mse: 0.
2334
Epoch 1453/2000
4/4 [==============================] - 0s 761us/step - loss: 0.2306 - mse:
0.2306
Epoch 1454/2000
4/4 [==============================] - 0s 2ms/step - loss: 0.2305 - mse: 0.
2305
Epoch 1455/2000
4/4 [==============================] - 0s 739us/step - loss: 0.2326 - mse:
0.2326
Epoch 1456/2000
4/4 [==============================] - 0s 633us/step - loss: 0.2310 - mse:
0.2310
Epoch 1457/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2309 - mse: 0.
2309
Epoch 1458/2000
4/4 [==============================] - 0s 951us/step - loss: 0.2382 - mse:
0.2382
Epoch 1459/2000
4/4 [==============================] - 0s 690us/step - loss: 0.2307 - mse:
0.2307
Epoch 1460/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2307 - mse: 0.
2307
Epoch 1461/2000
4/4 [==============================] - 0s 881us/step - loss: 0.2316 - mse:
0.2316
Epoch 1462/2000
4/4 [==============================] - 0s 864us/step - loss: 0.2339 - mse:
0.2339
Epoch 1463/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2321 - mse: 0.
2321
Epoch 1464/2000
4/4 [==============================] - 0s 846us/step - loss: 0.2341 - mse:
0.2341
Epoch 1465/2000
4/4 [==============================] - 0s 859us/step - loss: 0.2314 - mse:
0.2314
Epoch 1466/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2297 - mse: 0.
2297
Epoch 1467/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2312 - mse: 0.
2312
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
79 of 113 9/23/21, 09:01
Epoch 1468/2000
4/4 [==============================] - 0s 678us/step - loss: 0.2293 - mse:
0.2293
Epoch 1469/2000
4/4 [==============================] - 0s 965us/step - loss: 0.2293 - mse:
0.2293
Epoch 1470/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2319 - mse: 0.
2319
Epoch 1471/2000
4/4 [==============================] - 0s 664us/step - loss: 0.2358 - mse:
0.2358
Epoch 1472/2000
4/4 [==============================] - 0s 873us/step - loss: 0.2323 - mse:
0.2323
Epoch 1473/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2293 - mse: 0.
2293
Epoch 1474/2000
4/4 [==============================] - 0s 818us/step - loss: 0.2303 - mse:
0.2303
Epoch 1475/2000
4/4 [==============================] - 0s 822us/step - loss: 0.2335 - mse:
0.2335
Epoch 1476/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2297 - mse: 0.
2297
Epoch 1477/2000
4/4 [==============================] - 0s 754us/step - loss: 0.2316 - mse:
0.2316
Epoch 1478/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2292 - mse: 0.
2292
Epoch 1479/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2303 - mse: 0.
2303
Epoch 1480/2000
4/4 [==============================] - 0s 812us/step - loss: 0.2293 - mse:
0.2293
Epoch 1481/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2299 - mse: 0.
2299
Epoch 1482/2000
4/4 [==============================] - 0s 843us/step - loss: 0.2313 - mse:
0.2313
Epoch 1483/2000
4/4 [==============================] - 0s 717us/step - loss: 0.2303 - mse:
0.2303
Epoch 1484/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2301 - mse: 0.
2301
Epoch 1485/2000
4/4 [==============================] - 0s 935us/step - loss: 0.2291 - mse:
0.2291
Epoch 1486/2000
4/4 [==============================] - 0s 771us/step - loss: 0.2297 - mse:
0.2297
Epoch 1487/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2302 - mse: 0.
2302
Epoch 1488/2000
4/4 [==============================] - 0s 955us/step - loss: 0.2290 - mse:
0.2290
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
80 of 113 9/23/21, 09:01
Epoch 1489/2000
4/4 [==============================] - 0s 711us/step - loss: 0.2300 - mse:
0.2300
Epoch 1490/2000
4/4 [==============================] - 0s 896us/step - loss: 0.2299 - mse:
0.2299
Epoch 1491/2000
4/4 [==============================] - 0s 835us/step - loss: 0.2299 - mse:
0.2299
Epoch 1492/2000
4/4 [==============================] - 0s 848us/step - loss: 0.2304 - mse:
0.2304
Epoch 1493/2000
4/4 [==============================] - 0s 834us/step - loss: 0.2296 - mse:
0.2296
Epoch 1494/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2301 - mse: 0.
2301
Epoch 1495/2000
4/4 [==============================] - 0s 732us/step - loss: 0.2301 - mse:
0.2301
Epoch 1496/2000
4/4 [==============================] - 0s 859us/step - loss: 0.2286 - mse:
0.2286
Epoch 1497/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2310 - mse: 0.
2310
Epoch 1498/2000
4/4 [==============================] - 0s 744us/step - loss: 0.2291 - mse:
0.2291
Epoch 1499/2000
4/4 [==============================] - 0s 764us/step - loss: 0.2304 - mse:
0.2304
Epoch 1500/2000
4/4 [==============================] - 0s 938us/step - loss: 0.2306 - mse:
0.2306
Epoch 1501/2000
4/4 [==============================] - 0s 909us/step - loss: 0.2297 - mse:
0.2297
Epoch 1502/2000
4/4 [==============================] - 0s 658us/step - loss: 0.2300 - mse:
0.2300
Epoch 1503/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2294 - mse: 0.
2294
Epoch 1504/2000
4/4 [==============================] - 0s 917us/step - loss: 0.2281 - mse:
0.2281
Epoch 1505/2000
4/4 [==============================] - 0s 682us/step - loss: 0.2328 - mse:
0.2328
Epoch 1506/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2302 - mse: 0.
2302
Epoch 1507/2000
4/4 [==============================] - 0s 845us/step - loss: 0.2292 - mse:
0.2292
Epoch 1508/2000
4/4 [==============================] - 0s 731us/step - loss: 0.2286 - mse:
0.2286
Epoch 1509/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2285 - mse: 0.
2285
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
81 of 113 9/23/21, 09:01
Epoch 1510/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2306 - mse: 0.
2306
Epoch 1511/2000
4/4 [==============================] - 0s 715us/step - loss: 0.2311 - mse:
0.2311
Epoch 1512/2000
4/4 [==============================] - 0s 2ms/step - loss: 0.2299 - mse: 0.
2299
Epoch 1513/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2281 - mse: 0.
2281
Epoch 1514/2000
4/4 [==============================] - 0s 798us/step - loss: 0.2303 - mse:
0.2303
Epoch 1515/2000
4/4 [==============================] - 0s 2ms/step - loss: 0.2294 - mse: 0.
2294
Epoch 1516/2000
4/4 [==============================] - 0s 762us/step - loss: 0.2292 - mse:
0.2292
Epoch 1517/2000
4/4 [==============================] - 0s 813us/step - loss: 0.2282 - mse:
0.2282
Epoch 1518/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2283 - mse: 0.
2283
Epoch 1519/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2295 - mse: 0.
2295
Epoch 1520/2000
4/4 [==============================] - 0s 696us/step - loss: 0.2303 - mse:
0.2303
Epoch 1521/2000
4/4 [==============================] - 0s 992us/step - loss: 0.2283 - mse:
0.2283
Epoch 1522/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2285 - mse: 0.
2285
Epoch 1523/2000
4/4 [==============================] - 0s 847us/step - loss: 0.2281 - mse:
0.2281
Epoch 1524/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2285 - mse: 0.
2285
Epoch 1525/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2306 - mse: 0.
2306
Epoch 1526/2000
4/4 [==============================] - 0s 888us/step - loss: 0.2281 - mse:
0.2281
Epoch 1527/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2277 - mse: 0.
2277
Epoch 1528/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2293 - mse: 0.
2293
Epoch 1529/2000
4/4 [==============================] - 0s 792us/step - loss: 0.2298 - mse:
0.2298
Epoch 1530/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2274 - mse: 0.
2274
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
82 of 113 9/23/21, 09:01
Epoch 1531/2000
4/4 [==============================] - 0s 784us/step - loss: 0.2292 - mse:
0.2292
Epoch 1532/2000
4/4 [==============================] - 0s 735us/step - loss: 0.2278 - mse:
0.2278
Epoch 1533/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2276 - mse: 0.
2276
Epoch 1534/2000
4/4 [==============================] - 0s 839us/step - loss: 0.2351 - mse:
0.2351
Epoch 1535/2000
4/4 [==============================] - 0s 871us/step - loss: 0.2283 - mse:
0.2283
Epoch 1536/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2275 - mse: 0.
2275
Epoch 1537/2000
4/4 [==============================] - 0s 998us/step - loss: 0.2277 - mse:
0.2277
Epoch 1538/2000
4/4 [==============================] - 0s 871us/step - loss: 0.2275 - mse:
0.2275
Epoch 1539/2000
4/4 [==============================] - 0s 930us/step - loss: 0.2267 - mse:
0.2267
Epoch 1540/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2273 - mse: 0.
2273
Epoch 1541/2000
4/4 [==============================] - 0s 719us/step - loss: 0.2293 - mse:
0.2293
Epoch 1542/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2323 - mse: 0.
2323
Epoch 1543/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2294 - mse: 0.
2294
Epoch 1544/2000
4/4 [==============================] - 0s 687us/step - loss: 0.2270 - mse:
0.2270
Epoch 1545/2000
4/4 [==============================] - 0s 654us/step - loss: 0.2287 - mse:
0.2287
Epoch 1546/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2291 - mse: 0.
2291
Epoch 1547/2000
4/4 [==============================] - 0s 741us/step - loss: 0.2302 - mse:
0.2302
Epoch 1548/2000
4/4 [==============================] - 0s 735us/step - loss: 0.2289 - mse:
0.2289
Epoch 1549/2000
4/4 [==============================] - 0s 2ms/step - loss: 0.2270 - mse: 0.
2270
Epoch 1550/2000
4/4 [==============================] - 0s 751us/step - loss: 0.2286 - mse:
0.2286
Epoch 1551/2000
4/4 [==============================] - 0s 769us/step - loss: 0.2271 - mse:
0.2271
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
83 of 113 9/23/21, 09:01
Epoch 1552/2000
4/4 [==============================] - 0s 820us/step - loss: 0.2266 - mse:
0.2266
Epoch 1553/2000
4/4 [==============================] - 0s 950us/step - loss: 0.2283 - mse:
0.2283
Epoch 1554/2000
4/4 [==============================] - 0s 733us/step - loss: 0.2270 - mse:
0.2270
Epoch 1555/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2272 - mse: 0.
2272
Epoch 1556/2000
4/4 [==============================] - 0s 960us/step - loss: 0.2312 - mse:
0.2312
Epoch 1557/2000
4/4 [==============================] - 0s 697us/step - loss: 0.2280 - mse:
0.2280
Epoch 1558/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2266 - mse: 0.
2266
Epoch 1559/2000
4/4 [==============================] - 0s 832us/step - loss: 0.2270 - mse:
0.2270
Epoch 1560/2000
4/4 [==============================] - 0s 827us/step - loss: 0.2271 - mse:
0.2271
Epoch 1561/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2278 - mse: 0.
2278
Epoch 1562/2000
4/4 [==============================] - 0s 650us/step - loss: 0.2286 - mse:
0.2286
Epoch 1563/2000
4/4 [==============================] - 0s 793us/step - loss: 0.2259 - mse:
0.2259
Epoch 1564/2000
4/4 [==============================] - 0s 2ms/step - loss: 0.2298 - mse: 0.
2298
Epoch 1565/2000
4/4 [==============================] - 0s 856us/step - loss: 0.2263 - mse:
0.2263
Epoch 1566/2000
4/4 [==============================] - 0s 823us/step - loss: 0.2266 - mse:
0.2266
Epoch 1567/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2284 - mse: 0.
2284
Epoch 1568/2000
4/4 [==============================] - 0s 885us/step - loss: 0.2288 - mse:
0.2288
Epoch 1569/2000
4/4 [==============================] - 0s 775us/step - loss: 0.2275 - mse:
0.2275
Epoch 1570/2000
4/4 [==============================] - 0s 989us/step - loss: 0.2329 - mse:
0.2329
Epoch 1571/2000
4/4 [==============================] - 0s 883us/step - loss: 0.2265 - mse:
0.2265
Epoch 1572/2000
4/4 [==============================] - 0s 739us/step - loss: 0.2301 - mse:
0.2301
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
84 of 113 9/23/21, 09:01
Epoch 1573/2000
4/4 [==============================] - 0s 955us/step - loss: 0.2293 - mse:
0.2293
Epoch 1574/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2307 - mse: 0.
2307
Epoch 1575/2000
4/4 [==============================] - 0s 749us/step - loss: 0.2297 - mse:
0.2297
Epoch 1576/2000
4/4 [==============================] - 0s 2ms/step - loss: 0.2304 - mse: 0.
2304
Epoch 1577/2000
4/4 [==============================] - 0s 779us/step - loss: 0.2270 - mse:
0.2270
Epoch 1578/2000
4/4 [==============================] - 0s 683us/step - loss: 0.2306 - mse:
0.2306
Epoch 1579/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2271 - mse: 0.
2271
Epoch 1580/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2289 - mse: 0.
2289
Epoch 1581/2000
4/4 [==============================] - 0s 901us/step - loss: 0.2266 - mse:
0.2266
Epoch 1582/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2259 - mse: 0.
2259
Epoch 1583/2000
4/4 [==============================] - 0s 995us/step - loss: 0.2284 - mse:
0.2284
Epoch 1584/2000
4/4 [==============================] - 0s 762us/step - loss: 0.2257 - mse:
0.2257
Epoch 1585/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2253 - mse: 0.
2253
Epoch 1586/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2271 - mse: 0.
2271
Epoch 1587/2000
4/4 [==============================] - 0s 760us/step - loss: 0.2261 - mse:
0.2261
Epoch 1588/2000
4/4 [==============================] - 0s 678us/step - loss: 0.2273 - mse:
0.2273
Epoch 1589/2000
4/4 [==============================] - 0s 914us/step - loss: 0.2271 - mse:
0.2271
Epoch 1590/2000
4/4 [==============================] - 0s 761us/step - loss: 0.2252 - mse:
0.2252
Epoch 1591/2000
4/4 [==============================] - 0s 644us/step - loss: 0.2274 - mse:
0.2274
Epoch 1592/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2263 - mse: 0.
2263
Epoch 1593/2000
4/4 [==============================] - 0s 879us/step - loss: 0.2254 - mse:
0.2254
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
85 of 113 9/23/21, 09:01
Epoch 1594/2000
4/4 [==============================] - 0s 750us/step - loss: 0.2259 - mse:
0.2259
Epoch 1595/2000
4/4 [==============================] - 0s 848us/step - loss: 0.2256 - mse:
0.2256
Epoch 1596/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2277 - mse: 0.
2277
Epoch 1597/2000
4/4 [==============================] - 0s 667us/step - loss: 0.2258 - mse:
0.2258
Epoch 1598/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2267 - mse: 0.
2267
Epoch 1599/2000
4/4 [==============================] - 0s 660us/step - loss: 0.2250 - mse:
0.2250
Epoch 1600/2000
4/4 [==============================] - 0s 864us/step - loss: 0.2247 - mse:
0.2247
Epoch 1601/2000
4/4 [==============================] - 0s 850us/step - loss: 0.2255 - mse:
0.2255
Epoch 1602/2000
4/4 [==============================] - 0s 850us/step - loss: 0.2260 - mse:
0.2260
Epoch 1603/2000
4/4 [==============================] - 0s 772us/step - loss: 0.2255 - mse:
0.2255
Epoch 1604/2000
4/4 [==============================] - 0s 936us/step - loss: 0.2276 - mse:
0.2276
Epoch 1605/2000
4/4 [==============================] - 0s 886us/step - loss: 0.2250 - mse:
0.2250
Epoch 1606/2000
4/4 [==============================] - 0s 667us/step - loss: 0.2258 - mse:
0.2258
Epoch 1607/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2257 - mse: 0.
2257
Epoch 1608/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2311 - mse: 0.
2311
Epoch 1609/2000
4/4 [==============================] - 0s 650us/step - loss: 0.2260 - mse:
0.2260
Epoch 1610/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2249 - mse: 0.
2249
Epoch 1611/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2270 - mse: 0.
2270
Epoch 1612/2000
4/4 [==============================] - 0s 765us/step - loss: 0.2249 - mse:
0.2249
Epoch 1613/2000
4/4 [==============================] - 0s 2ms/step - loss: 0.2249 - mse: 0.
2249
Epoch 1614/2000
4/4 [==============================] - 0s 746us/step - loss: 0.2261 - mse:
0.2261
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
86 of 113 9/23/21, 09:01
Epoch 1615/2000
4/4 [==============================] - 0s 689us/step - loss: 0.2266 - mse:
0.2266
Epoch 1616/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2314 - mse: 0.
2314
Epoch 1617/2000
4/4 [==============================] - 0s 989us/step - loss: 0.2256 - mse:
0.2256
Epoch 1618/2000
4/4 [==============================] - 0s 746us/step - loss: 0.2262 - mse:
0.2262
Epoch 1619/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2242 - mse: 0.
2242
Epoch 1620/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2261 - mse: 0.
2261
Epoch 1621/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2246 - mse: 0.
2246
Epoch 1622/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2259 - mse: 0.
2259
Epoch 1623/2000
4/4 [==============================] - 0s 907us/step - loss: 0.2271 - mse:
0.2271
Epoch 1624/2000
4/4 [==============================] - 0s 904us/step - loss: 0.2267 - mse:
0.2267
Epoch 1625/2000
4/4 [==============================] - 0s 2ms/step - loss: 0.2249 - mse: 0.
2249
Epoch 1626/2000
4/4 [==============================] - 0s 828us/step - loss: 0.2253 - mse:
0.2253
Epoch 1627/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2246 - mse: 0.
2246
Epoch 1628/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2240 - mse: 0.
2240
Epoch 1629/2000
4/4 [==============================] - 0s 800us/step - loss: 0.2250 - mse:
0.2250
Epoch 1630/2000
4/4 [==============================] - 0s 924us/step - loss: 0.2276 - mse:
0.2276
Epoch 1631/2000
4/4 [==============================] - 0s 922us/step - loss: 0.2268 - mse:
0.2268
Epoch 1632/2000
4/4 [==============================] - 0s 642us/step - loss: 0.2323 - mse:
0.2323
Epoch 1633/2000
4/4 [==============================] - 0s 805us/step - loss: 0.2334 - mse:
0.2334
Epoch 1634/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2251 - mse: 0.
2251
Epoch 1635/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2261 - mse: 0.
2261
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
87 of 113 9/23/21, 09:01
Epoch 1636/2000
4/4 [==============================] - 0s 765us/step - loss: 0.2239 - mse:
0.2239
Epoch 1637/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2242 - mse: 0.
2242
Epoch 1638/2000
4/4 [==============================] - 0s 936us/step - loss: 0.2259 - mse:
0.2259
Epoch 1639/2000
4/4 [==============================] - 0s 747us/step - loss: 0.2240 - mse:
0.2240
Epoch 1640/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2241 - mse: 0.
2241
Epoch 1641/2000
4/4 [==============================] - 0s 827us/step - loss: 0.2260 - mse:
0.2260
Epoch 1642/2000
4/4 [==============================] - 0s 671us/step - loss: 0.2239 - mse:
0.2239
Epoch 1643/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2261 - mse: 0.
2261
Epoch 1644/2000
4/4 [==============================] - 0s 934us/step - loss: 0.2252 - mse:
0.2252
Epoch 1645/2000
4/4 [==============================] - 0s 680us/step - loss: 0.2269 - mse:
0.2269
Epoch 1646/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2235 - mse: 0.
2235
Epoch 1647/2000
4/4 [==============================] - 0s 893us/step - loss: 0.2270 - mse:
0.2270
Epoch 1648/2000
4/4 [==============================] - 0s 734us/step - loss: 0.2291 - mse:
0.2291
Epoch 1649/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2243 - mse: 0.
2243
Epoch 1650/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2257 - mse: 0.
2257
Epoch 1651/2000
4/4 [==============================] - 0s 968us/step - loss: 0.2239 - mse:
0.2239
Epoch 1652/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2251 - mse: 0.
2251
Epoch 1653/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2259 - mse: 0.
2259
Epoch 1654/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2230 - mse: 0.
2230
Epoch 1655/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2235 - mse: 0.
2235
Epoch 1656/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2256 - mse: 0.
2256
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
88 of 113 9/23/21, 09:01
Epoch 1657/2000
4/4 [==============================] - 0s 730us/step - loss: 0.2253 - mse:
0.2253
Epoch 1658/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2243 - mse: 0.
2243
Epoch 1659/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2238 - mse: 0.
2238
Epoch 1660/2000
4/4 [==============================] - 0s 719us/step - loss: 0.2243 - mse:
0.2243
Epoch 1661/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2246 - mse: 0.
2246
Epoch 1662/2000
4/4 [==============================] - 0s 825us/step - loss: 0.2233 - mse:
0.2233
Epoch 1663/2000
4/4 [==============================] - 0s 701us/step - loss: 0.2238 - mse:
0.2238
Epoch 1664/2000
4/4 [==============================] - 0s 779us/step - loss: 0.2230 - mse:
0.2230
Epoch 1665/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2255 - mse: 0.
2255
Epoch 1666/2000
4/4 [==============================] - 0s 667us/step - loss: 0.2234 - mse:
0.2234
Epoch 1667/2000
4/4 [==============================] - 0s 826us/step - loss: 0.2250 - mse:
0.2250
Epoch 1668/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2233 - mse: 0.
2233
Epoch 1669/2000
4/4 [==============================] - 0s 733us/step - loss: 0.2244 - mse:
0.2244
Epoch 1670/2000
4/4 [==============================] - 0s 766us/step - loss: 0.2230 - mse:
0.2230
Epoch 1671/2000
4/4 [==============================] - 0s 971us/step - loss: 0.2248 - mse:
0.2248
Epoch 1672/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2229 - mse: 0.
2229
Epoch 1673/2000
4/4 [==============================] - 0s 700us/step - loss: 0.2244 - mse:
0.2244
Epoch 1674/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2242 - mse: 0.
2242
Epoch 1675/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2236 - mse: 0.
2236
Epoch 1676/2000
4/4 [==============================] - 0s 839us/step - loss: 0.2238 - mse:
0.2238
Epoch 1677/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2255 - mse: 0.
2255
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
89 of 113 9/23/21, 09:01
Epoch 1678/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2258 - mse: 0.
2258
Epoch 1679/2000
4/4 [==============================] - 0s 680us/step - loss: 0.2236 - mse:
0.2236
Epoch 1680/2000
4/4 [==============================] - 0s 986us/step - loss: 0.2271 - mse:
0.2271
Epoch 1681/2000
4/4 [==============================] - 0s 954us/step - loss: 0.2237 - mse:
0.2237
Epoch 1682/2000
4/4 [==============================] - 0s 743us/step - loss: 0.2227 - mse:
0.2227
Epoch 1683/2000
4/4 [==============================] - 0s 687us/step - loss: 0.2244 - mse:
0.2244
Epoch 1684/2000
4/4 [==============================] - 0s 969us/step - loss: 0.2276 - mse:
0.2276
Epoch 1685/2000
4/4 [==============================] - 0s 719us/step - loss: 0.2317 - mse:
0.2317
Epoch 1686/2000
4/4 [==============================] - 0s 844us/step - loss: 0.2231 - mse:
0.2231
Epoch 1687/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2254 - mse: 0.
2254
Epoch 1688/2000
4/4 [==============================] - 0s 846us/step - loss: 0.2224 - mse:
0.2224
Epoch 1689/2000
4/4 [==============================] - 0s 817us/step - loss: 0.2224 - mse:
0.2224
Epoch 1690/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2218 - mse: 0.
2218
Epoch 1691/2000
4/4 [==============================] - 0s 990us/step - loss: 0.2220 - mse:
0.2220
Epoch 1692/2000
4/4 [==============================] - 0s 712us/step - loss: 0.2265 - mse:
0.2265
Epoch 1693/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2223 - mse: 0.
2223
Epoch 1694/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2240 - mse: 0.
2240
Epoch 1695/2000
4/4 [==============================] - 0s 739us/step - loss: 0.2230 - mse:
0.2230
Epoch 1696/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2219 - mse: 0.
2219
Epoch 1697/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2240 - mse: 0.
2240
Epoch 1698/2000
4/4 [==============================] - 0s 742us/step - loss: 0.2220 - mse:
0.2220
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
90 of 113 9/23/21, 09:01
Epoch 1699/2000
4/4 [==============================] - 0s 862us/step - loss: 0.2219 - mse:
0.2219
Epoch 1700/2000
4/4 [==============================] - 0s 925us/step - loss: 0.2238 - mse:
0.2238
Epoch 1701/2000
4/4 [==============================] - 0s 702us/step - loss: 0.2232 - mse:
0.2232
Epoch 1702/2000
4/4 [==============================] - 0s 801us/step - loss: 0.2218 - mse:
0.2218
Epoch 1703/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2258 - mse: 0.
2258
Epoch 1704/2000
4/4 [==============================] - 0s 748us/step - loss: 0.2270 - mse:
0.2270
Epoch 1705/2000
4/4 [==============================] - 0s 868us/step - loss: 0.2220 - mse:
0.2220
Epoch 1706/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2228 - mse: 0.
2228
Epoch 1707/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2251 - mse: 0.
2251
Epoch 1708/2000
4/4 [==============================] - 0s 652us/step - loss: 0.2220 - mse:
0.2220
Epoch 1709/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2264 - mse: 0.
2264
Epoch 1710/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2228 - mse: 0.
2228
Epoch 1711/2000
4/4 [==============================] - 0s 649us/step - loss: 0.2261 - mse:
0.2261
Epoch 1712/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2231 - mse: 0.
2231
Epoch 1713/2000
4/4 [==============================] - 0s 937us/step - loss: 0.2235 - mse:
0.2235
Epoch 1714/2000
4/4 [==============================] - 0s 980us/step - loss: 0.2242 - mse:
0.2242
Epoch 1715/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2214 - mse: 0.
2214
Epoch 1716/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2211 - mse: 0.
2211
Epoch 1717/2000
4/4 [==============================] - 0s 792us/step - loss: 0.2227 - mse:
0.2227
Epoch 1718/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2259 - mse: 0.
2259
Epoch 1719/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2209 - mse: 0.
2209
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
91 of 113 9/23/21, 09:01
Epoch 1720/2000
4/4 [==============================] - 0s 697us/step - loss: 0.2220 - mse:
0.2220
Epoch 1721/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2255 - mse: 0.
2255
Epoch 1722/2000
4/4 [==============================] - 0s 745us/step - loss: 0.2224 - mse:
0.2224
Epoch 1723/2000
4/4 [==============================] - 0s 714us/step - loss: 0.2263 - mse:
0.2263
Epoch 1724/2000
4/4 [==============================] - 0s 2ms/step - loss: 0.2220 - mse: 0.
2220
Epoch 1725/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2235 - mse: 0.
2235
Epoch 1726/2000
4/4 [==============================] - 0s 747us/step - loss: 0.2223 - mse:
0.2223
Epoch 1727/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2236 - mse: 0.
2236
Epoch 1728/2000
4/4 [==============================] - 0s 942us/step - loss: 0.2216 - mse:
0.2216
Epoch 1729/2000
4/4 [==============================] - 0s 696us/step - loss: 0.2241 - mse:
0.2241
Epoch 1730/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2223 - mse: 0.
2223
Epoch 1731/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2218 - mse: 0.
2218
Epoch 1732/2000
4/4 [==============================] - 0s 824us/step - loss: 0.2209 - mse:
0.2209
Epoch 1733/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2241 - mse: 0.
2241
Epoch 1734/2000
4/4 [==============================] - 0s 908us/step - loss: 0.2221 - mse:
0.2221
Epoch 1735/2000
4/4 [==============================] - 0s 689us/step - loss: 0.2233 - mse:
0.2233
Epoch 1736/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2210 - mse: 0.
2210
Epoch 1737/2000
4/4 [==============================] - 0s 784us/step - loss: 0.2237 - mse:
0.2237
Epoch 1738/2000
4/4 [==============================] - 0s 717us/step - loss: 0.2209 - mse:
0.2209
Epoch 1739/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2210 - mse: 0.
2210
Epoch 1740/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2207 - mse: 0.
2207
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
92 of 113 9/23/21, 09:01
Epoch 1741/2000
4/4 [==============================] - 0s 746us/step - loss: 0.2205 - mse:
0.2205
Epoch 1742/2000
4/4 [==============================] - 0s 694us/step - loss: 0.2245 - mse:
0.2245
Epoch 1743/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2226 - mse: 0.
2226
Epoch 1744/2000
4/4 [==============================] - 0s 787us/step - loss: 0.2215 - mse:
0.2215
Epoch 1745/2000
4/4 [==============================] - 0s 654us/step - loss: 0.2247 - mse:
0.2247
Epoch 1746/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2201 - mse: 0.
2201
Epoch 1747/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2221 - mse: 0.
2221
Epoch 1748/2000
4/4 [==============================] - 0s 652us/step - loss: 0.2202 - mse:
0.2202
Epoch 1749/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2229 - mse: 0.
2229
Epoch 1750/2000
4/4 [==============================] - 0s 696us/step - loss: 0.2207 - mse:
0.2207
Epoch 1751/2000
4/4 [==============================] - 0s 671us/step - loss: 0.2248 - mse:
0.2248
Epoch 1752/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2263 - mse: 0.
2263
Epoch 1753/2000
4/4 [==============================] - 0s 933us/step - loss: 0.2205 - mse:
0.2205
Epoch 1754/2000
4/4 [==============================] - 0s 672us/step - loss: 0.2230 - mse:
0.2230
Epoch 1755/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2199 - mse: 0.
2199
Epoch 1756/2000
4/4 [==============================] - 0s 891us/step - loss: 0.2214 - mse:
0.2214
Epoch 1757/2000
4/4 [==============================] - 0s 803us/step - loss: 0.2208 - mse:
0.2208
Epoch 1758/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2210 - mse: 0.
2210
Epoch 1759/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2271 - mse: 0.
2271
Epoch 1760/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2198 - mse: 0.
2198
Epoch 1761/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2201 - mse: 0.
2201
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
93 of 113 9/23/21, 09:01
Epoch 1762/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2218 - mse: 0.
2218
Epoch 1763/2000
4/4 [==============================] - 0s 757us/step - loss: 0.2228 - mse:
0.2228
Epoch 1764/2000
4/4 [==============================] - 0s 934us/step - loss: 0.2209 - mse:
0.2209
Epoch 1765/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2259 - mse: 0.
2259
Epoch 1766/2000
4/4 [==============================] - 0s 793us/step - loss: 0.2237 - mse:
0.2237
Epoch 1767/2000
4/4 [==============================] - 0s 765us/step - loss: 0.2254 - mse:
0.2254
Epoch 1768/2000
4/4 [==============================] - 0s 2ms/step - loss: 0.2205 - mse: 0.
2205
Epoch 1769/2000
4/4 [==============================] - 0s 714us/step - loss: 0.2244 - mse:
0.2244
Epoch 1770/2000
4/4 [==============================] - 0s 759us/step - loss: 0.2200 - mse:
0.2200
Epoch 1771/2000
4/4 [==============================] - 0s 846us/step - loss: 0.2205 - mse:
0.2205
Epoch 1772/2000
4/4 [==============================] - 0s 850us/step - loss: 0.2207 - mse:
0.2207
Epoch 1773/2000
4/4 [==============================] - 0s 846us/step - loss: 0.2192 - mse:
0.2192
Epoch 1774/2000
4/4 [==============================] - 0s 911us/step - loss: 0.2194 - mse:
0.2194
Epoch 1775/2000
4/4 [==============================] - 0s 748us/step - loss: 0.2225 - mse:
0.2225
Epoch 1776/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2202 - mse: 0.
2202
Epoch 1777/2000
4/4 [==============================] - 0s 909us/step - loss: 0.2203 - mse:
0.2203
Epoch 1778/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2204 - mse: 0.
2204
Epoch 1779/2000
4/4 [==============================] - 0s 777us/step - loss: 0.2220 - mse:
0.2220
Epoch 1780/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2200 - mse: 0.
2200
Epoch 1781/2000
4/4 [==============================] - 0s 733us/step - loss: 0.2194 - mse:
0.2194
Epoch 1782/2000
4/4 [==============================] - 0s 794us/step - loss: 0.2248 - mse:
0.2248
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
94 of 113 9/23/21, 09:01
Epoch 1783/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2256 - mse: 0.
2256
Epoch 1784/2000
4/4 [==============================] - 0s 810us/step - loss: 0.2200 - mse:
0.2200
Epoch 1785/2000
4/4 [==============================] - 0s 695us/step - loss: 0.2197 - mse:
0.2197
Epoch 1786/2000
4/4 [==============================] - 0s 745us/step - loss: 0.2190 - mse:
0.2190
Epoch 1787/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2188 - mse: 0.
2188
Epoch 1788/2000
4/4 [==============================] - 0s 757us/step - loss: 0.2206 - mse:
0.2206
Epoch 1789/2000
4/4 [==============================] - 0s 915us/step - loss: 0.2301 - mse:
0.2301
Epoch 1790/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2194 - mse: 0.
2194
Epoch 1791/2000
4/4 [==============================] - 0s 755us/step - loss: 0.2247 - mse:
0.2247
Epoch 1792/2000
4/4 [==============================] - 0s 715us/step - loss: 0.2189 - mse:
0.2189
Epoch 1793/2000
4/4 [==============================] - 0s 976us/step - loss: 0.2197 - mse:
0.2197
Epoch 1794/2000
4/4 [==============================] - 0s 712us/step - loss: 0.2200 - mse:
0.2200
Epoch 1795/2000
4/4 [==============================] - 0s 834us/step - loss: 0.2201 - mse:
0.2201
Epoch 1796/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2195 - mse: 0.
2195
Epoch 1797/2000
4/4 [==============================] - 0s 880us/step - loss: 0.2185 - mse:
0.2185
Epoch 1798/2000
4/4 [==============================] - 0s 705us/step - loss: 0.2193 - mse:
0.2193
Epoch 1799/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2203 - mse: 0.
2203
Epoch 1800/2000
4/4 [==============================] - 0s 979us/step - loss: 0.2201 - mse:
0.2201
Epoch 1801/2000
4/4 [==============================] - 0s 868us/step - loss: 0.2197 - mse:
0.2197
Epoch 1802/2000
4/4 [==============================] - 0s 676us/step - loss: 0.2195 - mse:
0.2195
Epoch 1803/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2203 - mse: 0.
2203
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
95 of 113 9/23/21, 09:01
Epoch 1804/2000
4/4 [==============================] - 0s 662us/step - loss: 0.2188 - mse:
0.2188
Epoch 1805/2000
4/4 [==============================] - 0s 817us/step - loss: 0.2192 - mse:
0.2192
Epoch 1806/2000
4/4 [==============================] - 0s 937us/step - loss: 0.2204 - mse:
0.2204
Epoch 1807/2000
4/4 [==============================] - 0s 735us/step - loss: 0.2184 - mse:
0.2184
Epoch 1808/2000
4/4 [==============================] - 0s 679us/step - loss: 0.2182 - mse:
0.2182
Epoch 1809/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2193 - mse: 0.
2193
Epoch 1810/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2197 - mse: 0.
2197
Epoch 1811/2000
4/4 [==============================] - 0s 825us/step - loss: 0.2182 - mse:
0.2182
Epoch 1812/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2213 - mse: 0.
2213
Epoch 1813/2000
4/4 [==============================] - 0s 894us/step - loss: 0.2231 - mse:
0.2231
Epoch 1814/2000
4/4 [==============================] - 0s 793us/step - loss: 0.2195 - mse:
0.2195
Epoch 1815/2000
4/4 [==============================] - 0s 976us/step - loss: 0.2209 - mse:
0.2209
Epoch 1816/2000
4/4 [==============================] - 0s 954us/step - loss: 0.2180 - mse:
0.2180
Epoch 1817/2000
4/4 [==============================] - 0s 722us/step - loss: 0.2197 - mse:
0.2197
Epoch 1818/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2181 - mse: 0.
2181
Epoch 1819/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2180 - mse: 0.
2180
Epoch 1820/2000
4/4 [==============================] - 0s 791us/step - loss: 0.2203 - mse:
0.2203
Epoch 1821/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2184 - mse: 0.
2184
Epoch 1822/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2201 - mse: 0.
2201
Epoch 1823/2000
4/4 [==============================] - 0s 786us/step - loss: 0.2226 - mse:
0.2226
Epoch 1824/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2214 - mse: 0.
2214
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
96 of 113 9/23/21, 09:01
Epoch 1825/2000
4/4 [==============================] - 0s 950us/step - loss: 0.2289 - mse:
0.2289
Epoch 1826/2000
4/4 [==============================] - 0s 852us/step - loss: 0.2183 - mse:
0.2183
Epoch 1827/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2183 - mse: 0.
2183
Epoch 1828/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2203 - mse: 0.
2203
Epoch 1829/2000
4/4 [==============================] - 0s 741us/step - loss: 0.2215 - mse:
0.2215
Epoch 1830/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2193 - mse: 0.
2193
Epoch 1831/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2185 - mse: 0.
2185
Epoch 1832/2000
4/4 [==============================] - 0s 695us/step - loss: 0.2185 - mse:
0.2185
Epoch 1833/2000
4/4 [==============================] - 0s 987us/step - loss: 0.2194 - mse:
0.2194
Epoch 1834/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2176 - mse: 0.
2176
Epoch 1835/2000
4/4 [==============================] - 0s 704us/step - loss: 0.2240 - mse:
0.2240
Epoch 1836/2000
4/4 [==============================] - 0s 898us/step - loss: 0.2191 - mse:
0.2191
Epoch 1837/2000
4/4 [==============================] - 0s 939us/step - loss: 0.2182 - mse:
0.2182
Epoch 1838/2000
4/4 [==============================] - 0s 991us/step - loss: 0.2193 - mse:
0.2193
Epoch 1839/2000
4/4 [==============================] - 0s 726us/step - loss: 0.2196 - mse:
0.2196
Epoch 1840/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2198 - mse: 0.
2198
Epoch 1841/2000
4/4 [==============================] - 0s 743us/step - loss: 0.2212 - mse:
0.2212
Epoch 1842/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2176 - mse: 0.
2176
Epoch 1843/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2188 - mse: 0.
2188
Epoch 1844/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2173 - mse: 0.
2173
Epoch 1845/2000
4/4 [==============================] - 0s 724us/step - loss: 0.2181 - mse:
0.2181
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
97 of 113 9/23/21, 09:01
Epoch 1846/2000
4/4 [==============================] - 0s 900us/step - loss: 0.2177 - mse:
0.2177
Epoch 1847/2000
4/4 [==============================] - 0s 994us/step - loss: 0.2180 - mse:
0.2180
Epoch 1848/2000
4/4 [==============================] - 0s 822us/step - loss: 0.2174 - mse:
0.2174
Epoch 1849/2000
4/4 [==============================] - 0s 933us/step - loss: 0.2204 - mse:
0.2204
Epoch 1850/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2253 - mse: 0.
2253
Epoch 1851/2000
4/4 [==============================] - 0s 742us/step - loss: 0.2201 - mse:
0.2201
Epoch 1852/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2180 - mse: 0.
2180
Epoch 1853/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2237 - mse: 0.
2237
Epoch 1854/2000
4/4 [==============================] - 0s 950us/step - loss: 0.2168 - mse:
0.2168
Epoch 1855/2000
4/4 [==============================] - 0s 997us/step - loss: 0.2188 - mse:
0.2188
Epoch 1856/2000
4/4 [==============================] - 0s 945us/step - loss: 0.2174 - mse:
0.2174
Epoch 1857/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2193 - mse: 0.
2193
Epoch 1858/2000
4/4 [==============================] - 0s 883us/step - loss: 0.2191 - mse:
0.2191
Epoch 1859/2000
4/4 [==============================] - 0s 787us/step - loss: 0.2203 - mse:
0.2203
Epoch 1860/2000
4/4 [==============================] - 0s 868us/step - loss: 0.2186 - mse:
0.2186
Epoch 1861/2000
4/4 [==============================] - 0s 914us/step - loss: 0.2178 - mse:
0.2178
Epoch 1862/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2171 - mse: 0.
2171
Epoch 1863/2000
4/4 [==============================] - 0s 946us/step - loss: 0.2174 - mse:
0.2174
Epoch 1864/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2190 - mse: 0.
2190
Epoch 1865/2000
4/4 [==============================] - 0s 799us/step - loss: 0.2180 - mse:
0.2180
Epoch 1866/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2199 - mse: 0.
2199
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
98 of 113 9/23/21, 09:01
Epoch 1867/2000
4/4 [==============================] - 0s 976us/step - loss: 0.2169 - mse:
0.2169
Epoch 1868/2000
4/4 [==============================] - 0s 771us/step - loss: 0.2181 - mse:
0.2181
Epoch 1869/2000
4/4 [==============================] - 0s 881us/step - loss: 0.2183 - mse:
0.2183
Epoch 1870/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2164 - mse: 0.
2164
Epoch 1871/2000
4/4 [==============================] - 0s 991us/step - loss: 0.2162 - mse:
0.2162
Epoch 1872/2000
4/4 [==============================] - 0s 858us/step - loss: 0.2164 - mse:
0.2164
Epoch 1873/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2176 - mse: 0.
2176
Epoch 1874/2000
4/4 [==============================] - 0s 772us/step - loss: 0.2219 - mse:
0.2219
Epoch 1875/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2165 - mse: 0.
2165
Epoch 1876/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2197 - mse: 0.
2197
Epoch 1877/2000
4/4 [==============================] - 0s 717us/step - loss: 0.2175 - mse:
0.2175
Epoch 1878/2000
4/4 [==============================] - 0s 895us/step - loss: 0.2173 - mse:
0.2173
Epoch 1879/2000
4/4 [==============================] - 0s 742us/step - loss: 0.2189 - mse:
0.2189
Epoch 1880/2000
4/4 [==============================] - 0s 950us/step - loss: 0.2193 - mse:
0.2193
Epoch 1881/2000
4/4 [==============================] - 0s 716us/step - loss: 0.2170 - mse:
0.2170
Epoch 1882/2000
4/4 [==============================] - 0s 765us/step - loss: 0.2160 - mse:
0.2160
Epoch 1883/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2164 - mse: 0.
2164
Epoch 1884/2000
4/4 [==============================] - 0s 821us/step - loss: 0.2207 - mse:
0.2207
Epoch 1885/2000
4/4 [==============================] - 0s 675us/step - loss: 0.2209 - mse:
0.2209
Epoch 1886/2000
4/4 [==============================] - 0s 887us/step - loss: 0.2228 - mse:
0.2228
Epoch 1887/2000
4/4 [==============================] - 0s 820us/step - loss: 0.2186 - mse:
0.2186
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
99 of 113 9/23/21, 09:01
Epoch 1888/2000
4/4 [==============================] - 0s 821us/step - loss: 0.2170 - mse:
0.2170
Epoch 1889/2000
4/4 [==============================] - 0s 886us/step - loss: 0.2162 - mse:
0.2162
Epoch 1890/2000
4/4 [==============================] - 0s 857us/step - loss: 0.2184 - mse:
0.2184
Epoch 1891/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2211 - mse: 0.
2211
Epoch 1892/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2185 - mse: 0.
2185
Epoch 1893/2000
4/4 [==============================] - 0s 905us/step - loss: 0.2158 - mse:
0.2158
Epoch 1894/2000
4/4 [==============================] - 0s 831us/step - loss: 0.2186 - mse:
0.2186
Epoch 1895/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2167 - mse: 0.
2167
Epoch 1896/2000
4/4 [==============================] - 0s 882us/step - loss: 0.2223 - mse:
0.2223
Epoch 1897/2000
4/4 [==============================] - 0s 890us/step - loss: 0.2188 - mse:
0.2188
Epoch 1898/2000
4/4 [==============================] - 0s 917us/step - loss: 0.2213 - mse:
0.2213
Epoch 1899/2000
4/4 [==============================] - 0s 855us/step - loss: 0.2173 - mse:
0.2173
Epoch 1900/2000
4/4 [==============================] - 0s 750us/step - loss: 0.2158 - mse:
0.2158
Epoch 1901/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2168 - mse: 0.
2168
Epoch 1902/2000
4/4 [==============================] - 0s 709us/step - loss: 0.2189 - mse:
0.2189
Epoch 1903/2000
4/4 [==============================] - 0s 891us/step - loss: 0.2204 - mse:
0.2204
Epoch 1904/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2159 - mse: 0.
2159
Epoch 1905/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2155 - mse: 0.
2155
Epoch 1906/2000
4/4 [==============================] - 0s 897us/step - loss: 0.2163 - mse:
0.2163
Epoch 1907/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2155 - mse: 0.
2155
Epoch 1908/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2166 - mse: 0.
2166
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
100 of 113 9/23/21, 09:01
Epoch 1909/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2212 - mse: 0.
2212
Epoch 1910/2000
4/4 [==============================] - 0s 896us/step - loss: 0.2176 - mse:
0.2176
Epoch 1911/2000
4/4 [==============================] - 0s 937us/step - loss: 0.2155 - mse:
0.2155
Epoch 1912/2000
4/4 [==============================] - 0s 908us/step - loss: 0.2198 - mse:
0.2198
Epoch 1913/2000
4/4 [==============================] - 0s 740us/step - loss: 0.2176 - mse:
0.2176
Epoch 1914/2000
4/4 [==============================] - 0s 981us/step - loss: 0.2186 - mse:
0.2186
Epoch 1915/2000
4/4 [==============================] - 0s 679us/step - loss: 0.2173 - mse:
0.2173
Epoch 1916/2000
4/4 [==============================] - 0s 796us/step - loss: 0.2168 - mse:
0.2168
Epoch 1917/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2160 - mse: 0.
2160
Epoch 1918/2000
4/4 [==============================] - 0s 995us/step - loss: 0.2168 - mse:
0.2168
Epoch 1919/2000
4/4 [==============================] - 0s 732us/step - loss: 0.2152 - mse:
0.2152
Epoch 1920/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2174 - mse: 0.
2174
Epoch 1921/2000
4/4 [==============================] - 0s 792us/step - loss: 0.2167 - mse:
0.2167
Epoch 1922/2000
4/4 [==============================] - 0s 872us/step - loss: 0.2153 - mse:
0.2153
Epoch 1923/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2176 - mse: 0.
2176
Epoch 1924/2000
4/4 [==============================] - 0s 737us/step - loss: 0.2159 - mse:
0.2159
Epoch 1925/2000
4/4 [==============================] - 0s 878us/step - loss: 0.2175 - mse:
0.2175
Epoch 1926/2000
4/4 [==============================] - 0s 999us/step - loss: 0.2160 - mse:
0.2160
Epoch 1927/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2166 - mse: 0.
2166
Epoch 1928/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2146 - mse: 0.
2146
Epoch 1929/2000
4/4 [==============================] - 0s 994us/step - loss: 0.2146 - mse:
0.2146
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
101 of 113 9/23/21, 09:01
Epoch 1930/2000
4/4 [==============================] - 0s 805us/step - loss: 0.2184 - mse:
0.2184
Epoch 1931/2000
4/4 [==============================] - 0s 827us/step - loss: 0.2167 - mse:
0.2167
Epoch 1932/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2156 - mse: 0.
2156
Epoch 1933/2000
4/4 [==============================] - 0s 756us/step - loss: 0.2183 - mse:
0.2183
Epoch 1934/2000
4/4 [==============================] - 0s 944us/step - loss: 0.2189 - mse:
0.2189
Epoch 1935/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2158 - mse: 0.
2158
Epoch 1936/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2177 - mse: 0.
2177
Epoch 1937/2000
4/4 [==============================] - 0s 804us/step - loss: 0.2146 - mse:
0.2146
Epoch 1938/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2180 - mse: 0.
2180
Epoch 1939/2000
4/4 [==============================] - 0s 874us/step - loss: 0.2173 - mse:
0.2173
Epoch 1940/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2158 - mse: 0.
2158
Epoch 1941/2000
4/4 [==============================] - 0s 2ms/step - loss: 0.2156 - mse: 0.
2156
Epoch 1942/2000
4/4 [==============================] - 0s 767us/step - loss: 0.2146 - mse:
0.2146
Epoch 1943/2000
4/4 [==============================] - 0s 871us/step - loss: 0.2166 - mse:
0.2166
Epoch 1944/2000
4/4 [==============================] - 0s 957us/step - loss: 0.2143 - mse:
0.2143
Epoch 1945/2000
4/4 [==============================] - 0s 951us/step - loss: 0.2186 - mse:
0.2186
Epoch 1946/2000
4/4 [==============================] - 0s 774us/step - loss: 0.2186 - mse:
0.2186
Epoch 1947/2000
4/4 [==============================] - 0s 2ms/step - loss: 0.2164 - mse: 0.
2164
Epoch 1948/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2152 - mse: 0.
2152
Epoch 1949/2000
4/4 [==============================] - 0s 926us/step - loss: 0.2143 - mse:
0.2143
Epoch 1950/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2152 - mse: 0.
2152
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
102 of 113 9/23/21, 09:01
Epoch 1951/2000
4/4 [==============================] - 0s 775us/step - loss: 0.2178 - mse:
0.2178
Epoch 1952/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2176 - mse: 0.
2176
Epoch 1953/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2153 - mse: 0.
2153
Epoch 1954/2000
4/4 [==============================] - 0s 864us/step - loss: 0.2139 - mse:
0.2139
Epoch 1955/2000
4/4 [==============================] - 0s 850us/step - loss: 0.2152 - mse:
0.2152
Epoch 1956/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2161 - mse: 0.
2161
Epoch 1957/2000
4/4 [==============================] - 0s 734us/step - loss: 0.2162 - mse:
0.2162
Epoch 1958/2000
4/4 [==============================] - 0s 737us/step - loss: 0.2167 - mse:
0.2167
Epoch 1959/2000
4/4 [==============================] - 0s 917us/step - loss: 0.2149 - mse:
0.2149
Epoch 1960/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2145 - mse: 0.
2145
Epoch 1961/2000
4/4 [==============================] - 0s 840us/step - loss: 0.2144 - mse:
0.2144
Epoch 1962/2000
4/4 [==============================] - 0s 721us/step - loss: 0.2152 - mse:
0.2152
Epoch 1963/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2151 - mse: 0.
2151
Epoch 1964/2000
4/4 [==============================] - 0s 750us/step - loss: 0.2163 - mse:
0.2163
Epoch 1965/2000
4/4 [==============================] - 0s 846us/step - loss: 0.2139 - mse:
0.2139
Epoch 1966/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2166 - mse: 0.
2166
Epoch 1967/2000
4/4 [==============================] - 0s 805us/step - loss: 0.2135 - mse:
0.2135
Epoch 1968/2000
4/4 [==============================] - 0s 827us/step - loss: 0.2154 - mse:
0.2154
Epoch 1969/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2153 - mse: 0.
2153
Epoch 1970/2000
4/4 [==============================] - 0s 842us/step - loss: 0.2144 - mse:
0.2144
Epoch 1971/2000
4/4 [==============================] - 0s 780us/step - loss: 0.2144 - mse:
0.2144
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
103 of 113 9/23/21, 09:01
Epoch 1972/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2168 - mse: 0.
2168
Epoch 1973/2000
4/4 [==============================] - 0s 809us/step - loss: 0.2174 - mse:
0.2174
Epoch 1974/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2141 - mse: 0.
2141
Epoch 1975/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2168 - mse: 0.
2168
Epoch 1976/2000
4/4 [==============================] - 0s 746us/step - loss: 0.2180 - mse:
0.2180
Epoch 1977/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2167 - mse: 0.
2167
Epoch 1978/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2139 - mse: 0.
2139
Epoch 1979/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2148 - mse: 0.
2148
Epoch 1980/2000
4/4 [==============================] - 0s 866us/step - loss: 0.2141 - mse:
0.2141
Epoch 1981/2000
4/4 [==============================] - 0s 927us/step - loss: 0.2159 - mse:
0.2159
Epoch 1982/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2146 - mse: 0.
2146
Epoch 1983/2000
4/4 [==============================] - 0s 851us/step - loss: 0.2158 - mse:
0.2158
Epoch 1984/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2187 - mse: 0.
2187
Epoch 1985/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2159 - mse: 0.
2159
Epoch 1986/2000
4/4 [==============================] - 0s 937us/step - loss: 0.2157 - mse:
0.2157
Epoch 1987/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2132 - mse: 0.
2132
Epoch 1988/2000
4/4 [==============================] - 0s 962us/step - loss: 0.2138 - mse:
0.2138
Epoch 1989/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2140 - mse: 0.
2140
Epoch 1990/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2152 - mse: 0.
2152
Epoch 1991/2000
4/4 [==============================] - 0s 883us/step - loss: 0.2132 - mse:
0.2132
Epoch 1992/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2152 - mse: 0.
2152
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
104 of 113 9/23/21, 09:01
Epoch 1993/2000
4/4 [==============================] - 0s 1ms/step - loss: 0.2133 - mse: 0.
2133
Epoch 1994/2000
4/4 [==============================] - 0s 833us/step - loss: 0.2149 - mse:
0.2149
Epoch 1995/2000
Let's test how well the network models the data
0.09983341664682815
[0.99505436]
68.03778650925375
0.6844330963696056
100
68.44330963696056
MSE= 0.21634121918016117
In [38]:
from sklearn.metrics import mean_squared_error
y_pred = model.predict(t)
print(y[1])
print(y_pred[1])
print(np.sum(np.absolute(np.subtract(y,y_pred)))/len(t))
print(np.square(np.subtract(y,y_pred)).mean())
print(len(y))
print(np.divide(np.sum(np.square(y-y_pred)),len(y)))
print('MSE=',mean_squared_error(y,y_pred))
plt.plot(t, y, label='y')
plt.plot(t, y_pred, label='y_pred')
plt.title('Training data (sine wave)')
plt.xlabel('Time')
plt.ylabel('y = sin(t)')
plt.grid(True, which='both')
plt.legend()
plt.show()
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
105 of 113 9/23/21, 09:01
MLP Classifier
Let's make two classes in 2D
In [39]:
# Coodinate system
plt.xlabel('pituus [m]')
#plt.ylabel('paino [kg]')
plt.axis([0.5,2.5,-1.1,+1.1])
# Generate random points for training
np.random.seed(11) # to always get the same points
N = 200
x_h = np.random.normal(1.1,0.3,N)
x_e = np.random.normal(1.9,0.4,N)
plt.plot(x_h,np.zeros([N,1]),'ro', markersize=8, label="hobitti")
plt.plot(x_e,np.zeros([N,1]),'gs', markersize=8, label="haltija")
plt.title('Näytteitä kahdesta luokasta')
plt.legend()
plt.show()
# Generate random points for testing
N_t = 50
x_h_test = np.random.normal(1.1,0.3,N_t) # h as hobit
x_e_test = np.random.normal(1.9,0.4,N_t) # e as elf
plt.plot(x_h,np.zeros([N,1]),'ro', markersize=8, label="hobitti")
plt.plot(x_e,np.zeros([N,1]),'gs', markersize=8, label="haltija")
plt.plot(x_e_test,np.zeros([N_t,1]),'kv',linewidth=1, markersize=12, label=
plt.plot(x_h_test,np.zeros([N_t,1]),'kv', markersize=12)
plt.title('Luokiteltavia näytteitä')
plt.legend()
plt.show()
# 1-NN classifier
# Form the train input and output vectors (1: hobit, 2: elf)
x_tr = np.concatenate((x_h,x_e))
y_tr = np.concatenate((1*np.ones([x_h.shape[0],1]),2*np.ones([x_e.shape[0],
# Form the test input and output vectors
x_te = np.concatenate((x_h_test,x_e_test))
y_te = np.concatenate((1*np.ones([N_t,1]),2*np.ones([N_t,1])))
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
106 of 113 9/23/21, 09:01
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net...
107 of 113 9/23/21, 09:01
Epoch 1/100
13/13 [==============================] - 0s 566us/step - loss: 0.2739 - ms
e: 0.2739
Epoch 2/100
13/13 [==============================] - 0s 684us/step - loss: 0.2630 - ms
e: 0.2630
Epoch 3/100
13/13 [==============================] - 0s 867us/step - loss: 0.2568 - ms
e: 0.2568
Epoch 4/100
13/13 [==============================] - 0s 568us/step - loss: 0.2563 - ms
e: 0.2563
Epoch 5/100
13/13 [==============================] - 0s 850us/step - loss: 0.2537 - ms
In [44]:
# With this example you learn the meaning of network size (# of neurons in the first layer:
# and the effect of learning rate 0.1 vs. 0.001
# Tee neuroverkko
model = Sequential()
# 1 tai 100
model.add(Dense(100, input_dim=1, activation='sigmoid'))
# Ulostuloja aina kaksi, yksi kummallekin luokalle
model.add(Dense(2, activation='sigmoid'))
# 0.1 tai 0.001
opt = keras.optimizers.SGD(lr=0.1)
model.compile(optimizer=opt, loss='mse', metrics=['mse'])
# Yksi-kuuma (one hot) -koodataan luokka 1 -> [1 0] 2 -> [0 1]
y_tr_2 = np.empty([y_tr.shape[0],2])
y_tr_2[np.where(y_tr==1),0] = 1
y_tr_2[np.where(y_tr==1),1] = 0
y_tr_2[np.where(y_tr==2),0] = 0
y_tr_2[np.where(y_tr==2),1] = 1
# Opetus – epokkeja 1 tai 100
model.fit(x_tr, y_tr_2, epochs=100, verbose=1)
# Tulokset opetuspisteille
y_tr_pred = np.empty(y_tr.shape)
y_tr_pred_2 = np.squeeze(model.predict(x_tr))
for pred_ind in range(y_tr_pred_2.shape[0]):
if y_tr_pred_2[pred_ind][0] > y_tr_pred_2[pred_ind][1]:
y_tr_pred[pred_ind] = 1
else:
y_tr_pred[pred_ind] = 2
tot_correct = len(np.where(y_tr-y_tr_pred == 0)[0])
print(f’Classication accuracy (training data): {tot_correct/len(y_tr)*100}%’
# Tulokset testauspisteille
y_te_pred = np.empty(y_te.shape)
y_te_pred_2 = np.squeeze(model.predict(x_te))
for pred_ind in range(y_te_pred_2.shape[0]):
if y_te_pred_2[pred_ind][0] > y_te_pred_2[pred_ind][1]:
y_te_pred[pred_ind] = 1
else:
y_te_pred[pred_ind] = 2
tot_correct = len(np.where(y_te-y_te_pred == 0)[0])
print(f’Classication accuracy (test data): {tot_correct/len(y_te)*100}%’)
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net…
108 of 113 9/23/21, 09:01
e: 0.2537
Epoch 6/100
13/13 [==============================] – 0s 564us/step – loss: 0.2536 – ms
e: 0.2536
Epoch 7/100
13/13 [==============================] – 0s 766us/step – loss: 0.2518 – ms
e: 0.2518
Epoch 8/100
13/13 [==============================] – 0s 815us/step – loss: 0.2529 – ms
e: 0.2529
Epoch 9/100
13/13 [==============================] – 0s 577us/step – loss: 0.2487 – ms
e: 0.2487
Epoch 10/100
13/13 [==============================] – 0s 776us/step – loss: 0.2482 – ms
e: 0.2482
Epoch 11/100
13/13 [==============================] – 0s 739us/step – loss: 0.2478 – ms
e: 0.2478
Epoch 12/100
13/13 [==============================] – 0s 862us/step – loss: 0.2447 – ms
e: 0.2447
Epoch 13/100
13/13 [==============================] – 0s 703us/step – loss: 0.2450 – ms
e: 0.2450
Epoch 14/100
13/13 [==============================] – 0s 777us/step – loss: 0.2424 – ms
e: 0.2424
Epoch 15/100
13/13 [==============================] – 0s 654us/step – loss: 0.2414 – ms
e: 0.2414
Epoch 16/100
13/13 [==============================] – 0s 714us/step – loss: 0.2395 – ms
e: 0.2395
Epoch 17/100
13/13 [==============================] – 0s 801us/step – loss: 0.2391 – ms
e: 0.2391
Epoch 18/100
13/13 [==============================] – 0s 717us/step – loss: 0.2370 – ms
e: 0.2370
Epoch 19/100
13/13 [==============================] – 0s 673us/step – loss: 0.2370 – ms
e: 0.2370
Epoch 20/100
13/13 [==============================] – 0s 852us/step – loss: 0.2341 – ms
e: 0.2341
Epoch 21/100
13/13 [==============================] – 0s 748us/step – loss: 0.2314 – ms
e: 0.2314
Epoch 22/100
13/13 [==============================] – 0s 827us/step – loss: 0.2319 – ms
e: 0.2319
Epoch 23/100
13/13 [==============================] – 0s 729us/step – loss: 0.2308 – ms
e: 0.2308
Epoch 24/100
13/13 [==============================] – 0s 860us/step – loss: 0.2296 – ms
e: 0.2296
Epoch 25/100
13/13 [==============================] – 0s 665us/step – loss: 0.2297 – ms
e: 0.2297
Epoch 26/100
13/13 [==============================] – 0s 674us/step – loss: 0.2283 – ms
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net…
109 of 113 9/23/21, 09:01
e: 0.2283
Epoch 27/100
13/13 [==============================] – 0s 770us/step – loss: 0.2244 – ms
e: 0.2244
Epoch 28/100
13/13 [==============================] – 0s 703us/step – loss: 0.2250 – ms
e: 0.2250
Epoch 29/100
13/13 [==============================] – 0s 674us/step – loss: 0.2236 – ms
e: 0.2236
Epoch 30/100
13/13 [==============================] – 0s 765us/step – loss: 0.2209 – ms
e: 0.2209
Epoch 31/100
13/13 [==============================] – 0s 726us/step – loss: 0.2196 – ms
e: 0.2196
Epoch 32/100
13/13 [==============================] – 0s 661us/step – loss: 0.2189 – ms
e: 0.2189
Epoch 33/100
13/13 [==============================] – 0s 744us/step – loss: 0.2199 – ms
e: 0.2199
Epoch 34/100
13/13 [==============================] – 0s 690us/step – loss: 0.2158 – ms
e: 0.2158
Epoch 35/100
13/13 [==============================] – 0s 641us/step – loss: 0.2115 – ms
e: 0.2115
Epoch 36/100
13/13 [==============================] – 0s 750us/step – loss: 0.2154 – ms
e: 0.2154
Epoch 37/100
13/13 [==============================] – 0s 644us/step – loss: 0.2117 – ms
e: 0.2117
Epoch 38/100
13/13 [==============================] – 0s 694us/step – loss: 0.2107 – ms
e: 0.2107
Epoch 39/100
13/13 [==============================] – 0s 845us/step – loss: 0.2097 – ms
e: 0.2097
Epoch 40/100
13/13 [==============================] – 0s 623us/step – loss: 0.2102 – ms
e: 0.2102
Epoch 41/100
13/13 [==============================] – 0s 749us/step – loss: 0.2083 – ms
e: 0.2083
Epoch 42/100
13/13 [==============================] – 0s 820us/step – loss: 0.2071 – ms
e: 0.2071
Epoch 43/100
13/13 [==============================] – 0s 650us/step – loss: 0.2053 – ms
e: 0.2053
Epoch 44/100
13/13 [==============================] – 0s 745us/step – loss: 0.1968 – ms
e: 0.1968
Epoch 45/100
13/13 [==============================] – 0s 814us/step – loss: 0.1985 – ms
e: 0.1985
Epoch 46/100
13/13 [==============================] – 0s 693us/step – loss: 0.1986 – ms
e: 0.1986
Epoch 47/100
13/13 [==============================] – 0s 633us/step – loss: 0.2027 – ms
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net…
110 of 113 9/23/21, 09:01
e: 0.2027
Epoch 48/100
13/13 [==============================] – 0s 852us/step – loss: 0.1945 – ms
e: 0.1945
Epoch 49/100
13/13 [==============================] – 0s 606us/step – loss: 0.1987 – ms
e: 0.1987
Epoch 50/100
13/13 [==============================] – 0s 704us/step – loss: 0.1940 – ms
e: 0.1940
Epoch 51/100
13/13 [==============================] – 0s 781us/step – loss: 0.1952 – ms
e: 0.1952
Epoch 52/100
13/13 [==============================] – 0s 630us/step – loss: 0.1922 – ms
e: 0.1922
Epoch 53/100
13/13 [==============================] – 0s 721us/step – loss: 0.1854 – ms
e: 0.1854
Epoch 54/100
13/13 [==============================] – 0s 1ms/step – loss: 0.1878 – mse:
0.1878
Epoch 55/100
13/13 [==============================] – 0s 697us/step – loss: 0.1803 – ms
e: 0.1803
Epoch 56/100
13/13 [==============================] – 0s 630us/step – loss: 0.1882 – ms
e: 0.1882
Epoch 57/100
13/13 [==============================] – 0s 690us/step – loss: 0.1819 – ms
e: 0.1819
Epoch 58/100
13/13 [==============================] – 0s 635us/step – loss: 0.1844 – ms
e: 0.1844
Epoch 59/100
13/13 [==============================] – 0s 561us/step – loss: 0.1783 – ms
e: 0.1783
Epoch 60/100
13/13 [==============================] – 0s 663us/step – loss: 0.1773 – ms
e: 0.1773
Epoch 61/100
13/13 [==============================] – 0s 596us/step – loss: 0.1749 – ms
e: 0.1749
Epoch 62/100
13/13 [==============================] – 0s 653us/step – loss: 0.1790 – ms
e: 0.1790
Epoch 63/100
13/13 [==============================] – 0s 620us/step – loss: 0.1734 – ms
e: 0.1734
Epoch 64/100
13/13 [==============================] – 0s 562us/step – loss: 0.1714 – ms
e: 0.1714
Epoch 65/100
13/13 [==============================] – 0s 745us/step – loss: 0.1723 – ms
e: 0.1723
Epoch 66/100
13/13 [==============================] – 0s 545us/step – loss: 0.1716 – ms
e: 0.1716
Epoch 67/100
13/13 [==============================] – 0s 601us/step – loss: 0.1677 – ms
e: 0.1677
Epoch 68/100
13/13 [==============================] – 0s 600us/step – loss: 0.1715 – ms
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net…
111 of 113 9/23/21, 09:01
e: 0.1715
Epoch 69/100
13/13 [==============================] – 0s 575us/step – loss: 0.1687 – ms
e: 0.1687
Epoch 70/100
13/13 [==============================] – 0s 612us/step – loss: 0.1681 – ms
e: 0.1681
Epoch 71/100
13/13 [==============================] – 0s 531us/step – loss: 0.1667 – ms
e: 0.1667
Epoch 72/100
13/13 [==============================] – 0s 679us/step – loss: 0.1554 – ms
e: 0.1554
Epoch 73/100
13/13 [==============================] – 0s 512us/step – loss: 0.1658 – ms
e: 0.1658
Epoch 74/100
13/13 [==============================] – 0s 659us/step – loss: 0.1628 – ms
e: 0.1628
Epoch 75/100
13/13 [==============================] – 0s 663us/step – loss: 0.1630 – ms
e: 0.1630
Epoch 76/100
13/13 [==============================] – 0s 596us/step – loss: 0.1625 – ms
e: 0.1625
Epoch 77/100
13/13 [==============================] – 0s 672us/step – loss: 0.1542 – ms
e: 0.1542
Epoch 78/100
13/13 [==============================] – 0s 499us/step – loss: 0.1508 – ms
e: 0.1508
Epoch 79/100
13/13 [==============================] – 0s 631us/step – loss: 0.1540 – ms
e: 0.1540
Epoch 80/100
13/13 [==============================] – 0s 507us/step – loss: 0.1521 – ms
e: 0.1521
Epoch 81/100
13/13 [==============================] – 0s 716us/step – loss: 0.1530 – ms
e: 0.1530
Epoch 82/100
13/13 [==============================] – 0s 563us/step – loss: 0.1526 – ms
e: 0.1526
Epoch 83/100
13/13 [==============================] – 0s 535us/step – loss: 0.1509 – ms
e: 0.1509
Epoch 84/100
13/13 [==============================] – 0s 708us/step – loss: 0.1517 – ms
e: 0.1517
Epoch 85/100
13/13 [==============================] – 0s 604us/step – loss: 0.1462 – ms
e: 0.1462
Epoch 86/100
13/13 [==============================] – 0s 654us/step – loss: 0.1430 – ms
e: 0.1430
Epoch 87/100
13/13 [==============================] – 0s 599us/step – loss: 0.1439 – ms
e: 0.1439
Epoch 88/100
13/13 [==============================] – 0s 554us/step – loss: 0.1438 – ms
e: 0.1438
Epoch 89/100
13/13 [==============================] – 0s 610us/step – loss: 0.1443 – ms
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net…
112 of 113 9/23/21, 09:01
e: 0.1443
Epoch 90/100
13/13 [==============================] – 0s 507us/step – loss: 0.1469 – ms
e: 0.1469
Epoch 91/100
13/13 [==============================] – 0s 614us/step – loss: 0.1436 – ms
e: 0.1436
Epoch 92/100
13/13 [==============================] – 0s 498us/step – loss: 0.1413 – ms
e: 0.1413
Epoch 93/100
13/13 [==============================] – 0s 637us/step – loss: 0.1430 – ms
e: 0.1430
Epoch 94/100
13/13 [==============================] – 0s 505us/step – loss: 0.1466 – ms
e: 0.1466
Epoch 95/100
13/13 [==============================] – 0s 626us/step – loss: 0.1418 – ms
e: 0.1418
Epoch 96/100
13/13 [==============================] – 0s 605us/step – loss: 0.1450 – ms
e: 0.1450
Epoch 97/100
13/13 [==============================] – 0s 569us/step – loss: 0.1358 – ms
e: 0.1358
Epoch 98/100
13/13 [==============================] – 0s 636us/step – loss: 0.1405 – ms
e: 0.1405
Epoch 99/100
13/13 [==============================] – 0s 540us/step – loss: 0.1327 – ms
e: 0.1327
Epoch 100/100
13/13 [==============================] – 0s 680us/step – loss: 0.1353 – ms
e: 0.1353
Classication accuracy (training data): 86.75%
References
C.M. Bishop (2006): Pattern Recognition and Machine Learning, Chapter 5
lec08_neural_networks http://localhost:8888/nbconvert/html/lec08_neural_net…
113 of 113 9/23/21, 09:01