Perform Instance Segmentation Using Mask R-CNN
조회 수: 5 (최근 30일)
이전 댓글 표시
thank you to click
i just following 'Perform Instance Segmentation Using Mask R-CNN' example
URL : "https://kr.mathworks.com/help/vision/ug/example-InstanceSegmentationUsingMaskRCNNDeepLearningExample.html"
I have download the file(instances_train2014.json, cocoapi-master, unpackAnnotations.m(was in helper file) )
but i don't know how to compling gason.
so i get a error
i just copy the example and change the file path
%download traindata
imageFolder = fullfile(dataFolder,"images");
captionsFolder = fullfile(dataFolder,"annotations");
if ~exist(imageFolder,"dir")
mkdir(imageFolder)
mkdir(captionsFolder)
end
annotationFile = fullfile(captionsFolder,"instances_train2014.json");
str = fileread(annotationFile);
%read and process training data
trainClassNames = ["person","car"];
numClasses = length(trainClassNames);
imageSizeTrain = [800 800 3];
cocoAPIDir = fullfile(dataFolder,"cocoapi-master","MatlabAPI");
addpath(cocoAPIDir);
unpackAnnotationDir = fullfile(dataFolder,"annotations_unpacked","matFiles");
if ~exist(unpackAnnotationDir,'dir')
mkdir(unpackAnnotationDir)
end
helper.unpackAnnotations(trainClassNames,annotationFile,imageFolder,unpackAnnotationDir);
%create data
i want to train coco dataset but i don't know c++ compling
how can i get complied data..?
댓글 수: 0
채택된 답변
Shivam Malviya
2023년 1월 12일
Hi Young Hun,
I understand you are working with the example Perform Instance Segmentation Using Mask R-CNN, and you are facing issues with the compilation of the gason parser.
In the file "gason.m", at line number 21, there is a command to compile the "gasonMex.cpp" file into a MEX file. Below is the command mentioned in the file;
mex('CXXFLAGS=\$CXXFLAGS -std=c++11 -Wall','-largeArrayDims','.\private\gasonMex.cpp','..\common\gason.cpp','-I..\common\','-outdir','private');
While executing this command if you encounter the following error;
Error using mex
g++: error: \-fexceptions: No such file or directory
Try out the following command;
mex('CXXFLAGS=$CXXFLAGS -std=c++11 -Wall','-largeArrayDims','.\private\gasonMex.cpp','..\common\gason.cpp','-I..\common\','-outdir','private');
Hope this helps!
Regards,
Shivam Malviya
댓글 수: 0
추가 답변 (0개)
참고 항목
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!