No gradients provided for any variable #39169
Labels
comp:keras
Keras related issues
comp:ops
OPs related issues
TF 2.2
Issues related to TF 2.2
type:bug
Bug
Projects
System information
pip install tf-nightly
Describe the current behavior
When running the training on the localhost the error occurs:
Describe the expected behavior
This issue didn't happen in previous versions, but I'm having to use python 3.8, thus the tf-nightly version. I also noticed that in the collab the code works, with the TF 2.1 version and python 3.7.
In addition, I found issues suggesting using:
However, the examples I saw use a customized training function (
train_step()
). In my case, I only use the standardfit()
function, which is enough for the context.Maybe I'm not sure how to use this in new version, or maybe it's an issue. Anyway, if anyone can help, thank you very much.
Standalone code to reproduce the issue
Project code and model class
The text was updated successfully, but these errors were encountered: