MATLAB: Why do I get the error Undefined function or variable ‘net’. Error in testalexnet1 (line 16) trainingFeatures = activation​s(net,trai​ningImages​,layer);

#alexnet #imagedatastore

I am trying to create my own image data store and this is my code
trainingFeatures = activations(net,trainingImages,layer);

Best Answer

Considering the name of your file testalexnet1 it appears that you missed
net = alexnet;