Hello,
Whenever I try and use import ROOT in python I get the following error:
python /home/thomasaur/Documents/Work/Thesis/Data/ColliderSimulation/LHC1/test.py
ERROR in cling::CIFactory::createCI():
resource directory /home/thomasaur/Downloads/pythia8303/etc//cling/lib/clang/9.0.1 not found!
fatal error: module map file 'lib/clang/9.0.1/include/module.modulemap' not found
Module libc not found.
Module std not found.
Module _Builtin_intrinsics not found.
input_line_5:1:10: fatal error: 'cling/Interpreter/DynamicLookupRuntimeUniverse.h' file not found
#include "cling/Interpreter/DynamicLookupRuntimeUniverse.h"
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
fatal error: module map file 'lib/clang/9.0.1/include/module.modulemap' not found
Module libc not found.
Module std not found.
Module _Builtin_intrinsics not found.
input_line_5:1:10: fatal error: 'cling/Interpreter/DynamicLookupRuntimeUniverse.h' file not found
#include "cling/Interpreter/DynamicLookupRuntimeUniverse.h"
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Very curious. Where does your ROOT installation come from? Which platform is this? Which version of ROOT? How do you set up ROOT such that python can find it?
Thanks for the reply.
ROOT was installed via conda on ubuntu 20.04, and the script was run in its environment.
Also I would like to note that, “root-config --has-pyroot” returns “yes”
Hi,
the conda package sets $ROOTSYS (I don’t know if it’s out of “kindness” or it’s really needed for something to work properly).
I have never seen this, but to me it looks like there is something in @Tmikhail 's environment that confuses cling. Maybe a system-wide ROOT installation? Maybe some env variable that points to the pythia installation at /home/thomasaur/Downloads/pythia8303?
Can you reproduce this in a Docker container or anywhere else, or if you remove that pythia8303 directory?