AttributeError: 'FileUpload' object has no attribute 'data'

When I try to upload the image of a bear and click classify. I get this


error

You post doesn’t show where/how btn_upload is set, which makes it hard to even guess and the issue. Can you link to the whole notebook?

What do you get from…

type(btn_upload)

and…

dir(btn_upload)