Reputation: 349
Is there a way by which I could write an SVMStruct (obtained using Matlab's svmtrain
) to a file and then read it later when I need it. I want to do this because I'm unable to use SVMclassify
after training the data, it gives out of memory error.
Upvotes: 3
Views: 3201
Reputation: 16055
You can just use save
to save:
svmstruct=svmtrain(........
save('file2save.mat','svmstruct');
and load
to reload it later:
load('file2save.mat','svmstruct');
svmclassify(svmstruct,.........
Upvotes: 5