AIX360 icon indicating copy to clipboard operation
AIX360 copied to clipboard

More modular dependencies

Open illeatmyhat opened this issue 4 years ago • 3 comments

Our environments expand 5x in size because all these dependencies that we don't use are installed. It makes our CI builds take longer. Offering something like extras_requires{'tensorflow': ['tensorflow>=1.14'], ...} should greatly help. The docutils package isn't even necessary.

illeatmyhat avatar Sep 04 '20 07:09 illeatmyhat

@illeatmyhat Most likely tensorflow 1.15 might work, although I probably need to test a bit more. However tensforflow 2.x would need some significant changes. There are two issues with tensorflow upgrade: (a) Some code used in aix360 algorithms will need to be modified (b) dependencies on other libraries such as Lime, Shap, etc. as we would like these to work too. You could probably upgrade tensorflow, but not everything will work. So its a balance between offering all explainability functions using a selected set of library versions versus offering only some explainability functions using a larger collection of compatible library versions. Hope we can make the code compatible with higher versions of tensorflow soon. If you are able to get the algorithms to work on other versions of the library, please do suggest those changes through a pull request.

vijay-arya avatar Sep 04 '20 08:09 vijay-arya

That's not what I was asking.

I was asking to make tensorflow an optional dependency. As in, dont install it (and others) at all.

illeatmyhat avatar Sep 04 '20 09:09 illeatmyhat

@illeatmyhat Thanks for pointing out this problem. We had planned to include the dependencies related to the main 8 explainability algorithms under install_requires (CEM requires tensorfow). I'm not sure if we can immediately decouple the libraries under install_requires and extras_requires. However, we'll definitely keep your idea in mind for a future update.

vijay-arya avatar Sep 04 '20 09:09 vijay-arya