OpenCV, arithmetical functions are a set of operations that can be performed on images, such as addition, subtraction, multiplication, and division. These functions are used to manipulate the pixel values of an image and can be used for image processing tasks such as image enhancement and thresholding.
Some examples of arithmetical functions in
cv2.add(): adds two images together element-wise;
cv2.subtract(): subtracts one image from another element-wise;
cv2.multiply(): multiplies two images together element-wise;
cv2.divide(): divides one image by another element-wise;
cv2.addWeighted(): performs a weighted sum of two images;
cv2.absdiff(): computes the absolute difference between two images element-wise.
- Read two images;
- Add two images together;
- Show the image.
Everything was clear?
Start learning today and achieve
- Learn with Step-by-Step Lessons.
- Get Ready for Real-World Projects.
- Earn a Certificate Upon Completion.