Failed mg5amc_py8_interface installation - specific Py8 version

Asked by Maura Barros

Hello all,

I am using MG 2.6.5 and I am trying to install Pythia8 version 8.243. I need to have these two versions to cross-check the results. However, I am having some problems.

I first installed Py8 locally on my computer and I linked it to MG giving the path to the Py8 directory on the input/mg5_configuration.txt file. But, when trying to install the mg5amc_py8_interface I get

The version of HEPMC2 linked to Pythia8 seems not to include a static library.
This is necessary for the default compilation of MG5aMC_PY8_interface.
You can try again with the option --pythia8_makefile but HEPMC2 will need to be available at runtime.

I then tried to re-installed Py8 with the MG hepmc linked to it. However, I got the same error. I am using hepmc version 2.06.09. After checking some questions here at the launchpad, I tried a fresh installation and instead of using Py8 local installation, I installed it inside MG:

install pythia8 --pythia8_tarball=/storage/Maura/ML/AD/SignalGen/installations/pythia8243.tgz

But I also get an error:

Connecting to madgraph.phys.ucl.ac.be (madgraph.phys.ucl.ac.be)|130.104.1.243|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 19542 (19K) [application/x-gzip]
Saving to: ‘MG5aMC_PY8_interface_V1.3.tar.gz’

MG5aMC_PY8_interface_V1.3.tar.gz 100%[========================================================================================>] 19,08K --.-KB/s in 0,05s

2024-03-13 09:46:11 (379 KB/s) - ‘MG5aMC_PY8_interface_V1.3.tar.gz’ saved [19542/19542]

Installing tool 'mg5amc_py8_interface'...
    > Follow the installation progress by running the command below in a separate terminal)
    > tail -f /storage/Maura/ML/AD/SignalGen/FreshInstallation_12032024/MG5_aMC_v2_6_5/HEPTools/MG5aMC_PY8_interface/mg5amc_py8_interface_install.log
A problem occured during the installation of 'mg5amc_py8_interface'.
Content of the installation log file '/storage/Maura/ML/AD/SignalGen/FreshInstallation_12032024/MG5_aMC_v2_6_5/HEPTools/MG5aMC_PY8_interface/mg5amc_py8_interface_install.log':

------------------------------------------------
MG5aMC_PY8_interface compilation output log:
g++ MG5aMC_PY8_interface.cc -o MG5aMC_PY8_interface /storage/Maura/ML/AD/SignalGen/FreshInstallation_12032024/MG5_aMC_v2_6_5/HEPTools/hepmc/include -I/storage/Maura/ML/AD/SignalGen/FreshInstallation_12032024/MG5_aMC_v2_6_5/HEPTools/pythia8//include -ldl -fPIC -lstdc++ -std=c++11 -O2 -DHEPMC2HACK -L/storage/Maura/ML/AD/SignalGen/FreshInstallation_12032024/MG5_aMC_v2_6_5/HEPTools/pythia8//lib -Wl,-rpath,/storage/Maura/ML/AD/SignalGen/FreshInstallation_12032024/MG5_aMC_v2_6_5/HEPTools/pythia8//lib -lpythia8 -ldl /storage/Maura/ML/AD/SignalGen/FreshInstallation_12032024/MG5_aMC_v2_6_5/HEPTools/hepmc/lib
In file included from MG5aMC_PY8_interface.cc:11:
/storage/Maura/ML/AD/SignalGen/FreshInstallation_12032024/MG5_aMC_v2_6_5/HEPTools/pythia8//include/Pythia8Plugins/HepMC2.h:17:10: fatal error: HepMC/IO_BaseClass.h: No such file or directory
   17 | #include "HepMC/IO_BaseClass.h"
      | ^~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
make: *** [Makefile_mg5amc_py8_interface_static:8: MG5aMC_PY8_interface] Error 1

------------------------------------------------
Error during the compilation of MG5aMC_PY8_interface:
g++ MG5aMC_PY8_interface.cc -o MG5aMC_PY8_interface /storage/Maura/ML/AD/SignalGen/FreshInstallation_12032024/MG5_aMC_v2_6_5/HEPTools/hepmc/include -I/storage/Maura/ML/AD/SignalGen/FreshInstallation_12032024/MG5_aMC_v2_6_5/HEPTools/pythia8//include -ldl -fPIC -lstdc++ -std=c++11 -O2 -DHEPMC2HACK -L/storage/Maura/ML/AD/SignalGen/FreshInstallation_12032024/MG5_aMC_v2_6_5/HEPTools/pythia8//lib -Wl,-rpath,/storage/Maura/ML/AD/SignalGen/FreshInstallation_12032024/MG5_aMC_v2_6_5/HEPTools/pythia8//lib -lpythia8 -ldl /storage/Maura/ML/AD/SignalGen/FreshInstallation_12032024/MG5_aMC_v2_6_5/HEPTools/hepmc/lib
In file included from MG5aMC_PY8_interface.cc:11:
/storage/Maura/ML/AD/SignalGen/FreshInstallation_12032024/MG5_aMC_v2_6_5/HEPTools/pythia8//include/Pythia8Plugins/HepMC2.h:17:10: fatal error: HepMC/IO_BaseClass.h: No such file or directory
   17 | #include "HepMC/IO_BaseClass.h"
      | ^~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
make: *** [Makefile_mg5amc_py8_interface_static:8: MG5aMC_PY8_interface] Error 1

I saw in other questions that the problem was solved by using this command but I don't manage to have it working. Do you have any solution for this?

Thank you!
Maura

Question information

Language:
English Edit question
Status:
Answered
For:
MadGraph5_aMC@NLO Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
Olivier Mattelaer (olivier-mattelaer) said :
#1

Hi,

2.6.5 version is not supported anymore (since many many years). One side effect is that the install command is not maintained for that version (and the install command is not shipped with the code). In particular I would expect that the command "install mg5amc_py8_interface" is now trying to install a version of "mg5amc_py8_interface" which assumes some recent version of pythia8. Since pythia8 API changed between that time and now, I do not think that it is possible to have pythia8 to be working both for LO and NLO part of the code (at least not if you use the install command which will assume the modern API).

So the first question is that are you trying to use pythia8 for LO or for NLO?

If this is for NLO, you do not need mg5amc_py8_interface and you will need the old PY8 API (which is used in Pythia8.2) to have it working at NLO.

If this is LO, then you need the mg5amc_py8_interface but you can not use the one coming from the install command since that one will assume the new API.
In that case, my suggestion would be to use this version of the interface:
https://bazaar.launchpad.net/~maddevelopers/mg5amcnlo/MG5aMC_PY8_interface/revision/42
(you do have a download tarball information if you do not want to use breezy) and likely to install it by hand.

Concerning the first error that you face, the corresponding code is here:
https://github.com/mg5amcnlo/MG5aMC_PY8_interface/blob/89e862c724bb89c40b2ab5b23ff7a66732a53da5/compile.py#L149
So this means that the file:
YOUR_PY*_PATH/share/Pythia8/examples/Makefile.inc
does not have the expected information for HEPMC

Concerning the second HepMC error, it seems to me that your code is missing a "-I" when compiling the code.
The compilation of that code is based on the pythia8 file YOUR_PY*_PATH/share/Pythia8/examples/Makefile.inc
So this might be specific to the version of py8 that you are looking at, in any case I would advise to check/edit that file if you still have such type of linking issue when compiling the old version of the interface.

Cheers,

Olivier

Revision history for this message
Maura Barros (maurabarros) said :
#2

Hi Olivier,

Thanks for your reply! I will need to use it for both LO and NLO so I will need the interface.

Can you give me further instructions on installing the interface by hand? I had already downloaded version 1.0 of the mg5amc_py8_interface but I don't know how to install it.

Okay, thank you! I will check and if this problem persists with the older version of the interface I will try to edit the file.

Cheers,
Maura

Revision history for this message
Olivier Mattelaer (olivier-mattelaer) said :
#3

In principle, you only need to run the script
python compile.py ~/Pythia/pythia8201
and chand the place where pythia8 is installed obviously.

If needed you can obviously changed the script compile.py itself.

Cheers,

Olivier

Revision history for this message
Maura Barros (maurabarros) said :
#4

Great! Thanks! I will give it a try and let you know as soon as possible.

Cheers,
Maura

Revision history for this message
Maura Barros (maurabarros) said :
#5

Installing the interface by hand with your instructions worked! The HepMC error did not appear.

Thanks a lot for your help!

Cheers,
Maura

Can you help with this problem?

Provide an answer of your own, or ask Maura Barros for more information if necessary.

To post a message you must log in.