Skip to content

Instantly share code, notes, and snippets.

@petewarden
Created July 24, 2017 19:51
Show Gist options
  • Save petewarden/02657e3f5e384ed9ad065855f22b5966 to your computer and use it in GitHub Desktop.
Save petewarden/02657e3f5e384ed9ad065855f22b5966 to your computer and use it in GitHub Desktop.
bazel build tensorflow/tools/graph_transforms:transform_graph
bazel-bin/tensorflow/tools/graph_transforms/transform_graph \
--in_graph="/tmp/model/tensorflow_inception_graph.pb" \
--out_graph="/tmp/model/quantized_graph.pb" --inputs='Mul:0' \
--outputs='softmax:0' \
--transforms='add_default_attributes strip_unused_nodes(type=float, shape="1,299,299,3") remove_nodes(op=Identity, op=CheckNumerics) fold_old_batch_norms quantize_weights quantize_nodes strip_unused_nodes'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment