Cannot convert CHARACTER(1) to REAL(8) at (1)

Asked by matteo maltoni on 2021-04-27

Dear Madgraph experts,

I've implemented two cuts for the process (pp>l+ vl a NP=2 [QCD]) at fixed order LO, with the model SMEFTatNLO. I added the run_card lines

70.0 = mt_w_min ! Min transv. mass for the W boson
0.7 = dral ! Min distance between photon and lepton

and defined the two parameters as real*8 in the cuts.inc file, but when I launch the generation, I get the following error:

Command "launch auto " interrupted with error:
MadGraph5Error : A compilation Error occurs when trying to compile /home/matteo/Scrivania/MG5_aMC_v3_1_0/bin/pp_w_eva/fixed_order_LO/Source.
 The compilation fails with the following output message:
     gfortran -O -fno-automatic -ffixed-line-length-132 -c -o setrun.o setrun.f
     run_card.inc:163:13:

       163 | DRAL = ' 0.7 '
           | 1
     Error: Cannot convert CHARACTER(1) to REAL(8) at (1)
     make: *** [makefile:35: setrun.o] Errore 1

 Please try to fix this compilations issue and retry.
 Help might be found at https://answers.launchpad.net/mg5amcnlo.
 If you think that this is a bug, you can report this at https://bugs.launchpad.net/mg5amcnlo
Please report this bug on https://bugs.launchpad.net/mg5amcnlo
More information is found in '/home/matteo/Scrivania/MG5_aMC_v3_1_0/bin/pp_w_eva/fixed_order_LO/run_06_LO_tag_1_debug.log'.
Please attach this file to your report.

Please note that the error occurs for the second parameter only.
I already added the line

self.add_param("dral", 0.0, True)

both to madgraph/various/banner.py and fixed_order_LO/bin/internal/banner.py, but with no improvements.
What can I do to fix this?

Best,

Matteo

P.S. I saw other questions about the same issue, but I didn't find any solution in there.

Question information

Language:
English Edit question
Status:
Solved
For:
MadGraph5_aMC@NLO Edit question
Assignee:
No assignee Edit question
Solved by:
Olivier Mattelaer
Solved:
Last query:
Last reply:
Manfred Hampl (m-hampl) said : #1

remove the quotes

Hi,

It's not me putting the quotes around the DRAL value in the run_card.dat, but it's madgraph adding them authomatically in the run_card.inc file.

How can I fix this? Maybe modifying the banner.py files?

Best,

Matteo

According to add_param definition
> def add_param(self, name, value, fortran_name=None, include=True,
> hidden=False, legacy=False, cut=False, system=False, sys_default=None,
> **opts):
> """ add a parameter to the card. value is the default value and
> defines the type (int/float/bool/str) of the input.
> fortran_name defines what is the associate name in the f77 code
> include defines if we have to put the value in the include file
> hidden defines if the parameter is expected to be define by the user.
> legacy:Parameter which is not used anymore (raise a warning if not default)
> cut: defines the list of cut parameter to allow to set them all to off.
> sys_default: default used if the parameter is not in the card
>
> options of **opts:
> - allowed: list of valid options. '*' means anything else should be allowed.
> empty list means anything possible as well.
> - comment: add comment for writing/help
> - typelist: type of the list if default is empty
> """

The first optional parameter (third argument) is fortran_name:
and the comment specifies:
> fortran_name defines what is the associate name in the f77 code

So I do not understand why you set that parameter to True.
Can you try with just
self.add_param("dral", 0.0)

Cheers,

Olivier

> On 27 Apr 2021, at 13:15, Manfred Hampl <email address hidden> wrote:
>
> Question #696780 on MadGraph5_aMC@NLO changed:
> https://answers.launchpad.net/mg5amcnlo/+question/696780
>
> Status: Open => Answered
>
> Manfred Hampl proposed the following answer:
> remove the quotes
>
> --
> You received this question notification because you are an answer
> contact for MadGraph5_aMC@NLO.

Hi Olivier,

Thank you for your answer.
I tried with

self.add_param("dral", 0.0)

in both the banner.py files, at line 1514, but I'm still getting the same error.

But line 1514 in which class is this?
This seems to be the proc_characterisitic file (that is an hidden file with some metadata)
and not the run_card.dat (for NLO run)
This should be around line 4155

Cheers,

Olivier

> On 27 Apr 2021, at 22:20, matteo maltoni <email address hidden> wrote:
>
> Question #696780 on MadGraph5_aMC@NLO changed:
> https://answers.launchpad.net/mg5amcnlo/+question/696780
>
> Status: Answered => Open
>
> matteo maltoni is still having a problem:
> Hi Olivier,
>
> Thank you for your answer.
> I tried with
>
> self.add_param("dral", 0.0)
>
> in both the banner.py files, at line 1514, but I'm still getting the
> same error.
>
> --
> You received this question notification because you are an answer
> contact for MadGraph5_aMC@NLO.

Hi Olivier,

Thanks again for the tip, I don't get the error anymore!

However, this new one occurs, for the same process (pp>l+ vl a NP=2 [QCD]), when I launch the fixed order computation:

INFO: Using 8 cores
INFO: Cleaning previous results
INFO: Doing fixed order LO
INFO: Setting up grids
WARNING: program /home/matteo/Scrivania/MG5_aMC_v3_1_0/bin/pp_w_eva/fixed_order_LO/SubProcesses/P0_dxu_veepa/ajob1 1 born 0 0 launch ends with non zero status: 1. Stop all computation
INFO: Idle: 0, Running: 0, Completed: 2 [ current time: 11h03 ]
Command "launch auto " interrupted with error:
Exception : program /home/matteo/Scrivania/MG5_aMC_v3_1_0/bin/pp_w_eva/fixed_order_LO/SubProcesses/P0_dxu_veepa/ajob1 1 born 0 0 launch ends with non zero status: 1. Stop all computation
Please report this bug on https://bugs.launchpad.net/mg5amcnlo
More information is found in '/home/matteo/Scrivania/MG5_aMC_v3_1_0/bin/pp_w_eva/fixed_order_LO/run_07_LO_tag_1_debug.log'.
Please attach this file to your report.
INFO:
quit

It doesn't seem to be related to the previous error, do you know where it is coming from?

Cheers,

Matteo

This is likely an issue that the phase-space integrator crash since it fails to find points passing your cuts.

You should look at the log of the fortran file in
Subprocesses/P0dxu_veepa/G??????/
This should confirm that hint.

Cheers,

Olivier

> On 28 Apr 2021, at 11:11, matteo maltoni <email address hidden> wrote:
>
> Question #696780 on MadGraph5_aMC@NLO changed:
> https://answers.launchpad.net/mg5amcnlo/+question/696780
>
> Status: Answered => Open
>
> matteo maltoni is still having a problem:
> Hi Olivier,
>
> Thanks again for the tip, I don't get the error anymore!
>
> However, this new one occurs, for the same process (pp>l+ vl a NP=2
> [QCD]), when I launch the fixed order computation:
>
> INFO: Using 8 cores
> INFO: Cleaning previous results
> INFO: Doing fixed order LO
> INFO: Setting up grids
> WARNING: program /home/matteo/Scrivania/MG5_aMC_v3_1_0/bin/pp_w_eva/fixed_order_LO/SubProcesses/P0_dxu_veepa/ajob1 1 born 0 0 launch ends with non zero status: 1. Stop all computation
> INFO: Idle: 0, Running: 0, Completed: 2 [ current time: 11h03 ]
> Command "launch auto " interrupted with error:
> Exception : program /home/matteo/Scrivania/MG5_aMC_v3_1_0/bin/pp_w_eva/fixed_order_LO/SubProcesses/P0_dxu_veepa/ajob1 1 born 0 0 launch ends with non zero status: 1. Stop all computation
> Please report this bug on https://bugs.launchpad.net/mg5amcnlo
> More information is found in '/home/matteo/Scrivania/MG5_aMC_v3_1_0/bin/pp_w_eva/fixed_order_LO/run_07_LO_tag_1_debug.log'.
> Please attach this file to your report.
> INFO:
> quit
>
> It doesn't seem to be related to the previous error, do you know where
> it is coming from?
>
> Cheers,
>
> Matteo
>
> --
> You received this question notification because you are an answer
> contact for MadGraph5_aMC@NLO.

Thanks Olivier Mattelaer, that solved my question.