Fast_bert using my finetuned model
I created a sentiment analysis model using one of the Huggingface models, i got good accuracy, i saved it and now i want to use it without passing by the training process again,I used the BertClassificationPredictor  function but it didn’t work for me.My work:from fast_bert.prediction import BertClassificationPredictorMODEL_PATH = ‘/content/latest_model’predictor = BertClassificationPredictor(model_path=MODEL_PATH,label_path=LABEL_PATH,multi_label=False,model_type=‘bert’)Single predictionsingle_prediction = predictor.predict(“just get me result for this text”)The model i finetuned :https://huggingface.co/asafaya/bert-base-arabic
2020-08-19T10:47:00Z
Hi@AhmedBoubetter to ask this on fast_bert issues. Also if you could post the stack trace then I can take a look.
2020-08-19T11:03:48Z
Hi, thank you for your reply, here’s the stack trace:UnicodeDecodeError                        Traceback (most recent call last)in ()7                                 label_path=LABEL_PATH, # location for labels.csv file8                                 multi_label=False,----> 9 				model_type=‘bert’)1011 # Single prediction/usr/lib/python3.6/codecs.py in decode(self, input, final)319         # decode input (taking the buffer into account)320         data = self.buffer + input–> 321         (result, consumed) = self._buffer_decode(data, self.errors, final)322         # keep undecoded input until the next call323         self.buffer = data[consumed:]UnicodeDecodeError: ‘utf-8’ codec can’t decode byte 0x80 in position 64: invalid start byte
2020-08-20T14:45:59Z
Do you think you can setup a colab for this ?