问题
Whenever I try to use "sklearn" in pycharm, I get the following error on the console.
DeprecationWarning: the imp module is deprecated in favour of importlib; see the module's documentation for alternative uses import imp
I am not sure if it should bother me, because program still working, but it's annoying. How can I get rid of it?
I made every change, people recommended in linked question but the error is still there.
Thank you
回答1:
I deleted the code that imports "imp", from "cloudpickle.py" and the warning is gone but I hope I didn't mess up anything. You can also simply ignore this, since it's not an error.
Edit: I don't want to remove the question or answer because people still visit this page but this is not a solution and it is a bad way to handle it, just ignore this warning. I did this in my very amateur days, sorry :(
来源:https://stackoverflow.com/questions/52596204/the-imp-module-is-deprecated