Quantization-aware training in Tensorflow using the highlevel keras api

Viewed 1377

I built my first covnet using the process described in this colab. Now I would like to run the model on Googles shiny new edge tpu.

But according to the Model Requirments described here, I need to use quantization-aware training (post-training quantization is not supported). to be able to convert the model into a format that I can use on the EdgeTPU.

How do I modify the example colab to do this quantization-aware training thing?

1 Answers

well because the keras API does not support quantization in the current edition you are left with 3 options:

  1. wait for keras to have the required functionality
  2. rewrite your model with a different API that has this functionality
  3. find a different TPU that does not require you to quantize your data

either way though the solution is not great though.

Related