Sign in

Saptashwa Bhattacharyya

In this post, I will give an introduction of Support Vector Machine classifier. This post will be a part of the series in which I will explain Support Vector Machine (SVM) including all the necessary minute details and mathematics behind it. It will be easy, believe me! Without any delay let’s begin —

Suppose we’re given these two samples of blue stars and purple hearts (just for schematic representation and no real data are used here), and our job is to find out a line that separates them best. What do we mean by best here ?

Figure 1: Samples in a 2D plane with some separation between them

Let’s see the…


Mathematics of Eggs! Photo by Katherine Chase on Unsplash

A standard formula for describing any bird’s egg in nature is here, and the research report is published recently in the Annals of the New York Academy of Sciences. Eggs are in a sense representation of perfect shape considering the evolution process because they are optimized to cover an embryo and, exit the body in an efficient way. Any bird’s egg shapes are divided into four basic geometric shapes: sphere, ellipsoid, ovoid (shape in 3-D space generated by rotating an oval by one of its axis of symmetry), and pyriform (pear-shaped). The first three shapes are already mathematically well defined…


Build a data pipeline as clean as this river (source: Author)

While training a neural network, it is quite common to use ImageDataGenerator class to generate batches of tensor image data with real-time data augmentation. However, in this post, I will discuss tf.data API, using which we can build a faster input data pipeline with reusable pieces. As mentioned in the TensorFlow documentation —

The tf.data API makes it possible to handle large amounts of data, read from different data formats, and perform complex transformations.

This post will be short and crisp including a working example using tf.data; so without any delay let’s begin. …


QFT Circuit for 3 Bits (Source: Author)

After covering the Deutsch-Jozsa algorithm and Grover’s algorithm, today we will focus on Quantum Fourier Transform. The main concept that we would develop here is to use a quantum computer to develop an analog of Discrete Fourier Transform (DFT). DFT is important in digital signal processing and allows us to split the input signal that is spread in time into the number of frequencies of certain amplitudes, and phases so that all those frequencies can form the original signal. Let’s see how we can build a quantum analog of the DFT and this will form the basis of Shor’s Algorithm


Back to Nature (Source: Author)

Wouldn’t it be arrogant enough from my side to assume that you would like what I have liked? Probably! Then I remember one of the quotes from the chapter —

The other side of the globe is but the home of our correspondent.

Book reviews should not always be considered as a benchmark for picking up a book. And I certainly felt that while going through few chapters of the book ‘Walden’ by Henry David Thoreau, including prolonged descriptions on bean cultivation or the author’s contemplation about the unusual depths of the pond Walden. I had to trudge through some…


Possible Circuit to Verify Grover’s Algorithm? (Source: Author)

After Deutsch-Jozsa algorithm, we will discuss Grover’s algorithm through which it was shown that Quantum Computers (QCs) can be substantially faster for searching databases than classical computers. The task that Grover’s algorithm aims to solve can be expressed as follows: given a classical function f(x):{0,1}ⁿ→{0,1}, where n is the bit-size of the search space, find an input x_0 for which f(x_0)=1. Our idea is to think about an oracle (black box) which has the ability to recognize the solution to the search problem and this recognition is signaled by making use of an oracle qubit. We will come to this…


Black Hole? Artist’s Impression (Source: Pixabay)

Palomar 5 is a ‘fluffy’ cluster, spanning over 20 degrees across the sky and, it has very low density (0.1 times the solar mass over 1 cubic parsec), making it about 3,000 times less dense than average. Recently a study by a group of scientists from Spain, the UK and the Netherlands have published a research report in Nature Astronomy where they suggested that the sparse nature of Palomar 5 may be due to more than 100 black holes lurking within it. Let’s get a bit deeper !!!

Long Tail of Palomar 5:

Palomar 5 is a globular cluster (GC) in our own galaxy Milky…


Left: Original Image, Right: After augmentation with Augly (Image Created by Author)

Facebook recently released [1] an augmentation library, Augly, that combines several modalities (audio, image, video, and text) under the same roof. Data augmentation is quite a common technique for increasing both the size and the diversity of labeled training data which also helps to build robust models. Here I focus only on few of the augmentation functions I tested on an image but, this library can be used for text and audio too.

Augly is more dedicated towards transformations that happen in social media platforms, including Facebook. So apart from the usual crop, flip, other augmentation functions include very realistic…


Verify DJ Algorithm for a balanced oracle. Image by Author created using Qiskit + Matplotlib.

Today we will learn and discuss about one of the most fundamental quantum algorithms, Deutsch-Jozsa algorithm, which was proposed by David Deutsch and Richard Jozsa in 1992 [1] and really showed the power of quantum algorithms over the classical ones. To discuss Deutsch-Jozsa algorithm, it is better to start from Deutsch algorithm where instead of n qubits, we just consider a single qubit. This will help us to ease our way towards understanding some of the hefty mathematics that will come later on. Before we start getting into detail, some of the important and necessary concepts like uniform superposition that…


Sunset ! Image by Author

Since Deep Neural Networks (DNN) have large set of learnable parameters, large amount of labeled data is necessary so that these parameters generalize well for our task in hand. Data augmentation is quite a common technique for increasing both the size and the diversity of labeled training data. In the Deep Learning Specialization course, Andrew Ng mentioned that unlike other domain, in computer vision it is almost always better to have more data. Image augmentations have also become a common implicit regularization technique to address over-fitting in DNNs. Usually in image augmentation we use combinations of flipping, rotating, scaling etc…

Saptashwa Bhattacharyya

PhD, Astrophysics. Using Deep Learning, Searching Dark Matter! https://www.linkedin.com/in/saptashwa

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store