Freezing the Graph - 1.3 English

Vitis AI Optimizer User Guide (UG1333)

Document ID
UG1333
Release Date
2020-12-17
Version
1.3 English

Freeze the graph using the following command:

freeze_graph \
    --input_graph=sparse_graph.pbtxt \
    --input_checkpoint=dense.ckpt \
    --input_binary=false \
    --output_graph=frozen.pb \
    --output_node_names=”vgg_16/fc8/squeezed”
After completing all the previous steps, you should get the final output file, frozen.pb, of the pruning. This file can be used for prediction or quantization. To get the FLOPs of the frozen graph, run the following command:
vai_p_tensorflow --action=flops --input_graph=frozen.pb --input_nodes=input --input_node_shapes=1,224,224,3 --output_nodes=vgg_16/fc8/squeezed