ROOT docker with python support?

I recently had a look at the ROOT docker images, because I sometimes like to test the most recent snapshot.

A lot of my code is written using PyROOT, so it would be really nice if the images could be generated with the Python bindings. Then I could start it with something like:

docker pull rootproject/root-ubuntu16:snapshot
docker run -e DISPLAY=$DISPLAY -v /tmp/.X11-unix:/tmp/.X11-unix -v /home/$USER:/userhome -v $(pwd):/cur -w /cur --rm -it --user $(id -u) rootproject/root-ubuntu16:snapshot python

It would be even nicer if something like numpy and root_numpy was installed, but for this I could just derive from the ROOT base image and do it myself, if necessary.


Dear @Graipher,

That’s a very good idea. Although the base image is mostly for testing purposes, it totally makes sense to create a more complete image that people can use for running their scripts and interactive analyses. Please make a list of all the ROOT options and external packages you’d like to have in the full image and I will create a separate image (or just update the current one) with everything in it.


Well, here are the options I usually compile ROOT with:

cmake -D all=ON -Dmathmore=ON -D roofit=ON -D minuit2=ON -D cxx14=ON -D r=ON -D imt=ON

I would say, Python, RooFit and TMVA are probably the most used ones, though.
And then numpy, root_numpy, root_pandas and rootpy would be really nice.

This will probably benefit those people who can’t avoid having to use ROOT on Windows a lot as well.


Ok, thanks! I will update the image to have these options enabled.

@amadio Sweet! Let me know when it landed, then I will give it a go :slight_smile:

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

@Graipher I just pushed a fresh image by hand. I tried to enable as much as possible in ROOT using Ubuntu’s own dependencies, but I did not install some of the extra packages (i.e. pandas) that you requested. The image is already quite big… Let me know what tweaks you think should still be applied. Cheers,

1 Like