Madgraph 3.1.1 Reweighting
Dear experts,
I have tried the following reweighting MGv3.1.1 run:
python3 ./bin/mg5_aMC
generate p p > t t~
output test_dir
launch
reweight=ON
with reweight card
launch --rwgt_name=op1
set mt 150
However, I get the following error:
INFO: Running Reweighting
change mode NLO # Define type of Reweighting. For LO sample this command
WARNING: Missing information for NLO type of reweighting. Keeping the mode to LO.
launch
INFO: detected model: sm. Loading...
INFO: generating the square matrix element for reweighting
INFO: generate p p > t t~ ;
INFO: Done 2.578
Command "generate_events run_01" interrupted with error:
ModuleNotFoundError : No module named 'rw_me.
Please report this bug on https:/
More information is found in '/nfs/scratch2/
Please attach this file to your report.
with run_01_
Traceback (most recent call last):
File "/nfs/scratch2/
from P1_uux_ttx2py import *
ModuleNotFoundE
Please let me know what I am doing wrong here.
Thank you.
Pim
Question information
- Language:
- English Edit question
- Status:
- Answered
- Assignee:
- No assignee Edit question
- Last query:
- Last reply:
Related bugs
Related FAQ:
None Link to a FAQ
Revision history for this message
|
#1 |
Do you have f2py installed and if so does it correspond to your python3 version?
(Or is it python2). You can specify the version of f2py to use within input/mg5_
Cheers,
Olivier
> On 2 Jun 2021, at 17:20, Pim Verschuuren <email address hidden> wrote:
>
> New question #697354 on MadGraph5_aMC@NLO:
> https:/
>
> Dear experts,
>
> I have tried the following reweighting MGv3.1.1 run:
>
> python3 ./bin/mg5_aMC
>
>
> generate p p > t t~
> output test_dir
> launch
> reweight=ON
>
> with reweight card
>
> launch --rwgt_name=op1
> set mt 150
>
> However, I get the following error:
>
> INFO: Running Reweighting
> change mode NLO # Define type of Reweighting. For LO sample this command
> WARNING: Missing information for NLO type of reweighting. Keeping the mode to LO.
> launch
> INFO: detected model: sm. Loading...
> INFO: generating the square matrix element for reweighting
> INFO: generate p p > t t~ ;
> INFO: Done 2.578
> Command "generate_events run_01" interrupted with error:
> ModuleNotFoundError : No module named 'rw_me.
> Please report this bug on https:/
> More information is found in '/nfs/scratch2/
> Please attach this file to your report.
>
> with run_01_
>
> Traceback (most recent call last):
> File "/nfs/scratch2/
> from P1_uux_ttx2py import *
> ModuleNotFoundE
>
> Please let me know what I am doing wrong here.
>
> Thank you.
>
> Pim
>
>
>
> --
> You received this question notification because you are an answer
> contact for MadGraph5_aMC@NLO.
Revision history for this message
|
#2 |
Hi Oliver,
How can I easily check if I have it installed? And if not, how do I install it?
Cheerss,
Pim
Revision history for this message
|
#3 |
which f2py
to see if you have one version install
and to see the associated version you can just type "f2py"
to install it, I typically use pip
via "pip3 install numpy'
and then found where pip install the f2py executable
and add a symbolic link in /usr/bin ponting to that location (or inidicate the full path within the configuration file of mG5aMC)
> On 2 Jun 2021, at 18:05, Pim Verschuuren <email address hidden> wrote:
>
> Question #697354 on MadGraph5_aMC@NLO changed:
> https:/
>
> Pim Verschuuren posted a new comment:
> Hi Oliver,
> How can I easily check if I have it installed? And if not, how do I install it?
> Cheerss,
> Pim
>
> --
> You received this question notification because you are an answer
> contact for MadGraph5_aMC@NLO.
Revision history for this message
|
#4 |
Thanks. I found the link to the f2py installed on our cluster and specified the executable path in the me configuration file of the output directory. However, I get a new error now:
Traceback (most recent call last):
File "/nfs/scratch2/
stop = self.onecmd(line)
File "/nfs/scratch2/
return self.error_
File "/nfs/scratch2/
stop = self.nice_
File "/nfs/scratch2/
stop = cmd.Cmd.
File "/nfs/scratch2/
str(
UnicodeEncodeError: 'ascii' codec can't encode character u'\u2018' in position 23588: ordinal not in range(128)
Revision history for this message
|
#5 |
This is likely related to a compilation error with f2py that raise an error message that can not be handle by python3 due to some unicode formatting handling.
You should have a directory
/nfs/scratch2/
in which you can run
make allmatrix2py.so
this should give the real error
Cheers,
Olivier
> On 2 Jun 2021, at 19:10, Pim Verschuuren <email address hidden> wrote:
>
> UnicodeEncodeError: 'ascii' codec can't encode character
Revision history for this message
|
#6 |
Hi Oliver,
I specified both the f2py and f2py3 compiler in the me_configuration plots.
The previous error was when run with python2. However, I couldnt find allmatrix2py.so in /rw_me/
all_matrix2py.
all_matrix3py.
When I run with python3 I get the following error:
Command "launch" interrupted with error:
MadGraph5Error : A compilation Error occurs when trying to compile /nfs/scratch2/
The compilation fails with the following output message:
/usr/
/usr/
gfortran -w -fPIC -ffixed-
gfortran -w -fPIC -ffixed-
ar cru ../lib//libmatrix.a P1_uux_ttx/matrix.o P1_gg_ttx/matrix.o all_matrix.o
ranlib ../lib//libmatrix.a
/usr/
running build
running config_cc
unifing config_cc, config, build_clib, build_ext, build commands --compiler options
running config_fc
unifing config_fc, config, build_clib, build_ext, build commands --fcompiler options
running build_src
build_src
building extension "P1_gg_ttx2py" sources
f2py options: []
f2py:> /tmp/pverschu/
creating /tmp/pverschu/
running build
running config_cc
unifing config_cc, config, build_clib, build_ext, build commands --compiler options
running config_fc
unifing config_fc, config, build_clib, build_ext, build commands --fcompiler options
running build_src
build_src
building extension "P1_uux_ttx2py" sources
f2py options: []
f2py:> /tmp/pverschu/
creating /tmp/pverschu/
running build
running config_cc
unifing config_cc, config, build_clib, build_ext, build commands --compiler options
running config_fc
unifing config_fc, config, build_clib, build_ext, build commands --fcompiler options
running build_src
build_src
building extension "all_matrix2py" sources
f2py options: []
f2py:> /tmp/pverschu/
creating /tmp/pverschu/
Reading fortran codes...
Reading file 'P1_gg_
Line #56 in P1_gg_ttx/
determine
Line #78 in P1_gg_ttx/
analyzeline: implied-DO list "(beams_
Line #94 in P1_gg_ttx/
analyzeline: implied-DO list "(nhel(i, 1),i=1,4)" is not supported. Skipping.
Line #95 in P1_gg_ttx/
analyzeline: implied-DO list "(nhel(i, 2),i=1,4)" is not supported. Skipping.
Line #96 in P1_gg_ttx/
analyzeline: implied-DO list "(nhel(i, 3),i=1,4)" is not supported. Skipping.
Line #97 in P1_gg_ttx/
analyzeline: implied-DO list "(nhel(i, 4),i=1,4)" is not supported. Skipping.
Line #98 in P1_gg_ttx/
analyzeline: implied-DO list "(nhel(i, 5),i=1,4)" is not supported. Skipping.
Line #99 in P1_gg_ttx/
analyzeline: implied-DO list "(nhel(i, 6),i=1,4)" is not supported. Skipping.
Line #100 in P1_gg_ttx/
analyzeline: implied-DO list "(nhel(i, 7),i=1,4)" is not supported. Skipping.
Line #101 in P1_gg_ttx/
analyzeline: implied-DO list "(nhel(i, 8),i=1,4)" is not supported. Skipping.
Line #102 in P1_gg_ttx/
analyzeline: implied-DO list "(nhel(i, 9),i=1,4)" is not supported. Skipping.
Line #103 in P1_gg_ttx/
analyzeline: implied-DO list "(nhel(i, 10),i=1,4)" is not supported. Skipping.
Line #104 in P1_gg_ttx/
analyzeline: implied-DO list "(nhel(i, 11),i=1,4)" is not supported. Skipping.
Line #105 in P1_gg_ttx/
analyzeline: implied-DO list "(nhel(i, 12),i=1,4)" is not supported. Skipping.
Line #106 in P1_gg_ttx/
analyzeline: implied-DO list "(nhel(i, 13),i=1,4)" is not supported. Skipping.
Line #107 in P1_gg_ttx/
analyzeline: implied-DO list "(nhel(i, 14),i=1,4)" is not supported. Skipping.
Line #108 in P1_gg_ttx/
analyzeline: implied-DO list "(nhel(i, 15),i=1,4)" is not supported. Skipping.
Line #109 in P1_gg_ttx/
analyzeline: implied-DO list "(nhel(i, 16),i=1,4)" is not supported. Skipping.
Line #118 in P1_gg_ttx/
analyzeline: implied-DO list "((polarization
Reading file 'coupl.inc' (format:fix)
Line #240 in P1_gg_ttx/
analyzeline: implied-DO list "(cf(i, 1),i= 1, 2)" is not supported. Skipping.
Line #246 in P1_gg_ttx/
analyzeline: implied-DO list "(cf(i, 2),i= 1, 2)" is not supported. Skipping.
Reading file 'coupl.inc' (format:fix)
Line #312 in P1_gg_ttx/
analyzeline: No name/args pattern found for line.
Post-
Block: P1_gg_ttx2py
Block: m0_smatrixhel
Block: m0_smatrix
Block: m0_matrix
Block: m0_get_value
Block: m0_initialisemodel
Block: m0_is_born_
Post-
Building modules...
Building module "P1_gg_ttx2py"...
Constructing wrapper function "m0_smatrixhel"...
ans = m0_smatrixhel(
Constructing wrapper function "m0_smatrix"...
ans = m0_smatrix(p)
Creating wrapper for Fortran function "m0_matrix"
Constructing wrapper function "m0_matrix"...
m0_matrix = m0_matrix(
Constructing wrapper function "m0_get_value"...
ans = m0_get_
Constructing wrapper function "m0_initialisem
Creating wrapper for Fortran function "m0_is_
Constructing wrapper function "m0_is_
Constructing COMMON block support for "m0_heluserchoi
userhel
Constructing COMMON block support for "m0_process_
nhel
Constructing COMMON block support for "m0_helreset"...
helreset
Constructing COMMON block support for "m0_born_
Constructing COMMON block support for "strong"...
g
Constructing COMMON block support for "weak"...
gal
Constructing COMMON block support for "rscale"...
mu_r
Constructing COMMON block support for "masses"...
Constructing COMMON block support for "widths"...
Constructing COMMON block support for "couplings"...
gc_11
Wrote C/API module "P1_gg_ttx2py" to file "/tmp/pverschu/
Fortran 77 wrappers are saved to "/tmp/pverschu/
adding '/tmp/pverschu/
adding '/tmp/pverschu/
copying /usr/local/
copying /usr/local/
adding '/tmp/pverschu/
build_src: building npy-pkg config files
running build_ext
customize UnixCCompiler
customize UnixCCompiler using build_ext
Reading fortran codes...
Reading file 'all_matrix.f' (format:fix,strict)
Reading file 'coupl.inc' (format:fix)
Line #52 in all_matrix.f:" CALL SETPARA(PATH) !first call to setup the paramaters"
analyzeline: No name/args pattern found for line.
Reading file '../Source/
Reading file '../Source/
Post-
Block: all_matrix2py
Block: smatrixhel
Block: initialise
Block: change_para
Block: update_all_coup
Block: get_pdg_order
Block: get_prefix
Post-
Building modules...
Building module "all_matrix2py"...
Constructing wrapper function "smatrixhel"...
ans = smatrixhel(
Constructing wrapper function "initialise"...
Constructing wrapper function "change_para"...
Constructing wrapper function "update_
Constructing wrapper function "get_pdg_order"...
Constructing wrapper function "get_prefix"...
prefix = get_prefix()
Constructing COMMON block support for "strong"...
g
Constructing COMMON block support for "weak"...
gal
Constructing COMMON block support for "rscale"...
mu_r
Constructing COMMON block support for "masses"...
Constructing COMMON block support for "widths"...
Constructing COMMON block support for "couplings"...
gc_11
Constructing COMMON block support for "m1_helreset"...
Constructing COMMON block support for "params_r"...
Constructing COMMON block support for "params_c"...
Wrote C/API module "all_matrix2py" to file "/tmp/pverschu/
Fortran 77 wrappers are saved to "/tmp/pverschu/
adding '/tmp/pverschu/
adding '/tmp/pverschu/
copying /usr/local/
copying /usr/local/
adding '/tmp/pverschu/
build_src: building npy-pkg config files
running build_ext
customize UnixCCompiler
customize UnixCCompiler using build_ext
get_
customize Gnu95FCompiler
Found executable /usr/bin/gfortran
Reading fortran codes...
Reading file 'P1_uux_
Line #59 in P1_uux_
determine
Line #81 in P1_uux_
analyzeline: implied-DO list "(beams_
Line #97 in P1_uux_
analyzeline: implied-DO list "(nhel(i, 1),i=1,4)" is not supported. Skipping.
Line #98 in P1_uux_
analyzeline: implied-DO list "(nhel(i, 2),i=1,4)" is not supported. Skipping.
Line #99 in P1_uux_
analyzeline: implied-DO list "(nhel(i, 3),i=1,4)" is not supported. Skipping.
Line #100 in P1_uux_
analyzeline: implied-DO list "(nhel(i, 4),i=1,4)" is not supported. Skipping.
Line #101 in P1_uux_
analyzeline: implied-DO list "(nhel(i, 5),i=1,4)" is not supported. Skipping.
Line #102 in P1_uux_
analyzeline: implied-DO list "(nhel(i, 6),i=1,4)" is not supported. Skipping.
Line #103 in P1_uux_
analyzeline: implied-DO list "(nhel(i, 7),i=1,4)" is not supported. Skipping.
Line #104 in P1_uux_
analyzeline: implied-DO list "(nhel(i, 8),i=1,4)" is not supported. Skipping.
Line #105 in P1_uux_
analyzeline: implied-DO list "(nhel(i, 9),i=1,4)" is not supported. Skipping.
Line #106 in P1_uux_
analyzeline: implied-DO list "(nhel(i, 10),i=1,4)" is not supported. Skipping.
Line #107 in P1_uux_
analyzeline: implied-DO list "(nhel(i, 11),i=1,4)" is not supported. Skipping.
Line #108 in P1_uux_
analyzeline: implied-DO list "(nhel(i, 12),i=1,4)" is not supported. Skipping.
Line #109 in P1_uux_
analyzeline: implied-DO list "(nhel(i, 13),i=1,4)" is not supported. Skipping.
Line #110 in P1_uux_
analyzeline: implied-DO list "(nhel(i, 14),i=1,4)" is not supported. Skipping.
Line #111 in P1_uux_
analyzeline: implied-DO list "(nhel(i, 15),i=1,4)" is not supported. Skipping.
Line #112 in P1_uux_
analyzeline: implied-DO list "(nhel(i, 16),i=1,4)" is not supported. Skipping.
Line #121 in P1_uux_
analyzeline: implied-DO list "((polarization
Reading file 'coupl.inc' (format:fix)
Line #246 in P1_uux_
analyzeline: implied-DO list "(cf(i, 1),i= 1, 2)" is not supported. Skipping.
Line #252 in P1_uux_
analyzeline: implied-DO list "(cf(i, 2),i= 1, 2)" is not supported. Skipping.
Reading file 'coupl.inc' (format:fix)
Line #312 in P1_uux_
analyzeline: No name/args pattern found for line.
Post-
Block: P1_uux_ttx2py
Block: m1_smatrixhel
Block: m1_smatrix
Block: m1_matrix
Block: m1_get_value
Block: m1_initialisemodel
Block: m1_is_born_
Post-
Building modules...
Building module "P1_uux_ttx2py"...
Constructing wrapper function "m1_smatrixhel"...
ans = m1_smatrixhel(
Constructing wrapper function "m1_smatrix"...
ans = m1_smatrix(p)
Creating wrapper for Fortran function "m1_matrix"
Constructing wrapper function "m1_matrix"...
m1_matrix = m1_matrix(
Constructing wrapper function "m1_get_value"...
ans = m1_get_
Constructing wrapper function "m1_initialisem
Creating wrapper for Fortran function "m1_is_
Constructing wrapper function "m1_is_
Constructing COMMON block support for "m1_heluserchoi
userhel
Constructing COMMON block support for "m1_process_
nhel
Constructing COMMON block support for "m1_helreset"...
helreset
Constructing COMMON block support for "m1_born_
Constructing COMMON block support for "strong"...
g
Constructing COMMON block support for "weak"...
gal
Constructing COMMON block support for "rscale"...
mu_r
Constructing COMMON block support for "masses"...
Constructing COMMON block support for "widths"...
Constructing COMMON block support for "couplings"...
gc_11
Wrote C/API module "P1_uux_ttx2py" to file "/tmp/pverschu/
Fortran 77 wrappers are saved to "/tmp/pverschu/
adding '/tmp/pverschu/
adding '/tmp/pverschu/
copying /usr/local/
copying /usr/local/
adding '/tmp/pverschu/
build_src: building npy-pkg config files
running build_ext
customize UnixCCompiler
get_
customize Gnu95FCompiler
customize UnixCCompiler using build_ext
Found executable /usr/bin/gfortran
customize Gnu95FCompiler
customize Gnu95FCompiler
get_
customize Gnu95FCompiler
Found executable /usr/bin/gfortran
customize Gnu95FCompiler using build_ext
building 'P1_gg_ttx2py' extension
compiling C sources
C compiler: gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -O2 -g -pipe -Wall -Wp,-D_
creating /tmp/pverschu/
creating /tmp/pverschu/
creating /tmp/pverschu/
creating /tmp/pverschu/
compile options: '-I/tmp/
customize Gnu95FCompiler using build_ext
building 'all_matrix2py' extension
compiling C sources
gcc: /tmp/pverschu/
C compiler: gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -O2 -g -pipe -Wall -Wp,-D_
creating /tmp/pverschu/
creating /tmp/pverschu/
creating /tmp/pverschu/
creating /tmp/pverschu/
compile options: '-I/tmp/
gcc: /tmp/pverschu/
customize Gnu95FCompiler
gcc: /tmp/pverschu/
gcc: /tmp/pverschu/
customize Gnu95FCompiler using build_ext
building 'P1_uux_ttx2py' extension
compiling C sources
C compiler: gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -O2 -g -pipe -Wall -Wp,-D_
creating /tmp/pverschu/
creating /tmp/pverschu/
creating /tmp/pverschu/
creating /tmp/pverschu/
compile options: '-I/tmp/
gcc: /tmp/pverschu/
gcc: /tmp/pverschu/
In file included from /usr/local/
/usr/
#warning "Using deprecated NumPy API, disable it with " \
^
/tmp/
static int f2py_size(
^
In file included from /usr/local/
/usr/
#warning "Using deprecated NumPy API, disable it with " \
^
/tmp/
static int f2py_size(
^
In file included from /usr/local/
/usr/
#warning "Using deprecated NumPy API, disable it with " \
^
/tmp/
static int f2py_size(
^
In file included from /usr/local/
/usr/
#warning "Using deprecated NumPy API, disable it with " \
^
In file included from /usr/local/
/usr/
#warning "Using deprecated NumPy API, disable it with " \
^
compiling Fortran sources
Fortran f77 compiler: gfortran -Wall -g -ffixed-form -fno-second-
Fortran f90 compiler: /usr/bin/gfortran -Wall -g -fno-second-
Fortran fix compiler: /usr/bin/gfortran -Wall -g -ffixed-form -fno-second-
creating /tmp/pverschu/
compile options: '-I/tmp/
In file included from /usr/local/
/usr/
#warning "Using deprecated NumPy API, disable it with " \
^
gfortran:f77: /tmp/pverschu/
gfortran:f77: P1_gg_ttx/matrix.f
compiling Fortran sources
Fortran f77 compiler: gfortran -Wall -g -ffixed-form -fno-second-
Fortran f90 compiler: /usr/bin/gfortran -Wall -g -fno-second-
Fortran fix compiler: /usr/bin/gfortran -Wall -g -ffixed-form -fno-second-
creating /tmp/pverschu/
compile options: '-I/tmp/
compiling Fortran sources
Fortran f77 compiler: gfortran -Wall -g -ffixed-form -fno-second-
Fortran f90 compiler: /usr/bin/gfortran -Wall -g -fno-second-
Fortran fix compiler: /usr/bin/gfortran -Wall -g -ffixed-form -fno-second-
compile options: '-I/tmp/
gfortran:f77: /tmp/pverschu/
gfortran:f77: /tmp/pverschu/
gfortran:f77: P1_uux_ttx/matrix.f
gfortran:f77: all_matrix.f
P1_
CALL VVV1P0_
Error: Symbol 'gc_10' at (1) has no IMPLICIT type
P1_
Warning: Possible change of value in conversion from COMPLEX(8) to REAL(8) at (1)
all_
Warning: Unused dummy argument 'npdg' at (1)
all_
Warning: Unused dummy argument 'scale2' at (1)
P1_
Warning: Possible change of value in conversion from COMPLEX(8) to REAL(8) at (1)
P1_
Warning: Unused variable 'tmp_jamp' declared at (1)
error: Command "gfortran -Wall -g -ffixed-form -fno-second-
/usr/
make: *** [P1_gg_ttx2py.so] Error 1
make: *** Waiting for unfinished jobs....
/usr/
updatevars
updatevars:p: attempt to change 'dimension(
analyzevars: character array "character*20 prefix(4)" is considered as "character prefix(4,20)"; "intent(c)" is forced.
analyzevars: character array "character*20 pref(4)" is considered as "character pref(4,20)"; "intent(c)" is forced.
Removing build directory /tmp/pverschu/
Removing build directory /tmp/pverschu/
Please try to fix this compilations issue and retry.
Help might be found at https:/
If you think that this is a bug, you can report this at https:/
Please report this bug on https:/
More information is found in '/nfs/scratch2/
Please attach this file to your report.
Thank you
Revision history for this message
|
#7 |
Please try to apply the patch associated to the above bug report looks like you face the exact same issue here.
Cheers,
Olivier
Revision history for this message
|
#8 |
Hm I applied the advised patch but now the error reverts back to the one posted in my first message. Even if I have f2py path specified in the me_configuration file
Cheers
Can you help with this problem?
Provide an answer of your own, or ask Pim Verschuuren for more information if necessary.