One Other Change—Starting Training from a Saved Weight File
Shortly, we will look at the complete listings for the backpropagation simulator. There is one other
enhancement to discuss. It is often useful in long simulations to be able to start from a known point, which is
from an already saved set of weights. This is a simple change in the backprop.cpp program, which is well
worth the effort. As a side benefit, this feature will allow you to run a simulation with a large beta value for,
say, 500 cycles, save the weights, and then start a new simulation with a smaller beta value for another 500 or
more cycles. You can take preset breaks in long simulations, which you will encounter in Chapter 14. At this
point, let’s look at the complete listings for the updated layer.h and layer.cpp files in Listings 13.1 and 13.2:
Do'stlaringiz bilan baham: |