Recent Releases of tf-keras-vis

tf-keras-vis - Release v0.8.7

A Improvement

  • Add support for Tensorflow 2.16+ and Keras 3.x

- Python
Published by keisen about 2 years ago

tf-keras-vis - Release v0.8.6

A Bugfix

  • Fixes a bug which invalid type was used

- Python
Published by keisen over 2 years ago

tf-keras-vis - Release v0.8.5

A Improvement

  • Add support for Tensorflow 2.13+ (#99 )

- Python
Published by keisen about 3 years ago

tf-keras-vis - Release v0.8.4

Bugfixes

  • Fixes a bug which seed_input value passed to ActivationMaximization was converted to Numpy array, but not tf.Tensor.
  • Fixes a bug which GifGenerator2D didn't cast tf.Tensor to Numpy array.
  • Fixes a bug which np.int was used in tf_keras_vis.saliency module.

- Python
Published by keisen over 3 years ago

tf-keras-vis - Release v0.8.3

A Breaking Change

  • Drop tf_keras_vis.activation_maximization.legacy module for compatibility with TF2.11+.

- Python
Published by keisen over 3 years ago

tf-keras-vis - Release v0.8.2

A Improvement

  • Add support for Tensorflow 2.9+ (#87)

A bugfix

  • Fixes a bug that is incorrect calculation of Layercam (#88)

- Python
Published by keisen almost 4 years ago

tf-keras-vis - Release v0.8.1

  • Add support for Python 3.10.x
  • Drop support for Python 3.6.x

- Python
Published by keisen over 4 years ago

tf-keras-vis - Release v0.8.0

Breaking Changes

  • Remove normalize_gradient option from tf_keras_vis.activation_maximization.ActivationMaximization.__call__(), tf_keras_vis.activation_maximization.legacy.ActivationMaximization.__call__() and tf_keras_vis.gradcam.Gradcam.__call__().
  • Remove standardize_cam option from tf_keras_vis.gradcam.Gradcam.__call__(), tf_keras_vis.gradcam_plus_plus.GradcamPlusPlus.__call__() and tf_keras_vis.scorecam.Scorecam.__call__(), Use normalize_cam option instead
  • Remove standardize_saliency option from tf_keras_vis.saliency.Saliency.__call__(), Use normalize_map option instead
  • Deprecate tf_keras_vis.utils.standardize(), Use tf_keras_vis.utils.normalize() instead

Add features

  • Add support for LayerCAM
  • Add gradient_modifier option to tf_keras_vis.gradcam.Gradcam.__call__() and tf_keras_vis.gradcam_plus_plus.GradcamPlusPlus.__call__()
  • Add __version__ to tf_keras_vis module

Other Changes

  • Add VERSION file to define the current version number.
  • Add MANIFEST.in file to exclude unnecessary files (such tests) from the package.

- Python
Published by keisen almost 5 years ago

tf-keras-vis - Release v0.7.2

A bugfix

  • Fixes a bug that is incorrect calculation of BinaryScore when ReplaceToLinear is applied to target model

Improvements

- Python
Published by keisen almost 5 years ago

tf-keras-vis - Release v0.7.1

Bugfix

  • Improve incorrect error messages in ActivationMaimization.

- Python
Published by keisen almost 5 years ago

tf-keras-vis - Release v0.7.0

Fixes critical bugs

ActivationMaximization

We've fixed a problem of unstable gradient calculation in ActivationMaximization. In addition, because the related implementation has a bad effect on the process with the mixed-precision model, as a result, the problems related to mixed-precision with ActivationMaximization below were also fixed.

  • Fixed issues related to mixed-precision
    • The results of fully-precision and mixed-precision models are different.
    • When the model has a layer which is set explicitly as float32 dtype, ActivationMaximization might raise an error.
    • Regularization values calculated by ActivationMaximization might be NaN or inf easily.

Because the results of the gradients calculation are now different compared to the past versions, to keep compatibility, we newly provide the module tf_keras_vis.activation_maximization.legacy. If you have the code adjusted by yourself in the past versions, you could also use legacy implementation as follows:

```python

from tfkerasvis.activation_maximization import ActivationMaximization

from tfkerasvis.activation_maximization.legacy import ActivationMaximization ```

Please notice that the tf_keras_vis.activation_maximization.legacy module above still has the problem of unstable gradient calculation. So we strongly recommend, if you don't have any code adjusted by yourself in the past versions, using the tf_keras_vis.activation_maximization module.

Regularization for ActivationMaximization

We also found and fixed some bugs of Regularizers below.

  • Fixed issues related to Regularizers
    • The TotalVariation2D has a problem that the more the number of samples of seed_input, the smaller the regularization value of it.
    • The Norm has a problem that the larger the spatial size of seed_input, the smaller the regularization value of it.

In addition to above, we've changed the signature of Regularizer#__call__(). The method now accepts only one seedinput (the legacy one accepts whole seedinputs). With this change, the regularizers argument of ActivationMaximization#__call__() now accepts a dictionary object that contains the Regularizer instances for each model input.

To keep compatibility, we've newly provided the tf_keras_vis.activation_maximization.regularizers module that includes the regularizers improved, instead of updating the tf_keras_vis.utils.regularizers module. If you have the code implemented or adjusted by yourself in the past versions, you could also use legacy implementation as follows:

```python

from tfkerasvis.activation_maximization.regularizers import Norm, TotalVariation2D

from tfkerasvis.utils.regularizers import Norm, TotalVariation2D ```

Please notice that the tf_keras_vis.utils.regularizers module still has the bugs and a lot of warnings will be printed. So we strongly recommend, if you do NOT have any code adjusted by yourself in the past versions, using the tf_keras_vis.utils.regularizers module.

If you face any problem related to this release, please feel free to ask us in Issues page.

Add features and Improvements

  • Add tf_keras_vis.utils.model_modifiers module.
    • To fix issues / #49
    • This module includes ModelModifier, ReplaceToLinear, ExtractIntermediateLayer and GuidedBackpropagation.
    • As a result, model_modifier argument of tf_keras_vis.ModelVisualization#__init__() now also accepts a tf_keras_vis.utils.model_modifiers.ModelModifier instance, a list of Callable objects or ModelModifier instances.
  • Add tf_keras_vis.gradcam_plus_plus module.
    • This module includes GradcamPlusPlus.
  • Add tf_keras_vis.activation_maximization.legacy module.
    • This module includes ActivationMaximization that still has the problem of unstable gradient calculation.
  • Add tf_keras_vis.activation_maximization.input_modifiers module.
    • This module includes Jitter, Rotate and Scale.
  • Add tf_keras_vis.activation_maximization.regularizers module.
    • This module includes TotalVariation2D and Norm that fixed some bugs.
  • Add Scale, that is the new InputModifier class, to the tf_keras_vis.activation_maximization.input_modifiers module.
  • Add Progress, that is the new Callback class, to the tf_keras_vis.activation_maximization.callbacks module.
  • Add activation_modifiers argument to ActivationMaximization#__call__().
  • ~~Add a github actions recipe to publish tf-keras-vis to Anaconda.org~~
    • To fix issues / #54
  • Improve Scorecam
    • Fixes the incorrect weight calculation. (Reducing noise)
    • Change cubic interpolation to linear one. (10x faster)
    • Change to apply softmax function to scores. (More stable)
    • Add validation to check invalid scores.

Breaking Changes

  • In all visualization, the score argument now must be a list of tf_keras_vis.utils.scores.Score instances or Callable objects when the model has multiple outputs.
  • Change the default parameters of ActivationMaximization#__call__().
    • Because of fixing critical bugs in ActivationMaximization that the calculation of gradient descent is unstable.
  • Deprecates tf_keras_vis.utils.regularizers module, Use tf_keras_vis.activation_maximization.regularizers module instead.
    • For now, both current and legacy regularizers can be used in ActivationMaximization, but please notice that they can't be mixed to use.
  • Deprecates tf_keras_vis.utils.input_modifiers, Use tf_keras_vis.activation_maximization.input_modifiers module instead.
  • Deprecates tf_keras_vis.activation_maximization.callbacks.PrintLogger, use Progress instead.
  • Add **arguments argument to Callback#on_begin().
    • **arguments is the values passed to ActivationMaximization#__call__() as arguments.
  • Deprecates tf_keras_vis.gradcam.GradcamPlusPlus, Use tf_keras_vis.gradcam_plus_plus.GradcamPlusPlus  module instead.

Bugfixes and Other Changes

  • Fixes a bug that Scorecam didn't work correctly with multi-inputs model.
  • Fixes some bugs when loading input modifiers.
  • Fixes a bug that Callback#on_end() might NOT be called when an error occurs.
  • Improve an error message when max_N is invalid in Scorecam.
  • Improve the input_range argument of ActivationMaximization#__call__() to raise an error when it's invalid.
  • Change docstring style to google.
  • Replace str#format() to f-string

- Python
Published by keisen almost 5 years ago

tf-keras-vis - Release v0.6.2

Improvements

  • tf_keras_vis.utils.input_modifiers.Jitter raises ValueError with proper message when the dimension of seed_input is 2.

Breaking Changes

  • Deprecates tf_keras_vis.utils.input_modifiers.Rotate. Use tf_keras_vis.utils.input_modifiers.Rotate2D instead.

Other Changes

  • Update classifiers in setup.py

- Python
Published by keisen almost 5 years ago

tf-keras-vis - Release 0.6.1

BugFix and Other Changes

  • Remove import a class that does NOT exist.
  • Improve performance to check mixed-precision models.

- Python
Published by keisen about 5 years ago

tf-keras-vis - Release 0.6.0

Change a terminology

  • The Loss is changed to Score. Because visualizations does NOT need to calculate any loss between labels and the model outputs, and the calculated values is used as just scores, we thought that the former is proper than latter.

Add Features and Improvements

  • Support Python 3.9
  • Support Tensorflow 2.4 and 2.5
  • Support mixed-precision
    • Issues / #43 , #45 and #47
    • only tensorflow 2.4.0+
  • Add unconnected_gradients option to __call__() of ActivationMaximization, Saliency, GradCAM, GradCAM++.
  • Add standardize_cam option to __call__() of GradCAM, GradCAM++ and ScoreCAM.
  • Add normalize_saliency option to __call__() of Saliency.

Breaking Changes

  • In all visualization class constructor, the model passed as a argument is NOT cloned when model_modifier is None.
    • issues / #51
  • Deprecates and Disable normalize_gradient option in ActivationMaximizaion and GradCAM.
  • Deprecates tf_keras_vis.utils.callback module. Use tf_keras_vis.activation_maximization.callbacks module instead.
    • Deprecates and Rename Print to PrintLogger.
    • Deprecates and Rename GifGenerator to GifGenerator2D.
  • Deprecates tf_keras_vis.utils.regularizers.TotalVariation. Use tf_keras_vis.utils.regularizers.TotalVariation2D instead.
  • Deprecates tf_keras_vis.utils.regularizers.L2Norm. Use tf_keras_vis.utils.regularizers.Norm instead.
  • Deprecates and Rename tf_keras_vis.utils.normalize to tf_keras_vis.utils.standardize.
  • Don't need to use tf_keras_vis.utils.normalize to visualize CAM or Saliency. Use standardize_cam and standardize_saliency option instead respectively.
  • Don't need to cast activations maximized by ActivationMaximization to visualize.

BugFix and Other Changes

  • Fixes a problem in Rotate input-modifier that it can't work correctly when input tensors is not 2D images.
  • Add a test utility and testcases.
  • Update dockerfiles and example notebooks.

Known Issues

  • With a mixed-precision model, Regurarization values that is calculated by ActivationMaximization may be NaN.
  • With a mixed-precision model that has a layer which are set float32 dtype exlicitly, ActivationMaximization may raise a error.

- Python
Published by keisen about 5 years ago

tf-keras-vis - Release 0.5.5

Bugfix

  • Fix a problem that GradCAM and GradCAM++ were NOT working correctly with mixed precision . (See issues / #41 for details).

Other Changes

  • Support tensorflow 2.4.0.
  • Python 3.5 is no longer supported (but it can be used if tensorflow<2.4.0).

- Python
Published by keisen over 5 years ago

tf-keras-vis - Release 0.5.4

Bugfix

  • Fix a problem that normalize_gradient option of ActivationMaximization and GradCAM was not working correctly. (See issues / #38 for details).

- Python
Published by keisen over 5 years ago

tf-keras-vis - Release 0.5.3

Bugfix

  • Fix a problem that model's training-mode can NOT turn off (See issues / #26 for details).

- Python
Published by keisen almost 6 years ago

tf-keras-vis - Release 0.5.2

Bugfix

  • Fix a problem that a Error occurs when max_N is None or under 0 in ScoreCAM

- Python
Published by keisen almost 6 years ago

tf-keras-vis - Release 0.5.0

Major Feature

  • Add new methods (ScoreCAM and Faster-ScoreCAM)

Breaking Changes

  • tf_keras_vis.utils.print_gpus() was deleted.
  • tf_keras_vis.utils.losses.SmoothedLoss was deleted.

BugFix and Other Changes

  • Fixes a problem that ActivationMaximization couldn't calculate and normalize losses correctly when multiple samples.
  • Fixes a problem that the output of ActivationMaximization was restricted when input_ranges contain None.
  • Improve to raise ValueError when input shape doesn't have channels dimension in GradCAM.
  • Fixes a problem that GradCAM++ couldn't calculate scores correctly when multiple samples.
  • Add tf_keras_vis.utils. num_of_gpus() instead of tf_keras_vis.utils. print_gpus().

- Python
Published by keisen almost 6 years ago

tf-keras-vis - Release 0.4.0

Major Feature

  • Add GradCAM++ algorism implemented as GradcamPlusPlus class

Bugfixes

  • The noise of SmoothGrad is too strong.
  • Rotation in InputModifier across channles-dim.

- Python
Published by keisen almost 6 years ago

tf-keras-vis - Release 0.3.3

Improvements

  • Refactoring and Vectorizing some processing in Gradcam and Saliency
  • Remove .travis.yml because there is Github Action as CI tools

- Python
Published by keisen almost 6 years ago

tf-keras-vis - Release 0.3.2

This release includes the patch for improving Issue #15 that is serious bugs. So We highly recommend to update tf-keras-vis.

BugFix and Other Changes

  • Fixes bug that tfkerasvis.utils.normalize() can't batchwisely do normalization.
  • Add expand_cam argument to GradCAM#call() for returning non-interpolated cam values.
  • In setup.py, rename development of extras_require to develop.

- Python
Published by keisen almost 6 years ago

tf-keras-vis - Release 0.3.1

We re-uploaded tf-keras-vis to PyPI as v0.3.1 because wrong library was uploaded.

- Python
Published by keisen about 6 years ago

tf-keras-vis - Release 0.3.0

Bug Fixes

  • Fixes a lot of bugs in ActivationMaximization and Gradcam

Breaking Changes

  • tf_keras_vis.activation_maximization.ActivationMaximization.__call__()'s regularizers argument no longer accepts dict object.
  • Rename tf_keras_vis.gradcam.Gradcam.__call__()'s seek_penultimate_layer argument to seek_penultimate_conv_layer.
  • Rename tf_keras_vis.utils.listify's empty_list_if_none argument to return_empty_list_if_none.

- Python
Published by keisen about 6 years ago

tf-keras-vis - Release 0.2.5

Bugfix

  • Fixes a bug that tf-keras-vis can't install on Python 3.8.x

- Python
Published by keisen about 6 years ago

tf-keras-vis - Release 0.2.4

Improvements

  • Python 3.8 are available
  • Added docker-images that contains tf-keras-vis v0.2.4

- Python
Published by keisen about 6 years ago

tf-keras-vis - Release 0.2.2

Improvement

  • Add a argument to Gradcam#call() to fix issues/#4

- Python
Published by keisen about 6 years ago

tf-keras-vis - Relase 0.2.1

Document issues fixes and other changes

  • Fixes examples of docker command in README.md
  • Remove unnecessary comments in source

[!NOTE] This release is for updating description page on PyPI, so it NOT contains any changes of library's behaviors.

- Python
Published by keisen over 6 years ago

tf-keras-vis - Release 0.2.0

Bug Fixes and Other Changes

  • In Saliency and Gradcam, support seed_input that don't have samples (batch) dimension.
  • Fixes a lot of bugs
  • Dockerfiles changed to tensorlfow image base.
  • Added tests and .travis.yml .

Breaking Changes

  • tf_keras_vis.utils.losses.SmoothingLoss class renamed to tf_keras_vis.utils.losses.SmoothedLoss.

- Python
Published by keisen over 6 years ago

tf-keras-vis - Initial Release

- Python
Published by keisen over 6 years ago