Skip to content

Commit

Permalink
From tensorflow==2.0.0 to tensorflow==2.1.0 (#111)
Browse files Browse the repository at this point in the history
* From tensorflow==2.0.0 to tensorflow==2.1.0

* Use light cpu version of TF

* Why is it failing now?
  • Loading branch information
Raphael Meudec committed Jan 9, 2020
1 parent df6bec3 commit e03745c
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 7 deletions.
5 changes: 1 addition & 4 deletions docs/source/overview.rst
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,4 @@ Tensorflow Compatibility
tf-explain is compatible with Tensorflow 2. It is not declared as a dependency
to let you choose between CPU and GPU versions. Additionally to the previous install,
run::
# For CPU version
pip install tensorflow==2.0.0
# For GPU version
pip install tensorflow-gpu==2.0.0
pip install tensorflow==2.1.0
2 changes: 1 addition & 1 deletion tests/core/test_integrated_gradients.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,6 @@ def test_get_integrated_gradients(random_data, convolutional_model):
images, convolutional_model, 0, n_steps=n_steps
)

expected_output_shape = (images.shape[0] / n_steps, *images.shape[1:])
expected_output_shape = (int(images.shape[0] / n_steps), *images.shape[1:])

assert gradients.shape == expected_output_shape
2 changes: 1 addition & 1 deletion tests/core/test_smoothgrad.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,6 @@ def test_get_averaged_gradients(random_data, convolutional_model):
images, convolutional_model, 0, num_samples=num_samples
)

expected_output_shape = (images.shape[0] / num_samples, *images.shape[1:])
expected_output_shape = (int(images.shape[0] / num_samples), *images.shape[1:])

assert gradients.shape == expected_output_shape
2 changes: 1 addition & 1 deletion tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,5 @@ deps =
pytest-cov
pytest-mock
commands =
pip install tensorflow==2.0.0
pip install tensorflow-cpu==2.1.0
pytest tests/ -vv --cov-report term-missing --no-cov-on-fail --cov-fail-under 85 --cov=tf_explain/

0 comments on commit e03745c

Please sign in to comment.