Consistent saved_model output format (#7032)

This commit is contained in:
Mrinal Jain authored and GitHub committed 2022-03-18 12:29:24 +01:00
1 parent 7c6a33564a
commit 4effd064b1
2 files changed
+2 -2

No files matched your search

+1 -1
View File
@@ -275,7 +275,7 @@ def export_saved_model(model, im, file, dynamic,
m = m.get_concrete_function(spec)
frozen_func = convert_variables_to_constants_v2(m)
tfm = tf.Module()
tfm.__call__ = tf.function(lambda x: frozen_func(x), [spec])
tfm.__call__ = tf.function(lambda x: frozen_func(x)[0], [spec])
tfm.__call__(im)
tf.saved_model.save(
tfm,