Running TEVEManager in Jupyter/Swan

Hi,
I wanted to know if there was anyway to use graphic windows from TEVEManager in a Jupyter notebook (e.g on Swan). At the moment when calling
gEve= TEveManager.Create()
I get the exception (since by default it is running in batch):
xception: static TEveManager* TEveManager::Create(bool map_window = kTRUE, const char* opt = “FIV”) =>
TEveManager::Create ROOT is running in batch mode. (C++ exception of type TEveException)

Of course it would be great if there was a way to make the event display based on TEVe available online for everyone to use. I do not know if there is a way to do this in Swan (or other methods?)

Thanks,
Sebastien

ROOT 6.10/08 mac os 10.13.4

Hi,

Well, you can already have some online event display with JSROOT, but it requires some coding… See for example this track & hits example and this projection
But no EVE, sorry…

Cheers, Bertrand.

Hi,

Seems to be, EVE requires interactive ROOT session with X11 and OpenGL be available.
The only alternative now in Jupyter notebooks - TGeoManager and just direct drawing of TGeo… classes with JSROOT.

Regards,
Sergey

Hi,
thanks both. So looks like JSROOOT is the only way. Is there a way to get the source code or more explanation on how this event display was coded (essential how do you load and draw TGeo objects in JSROOT) ? This is in fact exactly what I need but with my geometry.
I tried looking at the page source and in JSROOT online help but not so clear.

Otherwise I’ll keep on trying.

Thanks,
Sebastien

Question - do you want to use it inside Jupyter notebooks?
If yes - not all JSROOT functionality will be available for you.

No at this point I would do it in a webpage, which I would call for instance MyEvendDisplay.html. My understanding is that in Jupyter the interactive and 3D interface will not work.

Then you can use all features of JSROOT.
You just need your geometry, stored in ROOT file.
It could be TGeoManager or TGeoNode or TEveGeoShapeExtract.
To display it, you could use <iframe> and insert link like this one:

https://root.cern/js/latest/?nobrowser&file=https://root.cern/files/lhcbfull.root&item=Geometry;1&opt=all;dflt;black

See documentation about different url parameters and iframe usage here

Or you could use custom HTML like shown here:

In last case you just use any of your TGeo classes for the drawing.
For such use case I do not have examples with projections, but I could provide them.

thanks a lot. I’ll start, let you know how it goes and if I need the examples with projections.

Cheers,
Sebastien

Hi Sebastien,

There is a development of EVE as a web based server-client event display. At this stage we are writing demos to define eve element streaming, eve-projections, and server-client protocol.
The new implementation of EVE will build upon JSROOT.

Alya

This is very good news. Indeed if you can inform me when you have a first version that I can try it would be great. I can give you feedback. Thanks

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