C4_W3: Checkpoint is being deleted with unrestored values

I encountered this error for Exercise 3 in C4_W3 assignment test:
All tests passed
WARNING:tensorflow:Detecting that an object or model or tf.train.Checkpoint is being deleted with unrestored values. See the following logs for the specific values in question. To silence these warnings, use status.expect_partial(). See tf.train.Checkpoint  |  TensorFlow v2.14.0 details about the status object returned by the restore function.
WARNING:tensorflow:Value in checkpoint could not be found in the restored object: (root).final_layer.kernel
which cause the grader to reject my solution for Exercise 3 (With error: There was an error grading your submission. Details: name ‘transformer’ is not defined)
PI attached the notebook here, please let me know how to debug this, thank you so much!

Hi @Sandy_Phan

I answered it in PM.

The mistake is not to use global variable transformer. Instead you should use the model variable which is passed in as a parameter.

Cheers

4 Likes