remove the automatic importing mpi4py

This commit is contained in:
Zhenwen Dai 2015-09-23 16:25:39 +01:00
parent a98bafb5b4
commit cb1f6f1486
4 changed files with 18 additions and 24 deletions

View file

@ -148,7 +148,11 @@ def x_frame1D(X,plot_limits=None,resolution=None):
"""
assert X.shape[1] ==1, "x_frame1D is defined for one-dimensional inputs"
if plot_limits is None:
xmin,xmax = X.min(0),X.max(0)
from ...core.parameterization.variational import VariationalPosterior
if isinstance(X, VariationalPosterior):
xmin,xmax = X.mean.min(0),X.mean.max(0)
else:
xmin,xmax = X.min(0),X.max(0)
xmin, xmax = xmin-0.2*(xmax-xmin), xmax+0.2*(xmax-xmin)
elif len(plot_limits)==2:
xmin, xmax = plot_limits