Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Deploy Retrained inception model on Google cloud machine learning

I manage to retrain my specific classification model using the generic inception model following this tutorial. I would like now to deploy it on the google cloud machine learning following this steps.

I already managed to export it as MetaGraph but I can't manage to get the proper inputs and outputs.

Using it locally, my entry point to the graph is DecodeJpeg/contents:0 which is fed with a jpeg image in binary format. The output are my predictions.

The code I use locally (which is working) is:

softmax_tensor = sess.graph.get_tensor_by_name('final_result:0')
predictions = sess.run(softmax_tensor,{'DecodeJpeg/contents:0': image_data})

Should the input tensor be DecodeJpeg? What would be the changes I need to make if I would like to have a base64 image as input ?

I defined the output as:

outputs = {'prediction':softmax_tensor.name}

Any help is highly appreciated.

like image 460
KlezFromSpace Avatar asked Dec 02 '25 01:12

KlezFromSpace


1 Answers

We've now released a tutorial on how to retrain the Inception model, including instructions for how to deploy the model on the CloudML service.

https://cloud.google.com/blog/big-data/2016/12/how-to-train-and-classify-images-using-google-cloud-machine-learning-and-cloud-dataflow

like image 107
rhaertel80 Avatar answered Dec 05 '25 00:12

rhaertel80



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!