- Trending Categories
Data Structure
Networking
RDBMS
Operating System
Java
MS Excel
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
Physics
Chemistry
Biology
Mathematics
English
Economics
Psychology
Social Studies
Fashion Studies
Legal Studies
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
Bilateral filtering using OpenCV
In this program, we will perform bilateral filtering in an image. Bilateral filter is used for smoothening images and reducing noise, while preserving edges. We will use the bilateralFilter() function for this purpose. This function takes in diameter of each pixel, value of sigma in color space and value of sigma in coordinate space.
Original Image
Algorithm
Step 1: Import cv2. Step 2: Read the image. Step 3: Call the bilateralfilter() function. Step 4: Display the output.
Example Code
import cv2 image = cv2.imread('testimage.jpg') blur = cv2.bilateralFilter(image, 29,100,100) cv2.imshow('BilateralFilter', blur)
Output
- Related Articles
- How to implement Bilateral blur in OpenCV using Java?
- How to perform bilateral filter operation on an image in OpenCV using Python?
- Array filtering using first string letter in JavaScript
- Filtering Files Copied When Using rsync on Linux
- What is unilateral contracts and bilateral contracts?
- Using OpenCV with Tkinter
- Upsampling an image using OpenCV
- Downsampling an image using OpenCV
- jQuery Traversing Filtering
- ArduinoJSON: Filtering Data
- Histograms Equalization using Python OpenCv Module
- Template matching using OpenCV in Python
- Arithmetic operations using OpenCV in Python
- Java Image Translation example using OpenCV.
- Python Grayscaling of Images using OpenCV

Advertisements