ValueError: Tried to convert 'y' to a tensor and failed. Error: None value not supported #13407
Labels
type:support
User is asking for help / asking an implementation question. Stackoverflow would be better suited.
I'm running a very vanilla Sequential model API
where
x_train_pad
is a python list of tokens for some texts with pre-padding (0's in front of list). andy_train
is a python list of1.0
or0.0
depending on whether the corresponding text inx_train_pad
is positive or negative sentiment.The ValueError is from
grads = K.gradients(loss,params)
in theget_gradients
method of kerasoptimizer.py
. Seems like tensorflow assigns a None value for gradient of value 0. But this is causing downstream error when I try fitting my Sequential model to my training dataset.The text was updated successfully, but these errors were encountered: