-1

I'm trying to use the batch ensemble model with Colab. The pip install:

!pip install "git+https://github.com/google/uncertainty-baselines.git#egg=uncertainty_baselines"

and got the below error:

ERROR: tensorflow 2.5.0 has requirement keras-nightly~=2.5.0.dev, but you'll have keras-nightly 2.7.0.dev2021070800 which is incompatible.
ERROR: tf-nightly 2.7.0.dev20210708 has requirement grpcio<2.0,>=1.37.0, but you'll have grpcio 1.34.1 which is incompatible.

Once I try to use the library using import:

import uncertainty_baselines as ub

it raises this error

ImportError: cannot import name '__version__' from 'keras' (/usr/local/lib/python3.7/dist-packages/keras/__init__.py)

So I tried manually fix the versions of the packages, I tried to install first the below packages and the dependencies:

!pip install keras-nightly==2.5.0.dev2021020510
!pip install grpcio==1.34.0
!pip install tensorflow==2.5.0
!pip install tf-nightly==2.7.0.dev20210708

but it raises the below errors:

ERROR: tf-nightly 2.7.0.dev20210708 has requirement grpcio<2.0,>=1.37.0, but you'll have grpcio 1.34.1 which is incompatible.
ERROR: tf-nightly 2.7.0.dev20210708 has requirement keras-nightly~=2.7.0.dev, but you'll have keras-nightly 2.5.0.dev2021020510 which is incompatible

Again, I tried to fix the versions:

!pip install keras-nightly==2.7.0.dev2021070800
!pip install grpcio==1.37.0
!pip install tensorflow==2.5.0
!pip install tf-nightly==2.7.0.dev20210708

But now it raises the errors below:

ERROR: tensorflow 2.5.0 has requirement grpcio~=1.34.0, but you'll have grpcio 1.37.0 which is incompatible.
ERROR: tensorflow 2.5.0 has requirement keras-nightly~=2.5.0.dev, but you'll have keras-nightly 2.7.0.dev2021070800 which is incompatible.

It seems like circular dependencies that I can't manage to solve and related to tensor and not to the specific repository I'm trying to use.

EDIT:

Issue with this repository has been solved by removing the tf-nightly dependency (was removed after a new MR)

Tomer S
  • 900
  • 1
  • 10
  • 21
  • Got a different error on flat buffer ,but the second command "import uncertainty_baselines as ub " ran without any error. please find the gist for reference https://colab.research.google.com/gist/mohantym/a730e4f251452f2a794d8e1a2224851a/stack_68311356.ipynb –  Aug 24 '21 at 07:43
  • thanks, however it seems they are many issues to fix. https://github.com/google/uncertainty-baselines/issues/407 – Tomer S Aug 25 '21 at 19:45
  • issue has been solved in this MR - https://github.com/google/uncertainty-baselines/issues/407 – Tomer S Sep 20 '21 at 21:20

1 Answers1

0

The issue was solved with new MR - github.com/google/uncertainty-baselines/issues/407

The dependency of tf-nightly was removed.

Tomer S
  • 900
  • 1
  • 10
  • 21