필터 지우기
필터 지우기

How can I apply a natural logarithm to an image?

조회 수: 6 (최근 30일)
Lucaci Diana
Lucaci Diana 2020년 11월 26일
편집: KALYAN ACHARJYA 2020년 11월 26일
%%4 image natural log test
%%apply natural log function on the image 'image' to get 'ln_image'
%%note: you need to use mat2gray to convert the format of the image
%also, change negative values to postivie for display purpose
%add instruction here
ln_image = ;
subplot(2,3, 5);
%use display image with scaled colors command (not imshow). put title 'natural log'
%add instructions here
imagesc(ln_image);
title('Natural Log');
  댓글 수: 3
Lucaci Diana
Lucaci Diana 2020년 11월 26일
well, since I m not as smart as you are, I don't get it
KALYAN ACHARJYA
KALYAN ACHARJYA 2020년 11월 26일
편집: KALYAN ACHARJYA 2020년 11월 26일
@Lucaci Most members of this community are great, they are giving their precious time to help us. It is expected to take the suggestions in a positive way. Trust me, these people are very knowledgeable and they are guiding millions, like you and me.
Seems home work question, in such cases your own efforts are expected. If you have any specific question, let us know..?

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

채택된 답변

Image Analyst
Image Analyst 2020년 11월 26일
Did you try ln_image =log(mat2gray(image))?
By the way it's a terrible idea for them to tell you to use the word "image" for your variable name. image() is a built-in function. If there are any zeros in your image you should add 1 to the image before taking the log of it.
  댓글 수: 1
Lucaci Diana
Lucaci Diana 2020년 11월 26일
IT WORKED, you are amazing, thank you so much

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

추가 답변 (0개)

카테고리

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

Community Treasure Hunt

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

Start Hunting!

Translated by