From b17ef3856ea1f0897a5ee2225f966ca8ca1fc794 Mon Sep 17 00:00:00 2001 From: kushalkolar Date: Wed, 6 Mar 2024 05:19:46 -0500 Subject: [PATCH] fix fastplotlib.__init__ --- fastplotlib/__init__.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/fastplotlib/__init__.py b/fastplotlib/__init__.py index f0f3cc7b1..98dc17e26 100644 --- a/fastplotlib/__init__.py +++ b/fastplotlib/__init__.py @@ -4,6 +4,7 @@ from .graphics import * from .graphics.selectors import * from .legends import * +from .utils import _notebook_print_banner, config from wgpu.gui.auto import run @@ -16,13 +17,15 @@ from wgpu.backends.wgpu_native import enumerate_adapters +with open(Path(__file__).parent.joinpath("VERSION"), "r") as f: + __version__ = f.read().split("\n")[0] + adapters = [a.request_adapter_info() for a in enumerate_adapters()] if len(adapters) < 1: raise IndexError("No WGPU adapters found, fastplotlib will not work.") -with open(Path(__file__).parent.joinpath("VERSION"), "r") as f: - __version__ = f.read().split("\n")[0] +_notebook_print_banner() __all__ = [ "Plot",