This PR adds a new example script to the GDE project. The example builds a graph for the object detection model currently used in MAX-Object-Detector. In particular, the example script starts from the raw graph from the TensorFlow models repository, grafts on preprocessing ops that perform image conversion and postprocessing ops that map category IDs to category names; then runs a series of the Graph Transform Tool and GraphDef Editor rewrites.
I added some minor improvements to existing GDE code along the way:
Added error-checking code to gde.Graph.remove_node_by_name()
Improved an error message in reroute.py
Added a convenience method filter_ops_by_optype() for finding all ops of a given type without having to build a lambda.
This PR adds a new example script to the GDE project. The example builds a graph for the object detection model currently used in MAX-Object-Detector. In particular, the example script starts from the raw graph from the TensorFlow models repository, grafts on preprocessing ops that perform image conversion and postprocessing ops that map category IDs to category names; then runs a series of the Graph Transform Tool and GraphDef Editor rewrites.
I added some minor improvements to existing GDE code along the way:
gde.Graph.remove_node_by_name()
reroute.py
filter_ops_by_optype()
for finding all ops of a given type without having to build a lambda.