When executing tf.saved_model.save, this exception
Can’t pickle _thread._local objects
gets thrown. This does not occur when a more recent tensorflow version is used
Unfortunately, the web lab declares timeout/crash when trying to add a pip install of a newer version, or installation fails due to incompatibilities
Anyone managed to work-around this with ?
The lab uses tf version 2.0.0
I dont have access to this specialization but maybe @chris.favila could be helpful if its a matter of updates of software versions within the assignments!
Hi Olivier. Thank you for bringing this to our attention. As you and Gent mentioned, this is likely due to needed updates in the software packages. We’ll look into it and push revisions to the notebook if necessary. Thank you!
Thanks for looking into this
Any ETA for an update/fix ?
I checked today but it looks all the same
Hi Olivier! Sorry for the delay. I’ve bookmarked this for tomorrow and will post an update regarding possible changes. Thanks!
Hello again Olivier. My apologies but unfortunately, the debugging has to be pushed back a bit because of critical issues that came up this week. I’ve schedule this first thing on Monday.
Is this bug fix related to why there’s no link to the Jupyter notebook from the programming assignment exercise 2 & 3? I presume the code in github is outdated too?
Hi Olivier! Can you send me a copy of your notebook via direct message? We’re actively looking into this issue. Unfortunately, I am not able to replicate the error so we would need your code. Thanks!
Hi! Kindly do the lab from the
Lab item before the
Programming Assignment. Here’s the link for Week 2. The
Open Lab button will take you to the graded Jupyter notebook. After getting the correct output in the code cells, you should save the notebook and then press the
Submit Button on the upper right:
Hope this clarifies it. If you’re encountering the same bug as Olivier, please let me know. We’re trying to replicate the issue. Thank you!
I’m experiencing a similar issue as Olivier, namely “Cell #3. Can’t compile the student’s code. can’t pickle _thread._local objects”.
Could you please advise?
Never mind - I believe I found the issue with how I defined the Lambda layer. After I changed it, I no longer receive the “pickle_thread” error.
Hi Anton! Sorry for the late reply and glad you figured it out! Sorry I didn’t realize we resolved Olivier’s issue earlier via direct message.
For other learners who might encounter the error, please check how you added the Lambda layer as Anton also mentioned. The Tensorflow version used in this course will throw an error about local variables if you do something like this:
tf.keras.layers.Lambda(lambda x: self.some_func(x))
What you can do is add it this way instead just like in the docs (see antirectifier section):
Hope this helps!
Thanks Chris - much appreciated!