Skip to content
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: module 'keras.backend' has no attribute 'theano' #6

Closed
FahadMahdi opened this issue Mar 31, 2020 · 2 comments
Closed

Comments

@FahadMahdi
Copy link

FahadMahdi commented Mar 31, 2020

I am trying to calculate the dice coefficient using 2D-unet, however, I am getting the following error:

Using TensorFlow backend.
Traceback (most recent call last):
File "E:/2.U_Net_Humerus_Segmentation/U-Net/3D-brain-segmentation-master/2D-unet.py", line 235, in
compare()
File "E:/2.U_Net_Humerus_Segmentation/U-Net/3D-brain-segmentation-master/2D-unet.py", line 226, in compare
K.theano.shared(y_true),
AttributeError: module 'keras.backend' has no attribute 'theano'

@mrkolarik
Copy link
Owner

Hi FahadMahdi,

your problem is in the fact you apparently used some code from a repository using theano backend and added it to mine as the original file 2D-unet.py in this repository has only 203 lines and your error is on lines 235 and 226. I suggest you to find tensorflow implementation for you problem.

Take care,

mrkolarik

@FahadMahdi
Copy link
Author

FahadMahdi commented Apr 15, 2020 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants