问题
I'm trying to implement smart reply https://www.tensorflow.org/lite/models/smart_reply/overview concept in Python. You can download tflite model file here https://storage.googleapis.com/download.tensorflow.org/models/tflite/smartreply_1.0_2017_11_01.zip.
import numpy as np
import tensorflow as tf
interpreter = tf.lite.Interpreter(model_path="smartreply.tflite")
interpreter.allocate_tensors()
While using above code, i'm getting this error,
Traceback (most recent call last):
File "smart_reply.py", line 6, in <module>
interpreter.allocate_tensors()
File "/usr/local/lib/python3.7/site-packages/tensorflow_core/lite/python/interpreter.py", line 244, in allocate_tensors
return self._interpreter.AllocateTensors()
File "/usr/local/lib/python3.7/site-packages/tensorflow_core/lite/python/interpreter_wrapper/tensorflow_wrap_interpreter_wrapper.py", line 106, in AllocateTensors
return _tensorflow_wrap_interpreter_wrapper.InterpreterWrapper_AllocateTensors(self)
RuntimeError: Encountered unresolved custom op: Normalize.Node number 0 (Normalize) failed to prepare.
Thanks a lot in advance!
来源:https://stackoverflow.com/questions/59627407/runtimeerror-encountered-unresolved-custom-op-normalize-node-number-0-normali