markovmodel / PyEMMA

🚂 Python API for Emma's Markov Model Algorithms 🚂
http://pyemma.org
GNU Lesser General Public License v3.0
306 stars 119 forks source link

Implied timescales calculation hangs with multiprocessing #1590

Open yuxuanzhuang opened 1 year ago

yuxuanzhuang commented 1 year ago

It seems to be a recurring question (related #1576 #1553 #1582 and maybe more). And I know you guys will replace the implementation of it in a future version of pyemma, but I just want to point out that the issue seems to be related to the combination of threadpool_limits and get_context("spawn").Pool---for some weird reason, they don't play nice with the serialization of MaximumLikelihoodMSM.

Either removing threadpool_limits or using get_context().Pool can resolve the hanging.

ubuntu 20.04 python: 3.10 pyemma: 2.5.12 threadpoolctl: 3.1.0