Hi !

In my previous post I wrote

  • How to create a custom dataset with images to be used on a Azure Machine Learning Designer project.
  • How to use the custom data set and how to train an image classification model.
  • How to publish the model to be used as a WebService / HTTP REST endpoint.

Each endpoint provides a set of code samples in C#, Python and R. The code is autogenerated, and because we are working with binay images, the generated code will be huge !!! This is because it will include a Base64().toString() serialization of the file.

binary code included on the code sample

Based on the original code, I created a sample code in Python that will read a local file, encode the file and then make the http request.

It works almost without a change, and here is a sample output that also includes a call to the next sample, which process the JSON response, this sample may also help!

azure ml sample client calling endpoint

Tomorrow I’ll show a live webcam real-time analysis using the Azure ML Endpoint to detect Squirrels or Space Wolves!

Happy coding!

Greetings

El Bruno

More posts in my blog ElBruno.com.

More info in https://beacons.ai/elbruno



¿Con ganas de ponerte al día?

En Lemoncode te ofrecemos formación online impartida por profesionales que se baten el cobre en consultoría:

Leave a comment

Discover more from El Bruno

Subscribe now to keep reading and get access to the full archive.

Continue reading