credits : gif.com

Now if you’ve been bit active in the Machine learning community , you would have already heard about GANS ( Generative Adversarial Networks)

What exactly are GANS ?

To put it simple GANS pits two neural networks against each other , I know I made nothing clear with the above statement so let me give you an analogy.

Let’s consider the relation between a forger and an investigator


Hey, this is the first article I am going to write on medium so as you have seen the title this is about Face-Recognition so let’s get started.

You can check the code from my Github repo from here

Importing Stuff

well let’s start importing we need as you have guessed OpenCV(you can install it from there) and numpy as well as the most important one for this code face_recognition

Access the Webcam and load the sample images

Well we could use the webcam using VideoCapture(0) from openCV and then start loading your image or some other image which you want…


I have been working on Kornia, its a really cool library with some really cool application you can install it using

pip install --upgrade kornia

You can check its documentation from here.

Today we will create a Color Adjustment Application using Kornia and Streamlit

Importing Libraries

Let’s import the required libraries such as Kornia, Streamlit and Torch.

Add the Title

Let’s add the titles for the streamlit application and we will be using st.file_uploader() function for uploading the images dynamically

Display and Normalize the Image

Now we will create a function for displaying the image and also we will normalize it

In the above snippet first, we…


QR Code decoding is a really interesting application, now what if we could deploy it as a web application?

What exactly is a QR Code?


Facial landmarks can help us predict many things it could be used for emotion detection , distress detection or even whether a driver is falling asleep or not when driving . We are going to use a pre-trained model for detection of landmarks around the face .

Importing stuff

Let’s import the required libraries such as OpenCV , dlib & numpy

Define the Landmarks

There are a total of 68 landmarks that we are going to plot on this model (we can also alternate it to detect only 5 landmarks for real-time purposes in edge devices )

Draw Shapes

Now let’s define functions to draw…


In this blog we will create a CNN-Y-Network(2 Inputs , 1 output) with the help of a Functional API

Sequential API vs Functional API


Yes, Transfer learning is a important part of Machine learning(ML) even though it is not a Machine Learning Technique but is used in many real world applications

Why is it Important?

When we humans learn we don’t exactly start from scratch ,we might (intentionally or unintentionally) have some knowledge of the thing we are trying to learn , so we use our previous experience while learning something new or trying to complete a new task . Now how is it related to ML ?


I understand that this is a really basic concept that many machine learning enthusiasts out there can put it in better words than me but as basic as they might be there were many times(more times than I want to accept) I was really confused with differences between variance and bias or what did terms like high-variance or low-bias mean

Bias and Variance (what exactly are they)?

Bias is a set of assumptions that an ML algorithm makes to learn the representations underlying the given data.So to put it simply if a model performs really well on the training data it is said to have low-bias (as…


If you are familiar with Tensorflow you would have heard about callback function so here is a small blog of writing a custom one on your own.

What exactly is a Callback Function?

Well according to Tensorflow official website

A callback is a powerful tool to customize the behavior of a Keras model during training, evaluation, or inference. Examples include tf.keras.callbacks.TensorBoard to visualize training progress and results with TensorBoard, or tf.keras.callbacks.ModelCheckpoint to periodically save your model during training.

In a nutshell, this means you can execute special functionality when conditions are met, such as stopping model training after reaching a specified accuracy or saving the model…


Hello, I hope all of you are doing good in these troubled times and I hope 2021 is treating you better than 2020 did. So today let’s code Age- Gender Detection in real-time using transfer learning(obviously why to go through all that trouble of creating a model from scratch when we have pre-trained models with better accuracy(but will try to build a custom model though in near future) )

Importing the libraries

Let’s start with importing the necessary libraries for the code

Create getFaceBox

We will create a function called getFaceBox for preprocessing the image ,create a blob of the image(so that it can…

Pavan Kunchala

Machine learning & Computer Vision Engineer |Deep learning and Reinforcement learning enthusiast

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