simslab / scHPF

Single-cell Hierarchical Poisson Factorization
BSD 2-Clause "Simplified" License
66 stars 10 forks source link

Pytorch implementation #1

Open rfarouni opened 6 years ago

rfarouni commented 6 years ago

Thanks for your great contribution. I really enjoyed reading the paper. I hope you do not mind me asking, but are there any plans for implementing the code in Pytorch? Although I am pretty familiar with Tensorflow, I find TF's declarative mode and static graph design philosophy a major flaw for research purposes, where flexibility, ease of debugging, and clarity of code tend to be more important considerations for some, especially for those researchers who would want to build upon, incorporate, or modify existing code.

hannaml commented 6 years ago

Glad you enjoyed the paper! A numba implementation with a scikit-learn-like interface is already in the works, which will hopefully address many of the issues you listed. I plan to benchmark it against the tensorflow implementation, and will definitely look into pytorch if the performance difference is too onerous.

rfarouni commented 6 years ago

Thank you for your reply!

hannaml commented 5 years ago

I just merged a numba implementation which may address your concerns. In addition, it is much faster an memory efficient than the previous tensorflow implementation, and has a pretty clear (I think) scikit-learn-like API interface. I'll be posting some API tutorials soon, but a CLI walkthrough is already up.

rfarouni commented 5 years ago

Impressive work. Thank you for your contributions!