How to do division/divide of Tensors in TensorFlow?

In TensorFlow 2.0 Python Tutorial, We will Learn about the TensorFlow Math Module tf.divide() function. We will learn how to do the division of tensors in TensorFlow using tf.devide() function. tf.divide() : Do Element wise division,It can be divide scaler, Numpy array but not with list, tuple.tf variable/constant/placeholder/SparceMatrix with each other and with scaler and with list/tuple...
Read More

How to Calculate Square Root of Tensors in TensorFlow?

In TensorFlow 2.0 Python Tutorial, We will Learn about the TensorFlow Math Module tf.sqrt() function. We will learn how to calculate the square root of tensors in TensorFlow using tf.sqrt() function. tf.sqrt() : Calculate Element wise square root of numpy array and TF tensor,It can be give sqrt of list, tuple, scalerIt allow tf variable/constant/placeholder/SparceMatrix with Specific datatype...
Read More

How To Multiplication Of 2 Tensors In TensorFlow?

We will learn how to do multiplication in TensorFlow using tf.multiply() function. tf.multiply() : Do Element wise Multiplication,It can be multiply list, tuple, scaler,tf variable/constant/placeholder/SparceMatrix with each other and with scaler and with list/tuple Note: * operator can be used to multiply 2 tensors Syntax: tf.multiply(x, y, name=None) ArgsxA Tensor. Must be one of the...
Read More

How To Subtraction of 2 Tensors In TensorFlow?

We will learn how to do suntraction in TensorFlow using tf.subtract() function. tf.subtract() : Do Element wise subtraction with x & yIt can subtract list, tuple, scaler, TensorFlow variable/constant/placeholder/SparceMatrix with each other and with scaler and with list/tuple. Note: - operator can be used to subtract 2 tensors Syntax: tf.subtract(x, y, name=None) ArgsxA Tensor....
Read More

How to addition/add 2 Tensors in TensorFlow?

We will learn how to do addition in TensorFlow using tf.add() function. tf.add() : Do Element wise Addition with x & yIt can add list, tuple, scaler, TensorFlow variable/constant/placeholder/SparceMatrix with each other and with scaler and with list/tuple. Note: + operator can be use to add 2 tensors Syntax: tf.add(x, y, name=None) ArgsxA tf.Tensor. Must be one of the following types:...
Read More

Copy Single or Multiple Files in Seconds Using Python

In this tutorial, we are going to learn how to copy single or multiple files in a second using the Python shutil library. File extension is any like '.jpg', 'png', '.txt'. Syntax: shutil.copy(source_file_path, destination_file_path) IInstall Python Shutil Library Enter below command in python environment pip install pytest-shutil Import Libraries import shutil # copy the file import glob # get...
Read More

How to Change Image File Extension

In Python OpenCV Tutorial, we are going to change the image file extension from one form to another using  cv2.imwrite() function. Like JPG to PNG or PNG to JPG. Change Image File Format Supported Image file format by OpenCV Opencv Support Below Image file format to read & write(Save): Windows bitmaps - *.bmp, *.dib (always supported)JPEG files - *.jpeg, *.jpg, *.jpe (see the Notes...
Read More

Change the Pixel Value of an Image in OpenCV Python | OpenCV Tutorial

In Python OpenCV Tutorial, Explained How to Change Pixels Color in an image using NumPy Slicing and indexing. Get the answers of below questions: What is pixel?What is resolution?How to read image pixel?How to get image pixel?How to print image pixel?How to change the pixel value of an image in python opencv?How do I pixelate an image in OpenCV?How do I change the pixel value of an image in...
Read More

Get Image Pixels Using OpenCV Python | OpenCV Tutorial in Hindi

In Python OpenCV Tutorial, Explained How to get image pixel using NumPy Slicing and indexing. How to access image pixels Below code executed on Jupyter Notebook # Import Library import cv2 import numpy as np # Read & Show Image img_path = r"C:\Users\kashz\AI Life\AI Projects - IAIP, PTs (Web + Channel)\02 OpenCV\000 opencv tutorial\data\pexels-rafi-ahmed-haven-1253364.jpg" img =...
Read More

How to Dilate(Dilation) Image using OpenCV Python

Morphological Operations Morphological transformations are some simple operations based on the image shape. It is normally performed on binary images. It needs two inputs, one is our original image, the second one is called structuring element or kernel which decides the nature of the operation. Two basic morphological operators are Erosion and Dilation. Then its variant forms like Opening,...
Read More
Top