keras icon indicating copy to clipboard operation
keras copied to clipboard

AttributeError: 'VocabWeightHandler' object has no attribute 'name'

Open DachuanZhao opened this issue 3 years ago • 3 comments

System information.

  • Have I written custom code (as opposed to using a stock example script provided in Keras): https://colab.research.google.com/drive/1BD9G1o7CNxAaKKyihCKx0wa1zW-tmn0r?usp=sharing
  • OS Platform and Distribution (e.g., Linux Ubuntu 16.04):
  • TensorFlow installed from (source or binary): pip
  • TensorFlow version (use command below): 2.6.0
  • Python version: 3.8
  • Bazel version (if compiling from source):
  • GPU model and memory:
  • Exact command to reproduce:

Describe the problem. Tensorflow profiler crashes when using string categorical layer, not allowing to profile models with those layers.

Maybe the same issue

DachuanZhao avatar Aug 13 '21 07:08 DachuanZhao

The same issue happened to me.

I "fixed" it by changing the Tensorboard(histogram_freq=0), but it seems you mentioned it's a bad idea as we can't get tensorflow profiler in tensorboard.

i-chaochen avatar Nov 11 '21 23:11 i-chaochen

This is a known bug with some special classes we introduced for handling StaticHashTable and MutableHashTable in keras layers (TrackableWeightHandler and VocabWeightHandler). Both the classes have caused a number of issues, so I believe the best approach here would be to remove them entirely. We will need to think about the design of how best to do that.

mattdangerw avatar Nov 16 '21 00:11 mattdangerw

Is there any update on this issue?

kylemcmearty avatar Jun 27 '22 14:06 kylemcmearty