How to use a one-hot encoded nominal feature in a classifier in Scikit Learn?
I think you should try pd.get_dummies to code the categories; which will create new columns in dataframe and then use that df to pass it to the classifier.