You can ignore that cell / don’t run it, it was for the book
# For the book, we can't actually click an upload button, so we fake it
uploader = SimpleNamespace(data = ['images/chapter1_cat_example.jpg']) #don't run this
As you are on Kaggle, you run the upload and choose any image from your machine. (You can download the cat image from the repo to your home machine and try that, if you want). Unlike the book, this bit does not need to be faked, you can interact with it and upload any image to test.
Run this part. …
uploader = widgets.FileUpload()
uploader
Then click on the upload button that just appeared and select an image to test.
then run
img = PILImage.create(uploader.data[0])
is_cat,_,probs = learn.predict(img)
print(f"Is this a cat?: {is_cat}.")
print(f"Probability it's a cat: {probs[1].item():.6f}")
Either is fine. It is good to get some experience with both. There will be times when you use up your free GPU hours on one or the other or you want to enter a Kaggle competition. You’ll discover your own reasons for preferring one over the other at any given time.
If you follow along the course in conjunction with the book, you will get to use both.