@@ -85,65 +85,37 @@ pip install -e ".[notebook,docs,tests]"
85
85
>
86
86
> ` fastplotlib ` and ` pygfx ` are fast evolving, you may require the latest ` pygfx ` and ` fastplotlib ` from github to use the examples in the master branch.
87
87
88
- First clone or download the repo to try the examples
89
-
90
- ``` bash
91
- git clone https://github.com/kushalkolar/fastplotlib.git
92
- ```
88
+ Note that ` fastplotlib ` code is basically identical between desktop and notebook usage. The differences are:
89
+ - Running in ` Qt ` or ` glfw ` require a ` fastplotlib.run() ` call (which is really just a ` wgpu ` ` run() ` call)
90
+ - Notebooks plots have ipywidget-based toolbars and widgets 😄
93
91
94
92
### Desktop examples using ` glfw ` or ` Qt `
95
93
96
- ``` bash
97
- # most dirs within examples contain example code
98
- cd examples/desktop
94
+ Desktop examples are here:
99
95
100
- # simplest example
101
- python image/image_simple.py
102
- ```
103
-
104
- ### Notebook examples
96
+ https://github.com/fastplotlib/fastplotlib/tree/master/examples/desktop
105
97
106
- ``` bash
107
- cd examples/notebooks
108
- jupyter lab
98
+ Some of the examples require imageio:
109
99
```
110
-
111
- ** Start out with ` simple.ipynb ` .**
112
-
113
- ### Simple image plot
114
- ``` python
115
- import fastplotlib as fpl
116
- import numpy as np
117
-
118
- plot = fpl.Plot()
119
-
120
- data = np.random.rand(512 , 512 )
121
- plot.add_image(data = data)
122
-
123
- plot.show()
100
+ pip install imageio
124
101
```
125
- ![ image] ( https://user-images.githubusercontent.com/9403332/209422734-4f983b42-e126-40a7-a681-3b8e22dbd797.png )
126
102
127
- ### Fast animations
128
- ``` python
129
- import fastplotlib as fpl
130
- import numpy as np
131
-
132
- plot = fpl.Plot()
103
+ ### Notebook examples
133
104
134
- data = np.random.rand(512 , 512 )
135
- image = plot.image(data = data)
105
+ Notebook examples are here:
136
106
137
- def update_data ():
138
- new_data = np.random.rand(512 , 512 )
139
- image.data = new_data
107
+ https://github.com/fastplotlib/fastplotlib/tree/master/examples/notebooks
140
108
141
- plot.add_animations(update_data)
109
+ ** Start with ` simple.ipynb ` . **
142
110
143
- plot.show()
111
+ Some of the examples require imageio:
144
112
```
113
+ pip install imageio
114
+ ```
115
+
116
+ ### Video
145
117
146
- ![ out ] ( https://user-images.githubusercontent. com/9403332/209422871-6b2153f3-81ca-4f62-9200-8206a81eaf0d.gif )
118
+ You can watch our SciPy 2023 talk if you prefer watching demos: https://github. com/fastplotlib/fastplotlib#scipy-talk
147
119
148
120
## Graphics drivers
149
121
0 commit comments