TensorFlow-Course icon indicating copy to clipboard operation
TensorFlow-Course copied to clipboard

2 mistakes found

Open owenliang opened this issue 4 years ago • 1 comments

in linearregression,

# Create a callback that saves the model's weights every 5 epochs
checkpointCallback = tf.keras.callbacks.ModelCheckpoint(
    filepath=checkpoint_path, 
    verbose=1, 
    save_weights_only=True,
    save_freq=n_samples_save)

save_freq should be number of epochs(not batches):

# Create a callback that saves the model's weights every 5 epochs
checkpointCallback = tf.keras.callbacks.ModelCheckpoint(
    filepath=checkpoint_path, 
    verbose=1, 
    save_weights_only=True,
    save_freq=n_epochs_log)
# Return unique list elements
checkpoints =list(set(checkpoints))
print('checkpoints:',checkpoints)

to make the figures understood, the checkpoints file list should be sorted by created order:

# Return unique list elements
checkpoints = sorted(list(set(checkpoints)))
print('checkpoints:',checkpoints)

owenliang avatar Dec 11 '20 11:12 owenliang

Thank @owenliang. Please kindly make a pull request.

astorfi avatar Aug 13 '21 01:08 astorfi