ing-bank / skorecard

scikit-learn compatible tools for building credit risk acceptance models
https://ing-bank.github.io/skorecard/
MIT License
85 stars 24 forks source link

Missing dependency #94

Closed dlaprins closed 1 year ago

dlaprins commented 1 year ago

Skorecard relies on the optbinning package, but optbinning is not in the base_packages list of setup.py. It should be.

timvink commented 1 year ago

The idea initially was that you can use skorecard without optbinning also, which is quite a heavy depencency.

Hence this code, which gives a helpful error message:

https://github.com/ing-bank/skorecard/blob/bf6a89e4b0fc23ab97bdf587c851d2eb244a759f/skorecard/bucketers/bucketers.py#L19-L22

But now bucketers.py has a lot more bucketers than just OptimalBucketer, so you can't really get around it. So, either we add it as a dependency, or, we separate each bucketer into it's own module (and use the __init__.py file to control the namespace, so we don't breaking any existing imports).

Dronakurl commented 1 year ago

When we still want to be able to use skorecard without the package: Couldn't we do the following?

So if someone uses import bucketers nothing is broken and from bucketers import OptimalBucketer should still work