What is Error occupy for pixellabeldatastore code is following. ?
2 次查看(过去 30 天)
显示 更早的评论
for 3 D volumetric mri brain tumor image and file extension is nii. with my matlab code as following
classNames = ["background","tumor"];
pixelLabelID = [0 1];
pxds = pixelLabelDatastore(im ,classNames,pixelLabelID, ...
'FileExtensions','.nii','ReadFcn',volReader);
Error using pixelLabelDatastore>parseInputs (line 202)
'FileExtensions' is not a recognized parameter. For a list of valid name-value pair arguments,
see the documentation for this function.
Error in pixelLabelDatastore (line 151)
[location, classes, values,params] = parseInputs(varargin{:});
Error in SEp1 (line 27)
pxds = pixelLabelDatastore(im,classNames,pixelLabelID, ...
0 个评论
采纳的回答
Walter Roberson
2020-9-8
You did not indicate your MATLAB release.
The FileExtensions option was not available in some earlier releases. My memory is saying that it was added in one of the 2019 releases.
2 个评论
更多回答(1 个)
hla hla myint
2020-9-8
1 个评论
Walter Roberson
2020-9-8
You will need to add the complete list of file names instead of a directory name.
dinfo = dir( fullfile(im, '**, '*.nii'));
filenames = fullfile( {dinfo.folder}, {dinfo.name} ) ;
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Computer Vision Toolbox 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!