pdfcoffee
Chapter 1Figure 25: Accuracy for different models and optimizersControlling the optimizer learning rateThere is another approach we can take that involves changing the learning parameterfor our optimizer. As you can see in Figure 26, the best value reached by our threeexperiments [lr=0.1, lr=0.01, lr=0.001] is 0.1, which is the default learning rate forthe optimizer. Good! adam works well out of the box:Figure 26: Accuracy for different learning rates[ 33 ]
Neural Network Foundations with TensorFlow 2.0Increasing the number of internal hiddenneuronsYet another approach involves changing the number of internal hidden neurons. Wereport the results of the experiments with an increasing number of hidden neurons.We see that by increasing the complexity of the model, the runtime increasessignificantly because there are more and more parameters to optimize. However,the gains that we are getting by increasing the size of the network decrease moreand more as the network grows (see Figures 27, 28, and 29). Note that increasing thenumber of hidden neurons after a certain value can reduce the accuracy becausethe network might not be able to generalize well (as shown in Figure 29):Figure 27: Number of parameters for increasing values of internal hidden neuronsFigure 28: Seconds of computation time for increasing values of internal hidden neurons[ 34 ]
- Page 18 and 19: Table of ContentsPretrained models
- Page 20 and 21: PrefaceDeep Learning with TensorFlo
- Page 22 and 23: • Supervised learning, in which t
- Page 24 and 25: PrefaceThe complexity of deep learn
- Page 26 and 27: PrefaceFigure 5: Adoption of deep l
- Page 28 and 29: Chapter 1, Neural Network Foundatio
- Page 30 and 31: PrefaceChapter 13, TensorFlow for M
- Page 32 and 33: ConventionsThere are a number of te
- Page 34: PrefaceReferences1. Deep Learning w
- Page 37 and 38: Neural Network Foundations with Ten
- Page 39 and 40: Neural Network Foundations with Ten
- Page 41 and 42: Neural Network Foundations with Ten
- Page 43 and 44: Neural Network Foundations with Ten
- Page 45 and 46: Neural Network Foundations with Ten
- Page 47 and 48: Neural Network Foundations with Ten
- Page 49 and 50: Neural Network Foundations with Ten
- Page 51 and 52: Neural Network Foundations with Ten
- Page 53 and 54: Neural Network Foundations with Ten
- Page 55 and 56: Neural Network Foundations with Ten
- Page 57 and 58: Neural Network Foundations with Ten
- Page 59 and 60: Neural Network Foundations with Ten
- Page 61 and 62: Neural Network Foundations with Ten
- Page 63 and 64: Neural Network Foundations with Ten
- Page 65 and 66: Neural Network Foundations with Ten
- Page 67: Neural Network Foundations with Ten
- Page 71 and 72: Neural Network Foundations with Ten
- Page 73 and 74: Neural Network Foundations with Ten
- Page 75 and 76: Neural Network Foundations with Ten
- Page 77 and 78: Neural Network Foundations with Ten
- Page 79 and 80: Neural Network Foundations with Ten
- Page 81 and 82: Neural Network Foundations with Ten
- Page 83 and 84: Neural Network Foundations with Ten
- Page 86 and 87: TensorFlow 1.x and 2.xThe intent of
- Page 88 and 89: An example to start withWe'll consi
- Page 90 and 91: Chapter 23. Placeholders: Placehold
- Page 92 and 93: • To create random values from a
- Page 94 and 95: To know the value, we need to creat
- Page 96 and 97: Chapter 2Both PyTorch and TensorFlo
- Page 98 and 99: Chapter 2state = [tf.zeros([100, 10
- Page 100 and 101: Chapter 2For now, there's no need t
- Page 102 and 103: Chapter 2Let's see an example of a
- Page 104 and 105: Chapter 2If you want to save a mode
- Page 106 and 107: Chapter 2supervised=True)train_data
- Page 108 and 109: Chapter 2There, tf.feature_column.n
- Page 110 and 111: Chapter 2print (dz_dx)print (dy_dx)
- Page 112 and 113: Chapter 2In our toy example we use
- Page 114 and 115: Chapter 2For multi-machine training
- Page 116 and 117: Chapter 25. Use tf.layers modules t
Neural Network Foundations with TensorFlow 2.0
Increasing the number of internal hidden
neurons
Yet another approach involves changing the number of internal hidden neurons. We
report the results of the experiments with an increasing number of hidden neurons.
We see that by increasing the complexity of the model, the runtime increases
significantly because there are more and more parameters to optimize. However,
the gains that we are getting by increasing the size of the network decrease more
and more as the network grows (see Figures 27, 28, and 29). Note that increasing the
number of hidden neurons after a certain value can reduce the accuracy because
the network might not be able to generalize well (as shown in Figure 29):
Figure 27: Number of parameters for increasing values of internal hidden neurons
Figure 28: Seconds of computation time for increasing values of internal hidden neurons
[ 34 ]