If you have been programming in Python, chances are high that you have encountered at least one library that offers functionalities dealing with representation and customization of colors.From image processing to data visualization to web application development, you will find the use of colors everywhere.In fact, most of the modern deep neural networks used for the state of the art ...

Read More »## NumPy Meshgrid From Zero To Hero

What is a meshgrid? The term meshgrid is made up of two words – ‘mesh’ and ‘grid’, both of which in generalrefer to ‘a network’ or ‘an interlaced structure’ or an ‘arrangement’ of equally spaced valuesThe Cartesian coordinate system is a classic example of this. As shown in the image, each position is referred to by an ordered pair of ...

Read More »## 3D plotting in Python using matplotlib

Data visualization is one such area where a large number of libraries have been developed in Python. Among these, Matplotlib is the most popular choice for data visualization. While initially developed for plotting 2-D charts like histograms, bar charts, scatter plots, line plots, etc., Matplotlib has extended its capabilities to offer 3D plotting modules as well. In this tutorial, we ...

Read More »## Dijkstra’s algorithm in Python (Find Shortest & Longest Path)

In a previous tutorial, we talked about the Depth First Search algorithm where we visit every point from A to B and that doesn’t mean that we will get the shortest path. In this tutorial, we will implement Dijkstra’s algorithm in Python to find the shortest and the longest path from a point to another. One major difference between Dijkstra’s ...

Read More »## Depth First Search Algorithm In Python (Multiple Examples)

Introduction Graphs and Trees are one of the most important data structures we use for various applications in Computer Science.They represent data in the form of nodes, which are connected to other nodes through ‘edges’. Like other data structures, traversing all the elements or searching for an element in a graph or a tree is one of the fundamental operations ...

Read More »## Python Correlation Matrix Tutorial

In this blog, we will go through an important descriptive statistic of multi-variable data called the correlation matrix. We will learn how to create, plot, and manipulate correlation matrices in Python. We will be looking at the following topics: What is the correlation matrix? A correlation matrix is a tabular data representing the ‘correlations’ between pairs of variables in a ...

Read More »## How to Loop Over a Dictionary in Python: Keys, Values, and More

Welcome to yet another How to Python article. Today, we’ll be looking at looping over dictionaries which appears to be a hot topic—at least by an organic standpoint. As it turns out, there are few ways to get it done. First, we could loop over the keys directly: for key in dictionary. Alternatively, we might only need to loop over the ...

Read More »## NumPy Where Tutorial (With Examples)

Looking up for entries that satisfy a specific condition is a painful process, especially if you are searching it in a large dataset having hundreds or thousands of entries. If you know the fundamental SQL queries, you must be aware of the ‘WHERE’ clause that is used with the SELECT statement to fetch such entries from a relational database that ...

Read More »## Python humanize time-interval without Arrow or Humanize libraries

Sometimes when we need to debug functions in Python, we need a way to write some quick timer code to capture the time-delta and to compute the time it took for the function to execute. This article shows you a quick and easy way to humanize a time-interval/time-delta without bringing in additional dependencies or libraries like Arrow or Humanize. 1 ...

Read More »