Graph Neural Networks (GNN) have proven their capability in traffic forecasting, recommendation systems, drug discovery, etc., with their ability to learn from graph representations. What I’m going to do here is take you through the working of a simple Graph Neural Network and show you how we can build a GNN in PyTorch to solve the famous Zachary Karate Club node classification problem.(more…)
Well-made Docker images are the foundation for deploying secure and scalable Docker-based applications. Building quality images also improves image re-usability, readability, and maintainability. Here are some best practices you should follow while building Docker images.(more…)
An ecosystem of Internet-tethered devices underpins many of the services the world relies on today. But this connectivity comes with a major caveat in that services can be brought to naught with a simple security breach. The largest ransomware attack on a major U.S. pipeline last year involved a single password leak. The breach was grave enough to force the pipeline company to temporarily halt its operations, sending fuel prices soaring for weeks.
Statista projects the total installed base of IoT-connected devices to reach 30.9 billion by 2025. Depending on the use case, a security breach can cause major disruptions or even disasters. So in the Internet of Things era, it is crucial to ensure that only trustworthy devices are connected to the Internet. This is where device authentication comes into the picture.(more…)
The new architecture recommendation from Google is changing how we build Android apps. The architecture separates UI and data into distinct layers, with an optional “domain” layer in between. It doesn’t have a specific name like MVVM and is instead referred to as the “new architecture” or “layered architecture.”(more…)
While working on applications that process a large number of images, we often come across the requirement to resize images for different resolutions. An image generated by a typical 12MP mobile phone camera can be 5MB-12MB depending on the quality of the image. Once uploaded, the image must be optimized for different devices. As you know, image resizing is a complex mathematical process. The performance and quality of the optimized image really depend on the efficiency of the algorithms used.
Let me walk you through a high-performance solution for image resizing. We will implement the solution using libvips, a fast open-source image processing library, along with Golang and expose the resize functionality via a proxy server. With even 20% resource usage improvement per image, it can make a world of difference when scaling up to millions.(more…)
Scaling machine learning pipelines using PyTorch can be a pain.
You typically start a PyTorch-based machine learning project by defining the model architecture. Then you run it on a CPU machine and progressively create a training pipeline. Once the pipeline is done, you run the same code on a GPU or TPU machine for faster gradient computations. You update the PyTorch code to load all the tensors to the GPU/TPU memory with a ‘.to(device)’ function call. Now comes the difficult part: what if you want to use distributed training for the same pipeline? You have to overhaul the code and test it to make sure nothing is broken.
Why sweat the small stuff? Let’s use PyTorch Lightning instead.(more…)
Modality refers to how a particular subject is experienced or represented. Our experience of the world is multimodal—we see, feel, hear, smell and taste things. Multimodal deep learning tries to link and extract information from data of different modalities. Just as the human brain processes signals from all senses at once, a multimodal deep learning model extracts relevant information from different types of data in one go.(more…)
Cloud Development Kit (CDK), an Infrastructure as Code (IaC) framework, lets you define cloud resources using your favorite programming language and create CloudFormation (declarative programming model based on JSON or YAML files) template out of it. This means you can get started quickly if you have work experience in AWS and proficiency in any of the programming languages like TypeScript, Python, C#, or Java.
Hang on and I’ll show you in a bit how quickly you can create and deploy a CDK app.(more…)
Rarely do we use proxies on our personal devices to access anything. But when you are developing an app for a client, and they want only whitelisted IPs to access their server, you will have to set up a proxy. You can set up a proxy for all network traffic or a specific set of network calls (for example, requests from within an app).
Let me walk you through the steps to configure proxy settings for your Mac or iPhone globally.(more…)