Root on jupyter notebook does not plot graphics in C++

Dear all,
I am trying to use ROOT through a jubyter notebook in C++, however it does not plot any graphics, although it creates the object. Any ideas?

I have compiled root 6.26.10 with python 3.8.10
I used gcc 9.4.0
I have download JsRoot730 and provided the directory to CMAKE_INSTALL_JSROOTDIR (however I am not sure if this is the correct procedure).
My system is Ubuntu 20.04

Thank you in advance,
Costas

Hi Costas,

You do not need to install JSROOT extra - it is provided with ROOT already.
Also for ROOT 6.26 base JSROOT version is 6.3 - versions 7 may not work.

If after plain ROOT compilation JSROOT graphics in jupyter notebook does not work - please check output in browser console (activated with Ctrl-Shift-I)

Regards,
Sergey

Hi Sergey,

Thank you for your reply. I have compiled again root without the external JSROOT package.

Also I tried to run it through a conda environment, but the graphics still do not display.
The error message in the browser console is as follows:
“Failed to fetch ipywidgets through the “jupyter.widget.control” comm channel, fallback to fetching individual model state. Reason: Control comm was closed too early”

However, ipywidgets is installed as you can see below:
jupyter --version

Selected Jupyter core packages…
IPython : 8.10.0
ipykernel : 6.19.2
ipywidgets : 8.0.4
jupyter_client : 7.4.9
jupyter_core : 5.2.0
jupyter_server : 1.23.4
jupyterlab : 3.5.3
nbclient : 0.5.13
nbconvert : 6.5.4
nbformat : 5.7.0
notebook : 6.5.2
qtconsole : 5.4.0
traitlets : 5.7.1

Hi Costas,

It is definitely some configuration problems of jupyter.
Are you using jupyter lab or jupyter notebook?

I have a cases when some widgets from jupyter tutorials (not ROOT) were working with notebook, but not working with lab.
Try both to see difference.

Regards,
Sergey

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.