I’m trying to get an image plotting in bokehjs standalone, by loading in a 2d javascript array.
This shows it was possible in earlier versions of bokehjs. But now, if you switch out the lines to load bokeh 3.4.0, and use the same syntax for the ColumnDataSource and image() methods, the images don’t load.
Did something change about the figure.image() api?
BokehJS stopped accepting ragged “lists of lists” as 2d arrays a very long time ago. You must use an actual array object with a dtype and a shape for multi-dimensional arrays inside a CDS.
AFAIK to create an array in BokehJS you can use the ndarray function from core/util/ndarray. Called something like this (a 1-d example, but to make it 2-d just adjust the shape appropriately):