Aditya Chatterjee's Blog, page 148

November 4, 2021

The ShuffleNet Series (Part 3): Implementation using Pytorch

The ShuffleNet Series (Part 3): Implementation using Pytorch

We are now in the last part of the ShuffleNet series. I have already introduced the ShuffleNet family and we have seen the power of ShuffleNet in my previous articles. This article will include the complete explanation of building ShuffleNet using Pytorch, a popular deep learning package in Python. I will be covering the step by step tutorial starting from installation of all required packages to testing the Shufflenet model and visualization using CIFAR 10 dataset. We are going to build a multi...

 •  0 comments  •  flag
Share on Twitter
Published on November 04, 2021 06:07

Precision, Recall, Sensitivity and Specificity

In this article, we have explained 4 core concepts which are used to evaluate accuracy of techniques namely Precision, Recall, Sensitivity and Specificity. We have explained this with examples.

Table of contents:

Introduction with an exampleConfusion MatrixPrecisionRecall or SensitivitySpecificityHow to remember ?Let us have a small test !

Prerequisites:

Model EvaluationPerformance metrics in Classification and RegressionBasics of Machine Learning Image Classification Techniques

In o...

 •  0 comments  •  flag
Share on Twitter
Published on November 04, 2021 04:19

November 3, 2021

Reverse part of Singly Linked List

In this post, we have demonstrated ways in which we can not only reverse a singly linked list but also some part of Singly Linked List. It takes linear time O(N) to Reverse part of Singly Linked List.

Table of contents:

Introduction to reversing Linked ListApproach 1 to Reverse part of Singly Linked ListApproach 2 to Reverse part of Singly Linked List

This is similar to Leetcode problem 92. Reverse Linked List II. Let us get started with Reverse part of Singly Linked List.

Introduction to re...
 •  0 comments  •  flag
Share on Twitter
Published on November 03, 2021 13:34

Different ways to initialize Deque in C++ STL

In this article, we will learn about the concept behind a deque and different ways to initialize a deque in C++ Standard Template Library (STL).

Table of contents:

What is a Deque?C++ default constructorC++ fill constructorC++ range constructorC++ move constructorC++ copy constructorC++ initializer_list constructor

Let us get started with Different ways to initialize Deque in C++ STL.

What is a Deque?

A deque, also known as double-ended queues, are indexed sequence containers part of the...

 •  0 comments  •  flag
Share on Twitter
Published on November 03, 2021 06:38

October 31, 2021

Federation: Functional Partitioning of Database + FDBS

In this article, we have explained the concept of Federation including Functional Partitioning of Database + Federated Database System (FDBS). These System Design concepts are important to design efficient Database for systems.

Table of contents:

Introduction to DatabaseStrategies for partitioning dataHorizontal partitionVertical partitioningFunctional / Federation partitioningFederated Database System (FDBS)

Let us get started with Federation: Functional Partitioning of Database + FDBS.

...
 •  0 comments  •  flag
Share on Twitter
Published on October 31, 2021 11:00

Remove N-th Node from end of Singly Linked List

In this article, we have explained two approaches to Remove N-th Node from end of Singly Linked List. We can do this in single pass / one traversal in O(N) time.

Table of contents:

Introduction to Linked ListApproach 1: Making two passes through Linked ListApproach 2: Going through the list once, one pass

Prerequisites: Singly Linked List, Slow Fast pointer technique

Similar problems you should learn about:

Delete operation in Linked ListDelete Middle node of Linked List

This is similar t...

 •  0 comments  •  flag
Share on Twitter
Published on October 31, 2021 10:41

Interview Questions on Quick Sort

In this article, we have presented Interview Questions on Quick Sort (MCQ) with detailed answers. You must practice this as Quick Sort is the most important topic for Coding Interviews.

If you want to revise Quick Sort once quickly, go through this article. Let us answer Interview Questions on Quick Sort.

Q1. What is the Worst Case Time Complexity of Quick Sort?O(N^2)O(N)O(N logN)O(N loglogN)The worst case Time Complexity of Quick Sort is O(N2) and this happens when the partition algor...
 •  0 comments  •  flag
Share on Twitter
Published on October 31, 2021 10:09

Letter Combinations of a Phone Number

In this article, we have disccussed two approaches (recursive + iterative) to solve the problem "Letter Combinations of a Phone Number" in C++ language with explanation of Time and Space complexity.

Table of contents:

1.Explanation of the problem

2.Recursive approach discussion

Approach discussionAlgorithm walkthroughImplementation of recursive codeTime and space complexity

3.Iterative approach discussion

Approach discussionAlgorithm walkthroughImplementation of Iterative codeTime and s...
 •  0 comments  •  flag
Share on Twitter
Published on October 31, 2021 06:50

Roman to Integer

In this article, we have explained two efficient approaches / algorithms to convert Roman number to Integer. We have presented the implementation as well.

Table of contents:

Introduction to Roman SystemApproach 1: Using switch statementsApproach 2: Using Hash Map

Prerequisite:

Switch StatementsHash Map / Hash Table

Let us get started with Roman to Integer. This is similar to Leetcode Problem 13. Roman to Integer.

Introduction to Roman System

The roman number system consists of 7 main symb...

 •  0 comments  •  flag
Share on Twitter
Published on October 31, 2021 04:33

Merge Intervals problem

In this article, we will learn how to solve the Merge Overlapping Intervals problem in most efficient and easy to understand method with the help of stack. We do this in linear time O(N).

Table of contents

Problem statementGeneral ApproachAlgorithmC++ ImplementationFinal Code

Let us get started with Merge Intervals problem. This is similar to Leetcode problem 56. Merge intervals.

Problem Statement

Given a set of time intervals in any order, merge all overlapping intervals into one and outp...

 •  0 comments  •  flag
Share on Twitter
Published on October 31, 2021 04:12