I was able to retrain the model, but when it comes to the section below on inference toco complains that you can't use the same output format as the input format. If I skip this step and load into the camera I get the catch statement error message on the screen. Is there another way to optimize the model? Thanks.
# Optimize the model for inference:
toco \
--input_file=tf_files/retrained_graph.pb \
--output_file=tf_files/optimized_graph.pb \
--input_format=TENSORFLOW_GRAPHDEF \
--output_format=TENSORFLOW_GRAPHDEF \
--input_shape=1,${IMAGE_SIZE},${IMAGE_SIZE},3 \
--input_array=input \
--output_array=final_result