Hi!
I started playing around with bokeh, and I am trying to get continuous image updating to compare its speed to the matplotlib. The server is running on a
hardware platform which is similar to raspoberry pi, and i am using jupyter notebook. For now the code using bokeh is slower, bot looking around I saw that there
should be a possibility that only parts of the plot (image) are updated. I would like to update line by line, but I am not sure how to accomplish that (if its possible).
Can anyone help? I am running bokeh 0.12.7…
Currently I am using this code:
output_notebook()
my_figure = figure(plot_width=800, plot_height=400)
data_array =np.zeros((200,200))
test_data = data_array
x_range = [0, data_array.shape[0]]
y_range = [0, data_array.shape[1]]
p = figure(x_range=y_range, y_range=x_range)
r_blur = p.image(image=[data_array],
x=[0],
y=[0],
dw=[data_array.shape[1]],
dh=[data_array.shape[0]],
palette=“Spectral11”
)
handle = show(p, notebook_handle=True)
new_data=data_array
step = 0
step_size = 1
max_step = 100
period = .01
n_show = 10
while step < max_step:
data_array[step,:] = np.random.rand(200)
r_blur.data_source.data['image'] =[data_array]
push_notebook(handle=handle)
step += step_size
Thanks in advance!

