Undefined function 'prepareInputFiles'

조회 수: 5 (최근 30일)
Zelda Grey
Zelda Grey 2019년 2월 28일
댓글: Walter Roberson 2020년 6월 9일
Hi Matlabers, sorry for my naive question but I could not figure it out. I want to do image analysis with following the image recognition tutorial but I am gettiong error in this part
[training_set, test_set]=prepareInputFiles(imds)
Undefined function 'prepareInputFiles' for input arguments of type 'matlab.io.datastore.ImageDatastore'.
Error in img (line 27)
[training_set, test_set]=prepareInputFiles(imds)
Could you please help me, how can I get around the error. The whole code
imds=imageDatastore(folder,'includeSubfolders',true,'LabelSource','foldernames','FileExtensions','.jpg')
tbl=countEachLabel(imds)
categories=tbl.Label
sample=splitEachLabel(imds,4)
%% Partiton training and test set
[training_set, test_set]=prepareInputFiles(imds)
  댓글 수: 2
Shaheer Habib
Shaheer Habib 2020년 6월 9일
Error in prepareInputFiles (line 8)
imset = imageSet(strcat(image_location,'E:\Projects\Project8_I_M_G\..'),'recursive');
but i have found an error of something different kind
how to tacle this error
please tell me
Walter Roberson
Walter Roberson 2020년 6월 9일
you should not have edited prepareInputFiles. Instead you should have passed 'E:\Projects\Project8_I_M_G' to the function

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

채택된 답변

Walter Roberson
Walter Roberson 2019년 2월 28일
The code linked to by that webinar is here, image recognition and it contains only two files, neither of which is named img and neither of which calls prepareInputFiles .
prepareInputFiles is part of a different demonstration completely here, object recognition deep learning
You seem to have confused two webinars.
  댓글 수: 1
Zelda Grey
Zelda Grey 2019년 2월 28일
Thanks Walter, you ve just saved me. Iam totaly newbie in this era and try to figure out it.

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

추가 답변 (0개)

Community Treasure Hunt

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

Start Hunting!

Translated by