Message Boards Message Boards

How to obtain the error rate-round curve?

Posted 1 year ago

The loss-round curve can be obtained by the following code. Could you tell me how to obtain the error rate?

trainingdata = {1 -> 1.5, 2.5 -> 4, 3.5 -> 9, 4 -> 16.5, 5 -> 25, 
   6 -> 37, 6.6 -> 49, 8 -> 65, 9 -> 81, 10 -> 102};
net = NetChain[{5, Ramp, 5, 1}];
trained = 
 NetTrain[net, trainingdata, All, ValidationSet -> Scaled[0.3]]
POSTED BY: xiaotao li
2 Replies
Posted 1 year ago

Thank you very much for your help!

POSTED BY: xiaotao li

This network is solving a regression task and has no error rate. Building a classification network which automatically uses a cross entropy loss (e.g. which ends with a logistic sigmoid or a softmax layer) will automatically add the error rate among the network measurements.

You can access them via:

ListLinePlot /@ trained["ValidationMeasurementsLists"]

Or also "RoundMeasurementsLists" if you do not have a validation set.

Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard

Group Abstract Group Abstract