Issue
I am trying to install Tensorflow federated on google collab, which is not easy, there is a conflict with versions, but I either get this error if I install previous versions or similar errors.
module tensorflow_federated.python has no attribute federated_computation
If I want to install the new version it gives the "this requires this version but you have this version" during the installation. I am very confused. Is there an easy way to use Tensorflow federated learning? I tried to install it locally but that also didn't work. Why is it so hard to use it?
If I uninstalled all packages and installed them again it gives me the error mentioned above
If I try to import it ignoring the errors in the pictures it gives me this error with newer version
'type' object is not subscriptable
And this error with version 20
module 'tensorflow_federated.python' has no attribute 'federated_computation'
Solution
The problem was that
- you need to install Tensorflow federated learning version 0.20.0
!pip install --quiet tensorflow-federated==0.20.0
- Ignore the dependency error
- Instead of the below
from tensorflow_federated import python as tff
use:
import tensorflow_federated as tff
Answered By - DRA
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.