AI based image analysis techniques have come a long way in recent years. While image classification models can be trained from scratch it is often more practical to retrain an already trained model. This is called transfer learning. Read more about it in the link below. In this post, we will be looking at using a retrained TensorFlow model to optimize data processing throughput using Go.
TensorFlow allows exporting a trained model to be integrated in a variety of programming languages via it’s C API. The workflow discussed here is as follows:
Let’s walk through a quick setup to define a workflow for serving a
keras model packaged in a Go binary with TensorFlow backend engine. Keras is a high level Python API that makes it very easy to construct a deep learning model. It can seamlessly operate with TensorFlow as one of the supported ML engines. Typically, all such high level work is done in Python, however, it is quite useful to be able to serve a ML model in the form of a compiled binary without requiring the end user to install any dependencies on their system. …
TensorFlow is a very powerful computing platform, particularly for working with matrices, linear algebra and machine learning. Such computation can be very verbose and difficult to express in low level languages such as C and Go and we need an ability to design the computation in high level languages. TensorFlow, with its Python interface, allows us to express complex computations and at the same time provides the path for seamless integration with low level languages for production use cases.
The real beauty of TensorFlow is the ability to export a computation graph that is language agnostic. This makes it possible…
Edge computing covers a wide spectrum of configurations from a multi-node Kubernetes cluster running as an edge unit to a single node Raspberry Pi Zero or perhaps a micro-controller sending data over MQTT channel. Each of these configurations requires a different way of thinking for workload management. For instance, if the edge device is a Kubernetes cluster, we could leverage Git-Ops for deploying applications on it. However, if the edge device is a Raspberry Pi Zero with a single core processor, limited memory and ARM v6 architecture, there are only a few options to run applications on such devices.
Recently I purchased a GPS sensor to integrate with Raspberry Pi. It’s been fun and a good learning experience to collect GPS data from it using Go code. The sensor I have is a PA1010D connected to a Raspberry Pi Zero W over I²C bus. With a battery-pack powering the Raspberry Pi, the whole setup turned out to be highly portable.
Below is the final output from the setup showing overlay of GPS data on Google maps. This overlay was produced using Google drive’s map feature that allows importing GPX formatting GPS coordinates. …
BME280 sensor is a pressure, humidity and temperature sensor from Bosche and wonderfully packaged with I²C interface by Adafruit Industries, which makes it very easy to use with devices such as Raspberry Pi.
I have written about monitoring temperature and humidity in the past and this post is about evaluating its barometric pressure measurement capabilities. In particular, I took this sensor on a bike ride and correlated data captured using this sensor against what was reported by GPS sensing Strava app running on my phone. Let’s dig into details…
Strava is a very popular ride tracking app that can be…
Every API call to Kubernetes API server is made using an authorization bearer token. These tokens come in two flavors:
Both these tokens are so called
JWT tokens, which are increasingly becoming a standard way to communicate identity during API calls. The key property of these
JWT tokens is that they are open and can be decoded, but at the same time they contain a signature which can be cryptographically verified. This property allows
JWT tokens to be portable in the sense that they can be remotely verified using the…
I was looking for a sensor to monitor temperature, humidity and pressure using Raspberry Pi and came across BME280 sensor. The sensor is very nicely packaged by Adafruit Industries as you see in the image above. In particular, the stemma QT connectors on the board, make it very easy to connect the sensor board with GPIO pins of the Raspberry Pi. From a point of view of hardware assembly, getting the sensor connected was very easy and I used this diagram to connect it to the Raspberry Pi Zero.
The sensor uses I2C bus, which requires following setup on the…
This post addresses a special case of arriving at a multi-architecture container manifest, i.e., the container image name and tag that work the same across multiple OS architectures such as
Imagine you are pulling
ubuntu:21.04 container image on two separate OS architectures, say
linux/arm64. As you would expect, the contents of container image on these two architectures would differ despite the fact that both were pulled using the same container image name and tag. Let’s see this in action:
As you may have guessed from my previous posts, I am currently busy putting together a Kubernetes based cloud-native software stack for working with Raspberry Pi’s, and other IoT devices for that matter. This post is a quick overview of a use case where we want to track sensor data from a device and visualize it on a dashboard, but do so in a cloud-native way using Kubernetes primitives.
Software engineer and entrepreneur currently building Kubernetes infrastructure and cloud native stack for edge/IoT and ML workflows.