You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
EDSnlp loader from edsnlp 10.0 (AliasLoader in edsnlp init.py) is interferring with spacy default loader it seems, which creates additionnal dependencies from the edsnlp trainable components which are not listed, if intended.
Here it raises errors depending on the environment, "foldedtensor" or in our case "torch" module not found. which is not a dependency in any package, as edsnlp[ml] was not desired.
Hi, thank you for letting us know about this ! This is indeed problematic. By default, spacy imports all available components (i.e., that have a spacy_factories entrypoint namespace), even though they are not required by the user. You did not install edsnlp[ml] indeed, so importing some components like eds.transformer will fail, hence the bug you reported.
You can try with to re-install edsnlp with the fix from #235, let me know if this works for you !
Description
EDSnlp loader from edsnlp 10.0 (AliasLoader in edsnlp init.py) is interferring with spacy default loader it seems, which creates additionnal dependencies from the edsnlp trainable components which are not listed, if intended.
How to reproduce the bug
In a fresh environment
poetry add edsnlp
download a spacy model, for example fr_core_news_sm-3.5
then:
Here it raises errors depending on the environment, "foldedtensor" or in our case "torch" module not found. which is not a dependency in any package, as edsnlp[ml] was not desired.
Other
I found the bug with this snippet:
Which raises
[E002] Can't find factory for 'tok2vec' for language French (fr).
and shows no relation to edsnlp whatsoever interestingly enough.The text was updated successfully, but these errors were encountered: