Transfer Learning is a technique in machine learning where we reuse a pre-trained model to solve a different but related problem. It is one of the popular methods to train the deep neural network. It is generally used for image classification tasks where the amount of the dataset is small.

In this article, we will go through what transfer learning is, how it works and the advantages it offers. Additionally, we will also cover the most common problems related to it.

In this tutorial, we are going to focus on reading an image using the Python programming language. For this, we are going to use the OpenCV library. OpenCV refers to Open Source Computer Vision library aimed at computer vision and machine learning.

To use OpenCV in Python install the following libraries:

  1. NumPy
  2. OpenCV

To install the above libraries, use the following command.

pip install opencv-python 
pip install numpy


Here, we are going to import all the required libraries.

import numpy as np 
import cv2

cv2.imread — Reading an Image

To read an image cv2.imread() function is used.

Syntax: cv2.imread(path, flag)

  • path: The path represents the…

This tutorial focus on the implementation of the image segmentation architecture called UNET in the PyTorch framework. It’s a simple encoder-decoder architecture developed by Olaf Ronneberger et al. for Biomedical Image Segmentation in 2015 at the University of Freiburg, Germany.

What is Image Segmentation?

An image consists of multiple objects inside it, such as people, cars, animals, or any other object. To classify the image, we use image classification, where the task is to predict the label or class of the input image. Now imagine, we need to find the exact location of the object, i.e, which pixel belongs…

Convolutional Neural Network (CNN) is used to solve a wide range of visual tasks such as image classification, object detection, semantic segmentation, and many more. CNN consists of a series of convolutional layers with non-linear activation functions and some downsampling layers. These CNNs are able to capture hierarchical patterns and produce image representations.


  1. What is Convolution Neural Network?
  2. Why Convolution Neural Network over Feed Forward Neural Network?
  3. Major Building Block of CNN
  • Convolutional layer
  • Activation layer
  • Pooling layer
  • Fully connected layer

What is Convolution Neural Network?

Convolutional Neural Network (CNN) or ConvNets for short is a class of deep neural networks popularly used for…

In this post, you will learn how to implement UNET architecture in TensorFlow using Keras API. The post helps you to learn about UNET, and how to use it for your research.

UNET is one of the most popular semantic segmentation architecture. Olaf Ronneberger et al. developed this network for Biomedical Image Segmentation in 2015.

The block diagram of the original UNET architecture

To know more, read the article: What is UNET?


In this first part of the post, you need to import all classes required for the implementation of the UNET architecture.

from tensorflow.keras.layers import Conv2D, BatchNormalization, Activation, MaxPool2D, Conv2DTranspose, Concatenate, Input
from tensorflow.keras.models import Model


The current era started to move towards Artificial Intelligence, which massively impacted the world with its ability to achieve the tasks that were a dream of humanity. All of these achievements are mainly due to the research and development in the field of Deep Learning and Neural Network, which are a part of Artificial Intelligence.

What is the GPU?

A graphics processing unit or GPU is a single-chip processor designed for the parallel processing that can be used to accelerate a wide variety of tasks such as video rendering, gaming and machine learning.

A GPU is designed for handling specialized computations, whereas a CPU…

In this post, we are going to learn and build a python program where we are going to extract and save frames from videos using the OpenCV library.

OpenCV is one of the most commonly used libraries for computer vision tasks, such as reading and saving images, face recognition, segmentation, etc. It provides us with a list of powerful functions that can be used in image and video analysis.

Related Article


Here, we are going to load all the modules and function that we are going to use…

RESUNET refers to Deep Residual UNET. It’s an encoder-decoder architecture developed by Zhengxin Zhang et al. for semantic segmentation. It was initially used for the road extraction from the high-resolution aerial images in the field of remote sensing image analysis. Later, it was adopted by researchers for multiple other applications such as polyp segmentation, brain tumour segmentation, human image segmentation, and many more.

Original Paper: Road Extraction by Deep Residual U-Net

RESUNET is a fully convolutional neural network that is designed to get high performance with fewer parameters. It is an improvement over the existing UNET architecture. …

UNET is an architecture developed by Olaf Ronneberger et al. for Biomedical Image Segmentation in 2015 at the University of Freiburg, Germany. It is one of the most popularly used approaches in any semantic segmentation task today. It is a fully convolutional neural network that is designed to learn from fewer training samples. It is an improvement over the existing FCN — “Fully convolutional networks for semantic segmentation” developed by Jonathan Long et al. in (2014).


UNET — Network Architecture

UNET is a U-shaped encoder-decoder network architecture, which consists of four encoder blocks and four decoder blocks that are connected via a bridge. The…

All the technological advancements in the field of Artificial Intelligence (AI) is facilitated due to the availability large amount of dataset and the computational hardware’s like GPU’s and TPU’s. In some fields like medical imaging, the availability of the huge amount of data is not possible, as it takes a good amount of efforts to collect the data and then labelling it requires the domain expertise. To, solve this issue, we use data augmentation. In this article, we will go through the process of applying data augmentation to any semantic segmentation dataset.


  1. What is Data Augmentation?
  2. Why do we…

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