Я пытаюсь экспортировать предварительно обученную модель ugatit
в замороженную graph.pb
.
После запуска:
from tensorflow.python.tools.freeze_graph import freeze_graph
from tensorflow.python.saved_model import tag_constants
from tensorflow.core.protobuf import saver_pb2
freeze_graph(input_graph=None,
input_saver=None,
input_binary=False,
input_checkpoint='/content/checkpoint/UGATIT_light_selfie2anime_lsgan_4resblock_6dis_1_1_10_10_1000_sn_smoothing',
output_node_names="output",
restore_op_name=None,
filename_tensor_name=None,
output_graph='frozen_graph.pb',
clear_devices=False,
initializer_nodes="",
variable_names_whitelist="",
variable_names_blacklist="",
input_meta_graph=None,
input_saved_model_dir='tmp7qwt8bbw/',
saved_model_tags=tag_constants.SERVING,
checkpoint_version=saver_pb2.SaverDef.V2
)
я получаю:
AssertionError: output is not in the graph
Я использую этот ноутбук:
https://github.com/margaretmz/selfie2anime-with-tflite/blob/master/ml/Selfie2Anime_Model_Conversion.ipynb