Skip to content

Instantly share code, notes, and snippets.

@ajinkyajawale14499
Created July 8, 2019 20:28
Show Gist options
  • Save ajinkyajawale14499/cc1ab76180085a4ed55b3c858d73efb5 to your computer and use it in GitHub Desktop.
Save ajinkyajawale14499/cc1ab76180085a4ed55b3c858d73efb5 to your computer and use it in GitHub Desktop.
saved_model_dir = 'save/fine_tuning'
tf.saved_model.save(model, saved_model_dir)
converter = tf.lite.TFLiteConverter.from_saved_model(saved_model_dir)
tflite_model = converter.convert()
with open('model.tflite', 'wb') as f:
f.write(tflite_model)
# download the model & labels
from google.colab import files
files.download('model.tflite')
files.download('labels.txt')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment