R-CNN stop sign detector code
显示 更早的评论
I am trying understand the code for stop sign detector using cnn but i do no identify the "Command" in below sentencie of the program: "helperCIFAR10Data.download(url,cifar10Data); I look for help but it shows an error msg
9 个评论
douadi alim
2016-11-10
Hello, I had the same issue for using this class "helperCIFAR10Data" on Matlab R2015b. After trying [fullfile(toolboxdir('vision'),'visiondemos','helperCIFAR10Data.m'] I found may other classes in Matlab root but not that one. So if you found any solution, please help.
Walter Roberson
2016-11-10
That code requires R2016b or later.
Walter Roberson
2017-9-21
Your S is a structure array of loaded data. You should be extracting fields from it, not trying to load() it. For example, if each .mat file has a variable named "trainingImages" then
trainingImages = cat(4, S.trainingImages);
It's showing error of reference to non-existent field "trainingImages" but in R2017a they were able to extract each label by using:
[trainingImages, trainingLabels, testImages, testLabels] = helperCIFAR10Data.load(cifar10Data);
I need to do same in R2015a...please help me with it
Vrushal
2017-9-23
@walter robinson
Walter Roberson
2017-9-28
Please show the output of
whos -file data_batch_1.mat
whos -file data_batch_2.mat
whos -file data_batch_3.mat
whos -file data_batch_4.mat
whos -file data_batch_5.mat
Jun Zhang
2019-3-18
I have the same problem.
>> whos -file data_batch_1.mat
whos -file data_batch_2.mat
whos -file data_batch_3.mat
whos -file data_batch_4.mat
whos -file data_batch_5.mat
Name Size Bytes Class Attributes
batch_label 1x21 42 char
data 10000x3072 30720000 uint8
labels 10000x1 10000 uint8
Name Size Bytes Class Attributes
batch_label 1x21 42 char
data 10000x3072 30720000 uint8
labels 10000x1 10000 uint8
Name Size Bytes Class Attributes
batch_label 1x21 42 char
data 10000x3072 30720000 uint8
labels 10000x1 10000 uint8
Name Size Bytes Class Attributes
batch_label 1x21 42 char
data 10000x3072 30720000 uint8
labels 10000x1 10000 uint8
Name Size Bytes Class Attributes
batch_label 1x21 42 char
data 10000x3072 30720000 uint8
labels 10000x1 10000 uint8
Walter Roberson
2019-3-18
Could you clarify what problem you are having? Please post your code.
采纳的回答
更多回答(5 个)
Vignesh Ganapathiraman
2018-5-7
Or you can just add the path at the start
addpath([matlabroot,'/examples','/vision','/main']);
Ali
2017-11-1
编辑:Walter Roberson
2017-11-1
Hi guys,
The file is really at the directory provided by Walter Roberson, however the error message still there.
to overcome this problem, you may follow these steps:
- go to fullfile(matlabroot,'examples', 'vision', 'main', helperCIFAR10Data.m', find the file there and open it.
- inside 'helperCIFAR10Data.m' you will find 4 functions (download,load, loadBatchAsFourDimensionalArray, convertLabelsToCategorical). Copy each function to a new script and save them. you can give 'load' function to another name to avoid conflict with the same Matlab-builtin function.
- use the code provided on Mathworks website but remove the prefix'helperCIFAR10Data'
% Download CIFAR-10 data to a temporary directory
location = 'C:\Users\JICA\Desktop\Object Detection Using Deep Learning\';
url = 'https://www.cs.toronto.edu/~kriz/cifar-10-matlab.tar.gz';
download(url, location);
%%Load
% Load the CIFAR-10 training and test data.
[trainingImages, trainingLabels, testImages, testLabels] = Dataloading(location);
Each image is a 32x32 RGB image and there are 50,000 training samples.
size(trainingImages)
hope this helps
Ali
5 个评论
sheeza rafaqat
2018-2-18
how can i goto fullfile(matlabroot,'examples', 'vision', 'main', helperCIFAR10Data')
Walter Roberson
2018-2-18
cd(fullfile(matlabroot,'examples', 'vision', 'main'))
edit helperCIFAR10Data.m
sheeza rafaqat
2018-2-28
when i am copying each function in a seperate script it is giving an error of "Not enough arguments in function". how can i resolve this issue?
bhanu prakash
2019-3-5
when i am copying each function in a seperate script it is giving an error of "Not enough arguments in function". how can i resolve this issue?
Walter Roberson
2019-3-5
Please show which function you are calling, and show how you are calling it.
Did you follow Ali's suggestion to rename load ? That would include changing the references to the function so that you do not accidentally invoke MATLAB's built-in load()
巴山学长
2017-11-2
1 个投票
Just copy the 'helperCIFAR10Data.m' to your temporary directory, and then run. Good luck!
Saif Hussein
2017-9-28
编辑:Walter Roberson
2017-10-19
when l was to run the code in https://uk.mathworks.com/help/vision/examples/object-detection-using-deep-learning.html . l have that error below
Undefined variable "helperCIFAR10Data" or class "helperCIFAR10Data.load".
l have email the matlab team many times, they didn't solve the problem. l do believe the problem with matlab copy under Mac,
3 个评论
Walter Roberson
2017-9-28
Which MATLAB release are you using?
Donnie Agema
2017-10-14
I am using MATLAB version R2017b and getting the same error. Any solution?
Walter Roberson
2017-10-19
编辑:Walter Roberson
2019-1-30
In R2017b I find it at
fullfile(matlabroot,'examples', 'vision', 'main', 'helperCIFAR10Data.m')
This requires the Computer Vision toolbox.
Nicola Gaburro
2017-10-2
I'm having the same issue with Matlab R2017b When running the command
helperCIFAR10Data.download(url, cifar10Data);
it shows the error
Undefined variable "helperCIFAR10Data" or class "helperCIFAR10Data.download". Seems like helperCIFAR10Data class is missing
6 个评论
Walter Roberson
2017-10-19
编辑:Walter Roberson
2019-1-30
In R2017b I find it at
fullfile(matlabroot,'examples', 'vision', 'main', 'helperCIFAR10Data.m')
This requires the Computer Vision toolbox.
Walter Roberson
2019-1-30
By R2018b it has moved to
fullfile(matlabroot,'examples', 'nnet', 'main', 'helperCIFAR10Data.m')
Dora Craba
2020-5-15
what is the correct code for matlab2019b?
Walter Roberson
2020-5-15
fullfile(matlabroot,'examples','deeplearning_shared','main','helperCIFAR10Data.m')
Dora Craba
2020-5-16
Thank you for your answer. Now I get another error:
Unable to resolve the name helperCIFAR10Data.load.
Error in prova_dataset (line 9)
[trainingImages,trainingLabels,testImages,testLabels] = helperCIFAR10Data.load(cifar10Data);
Walter Roberson
2020-5-17
The helperCIFAR10Data class must be on your MATLAB path.
addpath(fullfile(matlabroot,'examples','deeplearning_shared','main'))
类别
在 帮助中心 和 File Exchange 中查找有关 Image Sequences and Batch Processing 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
