Delphes usage and External LHE file

Asked by Altan

Dear all,

since I tried to use the new version mg5, I face of a couple of problems in the following topics:

1. Installation of Delphes: it works smoothly with using "./bin/mg5" script together withmg5> install Delphes but I am not able to use Delphes any production since it could not find from the main script. I have changed (as explained in README) Cards/me5_configuration.txt for te delphes flag but when I execute

./bin/generate_events OR ./bin/newprocess_mg5 I do not see any flag for delphes run.

2. I also would like to learn how to include an external lhe file to the pythia interface + delphes.

Thanks in advance,
cheers, Altan.

Question information

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

Hi Altan,

>1. Installation of Delphes: it works smoothly with using "./bin/mg5" script together withmg5> install Delphes but I am not able to >use Delphes any production since it could not find from the main script. I have changed (as explained in README) >Cards/me5_configuration.txt for te delphes flag but when I execute

Did you install pythia-pgs? in order to run Delphes you need to have pythia installed.
(and correctly linked as well in the Cards/me5_configuration.txt)

> 2. I also would like to learn how to include an external lhe file to the pythia interface + delphes.

If the lhe file are not created by MG, I would advise to use those programs as standalone. (since some information required might be absent of the banner.)

Otherwise, one way of doing it is to put your lhe file exactly as MG5 would have done it.
i.e. put your lhe file in a copy of the Template directory in the directory:
Events/run_01/unweighted_events.lhe.gz
(it should be gzip!)

then you can do, as for a normal run (when to want to start at pythia level):
./bin/madevent
pythia run_01

MG will recognize that you cheat, (a warning will be printed) but will not try to find what are the number of events/cross-section,
so don't worry if you have:
  === Results Summary for run: run_01 tag: tag_1 ===

     Cross-section : 0 +- 0 pb
     Nb of events : 0

Cheers,

Olivier

Revision history for this message
Altan (cakir) said :
#2

Dear Oliver,

first of all I would like to thank you for your quick response and help.

Delphes part is now working but I have some problems for the external lhe file run. I used the file, which was simulated by Madgraph (version 5.1.3.30), from CMS Collaboration database. It complains with the following error:

finish
syntax: pgs [RUN] [--run_options]
-- run pgs on RUN (current one by default)
-- local options:
      -f : answer all question by default
      --tag= : define the tag for the pgs run
      --no_default : not run if pgs_card not present
-- session options:
      Note that those options will be kept for the current session
      --cluster : Submit to the cluster. Current cluster: condor
      --multicore : Run in multi-core configuration
      --nb_core=X : limit the number of core to use to X.
Command "pythia run_01" interrupted with error:
InvalidCmd : No file file pythia_events.hep currently available
             Please specify a valid run_name

Either it does not understand the cheat or the file is somehow different. I check the event by event here is interesting event information from both file.

Standard event from Madgraph standalone (for example):
5 1 0.6197400E+00 0.8081501E+02 0.7957747E-01 0.1325389E+00
       -2 -1 0 0 0 501 0.00000000000E+00 0.00000000000E+00 0.15411272711E+03 0.15411272711E+03 0.00000000000E+00 0. 1.
        1 -1 0 0 501 0 0.00000000000E+00 0.00000000000E+00 -0.10594623383E+02 0.10594623383E+02 0.00000000000E+00 0. -1.
      -24 2 1 2 0 0 0.00000000000E+00 0.00000000000E+00 0.14351810373E+03 0.16470735050E+03 0.80815006088E+02 0. 0.
       11 1 3 3 0 0 0.33232153565E+02 0.19765022334E+02 0.47840118472E+02 0.61511861246E+02 0.00000000000E+00 0. -1.
      -12 1 3 3 0 0 -0.33232153565E+02 -0.19765022334E+02 0.95677985259E+02 0.10319548925E+03 0.00000000000E+00 0. 1.

An event from LHE file in the CMS database

<event>
 12 0 4.9050000E-03 2.4888230E+02 7.9577470E-02 1.1213970E-01
      21 -1 0 0 501 502 0.00000000000E+00 0.00000000000E+00 1.21716550650E+02 1.21716550650E+02 0.00000000000E+00 0.0000E+00 1.0
      21 -1 0 0 502 503 0.00000000000E+00 0.00000000000E+00 -5.12740926210E+02 5.12740926210E+02 0.00000000000E+00 0.0000E+00 -1.0
       6 2 1 2 501 0 1.77757128810E+02 -2.42606021490E+01 -1.68081508720E+02 3.00322855000E+02 1.72500000000E+02 0.0000E+00 1.0
      -6 2 1 2 0 503 -1.77757128810E+02 2.42606021490E+01 -2.22942866830E+02 3.34134621870E+02 1.72500000000E+02 0.0000E+00 -1.0
       5 1 3 3 501 0 1.07940636090E+02 3.86138958430E+00 -1.55708226270E+01 1.09126265240E+02 0.00000000000E+00 0.0000E+00 -1.0
      24 2 3 3 0 0 6.98164927230E+01 -2.81219917330E+01 -1.52510686093E+02 1.91196589758E+02 8.73580991510E+01 0.0000E+00 9.0
      16 1 6 6 0 0 5.67694076165E+01 1.61002671886E+00 -1.47805203059E+02 1.58340569275E+02 0.00000000000E+00 0.0000E+00 -1.0
     -15 1 6 6 0 0 1.30470851065E+01 -2.97320184519E+01 -4.70548303469E+00 3.28560204829E+01 1.77684000000E+00 0.0000E+00 1.0
      -5 1 4 4 0 503 -1.17761559290E+02 -7.08125803990E+00 -4.22233472760E+01 1.25302594220E+02 0.00000000000E+00 0.0000E+00 1.0
     -24 2 4 4 0 0 -5.99955695176E+01 3.13418601890E+01 -1.80719519557E+02 2.08832027656E+02 7.98090876039E+01 0.0000E+00 9.0
       3 1 10 10 504 0 -6.69491482660E+00 1.87912425910E+01 5.26502530310E-02 1.99483195960E+01 0.00000000000E+00 0.0000E+00 -1.0
      -4 1 10 10 0 504 -5.33006546910E+01 1.25506175980E+01 -1.80772169810E+02 1.88883708060E+02 0.00000000000E+00 0.0000E+00 1.0
# 0.2488823E+03 0.2488823E+03

as it is understood, there are more entries in this file. I am not sure whether is possible to include this file or not or is this a problem. it might be already known fact, if so, I am sorry for asking but I thought that it is much better to use ready samples for checking a couple of distributions.

Thanks in advance,
sincerely, Altan.

Revision history for this message
Altan (cakir) said :
#3

sorry for confusing above, here is again:

Madgraph standalone

<event>
 6 2 0.6197400E+00 0.8658260E+02 0.7957747E-01 0.1310775E+00
       21 -1 0 0 501 502 0.00000000000E+00 0.00000000000E+00 0.19844169183E+03 0.19844169183E+03 0.00000000000E+00 0. 1.
       -2 -1 0 0 0 501 0.00000000000E+00 0.00000000000E+00 -0.32770472413E+02 0.32770472413E+02 0.00000000000E+00 0. 1.
      -24 2 1 2 0 0 -0.16668076232E+01 0.32638257033E+02 0.29957118509E+02 0.91618642706E+02 0.80178006162E+02 0. 0.
       11 1 3 3 0 0 -0.17299990374E+02 -0.16719627671E+02 0.31722614033E+02 0.39814066075E+02 0.00000000000E+00 0. -1.
      -12 1 3 3 0 0 0.15633182750E+02 0.49357884704E+02 -0.17654955238E+01 0.51804576630E+02 0.00000000000E+00 0. 1.
       -1 1 1 2 0 502 0.16668076232E+01 -0.32638257033E+02 0.13571410091E+03 0.13959352154E+03 0.00000000000E+00 0. 1.
</event>

==========================================================================

from CMS database

<event>
 12 0 4.9050000E-03 2.4888230E+02 7.9577470E-02 1.1213970E-01
      21 -1 0 0 501 502 0.00000000000E+00 0.00000000000E+00 1.21716550650E+02 1.21716550650E+02 0.00000000000E+00 0.0000E+00 1.0
      21 -1 0 0 502 503 0.00000000000E+00 0.00000000000E+00 -5.12740926210E+02 5.12740926210E+02 0.00000000000E+00 0.0000E+00 -1.0
       6 2 1 2 501 0 1.77757128810E+02 -2.42606021490E+01 -1.68081508720E+02 3.00322855000E+02 1.72500000000E+02 0.0000E+00 1.0
      -6 2 1 2 0 503 -1.77757128810E+02 2.42606021490E+01 -2.22942866830E+02 3.34134621870E+02 1.72500000000E+02 0.0000E+00 -1.0
       5 1 3 3 501 0 1.07940636090E+02 3.86138958430E+00 -1.55708226270E+01 1.09126265240E+02 0.00000000000E+00 0.0000E+00 -1.0
      24 2 3 3 0 0 6.98164927230E+01 -2.81219917330E+01 -1.52510686093E+02 1.91196589758E+02 8.73580991510E+01 0.0000E+00 9.0
      16 1 6 6 0 0 5.67694076165E+01 1.61002671886E+00 -1.47805203059E+02 1.58340569275E+02 0.00000000000E+00 0.0000E+00 -1.0
     -15 1 6 6 0 0 1.30470851065E+01 -2.97320184519E+01 -4.70548303469E+00 3.28560204829E+01 1.77684000000E+00 0.0000E+00 1.0
      -5 1 4 4 0 503 -1.17761559290E+02 -7.08125803990E+00 -4.22233472760E+01 1.25302594220E+02 0.00000000000E+00 0.0000E+00 1.0
     -24 2 4 4 0 0 -5.99955695176E+01 3.13418601890E+01 -1.80719519557E+02 2.08832027656E+02 7.98090876039E+01 0.0000E+00 9.0
       3 1 10 10 504 0 -6.69491482660E+00 1.87912425910E+01 5.26502530310E-02 1.99483195960E+01 0.00000000000E+00 0.0000E+00 -1.0
      -4 1 10 10 0 504 -5.33006546910E+01 1.25506175980E+01 -1.80772169810E+02 1.88883708060E+02 0.00000000000E+00 0.0000E+00 1.0
# 0.2488823E+03 0.2488823E+03

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

Hi Altan,

The main difference is off course that, the processus in the two files are different.
Also the CMS file is clearly generate with icckw=1 since it contains tags for passing matching information to pythia6.

I think that your problem is that you try to run Delphes/pgs but didn't run pythia first.
Is this True?

Cheers,

Olivier

Revision history for this message
Altan (cakir) said :
#5

Hi Oliver,

infact I also ran pythia in addition to the delpes/pgs run. The error is still there.

what I did is the following:

I copied Template dir to MyRunDir
I copied external_lhefile as unweighted_events.lhe.gz in the run_01 directory and then

./bin/madevent
> pythia run_01
> 1 (for pythia run)

and then I got the same error which I mentioned before. I have no idea whether I do something wrong or not. On the other hand, I am able to run the whole processes internally.

Thanks for your all helps,
sincerely, Altan.

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

Copy the template is probably not enough, since some python file are not in the Template but put in place with the "output" command.

Personally I did:

./bin/mg5
generate p p > e+ e-
output MYRUN
exit

then put the file in place and do exactly as you did.

Cheers,

Olivier

Revision history for this message
Altan (cakir) said :
#7

Dear Oliver,

I also tried that one before and there is, unfortunately, still the same error.

Have you ever tried to run over these samples (CMS or any other specific) in MG internally? Since I am able to include LHEF file if I produced MG internally and put one another directory (like we discussed above). However, it does not work with the CMS specific one. I am going to check with one another LHE file from CMS database. In addition to that Is it possible to something related to the matching flag in pythia card? I checked but I am not sure that default card has enough information to handle this LHE file from CMS?

I checked Pythia log and it says in the following:

Initiating pythia with external process
1****************** PYINIT: initialization of PYTHIA routines *****************
 Reading model: ^@^@^@^@^@^@^@^@
     IMSS(21) changed from 0 to 24
     IMSS(22) changed from 0 to 24
  Failed to read LHEF initialization information.

That is clearly say that it is not able to read the file. It is somehow file related issue I believe. What do you think?

Thanks for your all helps,
Cheers, Altan.

Revision history for this message
Altan (cakir) said :
#8

Dear Oliver,

I figure it out the problem which is mostly the cms specific issue. Therefore, thanks a lot for your kind helps so far. I managed to get a proper from mg together with lhe file from cms.

Sincerely, Altan.

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

Great Excellent,

Could you comment on what the problem was and how you resolve it?
This might help other people.

Thanks,

Olivier