andosa / treeinterpreter

BSD 3-Clause "New" or "Revised" License
745 stars 140 forks source link

Silence sklearn 0.22+ FutureWarning #29

Closed iamDecode closed 4 years ago

iamDecode commented 4 years ago

From sklearn 0.22 on, importing the treeinterpreter package yields the following FutureWarning:

FutureWarning: The sklearn.ensemble.forest module is  deprecated in version 0.22 and will be removed in version 0.24. The corresponding classes / functions should instead be imported from sklearn.ensemble. Anything that cannot be imported from sklearn.ensemble is now part of the private API.

This PR changes the import to silence this warning, and allow for compatibility with sklearn 0.24 and up.