October 2018
Intermediate to advanced
472 pages
10h 57m
English
Now, we will call the generator on the masked MNIST test data to generate images, that is, fill in the missing part of the digits:
# restore missing parts of the digit with the generatorgen_imgs_test = generator.predict(noised_test_data)
Then, we will pass the generated MNIST digits to the digit classifier we have modeled already:
# predict on the restored/generated digitsgen_pred_lab = mnist_model.predict_classes(gen_imgs_test)print('The model model accuracy on the generated images is:',np.mean(gen_pred_lab==y_test)*100)The MNIST CNN classifier is 87.82% accurate on the generated data.
The following is a plot showing 10 generated images by the generator, the actual label of ...
Read now
Unlock full access