DataFrame.replace: TypeError: “Cannot compare types 'ndarray(dtype=object)' and 'str' ”
I have a dataset in csv and a dictionary created by a classifier. It is necessary to put the key values in place of the keys . I use this code `df.replace(mapping,inplace = True) `and it works fine on 100 lines, but for 2000 and more, I get the error 

> "TypeError:“ Cannot compare types 'ndarray (dtype = object)' and 'str' ”.

 What am I doing wrong ??

