File tree 2 files changed +7
-4
lines changed
Filter options
2 files changed +7
-4
lines changed
Original file line number Diff line number Diff line change 24
24
__version__ = f .read ().split ("\n " )[0 ]
25
25
26
26
if len (enumerate_adapters ()) < 1 :
27
- raise IndexError (
27
+ from warnings import warn
28
+
29
+ warn (
28
30
f"WGPU could not enumerate any adapters, fastplotlib will not work.\n "
29
31
f"This is caused by one of the following:\n "
30
32
f"1. You do not have a hardware GPU installed and you do not have "
35
37
f"common in cloud computing environments.\n "
36
38
f"These two links can help you troubleshoot:\n "
37
39
f"https://wgpu-py.readthedocs.io/en/stable/start.html#platform-requirements\n "
38
- f"https://fastplotlib.readthedocs.io/en/latest/user_guide/gpu.html\n "
40
+ f"https://fastplotlib.readthedocs.io/en/latest/user_guide/gpu.html\n " ,
41
+ RuntimeWarning ,
39
42
)
Original file line number Diff line number Diff line change @@ -59,10 +59,10 @@ def _notebook_print_banner():
59
59
image = Image (value = logo_data , format = "png" , width = 300 , height = 55 )
60
60
61
61
# get adapters and info
62
- adapters = [a for a in wgpu .gpu .enumerate_adapters ()]
62
+ adapters = [a for a in wgpu .gpu .enumerate_adapters_sync ()]
63
63
adapters_info = [a .info for a in adapters ]
64
64
65
- default_adapter_info = wgpu .gpu .request_adapter ().info
65
+ default_adapter_info = wgpu .gpu .request_adapter_sync ().info
66
66
default_ix = adapters_info .index (default_adapter_info )
67
67
68
68
if len (adapters ) < 1 :
You can’t perform that action at this time.
0 commit comments