Use Google Cloud Machine Learning to predict using the retrained Inception model

I did a local reinstallation of the Inception model using the retrain.py file from the Google Code Lab TensorFlow for poets and want to use the Google Cloud machine Training service for forecasting.

In particular, I want to modify the retrain.py file, so the TensorFlow application is prepared for

gcloud beta ml predict --instances = INSTANCES --model = MODEL

(i.e. only prediction, no need to learn Google Cloud ML ala gloud beta ml jobs training training).

I understand conceptually that the retrain.py file should be modified as described in Preparing the Model .

But there is no complete answer showing all lines of code in the retrain.py file after the change. And the popularity of Google Code Lab TensorFlow for poets and Pete Wards screencasts about retraining Inception suggests that this will be a very common example of classifying images among the TensorFlow community; which means that the answer will benefit many in the community.

Will someone respond to their version of the retrain.py file after the change, as described in the "Preparing the model" section?

Note 1: I examined my question to confirm that he did not receive an answer ...

... The question asked by David Biraga and JoshGC's answer โ€œQ: How to predict an image in Google trainingโ€ does not show any changes in the retrain.py file, which redirects the initial model to Google Code Lab TensorFlow for Poets.

... , KlezFromSpace rhaertel80 ( ) ": Google" retrain.py : ; ; ; ; ; () . (. .)

... , Vinkeet Kaushik ( mrry) "Q: Tensorflow Google Cloud ML" retrain.py, Google Code Lab TensorFlow .

2: , jpeg-, , -

gcloud beta ml --instances = INSTANCES --model = MODEL

INSTANCES - JSON , , rhaertel80 "Q: jpeg- json Google machine learning"

3: , EXPORT EXPORT.META, retrain.py, URL-, Google.

+4
1

Google Slaven Bilac .

+3

Source: https://habr.com/ru/post/1663147/


All Articles