-
Notifications
You must be signed in to change notification settings - Fork 413
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
AttributeError: 'Tensor' object has no attribute 'assign' #2
Comments
Right now ResNet-152 supports Keras 1.2.2 and Tensorflow 0.12.0. The error you are seeing should be related to Tensorflow versioning. I will try to get the models work for the latest versions as soon as possible. |
Hi Felix, I see it closed don't see any recent commit for this.thanks |
Hello, same issue here for Keras 2.0.3 and Tensorflow 1.1.0 At scale_layer.py change:
to:
"edited" |
Thanks @lef-fan for the suggested patch, and apologize for the delay @SergeKrier . I've already made the necessary changes to get the code to work with the latest versions of Keras (2.0.5) and TensorFlow (1.2.1) |
Hi Felix, thanks for providing the resnet152 model in keras + weights.
However I have the following error when trying to run it :
File "resnet_152.py", line 252, in
model = resnet152_model(img_rows, img_cols, channel, num_class)
File "resnet_152.py", line 222, in resnet152_model
model.load_weights(weights_path)
File "/usr/local/lib/python3.4/dist-packages/keras/engine/topology.py", line 2500, in load_weights
load_weights_from_hdf5_group(f, self.layers)
File "/usr/local/lib/python3.4/dist-packages/keras/engine/topology.py", line 2913, in load_weights_from_hdf5_group
K.batch_set_value(weight_value_tuples)
File "/usr/local/lib/python3.4/dist-packages/keras/backend/tensorflow_backend.py", line 2022, in batch_set_value
assign_op = x.assign(assign_placeholder)
AttributeError: 'Tensor' object has no attribute 'assign'
tensorflow: 1.0.1
keras: 2.0.3
thanks
The text was updated successfully, but these errors were encountered: