Piecewise linear transformation function: Contrast Stretching in DIP & implementation in MATLAB|

Описание к видео Piecewise linear transformation function: Contrast Stretching in DIP & implementation in MATLAB|

Video lecture series on Digital Image Processing, Lecture:10,
Piecewise linear transformation function: Contrast Stretching and its implementation in MATLAB
#DigitalImageProcessing
#MATLAB
#DIPwithMATLAB
#StudywithDrDafda

What is Piecewise linear tansformation?
Which are different types of piecewise linear transformation functions?
What is Contrast?
What is contrast stretching?
What is the output equation for contrast stretching in DIP?
How to implement piecewise linear contrast stretching in MATLAB?
Digital Image Processing (DIP) using/in MATLAB
MATLAB code used in the video is present at the end in the Description

Link to download ppts/lecture notes:
https://drive.google.com/drive/folder...

Links of other lectures in the series:
1. What is Digital Image Processing?
   • What is Digital Image Processing || I...  

2. Human Visual System and Elements of Digital Image Processing
   • Human Visual System and  Elements of ...  

3. Fundamental steps in Digital Image Processing
   • Fundamental steps in Digital Image Pr...  

4. Image Sensing and Acquisition
   • Image Sensing and Acquisition in Digi...  

5. Relationship between Pixels in Digital Image Processing: Neighborhood, Adjacency & Distance measures
   • Relationship between Pixels in Digita...  

6. Image Sampling and Quantization
   • Image Sampling and Quantization in Di...  

7. Spatial and Intensity resolution in Digital Image Processing and its Implementation in MATLAB
   • Spatial and Intensity Resolution in D...  

8. Basics of intensity transformations and spatial filtering and implementation in MATLAB
   • Basics of Intensity transformations a...  

9. Image negatives, Log and Power-Law transformations for DIP and implementation in MATLAB
   • Intensity (Image negatives, Log and P...  

%Contrast streching using Piecewise linear transformation
%Slopes chosen are 0.5, 2 and 0.5
close all;
clear all;
clc
%I=imread('Maulik.png');
I=imread('Cameraman.tif');
%I=rgb2gray(I);
I=im2double(I);
I = (I * 2) / max(I(:));
I_str = 0;
[row,col] = size(I);
LT = 100; % The lower threshold value
UT = 150; % The upper threshold value
grid on;
for i=1:row
for j=1:col
if I(i,j){less than or equal to}LT
I_str(i,j)=0.5*I(i,j);
else if I(i,j){less than or equal to}UT
I_str(i,j)=2*(I(i,j)-LT)+(0.5*LT);
else
I_str(i,j)=0.5*(I(i,j)-UT)+0.5*LT+2*(UT-LT);
end
end
end
end
dd=[];
hold on;
dd(1:100)=0.5*(0:99);
dd(101:150)=2*((100:149)-100)+0.5*100;
dd(151:256)=(0.5*((150:255)-150))+(0.5*100)+(2*(150-100));
axis tight;
plot(dd);
hold on;
xlabel('Intensity in input image');ylabel('Intensity in output image');
title('Contrast-Stretch Transformation function');
figure
montage({I, I_str}, 'Size', [1 2]);
title('Original Image Contrast stretched Image');

Комментарии

Информация по комментариям в разработке