XENONnT / straxen

Streaming analysis for XENON
BSD 3-Clause "New" or "Revised" License
21 stars 32 forks source link

Update to bokeh v3 and holoviews v1, drop py3.8 support #1318

Closed dachengx closed 7 months ago

dachengx commented 7 months ago

What does the code in this PR do / what does it improve?

Close https://github.com/XENONnT/straxen/issues/1206

Depends on https://github.com/XENONnT/ax_env/pull/362 and https://github.com/XENONnT/ax_env/pull/363

Drop python 3.8 because bokeh>=3.2.0 stops support py3.8.

The test for Python 3.11 is experimental, not expect can pass. nestpy==2.0.0 does not support py3.11 now.

Also, minor update of SCADA interface: if np.all((run_id, self.context)): to if run_id is not None and self.context is not None: for numpy compatibility.

Can you briefly describe how it works?

  1. change plot_width to width and plot_height to height for bokeh.plotting.figure
  2. change style to styles for bokeh.models.Div
  3. change names=list to name=str for bokeh.models.HoverTool
  4. set all sizing_mode to "scale_width" for better visualization in the jupyter notebook
  5. use hv.opts.apply_groups to set grouped options, to be compatible with https://github.com/holoviz/holoviews/blob/62b7f1ea47461173253a123765a7d555a0c239ea/holoviews/core/accessors.py#L573

Can you give a minimal working example (or illustrate with a figure)?

coveralls commented 7 months ago

Coverage Status

coverage: 91.488% (-0.9%) from 92.424% when pulling 749f29333bb7d07ac2798af7af762d9039dc1179 on update_bokeh into 3afa3974c851a1dc8f3a68fa887c5f7edf14e9be on master.