Loading MAT file problem

4 views (last 30 days)
Ton Schomaker
Ton Schomaker on 3 Mar 2011
When loading a mat file (trained nn) in R2010b the following error warning is shown:
QUOTE
>> load('netAantalMosselen.mat') Warning: An error occurred when running a class's loadobj method. The object that was loaded from the MAT-file was a copy of the object before the loadobj method was run. The rest of the variables were also loaded from the MAT-file. The encountered error was: Reference to non-existent field 'name'.
UNQUOTE
Loading the same mat file in R2007b does not show this message. BtW The mat file value in the 2010b workspace is struct and not network.
Can some explain what is happening here? Thanks in advance
Ton

Accepted Answer

Andreas Goser
Andreas Goser on 8 Mar 2011
The customer received a fixed net.m file and confirmed it works now. If you see this issue in the future, please contact Technical Support and refer to solution 1-EGNM3S.
  1 Comment
Ton Schomaker
Ton Schomaker on 9 Mar 2011
Dear Andreas,
After compiling my neural network
QUOTE
%% Loading data
MosselData=load('driehoeksmossel_alt4.txt');
Stuurfactoren=MosselData(:,1:7)';
AantalMosselen=MosselData(:,8)';
VolumeMosselen=MosselData(:,9)';
%% Uitvoer aantal mosselen
load('netAantalMosselen.mat') % beste netwerk wordt weer ingeladen
UitvoerAantalMosselen=sim(netAantalMosselen,Stuurfactoren)
UNQUOTE
to a stand alone executable I still keep getting an error message when running the exe file at the system prompt:
QUOTE
Warning: Class 'network' is an unknown object class or does not have a valid 'loadobj' method. Object 'netAantalMosselen' of this class has been converted to a structure.
In test.m at...
??? Undefined function or method 'sim' for input argument of type 'struct'. MATLAB.Undefined function.
UNQUOTE
Do you have a workaround for this also?
Kind regards,
Ton Schomaker

Sign in to comment.

More Answers (2)

Ton Schomaker
Ton Schomaker on 3 Mar 2011
Thanks Andreas, waiting for answer of TS and hope this solution works.

hamdi
hamdi on 3 Sep 2011
Hi, I have a problem plz help me!!
warning: An error occurred when running a class's loadobj method.the object that was loaded from the MAT-file was a copy of the object before the loadobj method was run. The rest of the variables were also loaded from the MAT-file.The encountered error was: error using ==> feval Undefined function or method 'traingdx' for input arguments of type 'char'.
Thanks in advance

Community Treasure Hunt

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

Start Hunting!