qurator-spk / sbb_ner

Named Entity Recognition
Apache License 2.0
16 stars 2 forks source link

Fixing requirements.txt #6

Open katharinaost opened 3 months ago

katharinaost commented 3 months ago

To get sbb_ner to work (in a Python 3.11 environment), I had to fix flask==2.0.1 (i.e. a version that reintroduced Config.from_json, see the discussion here) and Werkzeug==2.3.7 (Werkzeug 3 causes an ImportError: cannot import name 'url_quote' from 'werkzeug.urls' error, see here).

Also updated sklearn to scikit-learn.

With these exceptions, modern package versions seem to work fine.

katharinaost commented 3 months ago

While sbb_ner works fine with Python 3.11 and largely modern package versions, the same is not true for sbb_ned - the pickled deciders rely on old scikit-learn versions (0.22). So it's probably best to stick with Python 3.6, which also requires the use of old virtualenv versions (20.18.0 is the last release that works with Python 3.6).