Error termination by fortran temp file

Asked by zheng

Hi,

I'm running processes with MG5 as a muon collider for mu+ mu- > tthhvv and sometimes (seems randomly) come across the following error message:

At line 190 of file driver.f (unit = 27, file = '/tmp/gfortrantmpNYVPMI')
Fortran runtime error: Bad address
Error termination. Backtrace
:#0  0x7f3f55d9e32a
#1  0x7f3f55d9eed5
#2  0x7f3f55d9f69d
#3  0x7f3f55f1a8b2
#4  0x7f3f55f199d8
#5  0x555fc8c379eb
#6  0x555fc8c37abc
#7  0x7f3f553fdbf6
#8  0x555fc8c359d9
#9  0xffffffffffffffff
ERROR DETECTED

It seems gfortran cannot find some temp file which is supposed to be generated. Do you have any clue about the cause this error? Thanks!

Yajuan

Question information

Language:
English Edit question
Status:
Answered
For:
MadGraph5_aMC@NLO Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:

This question was reopened

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

Is it possible that your /tmp is not large enough (or too busy because of something else) to store the full file.
This file is written (and then read later) by the script.

If your /tmp is too small, then one option is to ask fortran to use another disk to write such file.
This should be possible via environment variable TMPDIR (but does not seem to always work)

Cheers,

Olivier

> On 13 Jun 2021, at 05:25, zheng <email address hidden> wrote:
>
> New question #697508 on MadGraph5_aMC@NLO:
> https://answers.launchpad.net/mg5amcnlo/+question/697508
>
> Hi,
>
> I'm running processes with MG5 as a muon collider for mu+ mu- > tthhvv and sometimes (seems randomly) come across the following error message:
>
> At line 190 of file driver.f (unit = 27, file = '/tmp/gfortrantmpNYVPMI')
> Fortran runtime error: Bad address
> Error termination. Backtrace
> :#0 0x7f3f55d9e32a
> #1 0x7f3f55d9eed5
> #2 0x7f3f55d9f69d
> #3 0x7f3f55f1a8b2
> #4 0x7f3f55f199d8
> #5 0x555fc8c379eb
> #6 0x555fc8c37abc
> #7 0x7f3f553fdbf6
> #8 0x555fc8c359d9
> #9 0xffffffffffffffff
> ERROR DETECTED
>
> It seems gfortran cannot find some temp file which is supposed to be generated. Do you have any clue about the cause this error? Thanks!
>
> Yajuan
>
>
> --
> You received this question notification because you are an answer
> contact for MadGraph5_aMC@NLO.

Revision history for this message
zheng (yjzheng218) said :
#2

Thanks Olivier Mattelaer, that solved my question.

Revision history for this message
zheng (yjzheng218) said :
#3

Hi Olivier,

This was solved temporarily but the problem come up again when top and higgs decay in MG/ME. I changed the TMPDIR to a disk with 15G free space but sometimes this problem still occurs. The decay works fine in Madspin and I'm just curious that is it possible that the fortran tmp script can require up to 15 G space for a process like this?

Another question is about Madspin. When I let Higgs decays to bb with command

decay h > b b~

I find the output shows the branching ratio of Higgs has an extra ta+ ta- fraction with about 10% like below.

INFO: decay channels for h : ( width = 0.002639483 GeV )
INFO: BR d1 d2
INFO: 9.019702e-01 b~ b
INFO: 9.802980e-02 ta+ ta-

I wonder if ta+ ta- appears to mimic some misidentification in certain detector. Since I'm studying the process in lepton collider, is there any extra settings that I can make h>bb 100%?

Thanks!

Best regards,
Yajuan

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

Hi,

You can force MadSpin to use the Branching ratio of your choice if you specify those in the param_card for All particles that you ask to decay in madspin (so all particles that have line decay X > Y Z). If only one is missing (and even if that particles is not in the process that you decay) then all width will be recomputated at LO and assuming no three body decay.

Cheers,

Olivier

Revision history for this message
zheng (yjzheng218) said :
#5

Hi,

I've tried to change the branching ratio as follows, to let h > b b~ with 100% decay.

set DECAY 25 4.088e-03
set BR 1.000000e+00 2 5 5~ #

but got message ' invalid set command BR 1.000000e+00 2 5 5~". How should I set the branching ratio in the param_cad?

Best regards,
Yajuan

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

Hi,

Note first that MG5aMC does not use that branching ratio information
(other tools does like Madspin or the parton shower)

In those two code (and similar one), you can choose to simulate only b b~ final state and do not need to put fake information in the BR ratio block for that.

So we do not have a set command to hack the value of the BR ratio. If you need to specify those, you typically just pass the path to the param_card computed by a calculator.

Cheers,

Olivier

> On 28 Aug 2021, at 01:55, zheng <email address hidden> wrote:
>
> Question #697508 on MadGraph5_aMC@NLO changed:
> https://answers.launchpad.net/mg5amcnlo/+question/697508
>
> Status: Answered => Open
>
> zheng is still having a problem:
> Hi,
>
> I've tried to change the branching ratio as follows, to let h > b b~
> with 100% decay.
>
> set DECAY 25 4.088e-03
> set BR 1.000000e+00 2 5 5~ #
>
> but got message ' invalid set command BR 1.000000e+00 2 5 5~". How
> should I set the branching ratio in the param_cad?
>
> Best regards,
> Yajuan
>
> --
> You received this question notification because you are an answer
> contact for MadGraph5_aMC@NLO.

Revision history for this message
zheng (yjzheng218) said :
#7

Hi,

Thanks for the very quick response. I'll try a regular decay and pick up demanded final states manually.

I updated python from 2.7 to 3.9 and an error message appears like below when i type ./madspin

except Exception, error:
                    ^
SyntaxError: invalid syntax

How should I fix this ?

Best regards,
Yajuan

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

Which version of MG5aMC are you using?
Try to update to either 2.9.5 or 3.2.0. This will likely fix your issue.
If not please create a bug report with the debug file.

cheers,

Olivier

Revision history for this message
zheng (yjzheng218) said :
#9

I'm using MG5aMC 3.1.1.

Somehow the madspin problem is fixed by modifying

except Exception, error:

to

except Exception as error:

I could run madspin now.

I'll also try to update MG5aMC into the versions you suggested and let you know if similar problem persists.

Best regards,
Yajuan

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

Which file and which line did you change?

Cheers,

Olivier

Revision history for this message
zheng (yjzheng218) said :
#11

I changed the file ‘madspin’ 5 lines below following the error instruction when I try to run ./madspin with python3.9.6.

************************************

line 71
    print "For tab completion and history, install module readline."
          ^
SyntaxError: Missing parentheses in call to 'print'. Did you mean print("For tab completion and history, install module readline.")?

line 102
    print 'Running MG5 in debug mode'
          ^
SyntaxError: Missing parentheses in call to 'print'. Did you mean print('Running MG5 in debug mode')?

 line 133
    print "using input+file", input_file
          ^
SyntaxError: Missing parentheses in call to 'print'. Did you mean print("using input+file", input_file)?

line 161
    except Exception, error:
                    ^
SyntaxError: invalid syntax

line 164
    print 'writting history and quit on KeyboardInterrupt'
          ^
SyntaxError: Missing parentheses in call to 'print'. Did you mean print('writting history and quit on KeyboardInterrupt')?

***************************************

The above errors appear one by one and after I fix all of them, the new error message is

**********
MadSpin works only with python 2.6 or later (but not python 3.X).
               Please upgrate your version of python.
**********

Then I tried to run the modified file ./madspin with python2.7, it started working again. It seems to me python3.9.6 has different syntax from python2.7. Am I doing something dangerous?

Best regards,
Yajuan

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

Thanks, we indeed forget to update that file to make it python2/python3 compatible.
The rest of madspin is known to be python3 compatible.

Cheers,

Olivier

> On 28 Aug 2021, at 05:45, zheng <email address hidden> wrote:
>
> Question #697508 on MadGraph5_aMC@NLO changed:
> https://answers.launchpad.net/mg5amcnlo/+question/697508
>
> Status: Solved => Open
>
> zheng is still having a problem:
> I changed the file ‘madspin’ 5 lines below following the error
> instruction when I try to run ./madspin with python3.9.6.
>
> ************************************
>
> line 71
> print "For tab completion and history, install module readline."
> ^
> SyntaxError: Missing parentheses in call to 'print'. Did you mean print("For tab completion and history, install module readline.")?
>
> line 102
> print 'Running MG5 in debug mode'
> ^
> SyntaxError: Missing parentheses in call to 'print'. Did you mean print('Running MG5 in debug mode')?
>
> line 133
> print "using input+file", input_file
> ^
> SyntaxError: Missing parentheses in call to 'print'. Did you mean print("using input+file", input_file)?
>
> line 161
> except Exception, error:
> ^
> SyntaxError: invalid syntax
>
> line 164
> print 'writting history and quit on KeyboardInterrupt'
> ^
> SyntaxError: Missing parentheses in call to 'print'. Did you mean print('writting history and quit on KeyboardInterrupt')?
>
> ***************************************
>
> The above errors appear one by one and after I fix all of them, the new
> error message is
>
> **********
> MadSpin works only with python 2.6 or later (but not python 3.X).
> Please upgrate your version of python.
> **********
>
> Then I tried to run the modified file ./madspin with python2.7, it
> started working again. It seems to me python3.9.6 has different syntax
> from python2.7. Am I doing something dangerous?
>
> Best regards,
> Yajuan
>
> --
> You received this question notification because you are an answer
> contact for MadGraph5_aMC@NLO.

Revision history for this message
zheng (yjzheng218) said :
#13

Hi,

I'm now with MG5aMC 3.2.0 and the standalone version of madspin still requires python 2. When I decay top and higgs with madspin default settings, the following error message appears:

ERROR: Found a weight MUCH larger than the computed max_weight (ratio: 13.0513763414).     This usually means that the Narrow width approximation reaches it's limit on part of the Phase-Space.    Do not trust too much the tale of the distribution and/or relaunch the code with smaller BW_cut.    This is for channel ('h_bxb', 't_bwp_wp_sxc', 'tx_wmbx_wm_vmxmum') with current BW_value at : 1.10143'

I thought it's BW_cut problem and added 'set BW_cut 15' to rerun, the error still pops up with different numbers:

ERROR: Found a weight MUCH larger than the computed max_weight (ratio: 12.9660811497).
    This usually means that the Narrow width approximation reaches it's limit on part of the Phase-Space.
    Do not trust too much the tale of the distribution and/or relaunch the code with smaller BW_cut.
    This is for channel ('h_bxb', 't_bwp_wp_sxc', 'tx_wmbx_wm_vexem') with current BW_value at : 10.9519'

Should I set a even larger BW_cut or it's caused by some other reasons? Thanks!

Best regards,
Yajuan

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

This typically happens when you have issue with the narrow-width approximation hyppothesis.
we typically advise to reduce BW_cut to avoid large off-shell effects but in your case, you will need to reduce it to 1 to avoid that specific phase-space point so you likely have deeper issue with the narrow-width approximation.

So the answer is likely that MadSpin is not the correct tool in your case.
This is a bit surprising if you are doing SM tt~h obviously. Are you doing BSM? What is the width of the Higgs/top in your model?

Cheers,

Olivier

> On 29 Aug 2021, at 05:20, zheng <email address hidden> wrote:
>
> Question #697508 on MadGraph5_aMC@NLO changed:
> https://answers.launchpad.net/mg5amcnlo/+question/697508
>
> zheng posted a new comment:
> Hi,
>
> I'm now with MG5aMC 3.2.0 and the standalone version of madspin still
> requires python 2. When I decay top and higgs with madspin default
> settings, the following error message appears:
>
> ERROR: Found a weight MUCH larger than the computed max_weight (ratio:
> 13.0513763414). This usually means that the Narrow width
> approximation reaches it's limit on part of the Phase-Space. Do not
> trust too much the tale of the distribution and/or relaunch the code
> with smaller BW_cut. This is for channel ('h_bxb', 't_bwp_wp_sxc',
> 'tx_wmbx_wm_vmxmum') with current BW_value at : 1.10143'
>
> I thought it's BW_cut problem and added 'set BW_cut 15' to rerun, the
> error still pops up with different numbers:
>
> ERROR: Found a weight MUCH larger than the computed max_weight (ratio: 12.9660811497).
> This usually means that the Narrow width approximation reaches it's limit on part of the Phase-Space.
> Do not trust too much the tale of the distribution and/or relaunch the code with smaller BW_cut.
> This is for channel ('h_bxb', 't_bwp_wp_sxc', 'tx_wmbx_wm_vexem') with current BW_value at : 10.9519'
>
> Should I set a even larger BW_cut or it's caused by some other reasons?
> Thanks!
>
> Best regards,
> Yajuan
>
> --
> You received this question notification because you are an answer
> contact for MadGraph5_aMC@NLO.

Can you help with this problem?

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

To post a message you must log in.