I am working on image matting use the code in https://www.mathworks.com/matlabcentral/fileexchange/31412-learning-based-digital-matting.
function demo()
fn_im='C:\Users\Chen\Desktop\CAS781\learningBasedMatting\data\input_lowres\plasticbag.png';
fn_mask='C:\Users\Chen\Desktop\CAS781\learningBasedMatting\data\trimap_lowres\Trimap1\plasticbag.png';
addpath(genpath('C:\Users\Chen\Desktop\CAS781\learningBasedMatting\code'));
imdata=imread(fn_im);
mask=getMask_onlineEvaluation(fn_mask);
[alpha]=learningBasedMatting(imdata,mask);
figure,subplot(2,1,1); imshow(imdata);
subplot(2,1,2),imshow(uint8(alpha*255));
I want to use my own image. I am wondering how to get fn_mask. Could someone help me?
Thanks!