tensorflow: KeyError: 'ExperimentalFunctionBufferingResource' in Tf >= 1.13 (mkl)

  • OS Platform and Distribution - Linux Ubuntu 16.04)
  • TensorFlow installed from Anaconda dist 3.6.
  • TensorFlow version 1.13-mkl
  • Python version: Python 3.6.6 :: Anaconda, Inc.

Describe the current behavior Models trained using the Iterator-Gen for data and saved as meta & ckpt cannot be imported using the tf.train.import_meta_graph function. Gives a KeyError. Describe the expected behavior Working fine with Tensorflow1.12(mkl). Error found in Tf version >= 1.13

Other info / logs Here is the Traceback read=tf.train.import_meta_graph(self.paths[0], clear_devices=True) File "/home/pnayak/anaconda3/envs/coreml/lib/python3.6/site-packages/tensorflow/python/training/saver.py", line 1435, in import_meta_gra ph meta_graph_or_file, clear_devices, import_scope, **kwargs)[0] File "/home/pnayak/anaconda3/envs/coreml/lib/python3.6/site-packages/tensorflow/python/training/saver.py", line 1457, in _import_meta_gr aph_with_return_elements **kwargs)) File "/home/pnayak/anaconda3/envs/coreml/lib/python3.6/site-packages/tensorflow/python/framework/meta_graph.py", line 806, in import_scoped_meta_graph_with_return_elements return_elements=return_elements) File "/home/pnayak/anaconda3/envs/coreml/lib/python3.6/site-packages/tensorflow/python/util/deprecation.py", line 507, in new_func return func(*args, **kwargs) File "/home/pnayak/anaconda3/envs/coreml/lib/python3.6/site-packages/tensorflow/python/framework/importer.py", line 399, in import_graph_def _RemoveDefaultAttrs(op_dict, producer_op_list, graph_def) File "/home/pnayak/anaconda3/envs/coreml/lib/python3.6/site-packages/tensorflow/python/framework/importer.py", line 159, in _RemoveDefaultAttrs op_def = op_dict[node.op] KeyError: 'ExperimentalFunctionBufferingResource'

About this issue

  • Original URL
  • State: closed
  • Created 5 years ago
  • Comments: 18 (1 by maintainers)

Most upvoted comments

you just need to add *.so compiled file generated by model implementation. as follows add this line before session and import meta graph. tf.load_op_library('<compiled_filename>.so') this function add a new op in tensorflow runtime. for example. i compiled a model that contains a RoiPooling layer and generated roi_pooling.so file. so that i added this line to my code tf.load_op_library('op/roi_pooling.so')

and finally it works : )