Image-Captioning icon indicating copy to clipboard operation
Image-Captioning copied to clipboard

Error

Open Jhonatan-Souza opened this issue 6 years ago • 1 comments

Colocations handled automatically by placer. Traceback (most recent call last): File "test.py", line 27, in text(image) File "test.py", line 11, in text sd = SceneDesc.scenedesc() File "C:\Users\jhona\Desktop\Image-Captioning-master\SceneDesc.py", line 17, in init self.image_encodings = pickle.load( open( "image_encodings.p", "rb", ) ) UnicodeDecodeError: 'ascii' codec can't decode byte 0xe0 in position 32: ordinal not in range(128)

Jhonatan-Souza avatar May 26 '19 18:05 Jhonatan-Souza

You have to specify the encoding format while loading. Replace line 17 of "C:\Users\jhona\Desktop\Image-Captioning-master\SceneDesc.py" with the following line :

self.image_encodings = pickle.load( open( "image_encodings.p", "rb" ),encoding='latin1' )

avideep avatar May 27 '19 14:05 avideep