필터 지우기
필터 지우기

extracting the channels from the corrected image

조회 수: 4 (최근 30일)
LAXMI PRIYANKA
LAXMI PRIYANKA 2020년 4월 12일
댓글: LAXMI PRIYANKA 2020년 4월 15일
iam working with rgb fundus images
my task is to convert the rgb image to hsv space and extract the channels and
perform brightness correction in the image
now i am little confused on how to extract the channels of the corrected image
the corrected image is not saved as jpg format
could anyone help me to solve this issue
i have also attached the coding
thank you in advance

답변 (1개)

Ameer Hamza
Ameer Hamza 2020년 4월 12일
You converted the image to RGB after applying correction. You can extract the RGB channels by indexing along third dimension
R = newRGBImage(:,:,1);
G = newRGBImage(:,:,2);
B = newRGBImage(:,:,3);
  댓글 수: 29
LAXMI PRIYANKA
LAXMI PRIYANKA 2020년 4월 15일
thank you sir
LAXMI PRIYANKA
LAXMI PRIYANKA 2020년 4월 15일
sir now i tried with adaphist function for applying clahe
[f_name p_name]=uigetfile('*','select the image');
input_img=imresize(imread(strcat(p_name,f_name)),[512,512]);
imshow(input_img),title('Input Image');
[xRes,yRes]=size(input_img);
Min=0;
Max=255;
NrX=2;
NrY=2;
NrBins=256;
Cliplimit=0.01;
% I = imread('tire.tif');
J = adapthisteq(im2uint8(input_img),'clipLimit',0.02,'Distribution','rayleigh');
imshowpair(im2uint8(input_img),J,'montage');
title('Original Image (left) and Contrast Enhanced Image (right)')
the abve codings after execution displays the following error
Error using adapthisteq
Expected input number 1, I, to be two-dimensional.
Error in adapthisteq>parseInputs (line 416)
validateattributes(I, {'uint8', 'uint16', 'double', 'int16', 'single'}, ...
Error in adapthisteq (line 154)
[I, selectedRange, fullRange, numTiles, dimTile, clipLimit, numBins, ...

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 Image Processing and Computer Vision에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by