Importerror: Cannot Import Name Signature
I am tying to modify the original sklearn.CalibrationCV to create my won version. The original code has 'from .utils.fixes import signature'. So I did the following in my version:
Solution 1:
- In python 2, the
inspectmodule does not have asignaturemethod. - In python 3, the
inspectmodule does have asignaturemethod.
This code is just trying to work with both python 2 and 3.
You may want to use the funcsigs module if you are using python 2, or use sklearn.externals.funcsigs directly (for version sklearn >= 0.17).
Post a Comment for "Importerror: Cannot Import Name Signature"