0%
PythonTrain a classifier in the browser/15 min

Beat the closest-example model

The task

Graded on both test accuracies and on two verdict lines your code works out. The accuracies are not written anywhere in this brief; they come out of the models you train.

Fill in the network. The three print lines above the TODOs already report the two accuracies and the network's gap. Add two more lines:

  • Network above 0.95: followed by yes or no, depending on the network's test accuracy.
  • Winner: followed by network if the network's test accuracy is higher, or closest example if it is not.

Work both out from the numbers your own script computed. Guessing one of them and printing it will fail the accuracy checks anyway.

Sign in to start

Exercises need an account.

It is free. Log in or create one, and every attempt and pass is saved to your progress.