Azzera filtri
Azzera filtri

helperImportMatConvNet error-- Undefined function or variable

3 visualizzazioni (ultimi 30 giorni)
I have an error running
convnet = helperImportMatConvNet(cnnMatFile)
in the function DeepLearningImageClassificationExample which is an example provided by Matlab in their Documentation. The error says "Undefined function or variable 'helperImportMatConvNet'. I have neural network toolbox installed, but are running on a cpu. can you help with this please?

Risposte (4)

Diego Alcoceba Alvarez
Diego Alcoceba Alvarez il 13 Ago 2017
Hi everybody!
I had the same trouble with that example, at this line:
convnet = helperImportMatConvNet(cnnFullMatFile)
So I found at the article Deep Learning for Computer Vision with MATLAB some code attached. The line which made the difference is:
cnnFullMatFile = fullfile(cnnFolder, cnnMatFile);
Thus, I think the error wasn´t about the Matlab version or similar, it actually was that cnnFullMatFile was empty...
I hope this may help all of you!
Matlab R2017a. Computer Vision System Toolbox, version 7.3
  1 Commento
Lydia
Lydia il 4 Mag 2018
Thank you Diego! Your found works well! I was looking at the same webpage and had this error. Just for more clarification, the complete solution is this:
%
% Specify folder for storing CNN model
cnnFolder = 'C:\Users\Documents';
cnnMatFile = 'imagenet-caffe-alex.mat';
cnnFullMatFile = fullfile(cnnFolder, cnnMatFile);
%%Load Pre-trained CNN
% Load MatConvNet network into a SeriesNetwork
convnet = helperImportMatConvNet(cnnFullMatFile);
%%|convnet.Layers| defines the architecture of the CNN
convnet.Layers
Now the error should not appear anymore.

Accedi per commentare.


Eric Skaliks
Eric Skaliks il 19 Giu 2016
See the comments: "[...] using the helper function helperImportMatConvNet in the Computer Vision System Toolbox (TM)."

Walter Roberson
Walter Roberson il 27 Lug 2016
helperImportMatConvNet is part of the Computer Vision toolbox in R2016a. That demo requires R2016a or later to run.
  2 Commenti
Chan  Yao Jun
Chan Yao Jun il 27 Lug 2016
would you mind to explain more about the helperImportMatConvNet? Is it a function in the Computer Vision toolbox? Cos i couldn't find information related to this function on internet.
Walter Roberson
Walter Roberson il 27 Lug 2016
It is an internal utility function not intended for public use, so it is not present in the main documentation.
It is part of Computer Vision Toolbox in R2016a, which is the release that introduced Convolutional Neural Networks. The demo is defined as being part of Computer Vision Toolbox, so it is not expected that you would be able to run the demo without Computer Vision Toolbox installed.
>> help helperImportMatConvNet
Imports MatConvNet network into a SeriesNetwork object from the Neural
Network Toolbox. This function is provided for educational purposes only
and does not support all models from MatConvNet.
This helper function uses internal functions, which may change in a
future release. This function requires the Neural Network Toolbox.
References
----------
Vedaldi, Andrea, and Karel Lenc. "MatConvNet-convolutional neural
networks for MATLAB." arXiv preprint arXiv:1412.4564 (2014).

Accedi per commentare.


eiman kattan
eiman kattan il 3 Nov 2016
Modificato: Walter Roberson il 3 Nov 2016
any one found a solution for running this demo (pet detection using deep learning in mathwork document. i am also having error with running a function called helperImportMatConvNet??
any one can help
i am using for running the code giving in:
Matlab 2016b which has the computer vision toolbox.
and the error is generated becous of this function helperImportMatConvNet??
  2 Commenti
dimpy yadav
dimpy yadav il 18 Feb 2017
Same problem. Do you know the solution now?
Walter Roberson
Walter Roberson il 18 Feb 2017
Are you using R2016a or later, and do you have the Computer Vision Toolbox installed (and licensed)? and do you have an NVIDIA GPU with CUDA 3.0 or later? If your NVIDIA GPU is the Pascal architecture, have you installed the Pascal patch?
Please post the output of
ver('vision')
license('test','Video_and_Image_Blockset')
opengl info

Accedi per commentare.

Categorie

Scopri di più su Recognition, Object Detection, and Semantic Segmentation in Help Center e File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by