Closed Marius1311 closed 3 years ago
Thank you so much @Marius1311 for pointing this out!
This is now implemented in the new release v0.2.4, depencency reliance has been reduced as much as possible.
For clarification, functions needing a specific dependency are now mentionned in the documentation and will prompt a message when called, as you have suggested!
Fantastic, I think that's much more convenient! I'm eager to check this out.
Dear scFates developers, I've installed scFates via pip and I've been trying to import it in a jupyter notebook by simply calling
import scFates as scf
. However, that raises the error in the traceback below. This is an rpy2 error, and know from experience that rpy2 can cause all sorts of difficulties. I think it would be much more convenient for the user if rpy2, and related modules, were only to be loaded when they're actually needed, i.e. as optional dependencies. In your installation instructions, it says: "scFates rely on the R package mgcv to perform testing and fitting of the features on the peudotime tree. Package is installed in an R session with the following command:"If you really only need R dependencies for gene trend testing, then I would make mgcv and rpy2 optional dependencies and prompt the user to install them when calling the relevant functions. That way, you make sure that everyone can install and import scFates easily, even if rpy2 is not installed/causes difficulties. There are similar optional dependencies in CellRank (check out https://cellrank.readthedocs.io/en/stable/classes.html#cellrank.ul.models.GAMR, which also relies on
mgcv
) or scanpy (e.g. multicore TSNE). Again, these packages have dependencies which can be tricky to install and are only used in one part of the code, so they're made optional. Could this be done for scFates as well?Traceback