how to extract the pixel value of tumor in uint16 .mat from logical .mat?

조회 수: 2 (최근 30일)
mohd akmal masud
mohd akmal masud 2022년 10월 17일
댓글: mohd akmal masud 2022년 10월 17일
Hi all,
I have data uint16 .mat. then I label it into tumor and background, and save it into logical .mat. Means the background is 0, tumor is 1.
how to extract the pixel value of tumor in uint16 .mat?
the file unit16 and logical as attached.

답변 (1개)

Walter Roberson
Walter Roberson 2022년 10월 17일
uint8() the logical mask and multiply by the uint8 data. The locations where the mask is false will come out 0.
  댓글 수: 2
mohd akmal masud
mohd akmal masud 2022년 10월 17일
sorry sir, I dont understand. can you write the command?
mohd akmal masud
mohd akmal masud 2022년 10월 17일
this one is for total no. of voxel.
Voxels = sum(logical(:)==1)
then how to extract the PixelIdxList?

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

제품


릴리스

R2022a

Community Treasure Hunt

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

Start Hunting!

Translated by