Fall back to matplotlib GUI if dash GUI not available
@@ -80,7 +80,12 @@ if 'headless' not in sys.argv:
from ._dash.dash_gui import DashGui
DEFAULT_DISPLAY_CLASS = DashGui
except ImportError as import_error:
- warnings.warn(f"GUI is disabled because of missing dependency: {import_error}. To install all dependencies, run $ pip install phiflow")
+ warnings.warn(f"Web interface is disabled because of missing dependency: {import_error}. To install all dependencies, run $ pip install phiflow")
+ try:
+ from ._matplotlib.matplotlib_gui import MatplotlibGui
+ DEFAULT_DISPLAY_CLASS = MatplotlibGui
+ except ImportError as import_error:
+ warnings.warn(f"Matplotlib interface is disabled because of missing dependency: {import_error}. To install all dependencies, run $ pip install phiflow")
AUTORUN = 'autorun' in sys.argv
