tflite convert

tflite_convert  --graph_def_file=./opt.pb --output_format=TFLITE   --output_file=./model.tflite --inference_type=FLOAT  --input_arrays=x   --output_arrays=output --input_shapes=1,5000,1,1


bazel build tensorflow/python/tools:freeze_graph

build --host_force_python=py3

Cannot find python in PATH, please make sure python is installed and add its directory in PATH, or --define PYTHON_BIN_PATH='/something/else'.
changing permissions of 'python3': Operation not permitted


bazel-bin/tensorflow/python/tools/freeze_graph \
--input_graph=some_graph_def.pb \
--input_checkpoint=model.ckpt-8361242 \
--output_graph=/tmp/frozen_graph.pb --output_node_names=softmax

这里写图片描述

https://blog.csdn.net/liuzhengnan007/article/details/80434956

猜你喜欢

转载自blog.csdn.net/qq_32450111/article/details/81329401