Closed pl992 closed 4 years ago
Sorry for the delay. I cannot reproduce the error. I used this code and it runs smoothly:
import pyemma
import numpy as np
dtraj = np.random.randint(5, size=200)
statdist = np.ones(5)/5
msm = pyemma.msm.estimate_markov_model(dtraj, lag=1, statdist=statdist)
msm.pcca(2)
Does this code work for you? Maybe there is something wrong with your installation of pyemma?
Okay, after discussing with @clonker I believe that the test case above is not sufficient to assess the problem. Apparently, the issue is related to the iterative procedure used for estimating the transition matrix given stationary distribution constraints. If that is not converged "enough", the error will be raised in subsequent steps. You can try to work around the problem for now by trying to find a better converged transition matrix using the maxerr
keyword argument.
The problem's cause is that the max error defined during estimation of statdist constraint MSMs is lower than in other parts of PyEMMA or msmtools. These other parts are not accessible by keyword arguments from the user API and span multiple packages, so it'll take some time to properly fix this.
Sorry for the delay. I cannot reproduce the error. I used this code and it runs smoothly:
import pyemma import numpy as np dtraj = np.random.randint(5, size=200) statdist = np.ones(5)/5 msm = pyemma.msm.estimate_markov_model(dtraj, lag=1, statdist=statdist) msm.pcca(2)
Does this code work for you? Maybe there is something wrong with your installation of pyemma?
This code works fine.
Okay, after discussing with @clonker I believe that the test case above is not sufficient to assess the problem. Apparently, the issue is related to the iterative procedure used for estimating the transition matrix given stationary distribution constraints. If that is not converged "enough", the error will be raised in subsequent steps. You can try to work around the problem for now by trying to find a better converged transition matrix using the
maxerr
keyword argument.The problem's cause is that the max error defined during estimation of statdist constraint MSMs is lower than in other parts of PyEMMA or msmtools. These other parts are not accessible by keyword arguments from the user API and span multiple packages, so it'll take some time to properly fix this.
Indeed, I've tried to decrease the maxerr argument and the problem is gone.
Thank you!
Evaluating the pcca of an msm object built including the statdist option returns the following error:
Applying the cktest to a msm object built including the statdist option returns the following error:
Conda environment: conda_env.txt
Operating system: Distributor ID: Debian Description: Debian GNU/Linux 9.12 (stretch) Release: 9.12 Codename: stretch
Example: