你好,老师,我把模型保存,然后测试时将模型导入后,调用 model.call 时一直报错,我检查了一下代码,我的模型类继承的是 tf.keras.Model,但是我在 call 方面前面加了 tf.function 装饰器啊,不知道为什么还报这个错误
ValueError: Could not find matching function to call loaded from the SavedModel. Got:
Positional arguments (1 total):
* Tensor (“input:0”, shape=(60, 28, 28, 1), dtype=float64)
Keyword arguments: {}
Expected these arguments to match one of the following 1 option (s):
Option 1:
Positional arguments (1 total):
* TensorSpec (shape=(20, 28, 28, 1), dtype=tf.float32, name=‘input’)
Keyword arguments: {}